Get All Policies
GET {{cb_url}}/containers/v1/orgs/{{cb_org_key}}/guardrails/management/policies
This request returns the list of Container policies configured in the system. Policies are used to in order to define the misconfigurations, or rules we want to enforce on resources in the selected scope.
RBAC Permissions Required
Permission (.notation name) | Operation(s) |
---|---|
kubernetes.security | READ |
Response Schema
[
{
"policy_id": "<uuid>",
"name": "<string>",
"status": "<string>",
"creator": "<string>",
"created_on": <integer>,
"created_on_iso": "<string>",
"modified_by": "<string>",
"modified_on": <integer>,
"modified_on_iso": "<string>",
"scope_metadata": {
"scope_id": "<uuid>",
"scope_name": "<string>"
},
"exceptions_count": <integer>,
"violations_count": <integer>
}
]
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
X-AUTH-TOKEN | string | (Required) Carbon Black Access Key | |
Accept | string |
RESPONSES
status: OK
"{\n \"items\": [\n {\n \"policy_id\": \"a12bc3d4-d1bb-4859-ad3d-da21efb2ca2f\",\n \"name\": \"Demo Policy\",\n \"scope_metadata\": {\n \"scope_id\": \"12a34b5c-519f-4580-8d95-78738075dc63\",\n \"scope_name\": \"demo-scope\"\n },\n \"exceptions_count\": 1,\n \"creator\": \"demouser@demoorg.com\",\n \"created_on\": 1655190366737,\n \"created_on_iso\": \"2022-06-14T07:06:06.737Z\",\n \"modified_by\": \"demouser@demoorg.com\",\n \"modified_on\": 1666703636607,\n \"modified_on_iso\": \"2022-10-25T13:13:56.607Z\",\n \"status\": \"enabled\"\n}"