assign_policy
Assign a policy to a subject, role, or group to grant access. Use optional start and end times for time-based access control.
Instructions
Assign a policy to a subject, role, or group. This is what actually grants access — creating a policy alone does nothing until it is assigned.
entity_type must be "subject", "role", or "group".
For time-boxed (JIT) access: set expires_at. For future-dated access: also set starts_at.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"policy_id": "<policy_id>",
"entity_type": "<entity_type>",
"entity_id": "<entity_id>"
},
"name": "assign_policy"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| entity_id | Yes | UUID of the subject, role, or group | |
| policy_id | Yes | Policy UUID | |
| starts_at | No | RFC3339 timestamp when the assignment becomes active. If omitted, active immediately. | |
| expires_at | No | RFC3339 timestamp when the assignment expires. If omitted, does not expire. | |
| entity_type | Yes | What type of entity to assign the policy to |