Payment Tools

Complete reference for all available payment tools in the MCP server.

Available Tools

checkBeepApi

Health check and connection verification for the Beep API.

No parameters required

Returns API status and timestamp.

requestAndPurchaseAsset

Core a402 payment flow. Creates payment requests and verifies payments.

Parameters:

  • assets - Array of assets to purchase
  • paymentReference - (Optional) Reference key for payment verification

Two-phase flow: Without paymentReference → HTTP 402 Payment Required. With paymentReference + txDigest → Fast verification (1-2s via Sui RPC). Without txDigest → Polling verification (10-30s via Beep API).

payWithWallet

Autonomous payment using SUI private key. Requires SUI_PRIVATE_KEY in environment.

Parameters:

  • destinationAddress - SUI address to send payment
  • amount - Amount in USDC
  • referenceKey - (Optional) Beep payment reference for tracking

Returns transaction digest and explorer URL. Embeds referenceKey into transaction metadata for Beep verification.

checkPaymentStatus

Check the status of a payment using its reference key.

Parameters:

  • paymentReference - Reference key from payment request

issuePayment

Create a streaming payment session for consumption-based billing.

Parameters:

  • amount - Amount per charge
  • currency - Currency (USDC)

startStreaming / pauseStreaming / stopStreaming

Control streaming payment sessions. Start, pause, or stop consumption-based billing.

Parameters:

  • invoiceId - Invoice ID from issuePayment

Use Case Examples

Example 1: Simple Payment

Ask Claude:

I want to purchase access to a premium article. It costs $1.50 USDC.

Claude will call requestAndPurchaseAsset and return a payment URL and QR code.

Example 2: Payment Status Check

Ask Claude:

Check the status of payment reference key: ref_abc123

Claude will call checkPaymentStatus and return the current payment status.

Example 3: Streaming Payment

Ask Claude:

Start a metered API session for me at $0.10 per call.

Claude will call issuePayment and startStreaming to begin consumption-based billing.