Skip to main content
Glama

get_paywall_payments

Retrieve verified payment history for a specific x402 paywall, including transaction hashes, payer addresses, amounts, and timestamps.

Instructions

Get payment history for a specific x402 paywall. Returns verified payments with TX hashes, payer addresses, amounts, and timestamps.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paywall_idYesPaywall ID
pageNoPage number
per_pageNoResults per page (max 100)

Implementation Reference

  • The complete implementation of the 'get_paywall_payments' MCP tool. It's registered with server.tool(), defines input parameters using Zod schema (paywall_id, page, per_page), and includes a handler function that makes an API call to retrieve payment history for a specific paywall, returning verified payments with transaction hashes, payer addresses, amounts, and timestamps.
    // ─── Tool: get_paywall_payments ─────────────────────────────────
    
    server.tool(
      'get_paywall_payments',
      'Get payment history for a specific x402 paywall. ' +
        'Returns verified payments with TX hashes, payer addresses, amounts, and timestamps.',
      {
        paywall_id: z.number().int().describe('Paywall ID'),
        page: z.number().int().default(1).describe('Page number'),
        per_page: z.number().int().default(20).describe('Results per page (max 100)'),
      },
      async ({ paywall_id, page, per_page }) => {
        const data = await api(`/x402/paywalls/${paywall_id}/payments?page=${page}&per_page=${per_page}`);
        return jsonResponse(data);
      },
    );

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/hifriendbot/agentwallet-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server