Appendix API
Status codes
The table of status codes and messages used in responses.
https://api.screamingdata.dev/v1/appendix/errors- Authentication
- Optional
- Cost
- Free
- Body
- No request body
Overview
Returns every status code the API uses, with its message, HTTP status and meaning. The same table is on the Status codes page.
An API key is optional.
Cost
Request
GET /v1/appendix/errors.
This endpoint takes no parameters.
Request example
An API key is optional for this endpoint, so the examples omit it. Requests that send one are metered like any other call.
curl --request GET \
--url "https://api.screamingdata.dev/ v1/ appendix/ errors"import requests
response = requests.get(
"https://api.screamingdata.dev/ v1/ appendix/ errors",
timeout=30,
)
data = response.json()
print(data["status_code"], data["status_message"], "cost:", data["cost"])
for task in data["tasks"]:
print(task["id"], task["status_code"], task["status_message"])const response = await fetch("https://api.screamingdata.dev/ v1/ appendix/ errors");
const data = await response.json();
console.log(data.status_code, data.status_message, "cost:", data.cost);
for (const task of data.tasks) {
console.log(task.id, task.status_code, task.status_message);
}Response
HTTP 200. The body is the standard response envelope; check status_code at the top level and in every task.
{
"version": "1.0.0",
"status_code": 20000,
"status_message": "Ok.",
"time": "0.0049 sec.",
"cost": 0,
"tasks_count": 1,
"tasks_error": 0,
"tasks": [
{
"id": "09241254-1a6c-4d2e-9b8f-0e5d3c7a2f41",
"status_code": 20000,
"status_message": "Ok.",
"time": "0.0004 sec.",
"cost": 0,
"result_count": 18,
"path": [
"v1",
"appendix",
"errors"
],
"data": {
"api": "appendix",
"function": "errors"
},
"result": [
{
"status_code": 20000,
"status_message": "Ok.",
"http_status": 200,
"description": "The request, or the individual task, was processed successfully."
},
{
"status_code": 20100,
"status_message": "Task Created.",
"http_status": 200,
"description": "task_post accepted the task. Collect the result later with tasks_ready and task_get, or receive it with a webhook."
},
{
"status_code": 40000,
"status_message": "Bad Request.",
"http_status": 400,
"description": "The body is not valid JSON or does not have the expected shape (for example, not an array of task objects, or more than one task for live). Also returned with HTTP 413 for bodies larger than 1 MiB and with HTTP 405 for a wrong HTTP method. As a task-level code (HTTP 200) it means the task cannot be carried out as asked, for example because the account already has the maximum number of API keys or monitored products."
},
{
"status_code": 40001,
"status_message": "Too many tasks in one request (max 100).",
"http_status": 400,
"description": "A POST body contains more task objects than allowed."
},
{
"status_code": 40100,
"status_message": "Authentication failed.",
"http_status": 401,
"description": "The Authorization header is missing or malformed, or the login and API key do not match."
},
{
"status_code": 40101,
"status_message": "API key revoked.",
"http_status": 401,
"description": "The API key was revoked. Use another active key or create a new one."
},
{
"status_code": 40102,
"status_message": "Account disabled.",
"http_status": 401,
"description": "The account is disabled. Contact support."
},
{
"status_code": 40200,
"status_message": "Payment Required. Insufficient balance.",
"http_status": 402,
"description": "The balance does not cover the cost. When no task of a request can be paid for, the whole request fails with HTTP 402; otherwise only the tasks that cannot be paid for fail. Contact us to add balance, then retry."
},
{
"status_code": 40202,
"status_message": "Rate limit exceeded.",
"http_status": 429,
"description": "Too many requests or tasks per minute for this account, or too many access requests from one IP address. The Retry-After header says how many seconds to wait."
},
{
"status_code": 40400,
"status_message": "Not Found.",
"http_status": 404,
"description": "Unknown endpoint, or an unknown task, key or subscription id."
},
{
"status_code": 40401,
"status_message": "Task not ready yet.",
"http_status": 200,
"description": "task_get was called before the task completed. Retry later or use webhooks."
},
{
"status_code": 40402,
"status_message": "Product not found on Amazon.",
"http_status": 200,
"description": "The product page does not exist on that marketplace. The task is not charged."
},
{
"status_code": 40501,
"status_message": "Invalid field: `<name>`.",
"http_status": 400,
"description": "A field has a wrong type, format or value; the message names the field, for example \"Invalid field: `priority`.\""
},
{
"status_code": 40502,
"status_message": "Unknown marketplace.",
"http_status": 400,
"description": "The marketplace is not one of the 12 supported codes or their aliases."
},
{
"status_code": 40503,
"status_message": "Invalid ASIN.",
"http_status": 400,
"description": "The ASIN does not match ^[A-Z0-9]{10}$ after uppercasing."
},
{
"status_code": 40600,
"status_message": "Feature not available on your plan.",
"http_status": 403,
"description": "The requested feature is not enabled for this account."
},
{
"status_code": 50000,
"status_message": "Internal error.",
"http_status": 500,
"description": "Unexpected server error. The request can be retried; contact support if it persists."
},
{
"status_code": 50301,
"status_message": "Source temporarily unavailable. Try again later.",
"http_status": 503,
"description": "The data source could not be read (blocked, unavailable or too slow). The task is not charged: its cost is refunded automatically. Try again later."
}
]
}
]
}Result fields
Each element of tasks[].result is a status code. One row of the status code table.
status_codeStatus code.
status_messageStatus message.
http_statusHTTP status when the code is returned for the request as a whole.
descriptionWhen the code is returned.
Status codes
Codes this endpoint can return, at the request or task level. See Status codes for handling advice.
| Code | Message | HTTP | Level | When |
|---|---|---|---|---|
| 20000 | Ok. | 200 | Request / task | The request, or the individual task, was processed successfully. |
| 40100 | Authentication failed. | 401 | Request | The Authorization header is missing or malformed, or the login and API key do not match. |
| 40101 | API key revoked. | 401 | Request | The API key was revoked. Use another active key or create a new one. |
| 40102 | Account disabled. | 401 | Request | The account is disabled. Contact support. |
| 40202 | Rate limit exceeded. | 429 | Request | Too many requests or tasks per minute for this account, or too many access requests from one IP address. The Retry-After header says how many seconds to wait. |
| 50000 | Internal error. | 500 | Request | Unexpected server error. The request can be retried; contact support if it persists. |