x402-payments
Enable and integrate x402 crypto payment protocol for XActions API access. Supports multi-chain, multi-token payments for pay-per-use API calls. Use when users want to pay for XActions operations with crypto or integrate x402 into their own agent/app.
Best use case
x402-payments is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Enable and integrate x402 crypto payment protocol for XActions API access. Supports multi-chain, multi-token payments for pay-per-use API calls. Use when users want to pay for XActions operations with crypto or integrate x402 into their own agent/app.
Teams using x402-payments should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/x402-payments/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How x402-payments Compares
| Feature / Agent | x402-payments | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Enable and integrate x402 crypto payment protocol for XActions API access. Supports multi-chain, multi-token payments for pay-per-use API calls. Use when users want to pay for XActions operations with crypto or integrate x402 into their own agent/app.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# x402 Payments
XActions supports the [x402 payment protocol](https://x402.org) — an HTTP-native micropayment standard for pay-per-use API access with cryptocurrency.
## Entry Points
| Goal | Route | Method |
|------|-------|--------|
| Discover payment capabilities | `GET /.well-known/x402` | Public |
| Get OpenAPI spec with payment info | `GET /api/x402/openapi` | Public |
| Make a paid API call | Any protected route | REST API (with x402 headers) |
## Configuration
Config lives in `api/config/x402-config.js`. Key settings:
```js
{
networks: ['base', 'ethereum', 'polygon', 'arbitrum'], // Supported chains
tokens: {
base: ['USDC', 'ETH'],
ethereum: ['USDC', 'USDT', 'ETH'],
polygon: ['USDC', 'MATIC'],
arbitrum: ['USDC', 'ETH'],
},
pricing: {
'POST /api/operations/unfollow': { amount: '0.01', token: 'USDC' },
'POST /api/operations/follow': { amount: '0.005', token: 'USDC' },
// ... per-route pricing
}
}
```
## Discovery (`/.well-known/x402`)
Returns a JSON manifest describing all payable routes, supported networks, and token addresses:
```bash
GET https://api.xactions.io/.well-known/x402
```
Response includes:
- List of payable API endpoints with prices
- Supported blockchain networks
- Token contract addresses per network
- Payment verification endpoint
## Making a Paid Request
x402-compatible clients handle payment automatically. For manual integration:
```bash
# 1. Get payment requirements (HTTP 402 response)
POST /api/operations/unfollow → 402 Payment Required
X-Payment-Required: { amount, token, network, recipient }
# 2. Submit on-chain payment + proof
POST /api/operations/unfollow
X-Payment: <signed-payment-proof>
```
## Middleware
`api/middleware/x402.js` handles:
- Detecting x402-protected routes
- Returning `402 Payment Required` with payment details
- Verifying payment proofs before processing requests
- Multi-chain verification across Base, Ethereum, Polygon, Arbitrum
## Supported Clients
Any x402-compatible client works automatically:
- `x402-axios` — Axios adapter with auto-payment
- `x402-fetch` — Fetch adapter with auto-payment
- Claude agents with x402 MCP tools
- Custom implementations following the x402 spec
## Notes
- x402 payments are per-request — no subscription needed
- Payment proofs are cryptographically verified on-chain before operations run
- Use `/.well-known/x402` for discovery in agent applications
- Stripe billing (`billing-management` skill) remains an alternative for subscription access
## Related Skills
- **billing-management** — Stripe subscription-based payment alternative
- **xactions-mcp-server** — MCP server that uses x402 for AI agent access
- **a2a-multi-agent** — Agent-to-agent workflows that use x402 for paymentRelated Skills
xactions-mcp-server
Free MCP server providing 68+ tools for AI agents to automate X/Twitter. Scrapes profiles, followers, tweets. Posts, follows, likes, retweets, downloads videos, analyzes sentiment, monitors brands, manages DMs, runs workflows, and more. Uses local Puppeteer -- no API keys or payments required. Compatible with Claude Desktop, Cursor, Windsurf, VS Code. Use when setting up or using AI agent Twitter automation via MCP.
xactions-cli
Command-line interface for scraping X/Twitter data, managing MCP server config, and running automation. Scrapes profiles, followers, tweets, search results, and more from terminal. Outputs text, JSON, or CSV. Uses Puppeteer stealth. Use when running Twitter operations from command line or automated pipelines.
x-pro-management
Navigate to X Pro (TweetDeck), set up monitoring columns, and manage multi-column view. Use when users want to use X Pro / TweetDeck features or set up a multi-column dashboard.
webhooks
Create, manage, and test webhooks in XActions. Get notified via HTTP when automation jobs complete, followers change, or operations finish. Use when users want to integrate XActions events into external systems.
viral-thread-generation
Researches trending topics and competitor threads to generate high-engagement thread content with optimized hooks, value ladders, and calls to action. Use when creating threads or planning viral content.
video-downloading
Download videos and GIFs from X/Twitter posts in the browser or via API. Single video, batch download, and quality selection. Use when users want to save or download Twitter/X videos.
topic-management
Browse, follow, and unfollow X Topics. Manage your followed topics list and discover new ones by keyword. Use when users want to follow or unfollow topics on X, or manage their topic feed.
timeline-viewing
Switch between For You / Following timelines, auto-scroll and collect posts, scrape timeline data, and export as JSON. Use when users want to browse, collect, or export tweets from their X timeline.
teams-management
Create and manage teams in XActions — invite members, assign roles, and collaborate on automation tasks. Use when users want to set up multi-user access or team-based account management.
spaces-live
Interacts with X/Twitter Spaces (live audio) including joining rooms, scraping metadata, discovering live or scheduled Spaces, and managing Space participation. Use when finding Spaces, scraping Space data, or interacting with live audio features on X.
settings-privacy
Manages X/Twitter account settings and privacy controls including protected tweets, muted words, content filtering, notification preferences, and account configuration. Use when changing privacy settings, managing muted words, or configuring account preferences.
saved-searches
Create, manage, and run saved searches on X/Twitter. Save search queries, list saved searches, delete them, and run them to see fresh results. Use when users want to save or manage search queries on X.