Skip to content
PlatformMarkdown

Platform API

Every endpoint for realms, delegated administration, keys, host names, stored data and cross-origin calls, by area.

AvailableAPI

Every endpoint the platform serves on your realm’s host, https://foobar.cvyuh.com, from the code’s routes. Admin calls take a realm administrator’s session, as Cookie: x-cvyuh-token=$CVYUH_SESSION, and every object is read and written the same way, with the same paging, revisions and errors: see Call the API. Calls on a realm beneath yours go to that realm’s own host name, with your session. No endpoint here has a rate limit today, and every limit a realm has is in Limits.

The realms beneath yours. Each call is made by an administrator of the realm’s parent; the list and a read need only READ.

MethodEndpointWhat it doesPage
GEThttps://foobar.cvyuh.com/api/v0/am/global/realms/v1Your realm and every realm beneath it, deleted ones included (with deleteTime and purged), paged, filtered and sortedRealms and sub-realms
POSThttps://foobar.cvyuh.com/api/v0/am/global/realms/v1Create a realm: name, parentPath, hostnames, and its first administrator’s password and mailId. 202, with Location and ETagRealms and sub-realms
GEThttps://foobar.cvyuh.com/api/v0/am/global/realms/v1/{realmId}One realm, with its status, and its setup’s progress, code and reasonRealms and sub-realms
PATCHhttps://foobar.cvyuh.com/api/v0/am/global/realms/v1/{realmId}Suspend or reactivate it (status, with ?subrealms=true to carry the realms beneath), or replace its hostnames, one at a timeRealms and sub-realms, Host names
DELETEhttps://foobar.cvyuh.com/api/v0/am/global/realms/v1/{realmId}Delete it for good, with If-Match (?subrealms=true to take the realms beneath). 200Realms and sub-realms
POSThttps://foobar.cvyuh.com/api/v0/am/global/realms/v1/{realmId}/resumeCarry on a setup that stopped, from the first step it didn’t finish. 202Realms and sub-realms
POSThttps://foobar.cvyuh.com/api/v0/am/global/realms/v1/{realmId}/reconcileRun an active realm’s setup again, making only what’s missing. Its administrator, host names and status stay as they areRealms and sub-realms

Each call needs DELEGATE on the realm’s delegation configuration.

MethodEndpointWhat it doesPage
GEThttps://foobar.cvyuh.com/api/v0/am/privilege/v1Every privilege in the realm, and the groups that hold itDelegated administration
POSThttps://foobar.cvyuh.com/api/v0/am/privilege/v1Grant a privilege to a group: { "group", "privilege" }. 201Delegated administration
DELETEhttps://foobar.cvyuh.com/api/v0/am/privilege/v1/{group}?privilege={privilege}Take a privilege back from a groupDelegated administration
Anyhttps://foobar.cvyuh.com/api/v0/am/objects/v1/delegationPermissionPermission templates of your own, read and written as objectsRoles of your own
Anyhttps://foobar.cvyuh.com/api/v0/am/objects/v1/delegationPrivilegePrivileges of your own, read and written as objectsRoles of your own

Each call needs MODIFY on the realm’s keySettings. Every key change is recorded on the audit trail, never the key.

MethodEndpointWhat it doesPage
GEThttps://foobar.cvyuh.com/api/v0/am/keys/v1Every version of the signing, internal signing and storage keys: key, version, alg, state, validFromSigning keys
PUThttps://foobar.cvyuh.com/api/v0/am/keys/v1/signingRotate one algorithm’s signing key: { "algorithm", "validFrom" }. 204Rotate signing keys
PUThttps://foobar.cvyuh.com/api/v0/am/keys/v1/signing/importedImport a signing key and its certificate chain. 204Bring your own key
DELETEhttps://foobar.cvyuh.com/api/v0/am/keys/v1/signing/{version}Revoke a signing key version. 204Revoke a signing key
PUThttps://foobar.cvyuh.com/api/v0/am/keys/v1/cluster-localRotate the internal signing key, which signs only tokens that never leave Cvyūh. You never need to. 204The internal signing key
DELETEhttps://foobar.cvyuh.com/api/v0/am/keys/v1/cluster-local/{version}Revoke an internal signing key version. 204The internal signing key
PUT, GET, DELETEhttps://foobar.cvyuh.com/api/v0/am/keys/v1/{key}Another of the realm’s keys by name, such as secrets/encryption: rotate it, read it at ?version=, or shred it with ?shred=trueCrypto-shredding
GET, PATCHhttps://foobar.cvyuh.com/api/v0/am/objects/v1/keySettings/keySettingsThe publish lead, clock skew, key-set cache time and the algorithms on offerSigning keys
GEThttps://foobar.cvyuh.com/oauth2/jwksThe published key set: the public signing keys and the request-object encryption key. PublicCheck what clients discover
GEThttps://foobar.cvyuh.com/.well-known/oauth-authorization-server/oauth2The realm’s authorization server metadata. PublicCheck what clients discover
GEThttps://foobar.cvyuh.com/oauth2/.well-known/openid-configurationThe realm’s OpenID Connect discovery document. PublicCheck what clients discover
MethodEndpointWhat it doesPage
PATCHhttps://foobar.cvyuh.com/api/v0/am/global/realms/v1/{realmId}Replace a realm’s host names: { "hostnames": [...] }, as an administrator of its parentHost names
POSThttps://foobar.cvyuh.com/api/v0/am/objects/v1/baseUrl?id=baseUrlSet the realm’s base URLRealm base URL
PATCHhttps://foobar.cvyuh.com/api/v0/am/objects/v1/baseUrl/baseUrlChange itRealm base URL
MethodEndpointWhat it doesPage
GEThttps://foobar.cvyuh.com/api/v0/am/types/v1/{type}An object type’s schema, with the fields it seals (x-encrypt) or hashes (x-hash)Encryption of stored data
PUThttps://foobar.cvyuh.com/api/v0/am/types/v1/{type}Change it, to seal or hash a field of your own. Needs MODIFY on that typeEncryption of stored data
MethodEndpointWhat it doesPage
GET, PUThttps://foobar.cvyuh.com/api/v0/am/objects/v1/corsSettings/corsSettingsThe origins whose pages may call the realm, each with or without credentialsAllowed origins
OPTIONSAny endpoint aboveThe preflight a browser sends before a cross-origin writeAllowed origins