Skip to main content
Glama

Pay2GPT

Get the x402 payment address of a plan

get_x402_checkout
Read-onlyIdempotent

For an agent that holds USDC on Base: returns the HTTP address where one Pay2GPT plan is bought with the x402 payment protocol, with the current price in US cents and in USDC atomic units. This tool pays nothing. A GET to the returned url answers 402 with the payment requirements; the same GET with a PAYMENT-SIGNATURE header settles the payment and returns the order number and the order page, where the buyer connects their own ChatGPT account.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "plan": "<plan>",
      "email": "<email>"
    },
    "name": "get_x402_checkout"
  }
}

Input Schema

NameRequiredDescriptionDefault
planYesPlan slug from list_plans, such as plus
emailYesThe buyer's email address; order updates go there

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior5/5

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

Annotations already declare readOnly, idempotent, non-destructive and not open-world, yet the description still adds substantial protocol-level behavior: the tool itself pays nothing, the returned URL answers 402 with payment requirements, and a PAYMENT-SIGNATURE GET settles and returns an order number plus an order page where the buyer links their own ChatGPT account. This is exactly the kind of post-call semantics annotations cannot express.

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 core return value is front-loaded in the first sentence and the negative constraint ('pays nothing') follows immediately. Every subsequent sentence carries distinct protocol information. It is somewhat dense with multiple clauses per sentence, but no sentence is filler.

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?

There is no output schema, and the description fully compensates by enumerating the return contents: address/url, price in US cents, and price in USDC atomic units. It also explains the downstream 402/settlement contract, which is unusual and important for correct use. Nothing an agent needs to select or call this tool is missing.

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 both parameters (plan, email) are already documented in the schema, including the plan slug reference to list_plans. The description mentions 'one Pay2GPT plan' and the buyer's order but adds no format, validation, or constraint detail beyond the schema. Baseline 3 applies when the schema does the heavy lifting.

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

Purpose4/5

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

The description names a specific verb and resource: it 'returns the HTTP address where one Pay2GPT plan is bought with the x402 payment protocol', along with the price in cents and atomic units. It also explicitly disclaims the action a reader might fear ('This tool pays nothing'), which separates it from a purchase/payment tool. It does not name a specific sibling (e.g. list_plans or place_business_orders) to route against, so it stops just short of a 5.

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?

It states the situation clearly: 'For an agent that holds USDC on Base', giving a concrete precondition for use. The follow-up flow (plain GET yields 402, GET with PAYMENT-SIGNATURE settles) tells the agent what to do after calling, which is strong context. It does not explicitly say when NOT to use it or name an alternative tool, so no exclusions are 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.

Resources