Skip to Content
AgentShield

Core Concepts

The vocabulary of AgentShield, from organizations and agents to decisions, approvals, adapters, and the audit chain.

This page defines the terms used throughout AgentShield. Each concept links to the page that explains it in depth.

Principals

AgentShield has two kinds of principals, and they never share credentials or routes.

Prop

Type

  • Human sessions are rejected by the gateway's authorize and execute routes.
  • Agent signatures are rejected by every control plane /api/ route.
  • An agent can never approve its own action.

Read more in Agent identity and Trust boundaries.

Tool calls

A tool call is described by four fields that policy and adapters understand:

FieldExampleMeaning
tool_namehttp.requestWhich adapter executes the call
operationhttp.getThe policy action. Lowercase dotted segments such as tickets.read
resourcehttps://api.github.com/repos/octo/helloWhat the call acts on. Resource rules compare it exactly
arguments{"query": {"per_page": "5"}}Adapter input. Stored redacted, bound by SHA-256 hash

The operation is the policy action

Policy lists contain operations, not tool names. One tool can expose several operations with different permissions, for example http.get allowed and http.delete held for approval.

Decisions

Every authorize request that passes authentication and budgets produces exactly one recorded decision:

  • allow The call may be executed once through its adapter.
  • deny The call will not run. Returned with HTTP 403.
  • require_approval The call is held until a human approves it.

Each decision carries an explanation: the policy id and version, the matched_rule (for example denied:database.export), and a human-readable reason. See Policy evaluation.

Policies

A policy is a named, versioned JSON document with three action lists and optional resource rules:

{
  "permissions": {
    "allowed": ["tickets.read", "knowledge.search"],
    "denied": ["database.export"],
    "approval_required": ["payment.refund"]
  },
  "resource_rules": [
    { "effect": "deny", "action": "tickets.read", "resource": "ticket:vip-001" }
  ]
}

An organization has at most one active organization policy, and each agent at most one active agent policy. Both are evaluated together. Versions are immutable: editing a policy appends a new version and moves the current pointer.

Approvals

When the outcome is require_approval, the gateway stores an approval request bound to the SHA-256 of the exact raw request body. It expires after 15 minutes. An owner, admin, or approver approves or rejects it on the control plane. The agent then calls execute with the approval_id, which consumes the approval exactly once. See Human approvals.

Adapters

An adapter is gateway code that performs a tool's side effect. Tools without an adapter return HTTP 501; they are never simulated.

AdapterOperationsSide effect
sample.echosample.echoNone. Echoes the operation and resource
http.requesthttp.get, http.head, http.post, http.put, http.patch, http.deleteHTTPS calls to allow-listed hosts, with injected credentials

See Tool execution architecture.

Executions

An execution is the run of one decision. It is claimed before the adapter runs and finishes as completed with a redacted result, or failed with a failure kind (timeout, rejected, or adapter_error). A completed execution returns its stored result on repeat calls; a failed or interrupted one is never run again.

Budgets and circuits

After authentication, each request is charged against per-agent budgets in Redis: 60 requests, 30 calls per tool, and 100,000 tokens per minute. A circuit opens for 30 seconds after five adapter failures for a tool in an organization. See Budgets and limits.

Events, incidents, and alerts

RecordWritten byExample
Security eventGateway and control plane, in the same transaction as the changeauthorization.decided, tool.executed, approval.decided
Audit linkPostgreSQL trigger path, per eventSHA-256 chain link with prev_hash and event_hash
IncidentGateway behavioral rulesoversized_arguments, deny_burst
AlertGateway, from content analysisOne per flagged rule such as PI001
Evidence bundleEvent relay, in MinIOSnapshot for content.flagged and tool.failed

Readiness

Every service exposes GET /health/live and GET /health/ready. Readiness returns 200 only when the dependencies needed for that service's security function answer. A gateway that is not ready does not authorize.

Was this page helpful?

On this page