> For the complete documentation index, see [llms.txt](https://docs.i3d.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.i3d.net/connectivity/dedicated-networks-api/error-handling.md). Agents can also search and read this documentation through its [MCP server](https://docs.i3d.net/~gitbook/mcp).

# Error handling

Whenever a request to the Dedicated Networks API fails, the response tells you what went wrong in a machine-readable way. This page describes the shape of an error response; the full list of codes is on [Error codes](https://docs.i3d.net/connectivity/dedicated-networks-api/error-codes.md).

## Error response structure

Every error response from the Dedicated Networks API has the content type `application/problem+json` (RFC 9457) and this structure:

| Property  | Value type | Description                                                                            |
| --------- | ---------- | -------------------------------------------------------------------------------------- |
| `title`   | string     | Short, human-readable summary of the problem type.                                     |
| `status`  | int        | The HTTP status code of the response.                                                  |
| `detail`  | string     | Human-readable explanation of this specific occurrence. Safe to show to a user.        |
| `code`    | string     | Stable machine-readable error code: `E` followed by six digits, for example `E020001`. |
| `traceId` | string     | Identifier of the request. Quote it when you contact i3D.net support.                  |

Table 1: Error response structure

The same `traceId` value is also sent in the `X-Request-Id` response header of every response, successful or not, so it is available even when there is no body.

## Error response example

```json
{
  "title": "Validation failure",
  "status": 422,
  "detail": "a public network requires explicit addressing.prefixes[] (family and size) - there is no default public prefix",
  "code": "E020001",
  "traceId": "0af7651916cd43dd8448eb211c80319c"
}
```

## Working with error codes

* Key your error handling off `code`, not off `detail`. Codes are stable: a code's meaning never changes. The `detail` text may be reworded.
* New codes may be added over time. Treat an unknown code as a generic failure of its HTTP status.
* Errors from systems behind the API are mapped into this shape and never passed through. i3D.net can find the full detail in its logs using the `traceId`.

## HTTP status codes

<table data-full-width="true"><thead><tr><th width="120">Status</th><th>Meaning</th><th>What to do</th></tr></thead><tbody><tr><td><code>400</code></td><td>The request names an unknown filter field, or a known field with an unsupported operator.</td><td>Fix the query; the <code>detail</code> lists the supported filters.</td></tr><tr><td><code>401</code></td><td>Your API key is missing or not valid.</td><td>Check the <code>PRIVATE-TOKEN</code> header and your IP whitelisting. See the note below.</td></tr><tr><td><code>404</code></td><td>The resource does not exist on your account, belongs to another account, or was deleted. The API never confirms that someone else's resource exists.</td><td>Check the UUID. After a completed delete, <code>404</code> is the expected answer.</td></tr><tr><td><code>409</code></td><td>The request is correct but the current state does not allow it: a UUID replayed with a different body, a delete blocked by addresses in use, a limit reached, a missing contract, a resource that i3D.net manages, or an edit while an operation is still pending.</td><td>Read the <code>code</code>. The same request may succeed once the state has changed.</td></tr><tr><td><code>422</code></td><td>The request body or a query value fails validation. The request can never succeed as written.</td><td>Fix the request; the <code>detail</code> names the field or value.</td></tr><tr><td><code>500</code></td><td>Something went wrong on the i3D.net side.</td><td>Retry later. If it persists, contact support with the <code>traceId</code>.</td></tr></tbody></table>

Table 2: HTTP status codes

{% hint style="info" %}
**Authentication errors look different.** A request without a valid API key is stopped before it reaches the Dedicated Networks API, and the answer is a plain JSON object rather than a problem response:

```json
{"status":401,"error":"missing api key","message":"Validation of the API key failed"}
```

Treat any `401` as "fix the API key", whatever the body looks like.
{% endhint %}

## Asynchronous failures

A create or delete that was accepted (`202`) can still fail later. That failure is not an HTTP error: the operation resource reports `state: failed` together with an `error` object, and a failed network or prefix shows the same `error` on its own representation.

```json
{
  "resourceId": "01984f2e-1c3a-7d21-9d10-3542f27adccf",
  "resourceType": "network",
  "kind": "create",
  "state": "failed",
  "startedAt": "2026-07-27T09:00:00Z",
  "updatedAt": "2026-07-27T09:03:12Z",
  "completedAt": "2026-07-27T09:03:12Z",
  "error": {
    "code": "NETWORK_BOOTSTRAP_FAILED",
    "message": "network provisioning failed",
    "retryable": false
  },
  "links": {
    "resource": { "href": "/networks/01984f2e-1c3a-7d21-9d10-3542f27adccf" }
  }
}
```

| Property          | Description                                                                                                                                                           |
| ----------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `error.code`      | Stable code in SCREAMING\_SNAKE\_CASE. The list is on [Error codes](https://docs.i3d.net/connectivity/dedicated-networks-api/error-codes.md#operation-failure-codes). |
| `error.message`   | Human-readable message, safe to display.                                                                                                                              |
| `error.retryable` | Whether repeating the request may succeed. Sent on the operation resource only.                                                                                       |

Table 3: Operation error structure

When a create fails, the resource stays visible in state `failed`. Delete it and create a new one with a new UUID. When a delete fails, repeat the `DELETE`: it continues the teardown.

## Retrying safely

* `GET` requests can always be retried.
* `PUT` creates can be retried with the same UUID and the same body: a replay is answered with the same operation and never creates a duplicate.
* `DELETE` can be repeated: it continues a running or failed teardown, and answers `404` once the teardown has completed.
* On `500`, retry the same request after a short wait. If it persists, contact support with the `traceId`.

## Response headers

Every representation carries a strong `ETag` header. Every response, successful or not, carries an `X-Request-Id` header. Quote that value when you contact i3D.net support: it is how we find your request. On error responses the same value is in the `traceId` field of the body.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.i3d.net/connectivity/dedicated-networks-api/error-handling.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
