schemas/api-capabilities.schema.json
api-capabilities.schema.json
JSON Schema for the registrar_api_capabilities dataset. Versioned alongside the data.
Overview#overview
Field definitions#fields
| Field | Type | Required | Description |
|---|---|---|---|
| registrar_id | string | required | Foreign key to registrars.id. |
| api_available | boolean | required | Whether a public registrar API exists. |
| auth_model | enum | optional | api_key | oauth2 | basic | other | none. |
| scoped_tokens | boolean | optional | Token scopes are supported. |
| oauth_support | boolean | optional | OAuth 2.0 flows are supported. |
| webhooks | boolean | optional | Webhook event delivery is supported. |
| sandbox_url | string · uri | optional | Sandbox / test environment URL. |
| openapi_spec | string · uri | optional | Published OpenAPI / Swagger document URL. |
| rate_limit | string | optional | Documented rate limit, free text. |
| docs_url | string · uri | required | Canonical documentation URL. |
| sources | array · enum | required | Provenance. |
| verification_status | enum | required | See verification statuses. |
| last_checked | string · date-time | required | ISO 8601 timestamp. |
JSON Schema#preview
{
"$id": "https://opendomaindata.org/schemas/api-capabilities.schema.json",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "RegistrarApiCapabilities",
"description": "Documented API surface for a single registrar.",
"version": "2026.05",
"type": "object",
"required": ["registrar_id", "api_available", "docs_url", "sources", "verification_status", "last_checked"],
"properties": {
"registrar_id": { "type": "string", "description": "Foreign key to registrars.id." },
"api_available": { "type": "boolean" },
"auth_model": {
"type": "string",
"enum": ["api_key", "oauth2", "basic", "other", "none"]
},
"scoped_tokens": { "type": "boolean" },
"oauth_support": { "type": "boolean" },
"webhooks": { "type": "boolean" },
"sandbox_url": { "type": ["string", "null"], "format": "uri" },
"openapi_spec": { "type": ["string", "null"], "format": "uri" },
"rate_limit": { "type": "string" },
"docs_url": { "type": "string", "format": "uri" },
"sources": {
"type": "array",
"items": { "type": "string", "enum": ["iana", "rdap", "registrar_docs", "submission"] }
},
"verification_status": {
"type": "string",
"enum": [
"unknown",
"public_sources",
"independently_tested",
"registrar_submitted",
"registrar_verified",
"deprecated"
]
},
"last_checked": { "type": "string", "format": "date-time" }
},
"additionalProperties": false
}
Validation example#validation
Validate a record locally using any JSON Schema validator. The schema is draft 2020-12; for ajv use the 2020 import.
import Ajv from "ajv/dist/2020";
import schema from "https://opendomaindata.org/schemas/api-capabilities.schema.json" assert { type: "json" };
const ajv = new Ajv();
const validate = ajv.compile(schema);
const ok = validate(record);
if (!ok) console.error(validate.errors);Changelog#changelog
Schema changes are recorded in the project changelog and follow the dataset release tag.