Agent Action Authorization Check
agent.action_authorization_check
Overview
You send subject attributes, an action, resource attributes, optional context and up to 1,000 statements with effect ALLOW or DENY, actions, resources and conditions. Operators are EQUALS, IN, MATCHES_GLOB and numeric or time comparisons. Combining is DENY_OVERRIDES. Missing attributes and type mismatches mean that statement does not match. The explanation never echoes unrelated policy values. This does not enforce the decision or look up a directory.
An agent that proposes a tool call needs a typed allow/deny answer without a live directory.
Reliability
Deterministic DENY_OVERRIDES; missing attributes fail closed for that statement. AUTHZ_POLICY_INVALID — trigger: an unknown operator, empty actions or an unknown property; retryable: no; next: send the published statement shape. AUTHZ_LIMIT_EXCEEDED — trigger: more than 1,000 statements or 32 conditions; retryable: no; next: split the policy.
Context footprint
Decision, ids and a redacted explanation only. A successful call costs 1 execution credit.
When to use it
When a closed policy must be evaluated against one action, resource and subject.
When you need to enforce the decision, expand roles, or run Rego or XACML.
Scope
Non-goals
- Does not enforce the decision
- Does not look up a directory
- Does not execute arbitrary policy languages
Properties
Capabilities
Cost & billing
Flat rate per invocation
File handling
How we handle your data
What this means
This skill is designed to detect, mask, redact, validate, or otherwise process sensitive data.
Squillify guarantees
- Runs inside Squillify
- This skill runs inside Squillify.
- Payloads are not sent to an external service by this skill.
- Squillify does not permanently store submitted payloads.
- Telemetry records metadata only, not submitted content.
- Submitted payloads are not used for training.
- Submitted payloads are not reviewed by humans.
- Targets sensitive data
- The response does not contain submitted content.
Your responsibility
Squillify does not determine whether submitted content is sensitive. Your application is responsible for deciding what data it is allowed to submit. Your application is responsible for securing the response.
Input schema
| Field | Type | Required | Description |
|---|---|---|---|
| subject | object | Yes | Open map of scalar subject attributes reached as subject.<name>; extra keys are the attributes. |
| action | string | Yes | Proposed action name compared to statement actions. |
| resource | object | Yes | Purpose-bound resource attributes; id is matched against statement resource patterns. |
| context | object | No | Open map of scalar context attributes reached as context.<name>; omit it when unused. |
| statements | array | Yes | Bounded array of 0 through 10001 statements; runtime accepts at most 1000. |
Output schema
| Field | Type | Required | Description |
|---|---|---|---|
| decision | string | Yes | ALLOW, DENY or NOT_APPLICABLE. |
| combining | string | Yes | Fixed combining algorithm for v1. |
| matchedStatementIds | array | Yes | Matching statement ids as a bounded array of 0 through 1000 strings, DENY ids first then ALLOW ids. |
| explanation | string | Yes | Redacted reason that never echoes unrelated policy values. |
API contract
POST /v1/executecurl -sS -X POST "$BASE/v1/execute" -H "Authorization: Bearer $KEY" -H 'Content-Type: application/json' -d '{"skillKey":"agent.action_authorization_check","input":{"subject":{},"action":"read","resource":{"id":"x"},"statements":[{"id":"s1","effect":"ALLOW","actions":["read"],"resources":["x"]}]}}'import { Squillify } from "@squillify/sdk";
const sq = new Squillify({ apiKey: process.env.SQUILLIFY_API_KEY });
const { output } = await sq.execute("agent.action_authorization_check", {"subject":{"role":"analyst"},"statements":[{"actions":["files.read"],"resources":["doc-1"],"effect":"ALLOW","id":"allow-read"},{"actions":["files.*"],"resources":["doc-*"],"effect":"DENY","id":"deny-read"}],"action":"files.read","resource":{"id":"doc-1"}});Errors
| Code | HTTP | Retryable | Description |
|---|---|---|---|
| VALIDATION_ERROR | 400 | No | The request payload failed schema validation. |
| UNAUTHORIZED | 401 | No | Missing or invalid API key. |
| SKILL_NOT_ACCESSIBLE | 403 | No | The API key is not granted access to this skill. |
| SKILL_NOT_AVAILABLE_FOR_PLAN | 403 | No | This skill is not included in your current plan. |
| PLAN_ELIGIBILITY_UNAVAILABLE | 503 | Yes | Plan eligibility could not be decided. Retry after backoff. |
| SKILL_NOT_FOUND | 404 | No | The requested skill or version does not exist. |
| TENANT_RATE_LIMITED | 429 | Yes | Request rate limit exceeded. Retry after backoff. |
| QUOTA_EXCEEDED | 429 | Yes | Plan quota exhausted. Retryable once the quota period resets. |
| EXECUTION_TIMEOUT | 504 | Yes | Execution exceeded the allowed time budget. |
| AUTHZ_POLICY_INVALID | 400 | No | The request payload failed this skill's input validation. |
| AUTHZ_LIMIT_EXCEEDED | 429 | No | A size, quota, rate, or time limit was exceeded. |
Other limits
| Limit | Value |
|---|---|
| Recommended inline bytes | 32 KiB |
Limitations
- Does not enforce the decision
- Does not look up a directory
- Does not execute arbitrary policy languages
- Enforcing the decision at a gateway
- Expanding roles from a directory
How to call
POST /v1/execute (requires authentication)
{
"skillKey": "agent.action_authorization_check",
"input": {
"subject": {
"role": "analyst"
},
"statements": [
{
"actions": [
"files.read"
],
"resources": [
"doc-1"
],
"effect": "ALLOW",
"id": "allow-read"
},
{
"actions": [
"files.*"
],
"resources": [
"doc-*"
],
"effect": "DENY",
"id": "deny-read"
}
],
"action": "files.read",
"resource": {
"id": "doc-1"
}
}
}Examples
A matching DENY wins over a matching ALLOW
{
"subject": {
"role": "analyst"
},
"statements": [
{
"actions": [
"files.read"
],
"resources": [
"doc-1"
],
"effect": "ALLOW",
"id": "allow-read"
},
{
"actions": [
"files.*"
],
"resources": [
"doc-*"
],
"effect": "DENY",
"id": "deny-read"
}
],
"action": "files.read",
"resource": {
"id": "doc-1"
}
}{
"decision": "DENY",
"combining": "DENY_OVERRIDES",
"matchedStatementIds": [
"deny-read",
"allow-read"
],
"explanation": "DENY_OVERRIDES: a matching DENY statement won."
}No matching statement yields NOT_APPLICABLE
{
"subject": {
"role": "guest"
},
"statements": [
{
"actions": [
"files.read"
],
"resources": [
"doc-1"
],
"effect": "ALLOW",
"id": "allow-read"
}
],
"action": "files.delete",
"resource": {
"id": "doc-1"
}
}{
"decision": "NOT_APPLICABLE",
"combining": "DENY_OVERRIDES",
"matchedStatementIds": [],
"explanation": "DENY_OVERRIDES: no statement matched the proposed action."
}Recommended use cases
- Let an explicit DENY beat a matching ALLOW
- Treat a missing subject attribute as a non-match rather than an allow
Avoid for
- Enforcing the decision at a gateway
- Expanding roles from a directory
Related skills
Composable with
Safety & privacy
- Runs without calling any external service.
- Your payloads are never stored permanently.
- Telemetry captures metadata only — never your payload contents.
- We never train models on your payloads.
- No human reviews your payloads.