SentnelOpsSentnelOpsbeta
LAYER 1 · AGENT IDENTITY

Identity reference

Endpoints, fields, token claims, errors, and configuration for the identity surface. For the full API, see the API reference.

Endpoints

MethodPathMin rolePurposeReturns
POST/agentsdeveloperRegister an agent; mints its token in the same transaction.201{agent, token}; the token appears here only
GET/agentsviewerList your org's agents. Filters: environment, risk_level, status, owner; limit (default 50, max 200), offset.Array of agent records, newest first
GET/agents/{id}viewerFetch one agent record.The agent record
PATCH/agents/{id}developerUpdate mutable fields. status is deliberately not accepted — state changes go through the lifecycle endpoints only.The updated agent record
POST/agents/{id}/rotatedeveloperRevoke every live token for the agent and mint a replacement.{agent, token}; the new token appears here only
GET/cimd/{agent_id}.jsonnone (public)The agent's public identity document for MCP servers resolving callers. Metadata only, no secrets.client_id, client_name, and a sentnelops identity block

Agent record fields

FieldTypeSet byMutable?
idUUIDserver, at registrationno
namestringyou, at registrationno
ownerstringyou, at registrationyes — PATCH
environmentproduction | staging | devyou, at registrationno
risk_levellow | medium | highyou (default medium)yes — PATCH
allowed_mcpstring[]you (default [])yes — PATCH; frozen while suspended
denied_mcpstring[]you (default [])yes — PATCH; frozen while suspended
statusdraft | approved | active | suspended | decommissionedserver (from environment)only via lifecycle endpoints
created_bystringyou, at registrationno
approved_bystring | nullserver, on approvalno
org_idUUIDserver, from your credentialno
created_at / updated_attimestampserverno / advances on change
expires_attimestamp | nullyouyes — PATCH
last_review / next_reviewtimestamp | nullserver, on reviewvia the review endpoint
suspended_at / suspend_reasontimestamp | string | nullserver, on suspensionno

Agent token claims

HS256 JWT, self-contained, no exp — revocation happens in the database, not by expiry.

ClaimMeaning
subThe agent id (UUID). Everything else keys off this.
nameAgent name at issuance.
ownerOwner at issuance.
environmentThe agent's environment at issuance.
risk_levelRisk level at issuance.
allowed_mcpAllowed MCP servers at issuance. A snapshot — the policy engine reads the live record, not this claim.
issIssuer, verified on decode. Default sentnelops.com.
iatIssued-at, Unix seconds.
jtiRandom nonce (8 bytes hex) making every issuance a distinct token — so rotation can never revoke the token it just minted.

Errors on this surface

StatusWhenWhat it looks like
401Missing or invalid bearer credential; at the proxy, also a revoked token.missing bearer credential, invalid api key, revoked agent token
403Your role is below the endpoint's minimum.requires the developer role (you are viewer)
404Agent not found — including agents that exist in another org, and unknown or malformed CIMD ids.agent not found
409The record's state forbids the change.terminal_state (decommissioned), scope_frozen (scope PATCH while suspended)
422Body validation failed — e.g. an environment or risk level outside the allowed values.FastAPI validation detail listing the offending fields
429Per-credential rate limit exceeded.Includes a Retry-After header

Configuration knobs

SettingDefaultEffect
SNOPS_JWT_SECRETdev placeholder — change itSigns both agent tokens and user sessions. Rotating it invalidates every token and session at once.
SNOPS_PROXY_IDENTITY_TTL_SECONDS5.0How long the proxy caches identity resolution and revocation checks. The staleness bound on revocation: a just-revoked token survives at most this long. 0 disables the cache.

Lifecycle transitions, approvals, and review cadence live in Layer 2 — Lifecycle & policy. For registering step by step, go back to the guides.