Export a report

The ReportExport endpoint schedules a job to export reports asynchronously. It returns an object describing the initial job status, a URI to poll for status updates, and a URI to download the job result file. You can check the status of a job using the Jobs endpoint. Alternatively, enable a postback for the job completion event to be notified when your report data is ready to download.

Note: You need to add the field for which you require data in the query string to have the desired columns visible in the CSV. For example, to see the Action Batch Date, you must add SHOW_ACTION_BATCH_DATE=1 to the query string.

Parameters


SUBAID required for most reports

A program Id. Further refine the report to only retrieve data from a specific program.


StartDate required for most reports

From what date and time the report should retrieve data. See ISO 8601.


EndDate required for most reports

To what date and time the report should retrieve data. See ISO 8601.


CONV_CURRENCY optional

Specify the report's currency, for example USD or HKD.


ResultFormat optional

Which file format the report will be returned in.

View possible enum values
CSVReturns the report file in CSV format.
JSONReturns the report file in JSON format.
XMLReturns the report file in XML format.

Find the report ID / handle


You can find a report's ID or handle in the URL bar when viewing a report in impact.com. The URL will include either an ID or handle at the end, e.g.:

  • https://app.impact.com/secure/advertiser/engage/Adv_Performance_Report/r21/report/viewReport.report?id=4222
  • https://app.impact.com/secure/advertiser/report/viewReport.report?handle=adv_click_data_pm_only

In this scenario, your report ID is 4222 and the handle is adv_click_data_pm_only. You may use either the ID or the handle in your request, like this:

  • curl 'https://api.impact.com/Advertisers/A1b2C3d4E5f6G7h8I9j0K1l2M3/ReportExport/adv_click_data_pm_only'

Example Request


curl 'https://api.impact.com/Advertisers/<AccountSID>/ReportExport/<Id>' \
  -X GET \
  -u '<AccountSID>:<AuthToken>' \
  -H 'Accept: application/json' \

Example Response


{ "Status": "QUEUED", 
 "QueuedUri": "/Advertisers/<AccountSID>/Jobs/d8807a9f-a5ee-4e3f-ad2b-3dfd19d1915f", 
 "ResultUri": "/Advertisers/<AccountSID>/Jobs/d8807a9f-a5ee-4e3f-ad2b-3dfd19d1915f/Download" 
}