Skip to main content
POST
Create an approval policy
Creates an approval policy (which action waits for a person’s approval) after the Console’s validation, and answers 201 with its id. approverMustDifferFromRequester and approverMustBePerson set the approver limits. A non-workflow trigger needs acknowledgeNoUiYet: true. The retired quorum fields approverRole and requiredApprovals are refused as unknown fields. policies:manage must be held at the platform scope: policies have no org-unit home, so a key or External App whose grant covers only some org units receives 403, and an agent can never hold the key. The audit event names the credential that decided, as the Console’s names the person. With an Idempotency-Key, a same-key retry within 24 hours returns the recorded answer only while you still hold policies:manage at the platform scope (see Idempotency). See Trust policies.

Authorizations

Authorization
string
header
required

An External App: the JWT it obtains from POST /oauth/token with OAuth2 client_credentials. Pass as Authorization: Bearer <jwt>. An app's static companion key also authenticates as the app, but is deprecated and is not protected by Idempotency-Key.

Headers

Idempotency-Key
string

Optional logical intent key. A same-key retry within 24 hours returns the recorded result without writing again.

Required string length: 1 - 255

Body

application/json
name
string
required

Shown in Console; at most 200 characters.

Maximum string length: 200
description
string
required

At most 2000 characters.

Maximum string length: 2000
trigger
string
required

The action that waits for a person's approval.

Required string length: 1 - 100
scope
string
required

global, gateway or environment.

Required string length: 1 - 100
enabled
boolean
required

Whether the policy is live once created.

triggerCondition
string

Narrows the trigger; the approval condition grammar.

Required string length: 1 - 1000
approverMustDifferFromRequester
boolean

The approver may not be the person who asked.

approverMustBePerson
boolean

Only a person may approve, never a key or an app.

scopeId
string

The id the scope targets; required for every scope except global.

Required string length: 1 - 200
acknowledgeNoUiYet
boolean

Required true for a non-workflow trigger: its held turns wait until the Operations Center approve and reject controls ship.

Response

The created policy's id

data
object
required
meta
object
required