Skip to content
Business
Skill

/moonpay-x402

Make paid API requests to x402-protected endpoints. Automatically handles payment with your local wallet.

BOOST
From plugin
moonpay-skills
11142 skills
Install
$ npx -y skills add moonpay/skills --skill moonpay-x402 --agent claude-code

How it fires

How this skill gets triggered: by you, by Claude, or both.

  • Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
  • You can call itInvoke it directly when you want it.
  • Slash command/moonpay-x402

Context preview

The summary Claude sees to decide when to auto-load this skill.

Make paid API requests to x402-protected endpoints. Automatically handles payment with your local wallet.

SKILL.md

moonpay-x402.SKILL.md
name: moonpay-x402
description: Make paid API requests to x402-protected endpoints. Automatically handles payment with your local wallet.
tags: [payments, api]

x402 paid API requests

Goal

Make HTTP requests to x402-protected endpoints. The CLI automatically detects 402 Payment Required responses, builds and signs a payment transaction with your local wallet, and retries the request with the payment proof.

Command

mp x402 request \
  --method POST \
  --url <x402-endpoint-url> \
  --body '<json-body>' \
  --wallet <wallet-name-or-address> \
  --chain solana

Available x402 endpoints

| Endpoint | Cost | Input | |----------|------|-------| | `https://agents.moonpay.com/x402/upgrade` | $1-$20 | `{"duration": "day"}` or `{"duration": "month"}` |

Example flow

1. User: "Upgrade my rate limit for a day." 2. Run: `mp upgrade --duration day --wallet my-wallet --chain solana` 3. The CLI handles the 402 payment flow automatically and applies the upgrade.

Notes

  • Requires a local wallet with USDC on Solana or Base.
  • Payments accepted on Solana mainnet and Base.
  • If the request fails (status >= 400), the payment is not settled — you don't pay for errors.
  • Use **moonpay-auth** to set up a local wallet first.

Related skills

  • **moonpay-auth** — Create or import a local wallet.
  • **moonpay-check-wallet** — Check your wallet balance before making paid requests.
  • **moonpay-upgrade** — Upgrade your rate limit via x402.
Read more
Ships withmoonpay-skills

Agent Skills for crypto infrastructure — wallet management, token trading, cross-chain bridges, fiat on/off ramp, prediction markets, and more. Skills are instructional folders that AI agents load dynamically to perform specialized tasks.

Get the whole plugin

Other skills on moonpay-skills.