Docs

API reference

Stable v1. Additive only: routes, methods, fields and codes are added, never removed or renamed. Error codes are listed under x-obhut-error-codes.

Base URL

Every path is relative to https://api.obhut.io, for example /v1/orgs. Requests and responses are JSON. The machine form of this reference is the OpenAPI document at https://api.obhut.io/v1/openapi.json.

Authentication

Send an API token in the Authorization header: Authorization: Bearer token_…. Create one on the dashboard's API tokens page or with obhut tokens create; its secret shows once. A token acts with the permissions of the role it was created for, within its organization, and each operation names the permission it needs.

Idempotency

Mutations take an Idempotency-Key header, 16 to 64 characters of A-Z a-z 0-9 _ -. A retry with the same key and request replays the recorded response instead of running again. The same key with another request answers 422 idempotency_key_reused.

Errors

An error answers with its HTTP status and { "error": { "code", "message", "requestId", "details" } }. The code is stable and listed under error codes; the message is for people and may change. Quote the requestId when you contact support. Statuses: 400 invalid, 401 unauthenticated, 403 forbidden, 404 not found, 409 conflict, 413 body too large, 422 unprocessable, 429 rate limited, 503 unavailable, 500 internal.

Pagination

Lists take limit (1 to 100, default 50) and cursor, and answer { "items", "nextCursor" }. Pass nextCursor as cursor for the next page; it is null on the last.

Zones

OperationMethod and path
List the zones of the organization, alphabetical, with search and filtersGET/v1/orgs/{org}/zones
Add a domainPOST/v1/orgs/{org}/zones
Get a zoneGET/v1/orgs/{org}/zones/{zone}
Remove a zone and everything the edge serves for itDELETE/v1/orgs/{org}/zones/{zone}
Look up the public DNS now and activate the zone if the delegation or verification is in placePOST/v1/orgs/{org}/zones/{zone}/check
List the names the edge serves for a zoneGET/v1/orgs/{org}/zones/{zone}/hostnames
Add a hostname to a zonePOST/v1/orgs/{org}/zones/{zone}/hostnames
Read one hostname with its projectionsGET/v1/orgs/{org}/zones/{zone}/hostnames/{hostname}
Remove a hostname that serves nothing, against its reviewed revisionDELETE/v1/orgs/{org}/zones/{zone}/hostnames/{hostname}

DNS

OperationMethod and path
List the records of a zone, oldest firstGET/v1/orgs/{org}/zones/{zone}/dns/records
Add a recordPOST/v1/orgs/{org}/zones/{zone}/dns/records
Read one recordGET/v1/orgs/{org}/zones/{zone}/dns/records/{record}
Replace a record: name, TTL and contentPUT/v1/orgs/{org}/zones/{zone}/dns/records/{record}
Remove a recordDELETE/v1/orgs/{org}/zones/{zone}/dns/records/{record}
What obhut answers for the zone, name by name, and where each answer comes fromGET/v1/orgs/{org}/zones/{zone}/dns/effective
The DS records to publish at the registrarGET/v1/orgs/{org}/zones/{zone}/dns/dnssec
Read what publication last established for the zoneGET/v1/orgs/{org}/zones/{zone}/dns/publication
List the zone's record imports, newest firstGET/v1/orgs/{org}/zones/{zone}/dns/imports
Read the domain's records from its current nameservers or a zone file, for review; nothing is written to the zonePOST/v1/orgs/{org}/zones/{zone}/dns/imports
Read an import, each record found with what it is to the zone nowGET/v1/orgs/{org}/zones/{zone}/dns/imports/{import}
Write the chosen records of an import into the zone, as records of the zone's ownPOST/v1/orgs/{org}/zones/{zone}/dns/imports/{import}/apply

Certificates

OperationMethod and path
The edge certificates of a zone, in creation order, paginatedGET/v1/orgs/{org}/zones/{zone}/certificates
Certificates being obtained, and orders the CA refused, paginatedGET/v1/orgs/{org}/zones/{zone}/certificates/orders
Retry a failed order now instead of after the cooling-off periodPOST/v1/orgs/{org}/zones/{zone}/certificates/orders/{order}/retry

Origins and routes

OperationMethod and path
The origins of a zone, alphabetical, with searchGET/v1/orgs/{org}/zones/{zone}/origins
Add an originPOST/v1/orgs/{org}/zones/{zone}/origins
Which hostnames an origin serves, counted and paginatedGET/v1/orgs/{org}/zones/{zone}/origins/{origin}/usage
Get an originGET/v1/orgs/{org}/zones/{zone}/origins/{origin}
Replace an originPUT/v1/orgs/{org}/zones/{zone}/origins/{origin}
Remove an origin no hostname routes toDELETE/v1/orgs/{org}/zones/{zone}/origins/{origin}
Which origin each hostname of the zone goes toGET/v1/orgs/{org}/zones/{zone}/routes
Which origin a hostname's traffic goes toGET/v1/orgs/{org}/zones/{zone}/routes/{hostname}
Send a hostname's traffic to an originPUT/v1/orgs/{org}/zones/{zone}/routes/{hostname}
Stop sending a hostname's traffic anywhereDELETE/v1/orgs/{org}/zones/{zone}/routes/{hostname}
Which origins send their traffic through a connector, counted and paginatedGET/v1/orgs/{org}/connectors/{connector}/origins

Static hosting

OperationMethod and path
Selection, publication, delivery and domain readiness of a deploymentGET/v1/orgs/{org}/zones/{zone}/origins/{origin}/deployments/{deployment}/status
Whether a deployment is prepared, and what its preparation foundGET/v1/orgs/{org}/zones/{zone}/origins/{origin}/deployments/{deployment}/report
Organization hosting reservations and deployment history limitsGET/v1/orgs/{org}/hosting/usage
Delete an unselected deployment and release its reservationDELETE/v1/orgs/{org}/zones/{zone}/origins/{origin}/deployments/{deployment}
A static origin's deployments, newest firstGET/v1/orgs/{org}/zones/{zone}/origins/{origin}/deployments
Propose a deployment of a static origin by its manifest; answers the hashes to uploadPOST/v1/orgs/{org}/zones/{zone}/origins/{origin}/deployments
Upload one file of a deployment's manifest, as raw bytes under its SHA-256PUT/v1/orgs/{org}/zones/{zone}/origins/{origin}/deployments/{deployment}/files/{sha256}
Select a deployment for its static origin; inspect status for delivery and live domain evidencePOST/v1/orgs/{org}/zones/{zone}/origins/{origin}/deployments/{deployment}/activate
Give a deployment its preview address without serving it on the hostnames: files complete, rules readPOST/v1/orgs/{org}/zones/{zone}/origins/{origin}/deployments/{deployment}/preview
Who may open a static site's previews, its links and the domains they are served underGET/v1/orgs/{org}/zones/{zone}/origins/{origin}/previews
Make a site's previews public or private, or set or remove their password; a new password ends every sessionPATCH/v1/orgs/{org}/zones/{zone}/origins/{origin}/previews
Create a link to a site's previewsPOST/v1/orgs/{org}/zones/{zone}/origins/{origin}/previews/links
Revoke a link to a site's previews; every session of the site ends with itDELETE/v1/orgs/{org}/zones/{zone}/origins/{origin}/previews/links/{link}
A static site's optimization settings, which its next deployment is prepared withGET/v1/orgs/{org}/zones/{zone}/origins/{origin}/optimization
Change a static site's optimization settings; they apply from its next deployment onPATCH/v1/orgs/{org}/zones/{zone}/origins/{origin}/optimization

Proxy

OperationMethod and path
List the hostnames with their lifecycle summariesGET/v1/orgs/{org}/zones/{zone}/proxy/hostnames
Read the hostname lifecycle statusGET/v1/orgs/{org}/zones/{zone}/hostnames/{hostname}/proxy
Request a lifecycle mode; accepted with an operation id, never completed inlinePUT/v1/orgs/{org}/zones/{zone}/hostnames/{hostname}/proxy
Read what deleting the zone would remove, against its revisionGET/v1/orgs/{org}/zones/{zone}/deletion-impact

WAF

OperationMethod and path
List the rules of the deployed rule sets an exception can skipGET/v1/orgs/{org}/waf/rules
Read a zone's WAF settingsGET/v1/orgs/{org}/zones/{zone}/waf
Save a zone's WAF settings against the revision readPUT/v1/orgs/{org}/zones/{zone}/waf
List the zone's hostnames that have WAF settings of their ownGET/v1/orgs/{org}/zones/{zone}/waf/hostnames
Read a hostname's own WAF settingsGET/v1/orgs/{org}/zones/{zone}/hostnames/{hostname}/waf
Save a hostname's own WAF settings against the revision readPUT/v1/orgs/{org}/zones/{zone}/hostnames/{hostname}/waf
Remove a hostname's own WAF settings against the revision readDELETE/v1/orgs/{org}/zones/{zone}/hostnames/{hostname}/waf
List what the WAF did in a zone, per hour, hostname, rule and actionGET/v1/orgs/{org}/zones/{zone}/waf/counts
List what the WAF did on a hostname, per hour, rule and actionGET/v1/orgs/{org}/zones/{zone}/hostnames/{hostname}/waf/counts

Rulesets

OperationMethod and path
Check a ruleset without saving itPOST/v1/orgs/{org}/rules/check
List current validated rulesetsGET/v1/orgs/{org}/rules
Create a validated rulesetPOST/v1/orgs/{org}/rules
Read the current validated ruleset versionGET/v1/orgs/{org}/rules/{ruleset}
Save a new immutable ruleset version against the reviewed revisionPUT/v1/orgs/{org}/rules/{ruleset}
Delete an unused ruleset against the reviewed revisionDELETE/v1/orgs/{org}/rules/{ruleset}
Read a zone's rate-limit ruleset and what its pool appliedGET/v1/orgs/{org}/zones/{zone}/rate-limits
Bind an exact rate-limit ruleset version as the zone's rate limitsPUT/v1/orgs/{org}/zones/{zone}/rate-limits
Remove the zone's rate limits against the reviewed revisionDELETE/v1/orgs/{org}/zones/{zone}/rate-limits

Tunnels

OperationMethod and path
List the live connectors of the organizationGET/v1/orgs/{org}/connectors
Get a connectorGET/v1/orgs/{org}/connectors/{connector}
Mint a one-time token that enrolls one agentPOST/v1/orgs/{org}/connectors/enrollment-tokens
Where an enrollment token stands: unused, or the connector it enrolledGET/v1/orgs/{org}/connectors/enrollment-tokens/{token}
Revoke a connectorPOST/v1/orgs/{org}/connectors/{connector}/revoke

Access

OperationMethod and path
Read saved Access authority configuration and pending readinessGET/v1/orgs/{org}/access/authority
Save Access session settings and the sign-in label against the reviewed revisionPUT/v1/orgs/{org}/access/authority
List saved Access identity provider configurationGET/v1/orgs/{org}/access/providers
Save non-secret Access identity provider configurationPOST/v1/orgs/{org}/access/providers
Read saved provider settings and the reviewed revisionGET/v1/orgs/{org}/access/providers/{provider}
Save provider settings against the reviewed revisionPUT/v1/orgs/{org}/access/providers/{provider}
Remove desired provider configuration against the reviewed revisionDELETE/v1/orgs/{org}/access/providers/{provider}
List Access applications with their hostnames and pending readinessGET/v1/orgs/{org}/access/applications
Create an Access application and protect the origins of its hostnamesPOST/v1/orgs/{org}/access/applications
Read an Access application and its reviewed revisionGET/v1/orgs/{org}/access/applications/{application}
Save an Access application against the reviewed revisionPUT/v1/orgs/{org}/access/applications/{application}
Delete an Access application; its origins stay protectedDELETE/v1/orgs/{org}/access/applications/{application}
List protected origins with the hostnames a release would make publicGET/v1/orgs/{org}/access/protected-origins
Release an origin from Access against its reviewed revision and public hostnamesPOST/v1/orgs/{org}/access/protected-origins/{origin}/release
List guarded hostnames with what applications cover and their public pathsGET/v1/orgs/{org}/access/hostnames
Set the public paths of a guarded hostname against its reviewed origin and revisionPUT/v1/orgs/{org}/access/hostnames/{hostname}

AI gateway

OperationMethod and path
Where the organization's clients send gateway requestsGET/v1/orgs/{org}/ai/endpoint
The live gateway keys of the organization, newest firstGET/v1/orgs/{org}/ai/keys
Create a gateway key for the AI gatewayPOST/v1/orgs/{org}/ai/keys
Get a gateway key, without its secretGET/v1/orgs/{org}/ai/keys/{key}
Revoke a gateway keyPOST/v1/orgs/{org}/ai/keys/{key}/revoke
The budgets of the organization, oldest firstGET/v1/orgs/{org}/ai/budgets
Create a budget in EUR for the organization, a key, or a named group of keysPOST/v1/orgs/{org}/ai/budgets
Get a budgetGET/v1/orgs/{org}/ai/budgets/{budget}
Change a budget's limitPATCH/v1/orgs/{org}/ai/budgets/{budget}
Remove a budgetDELETE/v1/orgs/{org}/ai/budgets/{budget}
The catalog of models an alias may name, with where each runsGET/v1/orgs/{org}/ai/models
obhut's default aliases, which every organization's keys can call, oldest firstGET/v1/orgs/{org}/ai/default-aliases
The aliases of the organization, oldest firstGET/v1/orgs/{org}/ai/aliases
Create an alias: a model name for clients and the catalogued models it routes toPOST/v1/orgs/{org}/ai/aliases
Get an aliasGET/v1/orgs/{org}/ai/aliases/{alias}
Replace an alias's strategy and targets, with the checks of a new onePUT/v1/orgs/{org}/ai/aliases/{alias}
Remove an aliasDELETE/v1/orgs/{org}/ai/aliases/{alias}
The organization's own provider credentials, oldest first, never their secretsGET/v1/orgs/{org}/ai/credentials
Store the organization's own credential for a provider, sealed for the edgePOST/v1/orgs/{org}/ai/credentials
Get a provider credential, without its secretGET/v1/orgs/{org}/ai/credentials/{credential}
Remove a provider credentialDELETE/v1/orgs/{org}/ai/credentials/{credential}
The organization's gateway requests from the ledger, newest first, of one key or named budget if askedGET/v1/orgs/{org}/ai/usage
The organization's AI gateway policyGET/v1/orgs/{org}/ai/policy
Enable providers outside the EU, with the acknowledgmentPUT/v1/orgs/{org}/ai/policy/outside-eu
Disable providers outside the EUDELETE/v1/orgs/{org}/ai/policy/outside-eu

Organizations

OperationMethod and path
List the organizations the caller belongs toGET/v1/orgs
Create an organizationPOST/v1/orgs
Get an organizationGET/v1/orgs/{org}
Rename an organizationPATCH/v1/orgs/{org}
Delete the organization with all its dataDELETE/v1/orgs/{org}
What deleting the organization would removeGET/v1/orgs/{org}/deletion-impact
List the members of an organizationGET/v1/orgs/{org}/members
Change a member's rolePATCH/v1/orgs/{org}/members/{user}
Remove a member from an organizationDELETE/v1/orgs/{org}/members/{user}
org management offers listGET/v1/orgs/{org}/management/offers
org management offers createPOST/v1/orgs/{org}/management/offers
org management offers revokeDELETE/v1/orgs/{org}/management/offers/{offer}
org management offers previewPOST/v1/management/offers/preview
org management links listGET/v1/orgs/{org}/management/links
org management links approvePOST/v1/orgs/{org}/management/links
org management links getGET/v1/orgs/{org}/management/links/{link}
org management links updatePATCH/v1/orgs/{org}/management/links/{link}
org management assignments listGET/v1/orgs/{org}/management/links/{link}/assignments
org management assignments createPOST/v1/orgs/{org}/management/links/{link}/assignments
org management assignments replacePUT/v1/orgs/{org}/management/links/{link}/assignments/{assignment}
org management assignments removeDELETE/v1/orgs/{org}/management/links/{link}/assignments/{assignment}
org management links end_impactGET/v1/orgs/{org}/management/links/{link}/end-impact
org management links endPOST/v1/orgs/{org}/management/links/{link}/end
org management links handover_reviewPUT/v1/orgs/{org}/management/links/{link}/handover-review
org management customers listGET/v1/orgs/{org}/management/customers
org organization_access listGET/v1/me/organization-access

Identity and tokens

Audit log

OperationMethod and path
List audit log entries, newest firstGET/v1/orgs/{org}/audit-log
Read one audit log entryGET/v1/orgs/{org}/audit-log/{entry}

Limits

OperationMethod and path
Get the platform caps, the same for every organizationGET/v1/orgs/{org}/limits