Class: Adzerk::ScheduledReporting
Instance Attribute Summary
Attributes inherited from ApiEndpoint
#client, #datakey, #endpoint, #subendpoint
Instance Method Summary
collapse
Methods inherited from ApiEndpoint
#initialize, #update
Methods included from Util
#camelize_data, #parse_response, #uncamelize_data
Instance Method Details
#create(data) ⇒ Object
3
4
5
6
7
|
# File 'lib/adzerk/scheduled_reporting.rb', line 3
def create(data)
url = "report/schedule"
formatted_data = data.transform_keys{ |key| key.downcase }
parse_response(@client.post_json_request(url, camelize_data(formatted_data)))
end
|
#delete(report_id) ⇒ Object
19
20
21
22
|
# File 'lib/adzerk/scheduled_reporting.rb', line 19
def delete(report_id)
url = "report/schedule/#{report_id}/delete"
parse_response(@client.get_request(url))
end
|
#get(report_id) ⇒ Object
9
10
11
12
|
# File 'lib/adzerk/scheduled_reporting.rb', line 9
def get(report_id)
url = "report/schedule/#{report_id}"
parse_response(@client.get_request(url))
end
|
#list ⇒ Object
14
15
16
17
|
# File 'lib/adzerk/scheduled_reporting.rb', line 14
def list()
url = "report/schedule"
parse_response(@client.get_request(url))
end
|