Everything a client or a verifier needs to talk to CRDCA, in tables: the profiles with their lifetime
and challenges, the four product formats, every endpoint of the five services, the
limits that apply, and the status codes the ACME server returns. The verifier's rejection codes are in
[Verification codes](/en/reference/codes).

## Services

| Service | Host | What it does |
| --- | --- | --- |
| ACME | `acme.crdca.org` | ACME server (RFC 8555) with two v1 profiles and ARI renewal |
| CDN | `cdn.crdca.org` | Log publication: tiles, signed checkpoint, inclusion, trust package and status |
| Portal | `crdca.org` | Site, status, documentation, log lookup and abuse report |
| Validator | `autoridad.crdca.org` | Challenge validation: card, origin, quorum and DNS persistence |
| Authz | `authz.crdca.org` | Authorization filter for Envoy: nine steps and one code per rejection |

## Profiles

| Profile | Issued by | For | Max lifetime | Order challenges | Goes to the log |
| --- | --- | --- | --- | --- | --- |
| `agentcard` | CRDCA, from its class intermediate | agent class of an operator with a domain | 7 days | `card-01`, `dns-01` | yes |
| `delegator` | CRDCA, from the platform intermediate | platform hosting third-party agents | 7 days | `dns-01` | yes |
| `platform-agent` | the platform, under its `delegator` sub-CA | agent of a platform customer | 7 days | not an order profile | platform log |
| `instance` | the class or the `platform-agent` | running instance | 24 hours | not an order profile | not in v1 |
| `agent-mtls` | CRDCA, from its class intermediate | agent authenticating by mutual TLS as client and as server | 24 hours | `card-01`, `a2a-01`, `dns-persist-01` | yes |

`agentcard` and `delegator` are the two v1 order profiles; `agent-mtls` is the only v2 profile and the
ACME server publishes it separately, under `perfiles_orden_v2` and `retos_v2`, without growing the v1
maps.

- **`agentcard`**: the class leaf. `keyUsage` `digitalSignature`, `CA:FALSE`, an `https` URI with the
  AgentCard URL and, optionally, one `dNSName` and one `spiffe://`. It signs the card, signs HTTP and
  signs instance credentials.
- **`delegator`**: a platform sub-CA. `CA:TRUE` with `pathLenConstraint 0`, `keyUsage`
  `digitalSignature`, `keyCertSign` and `cRLSign`, and two permitted `nameConstraints`: the platform
  host and its DNS subtree. It signs `platform-agent` leaves and the platform log.
- **`agent-mtls`**: the mutual-TLS certificate. `keyUsage` `digitalSignature`, `CA:FALSE` and the only
  EKU with `clientAuth` and `serverAuth` together. The SAN carries one `https` URI (the AgentID) and
  one `dNSName` (the name the agent presents as a server). It lives 24 hours because the key is
  presented on every connection.

::: nota Orders
`/new-order` only accepts `agentcard`, `delegator` and `agent-mtls`. A `platform-agent` or an
`instance` is not an order profile and is rejected with `malformed`. The order identifier is the
AgentCard URL: `https`, absolute, with no query and no fragment, and a path ending in
`/agent-card.json`.
:::

## Formats

### AgentCard

The card that gets certified is an A2A v1.0 JSON object. CRDCA signs the card without `signatures` and
publishes the result in `signatures[]`.

```json
{
  "name": "Invoices",
  "description": "Issues and queries a customer's invoices.",
  "url": "https://example.com/agents/invoices/agent-card.json",
  "version": "1.0.0",
  "protocolVersion": "1.0",
  "provider": {"organization": "Example", "url": "https://example.com"},
  "capabilities": {"streaming": false, "pushNotifications": false, "extensions": []},
  "defaultInputModes": ["text/plain", "application/json"],
  "defaultOutputModes": ["application/json"],
  "skills": [],
  "signatures": [
    {
      "protected": "<base64url of the protected header>",
      "signature": "<base64url of the signature>"
    }
  ]
}
```

### Card signature

Detached JWS, A2A v1.0. The payload is the card **without** `signatures`, canonicalized with JCS; each
entry of `signatures[]` carries `protected` and `signature`. The v1 protected header has exactly five
keys.

| Key | Content |
| --- | --- |
| `alg` | `EdDSA`, `ES256` or, from v2, `ML-DSA-65` |
| `typ` | `JOSE` |
| `kid` | SHA-256 of the SPKI of `x5c[0]`, recomputed with a single hash |
| `x5c` | `agentcard` certificate and CRDCA intermediate, in that order; at least two elements |
| `crdca_inclusion` | log inclusion proof, base64url, bound to the signed card hash |

The decoded header looks like this:

```json
{
  "alg": "EdDSA",
  "typ": "JOSE",
  "kid": "<SHA-256 of the SPKI of x5c[0]>",
  "x5c": ["<agentcard certificate>", "<CRDCA intermediate>"],
  "crdca_inclusion": "<base64url proof>"
}
```

`jku`, `jwk`, `x5u` and `crit` are forbidden by presence: a header carrying any of the four rejects
the whole card. `alg: none` and any algorithm outside the list are rejected too. In hybrid cards the
header also declares `crdca_pq` with `{"alg", "pub", "sig"}`: the classical signature binds the
post-quantum key and that key signs the payload.

### Instance credential

Compact JWT, no `x5c` in the header. The class chain travels by reference, in the SHA-256 thumbprint of
the issuing certificate. It lives at most 24 hours and every issuance carries a unique `jti`.

```text
<base64url header>.<base64url claims>.<signature>
```

```json
{
  "alg": "EdDSA",
  "kid": "<thumbprint of the class SPKI>",
  "x5t#S256": "<SHA-256 thumbprint of the class certificate>"
}
```

```json
{
  "iss": "https://example.com/agents/invoices/agent-card.json",
  "sub": "https://example.com/agents/invoices/agent-card.json#r1",
  "iat": 1798761600,
  "exp": 1798848000,
  "jti": "01J0"
}
```

`iss` is the class AgentID, `sub` is `<AgentID>#<instance>` and `x5t#S256` is the thumbprint of the
issuing class certificate. In v1 the credential is not published in the CRDCA log.

### Human mandate

SD-JWT signed by the human's credential, with `cnf.jwk` bound to the SPKI of the agent key. It travels
in the `CRDCA-Mandate` header or in A2A metadata (`crdca.mandate`) and it is verified by the verifier,
not by CRDCA: CRDCA does not issue mandates and none of its roots appears as an issuer.

```http
POST /tasks HTTP/1.1
Host: invoices.agents.example.com
Content-Type: application/json
CRDCA-Mandate: <SD-JWT mandate with its key-binding kb-jwt>

{"task": "issue-invoice"}
```

| Field | What it fixes |
| --- | --- |
| `iss` | mandate issuer: `https` URL of one of the two admitted issuers |
| `sub` | AgentID of the presented card |
| `cnf` | one subfield only, `jwk`, with the agent public key |
| `scope` | list of strings with the authorized actions |
| `limits` | `max_amount` positive decimal, `currency` three letters, `per` in `day`, `month` or `total` |
| `exp` | expiry, after the verification instant |

Disclosures go in `_sd`. The presentation also carries a mandatory `kb-jwt` with `aud` (the receiving
AgentID), a single-use `nonce` and an `iat` that is not in the future. A mandate has no `aud` and no
`nonce` fields of its own: they live in the `kb-jwt`.

## Endpoints

This is the same table published for agents in [/api.json](/api.json); a route that is not here does
not exist. An empty `Quota` means the published table declares no quota for that route. The `Type`
column is the one declared in the table; `/cert/{id}` also returns the chain as PEM.

### ACME

Host `acme.crdca.org`.

| Method | Route | Purpose | Type | Quota | Auth |
| --- | --- | --- | --- | --- | --- |
| `GET` | `/directory` | server metadata and the URL of every operation | `application/json` | 60 rpm | none |
| `GET` | `/new-nonce` | a single-use nonce | `application/json` | 120 rpm | none |
| `HEAD` | `/new-nonce` | a nonce in the Replay-Nonce header | `application/json` | 120 rpm | none |
| `POST` | `/new-account` | open an account with a key; returns the kid | `application/json` | 20 rpm | none |
| `POST` | `/new-order` | request an order for one profile (agentcard, delegator, agent-mtls) | `application/json` | 20 rpm | none |
| `POST` | `/order/{id}` | read the order and its challenges | `application/json` | — | none |
| `POST` | `/authz/{id}` | read the authorization and its challenges | `application/json` | — | none |
| `POST` | `/chall/{id}` | answer a challenge (card-01, dns-01, a2a-01, dns-persist-01) | `application/json` | — | none |
| `POST` | `/finalize/{id}` | finalize with the CSR and receive the certificate | `application/json` | — | none |
| `POST` | `/cert/{id}` | download the certificate as PEM | `application/json` | — | none |
| `GET` | `/renewal-info/{certID}` | ARI renewal window | `application/json` | — | none |
| `GET` | `/limites` | the limits the server applies | `application/json` | — | none |
| `GET` | `/meta/politica` | the issuance policy as metadata | `application/json` | — | none |
| `GET` | `/raiz` | the CA root as PEM, to anchor the package | `application/x-pem-file` | — | none |
| `GET` | `/salud` | service health | `application/json` | — | none |
| `GET` | `/metrics` | Prometheus metrics | `text/plain; version=0.0.4` | — | none |

### CDN

Host `cdn.crdca.org`.

| Method | Route | Purpose | Type | Quota | Auth |
| --- | --- | --- | --- | --- | --- |
| `GET` | `/log/checkpoint` | signed log checkpoint (tree_size and Merkle root) | `application/json` | — | none |
| `GET` | `/log/tiles/{nivel}/{n}` | Merkle tree tiles | `application/json` | — | none |
| `GET` | `/log/claves` | the public keys that sign the checkpoint | `application/json` | — | none |
| `GET` | `/inclusion/{hash}` | inclusion proof for one leaf | `application/json` | — | none |
| `GET` | `/paquete` | signed trust package with its validity | `application/json` | — | none |
| `GET` | `/paquete/raiz.pem` | the package root as PEM | `application/x-pem-file` | — | none |
| `GET` | `/estado` | signed status-list fragment | `application/json` | — | none |
| `GET` | `/estado/claves` | the public key that signs the status | `application/json` | — | none |
| `GET` | `/federacion/{operador}` | anchor of a federated log | `application/json` | — | none |
| `POST` | `/hoja` | register a leaf (issuer only) | `application/json` | — | internal network |
| `GET` | `/salud` | service health | `application/json` | — | none |
| `GET` | `/metrics` | Prometheus metrics | `text/plain; version=0.0.4` | — | none |

### Portal

Host `crdca.org`. The four entries with a quota are status, documentation, lookup and abuse; the other
portal routes declare no quota in the published table.

| Method | Route | Purpose | Type | Quota | Auth |
| --- | --- | --- | --- | --- | --- |
| `GET` | `/estado` | service status as JSON | `application/json` | 60 rpm | none |
| `GET` | `/documentacion` | guide index; as JSON with Accept: application/json | `application/json` | 30 rpm | none |
| `GET` | `/log` | card position by serial or hash (HTML or JSON) | `application/json` | 10 rpm | none |
| `POST` | `/abuso` | abuse report with two fields: url and motivo | `application/json` | 1 rpm | none |
| `GET` | `/card/{agente}/agent-card.json` | the published card of an agent | `application/json` | — | none |
| `POST` | `/card/{agente}` | publish a card (operator token) | `application/json` | — | x-crdca-token |
| `GET` | `/metrics` | Prometheus metrics | `text/plain; version=0.0.4` | — | none |

### Validator

Host `autoridad.crdca.org`.

| Method | Route | Purpose | Type | Quota | Auth |
| --- | --- | --- | --- | --- | --- |
| `POST` | `/v1/origen` | check that the card origin is the certificate's | `application/json` | — | none |
| `POST` | `/v1/card01/quorum` | card-01 acceptance quorum by network and ASN | `application/json` | — | none |
| `POST` | `/v1/a2a01` | validate the card's a2a-01 extension | `application/json` | — | none |
| `POST` | `/v1/dnspersist` | dns-01 persistence across networks | `application/json` | — | none |
| `GET` | `/v1/autotest/card01` | self-test of the card validator | `application/json` | — | none |
| `GET` | `/v1/autotest/origen` | self-test of the origin validator | `application/json` | — | none |
| `GET` | `/salud` | service health | `application/json` | — | none |

### Authz

Host `authz.crdca.org`.

| Method | Route | Purpose | Type | Quota | Auth |
| --- | --- | --- | --- | --- | --- |
| `POST` | `/check` | Envoy ext_authz decision on a request | `application/json` | — | internal network |
| `GET` | `/healthz` | filter health | `application/json` | — | none |
| `GET` | `/metrics` | Prometheus metrics | `text/plain; version=0.0.4` | — | none |

## Request limits

### ACME: six caps per account and per domain

They apply at the same time per account and per registered domain, and the first one reached wins. A
registered domain belongs to a single account.

| Id | Cap | Per account | Per domain | Window |
| --- | --- | --- | --- | --- |
| `L-ORD-01` | open orders | 5 | 2 | — |
| `L-ORD-02` | new orders per hour | 30 | 10 | 3600 s |
| `L-ORD-03` | authorizations per order | 3 | 3 | — |
| `L-ORD-04` | certificates issued per day | 20 | 5 | 86400 s |
| `L-ORD-05` | challenge failures per day | 10 | 5 | 86400 s |
| `L-ORD-06` | registered domains | 20 | 1 | — |

A `/new-nonce` nonce is used once and expires after 300 s; reusing it returns `badNonce` with status
400. An order yields at most one certificate: a second `finalize` returns `orderNotReady`.

### Portal: per-origin cap

It is counted per incoming connection, not per identity: the site has no accounts. When the quota is
exhausted the response is `429` with `Retry-After` in seconds and no data body; there is no courtesy
response.

| Route | Requests per minute per origin |
| --- | --- |
| `/estado` | 60 |
| `/documentacion` | 30 |
| `/log` | 10 |
| `/abuso` | 1 |

A `/log` lookup result is cached for 60 s, inside the 300 s status-list cadence. The lookup accepts two
keys only: `serial` and `hash`.

### CDN and validator

The published table declares no quota for these two services.

## ACME status codes

Every error is returned as `application/problem+json`, with `type` in
`urn:ietf:params:acme:error:<type>`, `detail`, `status`, a fresh `Replay-Nonce` and
`Cache-Control: no-store`.

| Status | Problem type | When it appears |
| --- | --- | --- |
| `200` | — | POST-as-GET of an order, authorization, challenge or certificate; `/directory`, `/limites`, `/meta/politica`, `/raiz`, `/salud` and `/renewal-info` |
| `201` | — | `/new-account` and `/new-order` |
| `204` | — | `GET /new-nonce`; the nonce travels in `Replay-Nonce` |
| `400` | `malformed` | unreadable body, missing payload, profile that is not an order profile, order read with a payload |
| `400` | `badNonce` | reused, expired or missing nonce |
| `400` | `accountDoesNotExist` | the key or `kid` has no account |
| `400` | `rejectedIdentifier` | identifier that is not an `https` AgentCard URL, or domain already registered by another account |
| `400` | `caa` | the domain CAA does not authorize CRDCA |
| `400` | `badCSR` | CSR that is not base64url, does not verify its signature, or does not carry exactly the order URI |
| `401` | `unauthorized` | protected URL different from the request URL, or signature that does not verify with the account key |
| `403` | `orderNotReady` | `finalize` on an order that is not in `ready` |
| `404` | `malformed` | the order, authorization, challenge or certificate does not exist for the account |
| `429` | `rateLimited` | `L-ORD-01`, `L-ORD-02` or `L-ORD-04` reached |
| `500` | `serverInternal` | server failure; retry later |

::: nota Retries
`badNonce` is fixed by requesting a new nonce from `/new-nonce` and repeating the request with the same
payload. `rateLimited` is not retried in a loop: wait for the window of the cap named in `detail` to
open. `orderNotReady` means a challenge is still unanswered.
:::
