Skip to main content
Glama
Payagents

PayAgents MCP Server

Official
by Payagents

Servidor MCP de PayAgents (payagents-mcp)

npm version License: MIT

El servidor oficial Model Context Protocol (MCP) para PayAgents. Dale a tus agentes de IA (Claude Desktop, Cursor, Windsurf, Zed, LangChain, OpenDevin) una cartera controlada por políticas para pagar por APIs y herramientas de forma autónoma a través de Bitcoin Lightning (L402) y Base USDC (x402).


⚡ Inicio rápido para Claude Desktop

Añade payagents-mcp a tu claude_desktop_config.json:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

  • Windows: %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "payagents": {
      "command": "npx",
      "args": ["-y", "payagents-mcp"],
      "env": {
        "PAYAGENTS_API_KEY": "pa_live_your_api_key_here"
      }
    }
  }
}

Reinicia Claude Desktop y tu asistente de IA tendrá automáticamente acceso a las herramientas de pago de PayAgents.


Related MCP server: @coinbase/payments-mcp

🛠️ Herramientas MCP disponibles

1. payagents_pay_url

Ejecuta una solicitud HTTP a cualquier endpoint de API o recurso con muro de pago, resolviendo y pagando automáticamente los desafíos de pago HTTP 402 / L402 / x402 dentro de tus límites de gasto empresarial.

  • Parámetros:

    • url (obligatorio, string): URL de la API de destino.

    • method (opcional, por defecto: "GET"): GET, POST, PUT, DELETE.

    • body (opcional, objeto/cadena): Carga útil del cuerpo de la solicitud.

    • headers (opcional, objeto): Cabeceras HTTP adicionales.

    • max_amount (opcional, string): Cantidad máxima que se está dispuesto a pagar (p. ej. "0.01 USD").

2. payagents_get_balance

Comprueba el saldo de gasto disponible del agente, el nivel de suscripción y las políticas de gasto activas (límites por transacción y límites diarios).

3. payagents_get_transaction

Consulta los detalles de una transacción pasada, mostrando la vía de pago, el método de liquidación (🟢 Directo No Custodial vs Gestionado por la Plataforma) y las pruebas de verificación criptográfica.


💰 Monetiza tus propias herramientas MCP

Si estás construyendo un servidor MCP y quieres cobrar micro-tarifas cuando otros agentes llamen a tus herramientas:

npm install payagents-mcp @modelcontextprotocol/sdk zod
import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
import { mcpCharge } from 'payagents-mcp';
import { z } from 'zod';

const server = new McpServer({ name: 'weather-mcp', version: '1.0.0' });

// Gate your tool behind $0.002 micro-payment
server.tool(
  'get_forecast',
  'Retrieve real-time radar forecast data',
  { city: z.string() },
  mcpCharge({ price: '0.002 USD' }, async ({ city }) => {
    return {
      content: [{ type: 'text', text: `Forecast data for ${city}` }],
    };
  })
);

🔒 Políticas de Seguridad y Gasto

Todos los pagos de los agentes son aplicados por el Motor de Políticas de tu Panel de PayAgents:

  • Límite por Transacción: Bloquea cualquier llamada individual que supere tu tope (p. ej. máx. $0.01).

  • Tope de Presupuesto Diario: Evita bucles de recursión descontrolados (p. ej. máx. $5.00/día).

  • Listas de Dominios Permitidos: Restringe el gasto del agente solo a dominios verificados.

  • Disparadores de Aprobación Humana: Las llamadas de alto valor se pausan automáticamente para aprobación humana.


Licencia

MIT © PayAgents

Available Tools

3 tools
payagents_get_balanceA

Retrieve the current PayAgents spending balance, subscription tier, and active enterprise spending policy limits (per-transaction and daily limits).

NameRequiredDescriptionDefault

No parameters

TDQS

A3.9/5.0
Behavior3/5

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

With no annotations, the description must carry the burden. It states it 'Retrieves' data, indicating a read-only operation. However, it does not describe error cases, rate limits, or potential side effects, though for a simple read this is likely sufficient.

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?

The description is a single, focused sentence that lists exactly what is retrieved. It is concise, well‑structured, and contains no fluff.

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?

Since there is no output schema, the description must explain the return value. It explicitly lists all returned items: spending balance, subscription tier, and active policy limits (per‑transaction and daily). This fully informs the agent of what to expect.

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?

There are no parameters, so schema coverage is trivially 100%. The baseline for high coverage is 3, and the description does not add any parameter‑related semantics because there are none to explain.

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 clearly states the specific verb 'Retrieve' and the resource (PayAgents spending balance, tier, and policy limits), making its purpose unambiguous. It also implicitly differentiates from sibling tools like pay_url or get_transaction by focusing on current balance and limits.

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

Usage Guidelines3/5

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

The description implies usage (when balance or limit information is needed) but does not explicitly mention when to use this tool over alternatives. No guidance is given for when to choose this over pay_url or get_transaction, leaving some inference to the agent.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

payagents_get_transactionA

Lookup the status, rail (Lightning / Base USDC), settlement mode (Direct vs Managed), and cryptographic proof for a specific PayAgents transaction ID.

NameRequiredDescriptionDefault
transaction_idYesThe transaction ID or hash to look up.

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations, the description must convey behavioral traits. It indicates the tool retrieves and returns transaction details, implying a read-only operation, but it does not explicitly state side effects, error behavior, or required permissions. The description gives a basic understanding but lacks full transparency.

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?

The description is a single, focused sentence with no redundancy. It efficiently lists the key return fields and the target resource, making it easily scannable and understand.

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 absence of an output schema, the description provides a helpful overview of what the tool returns (status, rail, settlement mode, cryptographic proof). However, it does not describe the exact response structure, potential error cases, or any additional contextual details. It covers the essential information well but leaves some gaps.

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?

The input schema already fully describes the sole parameter (transaction_id) as 'The transaction ID or hash to look up.' The tool description adds the qualifier 'PayAgents' but does not introduce new semantic information. Since schema coverage is 100%, the baseline score of 3 applies.

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 clearly states a specific verb ('Lookup') and resource ('PayAgents transaction ID'), and enumerates the fields returned (status, rail, settlement mode, cryptographic proof). This distinct purpose differentiates it from sibling tools like payagents_pay_url (payment creation) and payagents_get_balance (balance retrieval).

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

Usage Guidelines2/5

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

The description does not provide explicit guidance on when to use this tool versus the sibling tools. It states what the tool does but lacks conditions like 'use when you need transaction details' or 'instead of get_balance for transaction-specific data'. The intended usage remains implicit rather than stated.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

payagents_pay_urlA

Execute a request to an HTTP API endpoint or paywalled resource, automatically resolving and paying any HTTP 402 / L402 Lightning or x402 Base USDC micro-payment challenges within your spending policy.

NameRequiredDescriptionDefault
urlYesThe URL of the API endpoint or paywalled resource to access.
bodyNoOptional request payload/body to send with the request.
methodNoHTTP method to use (defaults to GET).GET
headersNoOptional additional HTTP headers.
max_amountNoMaximum USD amount willing to pay for this request (e.g. "0.01 USD" or "0.002"). Prevents unexpected high charges.

TDQS

A4.2/5.0
Behavior4/5

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

No annotations are provided, so the description carries the full burden. It discloses that the tool automatically resolves and pays payment challenges, which is a significant behavioral trait (it will spend money). It also mentions 'within your spending policy' and the max_amount parameter, which adds context about spending limits. However, it doesn't disclose what happens on failure (e.g., if payment fails, if the request fails), or whether the tool modifies state on the target server. The spending behavior is the most critical disclosure and it's present.

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?

The description is a single, well-structured sentence that front-loads the core action (execute request) and then explains the key differentiator (automatic payment resolution). It's concise with no wasted words. The mention of 'within your spending policy' is a useful qualifier that adds context without bloat.

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?

For a tool that executes HTTP requests with payment handling, the description covers the essential context: what it does, how it handles payments, and the spending constraint. It doesn't describe the return format (no output schema), but for an HTTP request tool, the response is typically the HTTP response body, which is somewhat implied. The description could mention error handling or response format, but given the complexity of the tool (payment resolution), the description is reasonably complete. The lack of output schema is a minor gap.

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 schema already documents all 5 parameters. The description adds context about max_amount ('Prevents unexpected high charges') and the overall purpose of payment resolution, but doesn't add significant meaning beyond the schema. The description's mention of 'spending policy' and 'max_amount' reinforces the parameter's purpose, but the schema already covers it. Baseline 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 clearly states the tool's purpose: executing HTTP requests to API endpoints or paywalled resources, with automatic resolution of HTTP 402/L402/x402 payment challenges. It uses specific verbs ('Execute', 'resolving', 'paying') and identifies the resource (HTTP API endpoint or paywalled resource). It distinguishes itself from siblings (get_balance, get_transaction) by focusing on executing requests with payment handling.

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 implies when to use this tool: when accessing an API endpoint or paywalled resource that may require micro-payments. It doesn't explicitly state when NOT to use it or mention alternatives, but the context of payment challenges is clear. Sibling tools are balance and transaction lookups, which are distinct operations, so the usage context is reasonably clear without explicit exclusions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

  1. 3 tool updatesv0.1.0
    • First observedpayagents_get_balance
    • First observedpayagents_get_transaction
    • First observedpayagents_pay_url

TDQS

A4/5.0

Scored across 3 tools

Disambiguation5/5

Each tool targets a distinct action: payment execution, balance retrieval, and transaction lookup. There is no functional overlap—pay_url performs a side-effectful operation while the other two are read-only queries. An agent can easily distinguish them by purpose.

Naming Consistency5/5

All tools follow a consistent 'payagents_verb_noun' pattern (pay_url, get_balance, get_transaction). The prefix identifies the server, and the verb/noun structure is uniform across the set, making the naming predictable and clear.

Tool Count4/5

With three tools, the server is at the lower end of the typical range, but it appropriately covers the essential operations for its purpose: making a payment, checking balance, and verifying transaction status. The count feels slightly thin but is justified given the narrow domain.

Completeness4/5

The tool surface covers the core workflow: pay, check balance, and look up transaction details. Minor gaps exist, such as listing all transactions or managing spending policies directly, but these are unlikely to cause agent failures for the intended use case. The absence of an update/delete pattern is acceptable since payments are immutable.

Maintenance

ActivityStale
ResponsivenessNo issues

Related MCP Connectors

Related MCP Servers