Twilio Agent Payments MCP Server

# Twilio Agent Payments MCP Server An MCP (Model Context Protocol) server that enables handling agent-assisted payments via the Twilio API, with

Local serverstdioTypeScript

What is the Twilio Agent Payments MCP server?

If you already use Twilio Agent Payments, the twilio agent payments mcp server is the piece that lets your assistant work with it directly. # Twilio Agent Payments MCP Server An MCP (Model Context Protocol) server that enables handling agent-assisted payments via the Twilio API, with enhanced features for asynchronous callbacks and guided workflow through contextual prompts.

What the server does

  • Process secure payments during voice calls via Twilio
  • Capture payment information (card number, security code, expiration date)
  • Tokenize payment information for PCI compliance
  • Asynchronous callbacks via MCP Resources
  • Guided workflow with MCP Prompts for each step of the payment process
  • Support for re-entry of payment information

Available tools

The toolset is worth reading before you wire it up, because it tells you what the integration is really for:

  • startPaymentCapture — Parameters: - callSid: The Twilio Call SID for the active call
  • captureCardNumber — Parameters: - callSid: The Twilio Call SID for the active call - paymentSid: The Twilio Payment SID for the payment session - captureType: Set to
  • captureSecurityCode — Parameters: - callSid: The Twilio Call SID for the active call - paymentSid: The Twilio Payment SID for the payment session - captureType: Set to
  • captureExpirationDate — Parameters: - callSid: The Twilio Call SID for the active call - paymentSid: The Twilio Payment SID for the payment session - captureType: Set to
  • completePaymentCapture — Parameters: - callSid: The Twilio Call SID for the active call - paymentSid: The Twilio Payment SID for the payment session

Credentials and setup notes

Configuration is passed through the environment: TOKEN_TYPE, CURRENCY, PAYMENT_CONNECTOR, NGROK_AUTH_TOKEN, NGROK_CUSTOM_DOMAIN. Treat anything key-shaped as a real credential — scope it to the minimum the server needs, and rotate it if it ever lands in a shared config.

Installation

Installation goes through your MCP client rather than a global install: point it at twilio-agent-payments-mcp-server on npm and it is fetched when the client starts. The copy-paste blocks for Claude Desktop, Claude Code and Cursor are further down this page.

Where it fits

Among the payments and commerce options, the useful question is rarely "what can it do" but "what does it cost you to run" — permissions, credentials, and how much of your context its toolset consumes. Twilio Agent Payments's toolset — startPaymentCapture, captureCardNumber, captureSecurityCode and 2 more — is a fair guide to whether it matches your workflow. It is maintained by deshartman; worth a glance at recent repository activity before you build anything load-bearing on it.

SyncDev reviews every entry in this directory against the project's own documentation before publishing, and revisits them as servers change.

Worth knowing first

  • It runs with your machine's permissions. That is convenient and also the reason to think about what you point it at before you approve a tool call.
  • Missing credentials fail quietly in some clients — if no tools show up, check the environment block first.
  • Keep per-call confirmation enabled while you learn its behaviour; it is the cheapest safeguard you have.

Available tools

ToolWhat it does
startPaymentCaptureParameters: - callSid: The Twilio Call SID for the active call
captureCardNumberParameters: - callSid: The Twilio Call SID for the active call - paymentSid: The Twilio Payment SID for the payment session - captureType: Set to 'payment-card-number'
captureSecurityCodeParameters: - callSid: The Twilio Call SID for the active call - paymentSid: The Twilio Payment SID for the payment session - captureType: Set to 'security-code'
captureExpirationDateParameters: - callSid: The Twilio Call SID for the active call - paymentSid: The Twilio Payment SID for the payment session - captureType: Set to 'expiration-date'
completePaymentCaptureParameters: - callSid: The Twilio Call SID for the active call - paymentSid: The Twilio Payment SID for the payment session

How to install the Twilio Agent Payments MCP server

{
  "mcpServers": {
    "twilio-agent-payments": {
      "command": "node",
      "args": [
        "/PATHTONODE/twilio-agent-payments-mcp-server/build/index.js",
        "your_account_sid_here",
        "your_api_key_here",
        "your_api_secret_here"
      ],
      "env": {
        "TOKEN_TYPE": "reusable",
        "CURRENCY": "USD",
        "PAYMENT_CONNECTOR": "your_connector_name",
        "NGROK_AUTH_TOKEN": "your_ngrok_auth_token_here",
        "NGROK_CUSTOM_DOMAIN": "your_custom_domain_here" // Optional
      }
    }
  }
}

Configuration as documented by the project. Restart the client after saving.

Configuration

VariableDescriptionRequired
TOKEN_TYPECredential the server authenticates with.Yes
CURRENCYConfiguration value read at startup.Optional
PAYMENT_CONNECTORConfiguration value read at startup.Optional
NGROK_AUTH_TOKENCredential the server authenticates with.Yes
NGROK_CUSTOM_DOMAINConfiguration value read at startup.Optional

Example prompts to try

  • Use Twilio Agent Payments to startPaymentCapture.
  • Use Twilio Agent Payments to captureCardNumber.
  • Use Twilio Agent Payments to captureSecurityCode.

Frequently asked questions

Run via npx: `npx twilio-agent-payments-mcp-server <accountSid> <apiKey> <apiSecret>`, or install globally with `npm install -g twilio-agent-payments-mcp-server` and then run the same command with required arguments.