lib/3scale/api/client.rb in 3scale-api-1.2.0 vs lib/3scale/api/client.rb in 3scale-api-1.3.0

- old
+ new

@@ -1,7 +1,10 @@ module ThreeScale module API + MAX_BACKENDS_PER_PAGE = 500 + MAX_SERVICES_PER_PAGE = 500 + class Client attr_reader :http_client # @param [ThreeScale::API::HttpClient] http_client @@ -17,12 +20,12 @@ extract(entity: 'service', from: response) end # @api public # @return [Array<Hash>] - def list_services - response = http_client.get('/admin/api/services') + def list_services(params = nil) + response = http_client.get('/admin/api/services', params: params) extract(collection: 'services', entity: 'service', from: response) end # @api public # @param [Fixnum] id Service ID @@ -826,11 +829,11 @@ extract(entity: 'account', from: response) end # @api public # @return [List] - def list_backends - response = http_client.get('/admin/api/backend_apis') + def list_backends(params = nil) + response = http_client.get('/admin/api/backend_apis', params: params) extract(collection: 'backend_apis', entity: 'backend_api', from: response) end # @api public # @param [Hash] attributes Backend attributes