v22

latestOpenAPI 3.0.0raw.githubusercontent.com2026-07-01140308542.4 KB
Policies

Create a new policy

post/zones/{zone_id}/policies

Path parameters

zone_idstring required

The zone identifier

Headers

X-API-Versionstring

API version header (date-based, e.g. 2026-02-01)

X-Client-Request-IDstring uuid

Unique request identifier specified by the originating caller and passed along by proxies.

Request body

namestring required
descriptionstring

Response

The newly created policy

idstring required
zone_idstring required
namestring required
descriptionstring nullable
archived_atstring date-time nullable
created_atstring date-time required
updated_atstring date-time required
created_bystring required
updated_bystring nullable
latest_version_idstring nullable
latest_versioninteger nullable

Human-readable version number of the latest version (e.g., 1, 2, 3)

latest_schema_versionstring nullable

Schema version the latest version was validated against (e.g., "2026-02-24"). Null when the policy has no published versions. Denormalized from PolicyVersion.schema_version for the policy referenced by latest_version_id.

owner_type'platform' | 'customer' required

Who manages this policy:

  • "platform" — managed by the Keycard platform (system policies).
  • "customer" — managed by the tenant (custom policies).