Download export file

The export API allows you to download files extracted by your export request.

API Description

Download

get

Download the extraction file of an export request. Status of the export must be SUCCESS to call this API. See view export API to get the current status of your export. The link to the JSON file that you can found under the Location section of the response header will expire after 20 minutes. You will need to call this API again to generate a new file.

Authorizations
Query parameters
idstringrequired

ID of the file to be downloaded.

Example: file_063bc4w4x8e363yem6wfnxc5c13c0n46
Header parameters
X-Batch-Projectstringrequired

The unique project key, identifying a project on the Batch platform

Example: project_0664hxvwffvbpn278gxdyhsadddqgna6
Responses
get
GET /2.4/exports/download HTTP/1.1
Host: api.batch.com
Authorization: Bearer YOUR_SECRET_TOKEN
X-Batch-Project: text
Accept: */*

No Content

Route

The Project Export API exposes a GET endpoint that allows to download result files:

https://api.batch.com/2.4/exports/download

Headers and authentication

See Overview → Using Project APIs.

Success

Batch will respond with an HTTP status code: 307. The download link is located under the location section of the response header.

The link to the file will expire after 20 minutes. You will need to call again the API to generate a new file.

Failure

If the POST data does not meet the API requirements you will receive an actionable error message. Contact us at [email protected] if you need further support.

See the list of potential failures in the API Description.

Last updated

Was this helpful?