Documentation Index
Fetch the complete documentation index at: https://docs.goantiai.com/llms.txt
Use this file to discover all available pages before exploring further.
Create a policy
curl -X POST https://api.antiailabs.com/api/v1/policies \
-H "Authorization: Bearer YOUR_CLERK_JWT" \
-H "Content-Type: application/json" \
-d '{
"name": "allow-stripe-read",
"policy_type": "rego",
"content": "package oculus.authz\n\ndefault allow = false\n\nallow {\n input.action == \"stripe:customer:read\"\n input.subject.status == \"active\"\n}\n"
}'
List / Get / Update / Delete
GET /api/v1/policies
GET /api/v1/policies?active_only=true
GET /api/v1/policies/{policy_id}
PUT /api/v1/policies/{policy_id}
DELETE /api/v1/policies/{policy_id}
Simulate a policy decision
curl -X POST https://api.antiailabs.com/api/v1/policies/simulate \
-H "Authorization: Bearer YOUR_CLERK_JWT" \
-H "Content-Type: application/json" \
-d '{
"subject_id": "your-agent-id",
"action": "stripe:customer:read",
"resource": "stripe/customers",
"context": {}
}'
Response:
{
"allowed": true,
"decision": "allow",
"reason": "Matched rule: allow { input.action == \"stripe:customer:read\" }"
}
Version history and rollback
GET /api/v1/policies/{id}/versions
GET /api/v1/policies/{id}/versions/{version_number}
POST /api/v1/policies/{id}/rollback?version=3
POST /api/v1/policies/{id}/activate