lib/emarsys/api/services.rb in emarsys-api-0.6.1 vs lib/emarsys/api/services.rb in emarsys-api-0.7.0

- old
+ new

@@ -16,9 +16,17 @@ validate_response! response response.body end + def flippers(customer_id) + response = client.get("customers/#{customer_id}/flippers") + validate_response!(response) + + response.body['flippers'].each_with_object({}) do |flipper, flippers| + flippers[flipper['id']] = flipper['is_on'] + end + end private def module_path '/api/services'