# GET /v1/tracking-domains/{id}

Read a tracking domain

Takes an account key (`ak_…`) as a bearer token. TypeScript: `account.trackingDomains.get(trackingDomainId)`. Python: `account.tracking_domains.get(tracking_domain_id)`. PHP: `$account->trackingDomains->get($trackingDomainId)`. Java: `account.trackingDomains().get(trackingDomainId)`.

## Parameters

- `id` (path, required, string (uuid)): The tracking domain id.

## Responses

### 200 A tracking domain, the record it needs and what the last check found.

- `trackingDomainId` (string (uuid), required)
- `host` (string, required): The host, lower-cased and IDNA-encoded.
- `sendingDomainId` (string (uuid) or null, required): The sending domain whose new mail will use the host; null once that domain is deleted.
- `state` ("pending" | "waiting_for_certificate" | "ready" | "failing" | "stopped" | "sending_domain_lost", required): pending: the records have not been right yet, and the host goes at expiresAt. waiting_for_certificate: the records are right. ready: new mail from the sending domain uses the host. failing: a check found the records wrong, and new mail keeps using a host that was ready until 24 hours after failingSince. stopped: those 24 hours have passed. sending_domain_lost: the sending domain is deleted or has lost its verification, so new mail does not use the host.
- `createdAt` (string (date-time), required)
- `lastCheckedAt` (string (date-time) or null, required): When the records were last looked up.
- `certificateReadyAt` (string (date-time) or null, required): When the certificate was proved to work; null before that.
- `failingSince` (string (date-time) or null, required): When a check first found the records wrong on a host whose records have been right. Null unless it is in that warning or past it.
- `expiresAt` (string (date-time) or null, required): When a host whose records have never been right goes; null once they have been.
- `cname` (object, required): The CNAME record to add.
  - `type` ("CNAME", required)
  - `host` (string, required): The name to create the record under.
  - `value` (string, required): The value the record must hold.
  - `check` ("ok" | "missing" | "mismatch" | "proxied" | "dns_error" or null, required): What the last check found; null before the first. mismatch is a record that points elsewhere, an A record included. proxied is a proxy in front of the name, such as Cloudflare’s, which must be switched off. dns_error is a resolver failure, not an absent record, and changes nothing.
- `caa` (object, required): Whether CAA records let Let’s Encrypt issue the certificate.
  - `check` ("ok" | "no_lets_encrypt" | "other_account" | "no_http_01" | "dns_error" or null, required): What the last check of the CAA records on the host and its parents found; null before the first. dns_error is a resolver failure and changes nothing.
  - `record` (object or null, required): What lets the certificate be issued; null unless the check found a problem.
    - `type` ("CAA", required)
    - `host` (string, required): The name that holds the CAA records in the way.
    - `value` (string, required): The record to add beside them.

Example:

```json
{
  "trackingDomainId": "3f2b8c1e-6a7d-4e9f-8b10-5c4d3e2f1a09",
  "host": "links.example.se",
  "sendingDomainId": "0d7f6a1e-4c0b-4b7e-9d3c-2a1f5e8b9c01",
  "state": "pending",
  "createdAt": "2026-11-05T12:00:00.000Z",
  "lastCheckedAt": null,
  "certificateReadyAt": null,
  "failingSince": null,
  "expiresAt": "2026-11-12T12:00:00.000Z",
  "cname": {
    "type": "CNAME",
    "host": "links.example.se",
    "value": "track.sendora.se",
    "check": null
  },
  "caa": {
    "check": null,
    "record": null
  }
}
```

## Errors

Every error answers `error`, the code, and `message`, a sentence for a person. A code that adds fields is shown in full below the table.

| Code | Status | Meaning |
| --- | --- | --- |
| `unauthorized` | 401 | The key is missing, malformed or revoked. |
| `wrong_token_kind` | 403 | The key is of the other kind: a server key (sk_) where an account key (ak_) is needed, or the reverse. The message names the kind the operation takes. |
| `not_for_connections` | 403 | A connected app called an operation that no tool of the MCP server calls. An API key can. |
| `read_only_connection` | 403 | A connected app may only read here: the account is read only through a connection, and a live server takes changes only if the person allowed them when connecting. |
| `test_server_only` | 403 | A connected app may create a secret, or do what cannot be undone, on a test server only. |
| `not_found` | 404 | No such tracking domain of this account. |

Headers sent with an error:

- `WWW-Authenticate` ("Bearer") on 401: Always Bearer: send the key as Authorization: Bearer <key>.
