Skip to main content
Glama

HANRIA agent mandate check

Check an agent action against a mandate

check_action
Read-onlyIdempotent

Call this before your agent does something consequential (sends, pays, deletes, publishes, installs or changes access). Pass mandate (the operator's rules; the first matching clause decides) and action (kind, verb, target, optional counterparty and amount). Returns permit, deny or escalate with the governing clause, a reason, an action digest and a signed receipt; treat error as deny. Advisory: it cannot stop an action, and it keeps no request content. To check a new mandate first, call validate_mandate. Examples: inputSchema. Docs: https://hanria.ai/llms.txt

Input Schema

NameRequiredDescriptionDefault
actionYesA typed description of a proposed operation, submitted by an agent to a local HANRIA runtime. MUST NOT contain credentials, secrets, private keys, or tokens.
mandateYesAn operator-authored statement of what an agent may do. Written by a person, read by an agent, evaluated locally. A mandate is advisory: it describes intended authority and supports a local check, but it does not enforce anything. Enforcement requires a component that exclusively holds the credentials and can refuse.

Output Schema

NameRequiredDescriptionDefault
clauseNoThe clause that decided, when one did.
reasonYes
outcomeYesTreat error as deny.
receiptNoEd25519-signed receipt binding the outcome to this action and mandate for 15 minutes. Keys and the signed-bytes rule: https://check.hanria.ai/.well-known/hanria-receipt-keys.json
clause_noteNo
mandate_refNo
action_digestNoSHA-256 of hanria-action-v1 followed by the action's canonical JSON.
schema_versionYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "additionalProperties": false,
      +  "properties": {
      +    "action_digest": {
      +      "description": "SHA-256 of hanria-action-v1 followed by the action's canonical JSON.",
      +      "type": "string"
      +    },
      +    "clause": {
      +      "description": "The clause that decided, when one did.",
      +      "type": "string"
      +    },
      +    "clause_note": {
      +      "type": "string"
      +    },
      +    "mandate_ref": {
      +      "type": "string"
      +    },
      +    "outcome": {
      +      "description": "Treat error as deny.",
      +      "enum": [
      +        "permit",
      +        "deny",
      +        "escalate",
      +        "error"
      +      ],
      +      "type": "string"
      +    },
      +    "reason": {
      +      "type": "string"
      +    },
      +    "receipt": {
      +      "additionalProperties": false,
      +      "description": "Ed25519-signed receipt binding the outcome to this action and mandate for 15 minutes. Keys and the signed-bytes rule: https://check.hanria.ai/.well-known/hanria-receipt-keys.json",
      +      "properties": {
      +        "action_digest": {
      +          "type": "string"
      +        },
      +        "clause": {
      +          "type": "string"
      +        },
      +        "issued_at": {
      +          "format": "date-time",
      +          "type": "string"
      +        },
      +        "kid": {
      +          "type": "string"
      +        },
      +        "mandate_digest": {
      +          "type": "string"
      +        },
      +        "mandate_ref": {
      +          "type": "string"
      +        },
      +        "not_after": {
      +          "format": "date-time",
      +          "type": "string"
      +        },
      +        "outcome": {
      +          "enum": [
      +            "permit",
      +            "deny",
      +            "escalate"
      +          ],
      +          "type": "string"
      +        },
      +        "signature": {
      +          "type": "string"
      +        },
      +        "type": {
      +          "const": "hanria-receipt-v1",
      +          "type": "string"
      +        }
      +      },
      +      "required": [
      +        "type",
      +        "kid",
      +        "outcome",
      +        "action_digest",
      +        "mandate_digest",
      +        "issued_at",
      +        "not_after",
      +        "signature"
      +      ],
      +      "type": "object"
      +    },
      +    "schema_version": {
      +      "const": "0.1-draft",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "schema_version",
      +    "outcome",
      +    "reason"
      +  ],
      +  "type": "object"
      +}
  2. Changed1 schema field changed
    • changedInput schema / examples
      Previous value: -[
      -  {
      -    "action": {
      -      "justification": "Read the permitted file.",
      -      "operation": {
      -        "kind": "file",
      -        "target": "/tmp/example",
      -        "verb": "read"
      -      },
      -      "requested_by": {
      -        "agent": "example-agent"
      -      },
      -      "schema_version": "0.1-draft"
      -    },
      -    "mandate": {
      -      "clauses": [
      -        {
      -          "effect": "permit",
      -          "id": "permit-file",
      -          "match": {
      -            "kind": [
      -              "file"
      -            ]
      -          }
      -        }
      -      ],
      -      "default": "deny",
      -      "mandate_id": "minimal-permit",
      -      "purpose": "Permit one file action.",
      -      "schema_version": "0.2-draft"
      -    }
      -  }
      -]New value: +[
      +  {
      +    "action": {
      +      "justification": "Read the permitted file.",
      +      "operation": {
      +        "kind": "file",
      +        "target": "/tmp/example",
      +        "verb": "read"
      +      },
      +      "requested_by": {
      +        "agent": "example-agent"
      +      },
      +      "schema_version": "0.1-draft"
      +    },
      +    "mandate": {
      +      "clauses": [
      +        {
      +          "effect": "permit",
      +          "id": "permit-file",
      +          "match": {
      +            "kind": [
      +              "file"
      +            ]
      +          }
      +        }
      +      ],
      +      "default": "deny",
      +      "mandate_id": "minimal-permit",
      +      "purpose": "Permit one file action.",
      +      "schema_version": "0.2-draft"
      +    }
      +  },
      +  {
      +    "action": {
      +      "justification": "Pay the invoiced supplier.",
      +      "operation": {
      +        "amount": {
      +          "currency": "USDC",
      +          "value": "25"
      +        },
      +        "counterparty": "0x2222222222222222222222222222222222222222",
      +        "kind": "transaction",
      +        "target": "eip155:11155111/0x1111111111111111111111111111111111111111/transfer",
      +        "verb": "transfer"
      +      },
      +      "requested_by": {
      +        "agent": "example-agent"
      +      },
      +      "schema_version": "0.1-draft"
      +    },
      +    "mandate": {
      +      "clauses": [
      +        {
      +          "effect": "permit",
      +          "id": "small-transfers",
      +          "match": {
      +            "counterparty": [
      +              "0x2222222222222222222222222222222222222222"
      +            ],
      +            "kind": [
      +              "transaction"
      +            ],
      +            "max_amount": {
      +              "currency": "USDC",
      +              "value": "100"
      +            },
      +            "target_prefix": [
      +              "eip155:11155111/0x1111111111111111111111111111111111111111/"
      +            ],
      +            "verb": [
      +              "transfer"
      +            ]
      +          }
      +        }
      +      ],
      +      "default": "escalate",
      +      "mandate_id": "example-payments",
      +      "purpose": "Permit small transfers to one named recipient on a test network.",
      +      "schema_version": "0.2-draft"
      +    }
      +  }
      +]
  3. First observed

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the readOnly/idempotent annotations, it discloses the decision vocabulary (permit, deny, escalate), the returned artifacts (governing clause, reason, action digest, signed receipt), the error-handling rule ('treat error as deny'), and the crucial limitation that it is advisory and 'cannot stop an action' and keeps no request content. These are exactly the behaviors annotations cannot convey.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with purpose and triggering conditions, then moves to parameters, outputs, caveats, and the sibling pointer, with the two Examples/Docs pointers at the tail. It is dense but nearly every sentence carries weight; the parenthetical nesting makes parts slightly harder to scan than ideal.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex nested schema with an output schema present, the description supplies what the schema cannot: invocation timing, the advisory-only nature, error semantics, and sibling routing. An agent has everything needed to call it correctly and interpret results.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, which sets a baseline of 3, but the description adds real semantic value: it explains mandate carries the operator's rules and that 'the first matching clause decides,' and summarizes the action shape (kind, verb, target, optional counterparty and amount). This clarifies evaluation order beyond the schema's field-level docs.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource ('Check an agent action against a mandate') and frames the timing ('before your agent does something consequential'). It also distinguishes itself from the sibling by naming validate_mandate as the tool for checking a new mandate first. An agent can identify the tool's role without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explicitly says when to call it ('before your agent does something consequential') and enumerates triggering actions (sends, pays, deletes, publishes, installs, changes access). It also routes to the alternative: call validate_mandate to check a new mandate first. Both the when and the alternative are stated outright.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources