CAIN-42 CAIN Studio

API reference · CAIN Agent Security

Evaluate Security

POST /fabric/security/evaluate

Last reviewed 2026-10-03

POST /fabric/security/evaluate

Evaluate security for an action.

This endpoint runs the action through all security checks and returns the verdict along with any threat detections.

CAIN 24.0: `identity_active`/`delegation_valid`/`trajectory_safe` are a fallback only. Pass `identity_id` (and, if relevant, `delegation_id` / `trajectory_id` / `required_capability`) to have this endpoint independently re-derive those facts from identity_engine and trajectory_enforcement rather than trusting the caller's claim -- see AgentSecurityEngine.evaluate_security's docstring.

Parameters

NameInTypeMeaning
action requiredquerystring
toolquerystring or null
resourcequerystring or null
agent_idquerystring or null
principal_idquerystring or null
identity_activequeryboolean default true
delegation_validqueryboolean default true
credential_scope_validqueryboolean default true
trajectory_safequeryboolean default true
policy_compliantqueryboolean default true
mcp_authorizedqueryboolean default true
identity_idquerystring or null
delegation_idquerystring or null
required_capabilityquerystring or null
trajectory_idquerystring or null

Request body

array of string or null

Responses

StatusMeaningBody
200Successful Responseobject
422Validation ErrorHTTPValidationError
401No key, or a key that is not validJSON detail
429Rate limit for your plan reached; retry after the Retry-After secondsJSON detail

Try it

This call changes data in the account the key belongs to.

The request goes from your browser straight to this site. Your key is not stored unless you tick the box, and then only in this tab's session storage.

Code

curl -sS -X POST 'https://cainstudio.online/fabric/security/evaluate?action=action' \
  -H "X-API-Key: $CAIN_API_KEY" \
  -H 'Content-Type: application/json' \
  -d '["string"]'

Schemas used

HTTPValidationError · ValidationError

← Contain Agent · all 9 CAIN Agent Security calls · Security Health →

Try CAIN-42 on your own agents

Create a free account and every new account starts with a 7-day trial of the full platform. Or try the sandbox first, with no account at all.

Create a free account →  ·  Try the sandbox  ·  See the whole ecosystem