Skip to navigation

Get a policy. [experimental]

View as Markdown
Retrieve policy details by id, including both the declared rules and the effective rules.

Authentication

AuthorizationBearer
Bearer authentication

Path parameters

PolicyIdstringRequiredformat: "uuid"
The unique identifier for the policy.

Response

The requested policy.
workloadTypeobject

Specifies the Group, Version, and Kind (GVK) of the Kubernetes resource that defines the workload.

scopeenum
Allowed values:
idstringformat: "uuid"
The unique identifier for the policy.
createdBystring>=1 character
Identifier of the user who created the policy.
createdAtdatetime
The timestamp for when the policy was created.
updatedBystring>=1 character
Identifier of the user who last updated the policy.
updatedAtdatetime
The timestamp for when the policy was last updated.
descriptionstringOptionalformat: ".*"1-1023 characters
A description of the policy.
clusterIdstring or nullOptionalformat: "uuid"
The id of the cluster the policy applies to. Required when the scope is cluster.
departmentIdstring or nullOptionalformat: ".*">=1 character
The id of the department the policy applies to. Required when the scope is department.
projectIdstring or nullOptionalformat: ".*"
The id of the project the policy applies to. Required when the scope is project.
ruleslist of objectsOptional
The rules declared on this policy. Each rule targets a field in the workload spec and constrains its allowed values through its enforcements.
effectiveRuleslist of objectsOptional

The merged rule set in effect for this policy, including rules inherited from broader scopes (cluster, then department, then project). Each entry adds the sourceOfRule indicating where the rule was defined. Returned in responses only; not accepted in requests.

statusobject or nullOptional

Configuration issues detected by the server for this policy. Returned in responses only; not accepted in requests.

breakdownobject or nullOptional

The detailed breakdown, keyed into per-field variations and per-spec-selector details.

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
503
Service Unavailable Error