STACK
MENU
DOCS / GUIDES / ENFORCED MODE

Guide: enforced mode

Enforced is the strictest accountability mode. Passport TTL ties to the checkpoint interval. Critical detector results can block a request. A critical event can also block new Passport issuance when on_critical is set to block. Any delegation must preserve the mode.

1. Enable on an agent

bash
curl -X PATCH https://api.getstack.run/v1/agents/agt_support_bot \
  -H "Authorization: Bearer $STACK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "accountability_mode": "enforced" }'

2. TTL ties to checkpoint interval

In enforced mode, ttl_seconds is capped bycheckpoint_interval_seconds. The signed Passport expires after one interval.

text
ttl_actual = min(ttl_seconds, checkpoint_interval_seconds)

Presets:

  • frequent - 2 minutes (high-risk, real-money paths)
  • standard - 5 minutes (default)
  • relaxed - 15 minutes (long-running but still monitored)
  • marathon - 60 minutes (batch jobs)

3. Submit checkpoints and refresh the token

A checkpoint records progress and advances the stored monitoring deadline. It returns new_expires_at. It does not change the signed JWT exp or return a new token. Refresh the Passport to continue beyond the current token expiry.

bash
curl -X POST https://api.getstack.run/v1/passports/pas_8f3a/checkpoint \
  -H "Authorization: Bearer $STACK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "services_used": ["slack"],
    "actions_count": 2,
    "summary": "Fetched ticket context"
  }'

4. Detector enforcement

An enforced critical detector result can block the current request. A recorded critical event can block future Passport issuance when on_critical is block. The scope_drift path is different. It revokes the active Passport in enforced mode and cascades to delegated children.

text
scope_drift fires in enforced mode
  -> record a security event
  -> revoke the active Passport and delegated children
  -> reject the next STACK-verified call

5. Delegation cannot drop the mode

An enforced parent cannot delegate to a child whose agent is inlogged or standard. The delegate call throws DELEGATION_ACCOUNTABILITY_VIOLATION and fires adelegation_downgrade security event at critical severity.

6. Checkout review is stricter

Enforced mode keeps the full set of checkout flags. Logged mode keeps only critical flags. A critical flag blocks future Passport issuance only when on_critical is block. A warning blocks only when on_warning is block.

Signals enforced mode raises

  • checkpoint_silence - more than two intervals without a checkpoint
  • credential_burst - credential retrievals above threshold
  • credential_after_checkout - activity after checkout was submitted
  • scope_drift - behavioral drift from declared intent; auto-revokes on fire
  • delegation_without_intent - delegation when intent.will_delegate was not set
  • delegation_downgrade - child agent is in a looser mode
  • unauthorized_skill_access - skill outside skill_access_mode

Enforced mode is strict by design. Test your agent inlogged mode first. Use the recorded results to calibrate the checkpoint cadence and Intent before you enable enforced blocking.

Related

  • /docs/guides/passport-lifecycle - full issue → checkpoint → checkout → review flow
  • /docs/concepts/detectors - full detector catalog and auto-revoke rules
  • /docs/concepts/revocation - online checks and cascade behavior

Proxy scope and constraint checks apply in every mode. Enforced mode can also block a critical detector result. Logged mode records detector results without that enforced detector block. Standard mode does not support checkpoint or checkout.

stack | Docs