Skip to main content
Glama

MandateShield AI Payment Evidence

Project Agent Payment Fields

normalize_agent_payment_protocol
Read-onlyIdempotent

Use when an agent encounters an AP2 terminal closed-payment projection, x402 v2 PAYMENT-REQUIRED offer, or explicitly profiled MPP Payment challenge and needs the supported fields projected before an authority check. Map those documented fields into a deterministic MandateShield purchase envelope. X402 requires source-matched network+payTo identity and MPP requires source-matched HTTPS service-origin+method identity; merchant_id alone is insufficient. Evidence references are not independently verified. projection_fields_valid is not full protocol conformance: this tool never verifies delegated authority or a payment credential and always returns enforcement_authorized=false under assurance.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sourceYesRaw protocol input: AP2 compact SD-JWT, x402 PAYMENT-REQUIRED base64 JSON, MPP WWW-Authenticate Payment challenge, or the documented decoded object.
adapterYes
contextYes
selectionNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
adapterYes
envelopeYes
protocolYes
warningsYes
assuranceYes
next_stepYes
source_digestYes
adapter_versionYes
envelope_digestYes

TDQS

A4.3/5.0
Behavior5/5

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

Annotations already declare readOnly, idempotent, and non-destructive behavior. The description adds critical disclosures beyond annotations: 'Evidence references are not independently verified,' 'projection_fields_valid is not full protocol conformance,' and 'always returns enforcement_authorized=false under assurance.' These set clear expectations for agents and are not repeated in annotations.

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 four sentences long, front-loaded with the use case, and each sentence carries substantive constraints. It avoids fluff, but the dense jargon and compound phrasing make it less crisp than ideal.

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

Completeness4/5

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

Given the tool's complexity (4 parameters, nested objects, multiple protocol adapters), the description covers the trigger conditions, adapter-specific identity requirements, and the key limitation (no authority verification). It does not explain the output shape, but an output schema exists. This is sufficient for an agent to select and use the tool appropriately.

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

Parameters3/5

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

Schema description coverage is only 25%, so the description must compensate. It does clarify adapter selection through the enumerated protocols and explains payee_identity binding requirements (network+payTo for X402, service-origin+method for MPP). However, it does not explain most context fields (e.g., mandate_id, agent_id, asset_id, idempotency_key) or the optional selection parameter, leaving notable gaps.

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 opens with a specific trigger ('Use when an agent encounters...') and states the action: 'Map those documented fields into a deterministic MandateShield purchase envelope.' This clearly identifies the function as projection/normalization and differentiates it from sibling authority-checking tools by explicitly noting it 'never verifies delegated authority or a payment credential.'

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?

The description explicitly tells when to use the tool: 'Use when an agent encounters an AP2 terminal closed-payment projection, x402 v2 PAYMENT-REQUIRED offer, or explicitly profiled MPP Payment challenge.' It also provides protocol-specific identity requirements and cautions that 'merchant_id alone is insufficient.' It does not name sibling tools directly, but the 'never verifies authority' phrase implies the boundary.

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.

TDQS

A4.2/5.0
Disambiguation4/5

Tools have distinct purposes: check is a non-executable entry check, normalize maps protocols, and verify is a cryptographic production gate. However, the conceptual overlap between check and verify could cause slight confusion, but the descriptions clearly differentiate them.

Naming Consistency5/5

All tools follow a consistent verb_object pattern using snake_case, e.g., check_ai_payment_authority, normalize_agent_payment_protocol, verify_cryptographic_payment_authority. The verbs are distinct and the naming is descriptive.

Tool Count5/5

With exactly 3 tools, the server is well-scoped for its domain of payment authority checks. Each tool serves a necessary and non-redundant role in the workflow.

Completeness3/5

The server covers the core authority check flow (non-executable check, protocol normalization, cryptographic verification). However, it lacks tools for mandate creation, payment execution, or post-authorization steps, leaving notable gaps for a complete payment lifecycle.

Resources