Skip to main content
Glama

create_payment_mandate

Create an AP2 payment mandate: a pre-authorization that lets your agent place orders autonomously (human-not-present) within strict limits — total budget, optional per-order cap, currency, optional seller/category scope, and expiry. Returns a mandate_id to pass to place_order. Each order authorized against it is recorded as a verifiable intent and decrements the budget. Requires authentication.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
currencyNoCurrency, e.g. USD (default USD). Must match the order currency to authorize.
expires_atNoOptional ISO timestamp after which the mandate is no longer valid.
seller_scopeNoOptional list of allowed seller_user_id UUIDs. Omit = any seller.
category_scopeNoOptional list of allowed category codes (mall_category_code). Omit = any category.
max_total_amountYesTotal spend budget for this mandate (required, > 0)
max_per_order_amountNoOptional per-order cap

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.3/5.0
Behavior4/5

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

Discloses behavioral traits beyond annotations: requires authentication, decrements budget, records verifiable intent. Annotations already indicate non-readonly and non-destructive, but description adds valuable operational detail without contradiction.

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

Conciseness5/5

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

Single, well-structured sentence that front-loads the core purpose and immediately follows with key constraints and outcome, using no filler words.

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 creation tool with no output schema, the description covers all essential aspects: input constraints, return value (mandate_id), usage context, and authorization requirement, making it fully actionable.

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 100%, so the description's parameter info adds limited value beyond schema; it summarizes the purpose but does not provide additional syntax or constraints. Baseline of 3 is appropriate.

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 precisely states it creates an AP2 payment mandate for autonomous ordering, with clear resource ('payment mandate') and action ('create'), distinguishing it from siblings like place_order and list_payment_mandates.

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?

Explicitly states the mandate enables autonomous ordering and returns a mandate_id for use with place_order, providing context on when to use; however, no explicit when-not-to-use or alternative comparison is given.

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.