Skip to content

Approvals API

Allow or decline an effect the rails held for a person: a message, a payment, a change that needs a yes.

The same operations are in the interactive API reference, and the whole contract is in the OpenAPI document.

GET/v1/approvals

List effects waiting for you

The effects held for an approval, oldest first, with the kind, the estimated cost and the level of approval each needs. The content and the target are not sent. Needs approvals:read.

Paged: limit is 1 to 100 (default 50, out of range values are clamped) and cursor is the next_cursor of the previous page. The cursor is opaque and never built by the client; a cursor this API did not return is a 400. has_more is true while another page exists. There is no total.

Scope approvals:read. Accepts: API key or personal access token. Open in the API reference

ParameterInTypeRequiredDescription
limitqueryintegerNoHow many items to return. Default 50, at most 100.
cursorquerystringNoThe `next_cursor` of the previous page. Opaque; never built by the client.
AirFone-VersionheaderstringNoThe API version to use, as a date. Defaults to the version the account was pinned to.

POST/v1/approvals/begin

Begin approving an effect

Says how hard an approval the effect needs. For a passkey it returns the ceremony made for this one effect: pass options to the browser and send the answer to approve. Needs approvals:write.

Scope approvals:write. Accepts: API key or personal access token. Open in the API reference

ParameterInTypeRequiredDescription
AirFone-VersionheaderstringNoThe API version to use, as a date. Defaults to the version the account was pinned to.

POST/v1/approvals/approve

Allow an effect

Records your approval. Leave ceremony_id and credential out for a tap; send both for a passkey. A tap is refused when the effect needs a passkey. An effect of the third level then waits out its delay before it goes. Needs approvals:write.

Scope approvals:write. Accepts: API key or personal access token. Open in the API reference

ParameterInTypeRequiredDescription
AirFone-VersionheaderstringNoThe API version to use, as a date. Defaults to the version the account was pinned to.

POST/v1/approvals/decline

Decline an effect

Stops an effect that is waiting. Nothing is sent. Needs approvals:write.

Scope approvals:write. Accepts: API key or personal access token. Open in the API reference

ParameterInTypeRequiredDescription
AirFone-VersionheaderstringNoThe API version to use, as a date. Defaults to the version the account was pinned to.