Schema
Complete field definitions for legal-context.json — required and optional fields.
The legal-context.json discovery document has one required field and a set of optional fields that correspond to increasing levels of trust.
Required Fields
| Field | Type | Required | Description |
|---|---|---|---|
terms | string | REQUIRED | Absolute HTTPS URL of the legal terms document. MUST return a standalone, downloadable file. For services with only confidential/private terms, this URL MAY return a document stating that terms are provided at transaction time (see Private and Custom Terms). |
Optional Fields
| Field | Type | Required | Description |
|---|---|---|---|
termsFormat | string | OPTIONAL | The format or schema of the terms document. Signals to agents whether the terms are machine-readable before fetching. Known values: "markdown", "json", "plain", "html", "pdf". Terms intended for agent consumption SHOULD use a machine-readable value ("markdown", "json", or "plain"); "pdf" is not recommended for agent-facing terms. Implementations MAY define additional values for application-specific structured formats. When absent, agents determine format from the Content-Type header after fetching. |
atrHash | string | OPTIONAL | SHA-256 hash of the Agentic Transaction Record (ATR) — the ATR is the terms document itself (the standalone, downloadable artifact), and atrHash is its digest. 0x-prefixed hex (66 characters); lowercase hex is RECOMMENDED for emission. Two atrHash values are equal when their decoded 32-byte values are equal, so implementations MUST compare the decoded bytes rather than the strings. See Level 2: Provable. |
acceptanceRequired | boolean | OPTIONAL | If true, counterparties MUST explicitly accept terms before transacting. See Level 3: Signed. Default: false. |
disputeResolution | object | OPTIONAL | Dispute resolution process. See Level 4: Integrated. |
disputeResolution.method | string | OPTIONAL | The dispute resolution method (e.g., "Dispute Resolution Service Rules"). |
disputeResolution.jurisdiction | string | OPTIONAL | Governing jurisdiction. |
disputeResolution.contact | string | OPTIONAL | Contact for dispute filing. |
disputeResolution.clauseId | string | OPTIONAL | Content-addressed identifier of the dispute resolution clause. Format: sha256:0x followed by 64 hex characters. When present, the clause is verifiable — any party can retrieve the text and confirm it matches the hash. |
disputeResolution.source | string | OPTIONAL | URL where the dispute resolution clause text can be retrieved. Any resolvable URI (HTTPS, IPFS, Arweave, etc.). |
disputeResolution.catalog | string | OPTIONAL | URL of the dispute resolution provider's service catalog. When present, agents can browse offerings, parameters, and constraints, and generate customized clause specifications programmatically. |
returns | string | OPTIONAL | URL of a returns or claims API/process. |
contact | object | OPTIONAL | Contact information for the service. |
contact.legal | string | OPTIONAL | Legal department contact. |
contact.technical | string | OPTIONAL | Technical support contact. |
api | string | OPTIONAL | URL of a legal context API providing richer functionality (record management, verification, dispute filing). See Level 4: Integrated. |
Full Example
{
"terms": "https://example.com/terms/v3.json",
"termsFormat": "json",
"atrHash": "0x7f83b1657ff1fc53b92dc18148a1d65dfc2d4b1fa3d677284addd200126d9069",
"acceptanceRequired": true,
"disputeResolution": {
"method": "Dispute Resolution Service Rules",
"jurisdiction": "New York, USA",
"contact": "[email protected]",
"clauseId": "sha256:0xc2eb26d28ff4e229ff35917bd53339d82c1b30ec69435572a8872a4d7609c1dd",
"source": "https://adr.example.org/clauses/dispute-resolution-service-rules",
"catalog": "https://adr.example.org/.well-known/dispute-services.json"
},
"returns": "https://example.com/api/returns",
"contact": {
"legal": "[email protected]",
"technical": "[email protected]"
},
"api": "https://api.example.com/legal-context/v1"
}Extensibility
The field set is extensible. Implementations SHOULD ignore fields they do not recognize.
What these fields are. The optional fields are a machine-readable index of what the terms document says. They exist so that an agent can filter, route, and apply policy without parsing prose. They are not themselves terms. The agreement is the terms document identified by terms — at Level 2+, the specific document fixed by atrHash — and where a structured field and the terms document differ, the terms document controls. A provision that appears only in legal-context.json and not in the terms document is advertising, not agreement. A service that intends a provision to bind states it in the terms document. This holds for every field, disputeResolution included: publishing disputeResolution.jurisdiction advertises a choice of law, and the clause in the terms document makes it. Transaction-Time Verification draws the corresponding distinction in time — discovery is informational, and the transaction-time document is the one that governs.