# Errors

`POST /v1/account/errors`

Tasks that failed in the last 7 days, newest first.

Family: Account

## Price

Unit: request

Free. Account routes never charge your wallet.

## Description

Lists queued tasks that ended in an error, with the request you sent, so you can fix and resend them. Live requests return their errors directly and aren't listed. Free. Account routes never charge your wallet.

## Authentication

HTTP Basic auth: any login, with your `dg_` API key as the password. A `Bearer` token header with the key also works.

## Request

Send a JSON array of task objects (up to 1 per request).

| Field | Type | Required | Description |
|---|---|---|---|
| `limit` | integer | no | Most failed tasks to return. default `1000`; min 1; max 1000 |
| `offset` | integer | no | Number of failed tasks to skip, for paging. default `0`; min 0 |

### Example request

```bash
curl -X POST "https://api.dataforgaio.com/v1/account/errors" \
  -u "api:$DATAFORGAIO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '[
  {
    "limit": 10,
    "offset": 0
  }
]'
```

## Response

| Field | Type | Description |
|---|---|---|
| `version` | string | Response format version, for example `0.1.20261203`. |
| `status_code` | integer | Status of the request as a whole. 20000 when it was accepted; each task has its own `status_code`. |
| `status_message` | string | Plain-language request status. |
| `time` | string | Time the whole request took, for example `1.8410 sec.` |
| `cost` | number | Sum of every task's `cost`, in USD. |
| `tasks_count` | integer | Number of tasks in `tasks`. |
| `tasks_error` | integer | Tasks whose `status_code` is 40000 or higher. |
| `tasks` | array<object> | One entry per task you sent, in the order you sent them. |
| `tasks.id` | string | Task id (a UUID). For task_post, use it with task_get. |
| `tasks.status_code` | integer | Outcome of this task. 20000 means data came back; 20100 means queued. See the status codes table. |
| `tasks.status_message` | string | Plain-language status. For 40501 it names the field that failed. |
| `tasks.time` | string | Time this task took on our side, for example `1.8203 sec.` |
| `tasks.cost` | number | What this task was charged, in USD. 0 when it returned no data. |
| `tasks.result_count` | integer | Number of entries in `result`. |
| `tasks.path` | array<string> | The route this task ran on, split into segments, starting with `v1`. |
| `tasks.data` | object | The task you sent, echoed back. Utility routes echo their query parameters. |
| `tasks.result` | array<object>\|null | One entry. |
| `tasks.result.total_count` | integer | Failed tasks in the last 7 days. |
| `tasks.result.items_count` | integer | Entries in `items`. |
| `tasks.result.items` | array<object> | The failed tasks. |
| `tasks.result.items.id` | string | Task id. |
| `tasks.result.items.status_code` | integer | The error code the task ended with. |
| `tasks.result.items.status_message` | string | The error message. |
| `tasks.result.items.function` | string | The route the task was posted to, `/v1/...`. |
| `tasks.result.items.data` | object | The task as you sent it. |
| `tasks.result.items.datetime` | string\|null | When the task was posted, `YYYY-MM-DD HH:MM:SS +00:00`. |
| `tasks.receipt_id` | string\|null | Id of the ledger receipt for this task: what was fetched, at which level, and what was charged. Null for utility routes and failed checks. |
| `tasks.fetch_level` | string\|null | The fetch level that delivered the data: `standard`, `rendered` or `protected`. Null when the route doesn't fetch pages or nothing was fetched. one of `standard`, `rendered`, `protected` |
| `tasks.upgraded` | boolean | True when Auto-upgrade moved the request past the included level (or, for SERP, to the live path) and the charge reflects that. |
| `tasks.upgrade_reason` | string\|null | Why the request upgraded, in our level names and HTTP facts, for example `403 at standard; challenge page at rendered`. Null when it didn't upgrade. |
| `tasks.cache_hit` | boolean | True when the data came from the shared result cache instead of a new fetch. |

### Example response

```json
{
  "version": "0.1.20261203",
  "status_code": 20000,
  "status_message": "Ok.",
  "time": "0.4210 sec.",
  "cost": 0,
  "tasks_count": 1,
  "tasks_error": 0,
  "tasks": [
    {
      "id": "8cbb5b5c-8e15-5c82-9959-45f93cdad009",
      "status_code": 20000,
      "status_message": "Ok.",
      "time": "0.4210 sec.",
      "cost": 0,
      "result_count": 1,
      "path": [
        "v1",
        "account",
        "errors"
      ],
      "data": {
        "limit": 10,
        "offset": 0
      },
      "result": [
        {
          "total_count": 1,
          "items_count": 1,
          "items": [
            {
              "id": "744695e7-dd8a-5016-bb2b-2d314ea9ef81",
              "status_code": 40501,
              "status_message": "Invalid Field: 'keyword'.",
              "function": "/v1/serp/google/organic/task_post",
              "data": {
                "keyword": "",
                "location_code": 2840,
                "language_code": "en"
              },
              "datetime": "2026-12-03 10:42:18 +00:00"
            }
          ]
        }
      ],
      "receipt_id": null,
      "fetch_level": null,
      "upgraded": false,
      "upgrade_reason": null,
      "cache_hit": false
    }
  ]
}
```

## Errors

| Code | When |
|---|---|
| 40100 | No credentials were sent (HTTP 401). |
| 40101 | The API key is missing, malformed or revoked (HTTP 401). |
| 40202 | Too many requests for this key (HTTP 429, with `Retry-After`). |
| 40503 | The body isn't a JSON array of task objects, or the method isn't POST (HTTP 400 or 405). |
| 40006 | More than 100 tasks in one POST (HTTP 400). |
| 40210 | Wallet balance below the worst case this POST could cost (HTTP 402). |
| 40501 | A task field failed validation. Returned per task; other tasks still run. |
| 50000 | The task returned no data because of an error on our side or upstream. $0. |
| 40501 | `limit` or `offset` isn't a whole number. |

## Migrating

Replaces DataForSEO `/v3/appendix/errors`. Same request body and response envelope; change the base URL and the key.

## Related

- [User Data](https://dataforgaio.com/docs/api/account-user-data.md): Your login, organization, rate limit, wallet balance and the price list.
- [Status](https://dataforgaio.com/docs/api/account-status.md): A health check that also confirms your key.
- [Webhook Resend](https://dataforgaio.com/docs/api/account-webhook-resend.md): Send a finished task's pingback and postback again.
- [Support Matrix](https://dataforgaio.com/docs/api/account-support-matrix.md): Every route we mirror, whether it's supported yet, and its list price.
- [Receipt](https://dataforgaio.com/docs/api/account-receipts.md): Look up the receipt behind any response's `receipt_id`.
