Create Policy

Creates a new policy.

A policy binds one or more roles to a set of resources, granting members who hold those roles the actions defined by them. Roles must already exist before they are referenced in a policy; create roles using POST /api/permissions/roles.

Authentication

AuthorizationBasic

This is the Polytomic deployment key (on-premises only)

OR
AuthorizationBearer
This is the Polytomic API key

Headers

X-Polytomic-VersionstringRequired

Request

This endpoint expects an object.
namestringRequired
policy_actionslist of objects or nullRequired
organization_idstring or nullOptionalformat: "uuid"

Response

OK
dataobject

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
500
Internal Server Error