Bulk API - Export
Integrations Training Export API

Bulk API - Export

The Export API makes it possible to extract records in batches from Xurrent. The most common use of this API is to automatically load data from one or more Xurrent accounts into the data warehouse of the organization to which these accounts belong.

With the Export API you can automatically prepare a UTF-8 encoded comma-separated values (CSV) file for each type of Xurrent record. These CSV files can then be picked up by a script that imports them into the data warehouse. The functionally is similar to the Export feature that is available to account administrators within the Xurrent user interface.

There is one important difference, however. By telling the Export API that you only want to receive the records that were created or updated after a specific date and time, you can make this an incremental process. That will ensure that the size of the CSV files remain manageable, even when then total number of records (like requests) continues to grow in the account(s).

Questions:

curl -X POST -u "api-token:x" -H "X-Xurrent-Account: wdc" -F "type=requests" -F "from=20150128" "https://api.xurrent.com/v1/export"

Make sure you add the ‘Widget N. America – Information Technology’ account to the scope of your personal access token and that you give Read access to the record types Site, Team and Organization. Below you see how you can specify that the data should be obtained from the ‘Widget N. America – IT’ account, which Account ID is ‘wna-it’.

curl -X POST -u "api-token:x" -H "X-Xurrent-Account: wna-it" -F "type=sites,teams,organizations" "https://api.xurrent.com/v1/export"

By not specifying a date, all records of the specified types will be exported.

Don’t forget to modify the personal access token. When you know that the Account ID of the ‘Widget Europe – IT’ account is ‘weu-it’, then you will have defined the following CURL statement:

curl -X POST -u "api-token:x" -H "X-Xurrent-Account: weu-it" -F "type=cis" "https://api.xurrent.com/v1/export"

Next Topic