Skip to main content
Glama

TWZRD Agent Intelligence

verify_receipt

Read-onlyIdempotent
Free utility: offline-verify a portable V7 trust receipt (earlier V5/V6 receipts
still verify), the "after you pay" half of the loop.

Recomputes the Keccak256 leaf from the receipt's preimage (tamper-evidence) AND
verifies the Ed25519 signature against the published TWZRD receipt-signing key
(authenticity). Returns valid/leaf_valid/signature_valid plus the recomputed
leaf and any errors. Pure and offline — no DB, no network, no payment.

Pass the entire PaidReceipt object you were issued. Trust is anchored on the
published key (or expected_pubkey), NOT on whatever pubkey the receipt carries.

max_age_seconds: optional freshness gate (replay protection). Same semantics
as the Python library verify_paid_receipt(..., max_age_seconds=...) and the
standalone CLI --max-age.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
receiptYesThe full signed receipt object (leaf + preimage + signature + signing_pubkey) returned by the paid /v1/intel/trust surface (V7; earlier V5/V6 receipts still verify).
expected_pubkeyNoOverride the trusted signing pubkey to verify against (default: the published TWZRD receipt key).
max_age_secondsNoIf > 0, reject the receipt if its preimage.timestamp_unix is older than this many seconds (replay/freshness protection, same as CLI --max-age and library).
require_signatureNoRequire and verify the Ed25519 signature (default true). Set false only to inspect an unsigned preview.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
validNoTrue iff the leaf recomputes AND the signature verifies against the trusted key.
domainNoThe V5 domain detected in the preimage.
errorsNoIssues found; empty on success.
leaf_validNoTrue iff the Keccak256 leaf recomputes from the preimage.
provided_leafNoThe normalized leaf supplied in the receipt.
signing_pubkeyNoThe pubkey carried by the receipt.
trusted_pubkeyNoThe published key authenticity was checked against.
recomputed_leafNoThe leaf recomputed from the preimage (0x...).
signature_validNoTrue iff the Ed25519 signature verifies; None if the signature check was skipped.
signature_checkedNoWhether the signature was checked (require_signature).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / receipt / description
      Previous value: -"The full v6 PaidReceipt object (leaf + preimage + signature + signing_pubkey) returned by the paid /v1/intel/trust surface."New value: +"The full signed receipt object (leaf + preimage + signature + signing_pubkey) returned by the paid /v1/intel/trust surface (V7; earlier V5/V6 receipts still verify)."
  2. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations only declare readOnlyHint/idempotentHint, but the description adds substantial context: pure and offline (no DB/network/payment), tamper-evidence vs authenticity semantics, the return fields, and the key-anchoring rule (trust comes from the published key, not the receipt's pubkey). Minor omission: it never states the effect of require_signature beyond what the schema says.

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?

Front-loaded with the core action and mechanism, then layers in guardrails; every sentence carries information. Mild padding in phrases like 'Free utility' and 'the after you pay half of the loop' keeps it from a 5.

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?

Given annotations, 100% schema coverage, and an output schema, the description covers the remaining gaps: offline/pure nature, key-anchoring trust model, version compatibility, and freshness semantics. An agent has everything needed to call it correctly without opening the schema.

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 coverage is 100%, so the baseline is 3, but the description adds meaning: max_age_seconds is tied to the library/CLI equivalents and framed as replay freshness gating, and expected_pubkey is explained as the trust anchor override. It does not add anything for require_signature beyond the schema.

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?

States a specific verb (offline-verify) and resource (portable V7 trust receipt), plus the exact mechanisms (Keccak256 leaf recomputation, Ed25519 signature check). It is clearly distinguished from siblings like verify_root_inputs and verify_x402_settled_claim by scoping itself to receipt verification.

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

Usage Guidelines4/5

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

Frames itself as the 'after you pay' half of the loop and instructs the caller to pass the entire PaidReceipt object, with a note that V5/V6 receipts still verify. Clear context for when to reach for it, though it stops short of naming when another sibling is the better choice.

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.