Skip to main content

Policies

Global, reusable IAM policy documents attached to users and API keys; managed by admins, evaluated at request time.

Overview​

A Policy is a named policy document stored globally, attached to users and API keys. Filter the listing by user to see a user's policies. Ids are prefixed pol_.

See the Permissions Reference for the IAM action strings for this module.

Data Model​

FieldTypeDescription
idstringPublic identifier prefixed with pol_
namestringHuman-readable policy name
descriptionstringOptional description
documentobjectPolicy document (see IAM)
created_atstringISO 8601 creation timestamp
updated_atstringISO 8601 last-updated timestamp

Key Concepts​

Policy Document​

Each statement has an effect (Allow or Deny), action strings, and optional resource SRNs.

{
"statement": [
{
"effect": "Allow",
"action": ["documents:GetDocument", "documents:ListDocuments"],
"resource": ["srn:proj_ABC:document:*"]
}
]
}

Format and evaluation: IAM — Policy Documents. Example: Permissions in Practice - Step 4 (Create policies).

Attaching Policies to Users​

All of a user's policies are evaluated together. Attaching replaces the full list. See Permissions in Practice - Step 5 (Attach policies to users), and the Attach policies to a user example below.

Attaching Policies to API Keys​

With key policies, effective permissions are the intersection of the user's and the key's; a key never exceeds its user. Without them, the key inherits the user's permissions. See API Keys.

SRN Scoping​

Policies are global, so resource SRNs carry the full project identifier:

{ "resource": ["srn:proj_ABC:document:*"] }

srn:*:*:* grants all projects (admin-level); a project-specific SRN restricts a policy to one project without scoping the API key.

Examples​

Create a policy​

soat create-policy \
--name "Read Only Documents" \
--document '{"statement":[{"effect":"Allow","action":["documents:GetDocument","documents:ListDocuments"],"resource":["srn:proj_ABC:document:*"]}]}'

Attach policies to a user​

soat attach-user-policies \
--user-id user_01 \
--policy-ids pol_V1StGXR8Z5jdHi6B