Error body formats
Most errors return amessage field:
Do not assume that the body is JSON.
400 Bad request
The request has missing or invalid data. Common causes:- A required field is missing.
- A manifest is not correctly formatted.
- A new dataset receives an upload before its columns are initialized.
$filtercannot be parsed or names a column that does not exist. Column names are case-sensitive.- A download uses an unsupported
$parameter, or uses$topand$lasttogether.
401 Unauthorized
The key is missing or invalid. Most endpoints require Basic Auth, with the key as the username.402 Payment required
Your plan does not let you create or clone assets, such as datasets. See pricing.403 Forbidden
You do not have the permission that the action requires. Many dataset and repository actions also return403 when the ID does not exist or you cannot access it. Check both the ID and your permission.
404 Not found
The resource does not exist or is not visible to you. Check the ID.409 Conflict
The request conflicts with the current state. Common causes:
Some
409 errors have no code.
413 Request too large
The request body is over 80 MB. Compress your CSV with gzip or split the upload.429 Too many requests
On provider endpoints, this means that an external provider’s limit was reached. Wait, then send fewer requests. For some providers you can save your own key.500 Internal server error
Something failed on the server. Check your request against the endpoint page. If it is correct and the error continues, contact support. Include the endpoint and the time of the request.501, 502, and 503
504 Gateway timeout
The request took too long. Ask for less data in one request: use$filter, $select, $top, or $last on downloads, or the provider’s date parameters on provider series. Before you repeat a POST or an upload, check whether it already succeeded.
Failures that arrive with a success status
- Uploads:
201means that the upload was accepted. Data errors appear later, when the process status isError. - Downloads: check that the file contains data. See Plan access to data.
Debugging checklist
- Check the status code before you read the body.
- Read
messageorerror. See error body formats. - Check authentication.
curl -vshows the headers that you send, including your key, so do not share that output. - Check that your JSON is valid and that you send
Content-Type: application/json. - Check IDs. List repositories or list datasets.
- Before you filter, check column names with Get columns.