CAT
/MCP
SkillsMCPMarketplacesDigestToolsAdvertise

This week in Claude

Every Monday: Claude Code, Agent SDK, MCP, and the Anthropic platform moves worth your time.

Skills by Category
Frontend DevelopmentBackend & APIsTesting & QASecurityDevOps & CI/CDGit & Pull RequestsDocumentationCode Review & QualityAI & Agent BuildingSkill Development
MCP Servers by Category
Sales & MarketingWeb & Browser AutomationDatabasesAI & LLM ToolsCloud & InfrastructureCommunication & MessagingDeveloper ToolsDesign & CreativeDocuments & KnowledgeSearch & Web Crawling
Marketplaces by Category
AI Agents & OrchestrationLLM IntegrationDevelopment ToolsFrontend & UIBackend & APIsDatabasesTesting & Code QualityDevOps & CloudSecurity & ComplianceGit & Version Control

Cross AI Tools

Discover Claude Code plugins, extensions, and tools. Automatically updated directory of Anthropic Claude AI marketplaces with development tools, productivity plugins, and integrations.

Resources

  • Browse Skills
  • Browse MCP Servers
  • Browse Marketplaces
  • Plugins Reference

Community

  • About
  • Tools
  • Feedback
  • Privacy Policy
  • Advertise

Built for the Claude Code community with Claude Code by @mertduzgun

Independent project, not affiliated with Anthropic

Xenarch Mcp

xenarch-ai/xenarch-mcp
29 toolsauthSTDIO, HTTPregistry active
Summary

Turns Claude into a paying API consumer using USDC on Base L2. Exposes three tools: xenarch_check_gate to inspect if a URL requires payment, xenarch_pay to sign an EIP-3009 transfer and fetch gated content, and xenarch_get_history to review past transactions. The agent wallet only needs USDC, never ETH. Payments settle on-chain directly to the publisher with zero platform fees. Implements the x402 spec for HTTP 402 responses. Reach for this when you want Claude to autonomously pay for paywalled APIs or content without API keys, subscriptions, or manual approval flows. Works with any MCP client including Cursor, LangChain, and CrewAI.

CodeRabbit
CodeRabbit
AI writes the code. CodeRabbit catches the slop.
Try For Free →
Keep your Mac awake
Keep your Mac awake
Keep your Mac awake while Claude Code and 40+ AI agents run. Sleeps when they're idle.
One time payment $9 →
Context.devContext.dev
Context.dev
Integrate web data into your AI product. One API to scrape website & brand data.
Get API Key Now →
Make your agent a DeFi expert
Make your agent a DeFi expert
Agent, run crypto. Access onchain data & trade routes via 1inch.
Install now →
Make money from your Skills
Make money from your Skills
On Capafy, your Skill runs online 24/7 as an agent product, and you get paid every time someone uses it.
Start earning →
AppSignal
AppSignal
Monitor with ease. Code with confidence.
Start Free Trial →
CodeRabbit
CodeRabbit
AI writes the code. CodeRabbit catches the slop.
Try For Free →
Keep your Mac awake
Keep your Mac awake
Keep your Mac awake while Claude Code and 40+ AI agents run. Sleeps when they're idle.
One time payment $9 →
Context.devContext.dev
Context.dev
Integrate web data into your AI product. One API to scrape website & brand data.
Get API Key Now →
Make your agent a DeFi expert
Make your agent a DeFi expert
Agent, run crypto. Access onchain data & trade routes via 1inch.
Install now →
Make money from your Skills
Make money from your Skills
On Capafy, your Skill runs online 24/7 as an agent product, and you get paid every time someone uses it.
Start earning →
AppSignal
AppSignal
Monitor with ease. Code with confidence.
Start Free Trial →

Tools

Public tool metadata for what this MCP can expose to an agent.

29 tools
xenarch_check_gateCheck if a URL or domain has an x402 payment gate. Returns gate status, accepted payment requirements (price, asset, network), and the seller wallet. Use this before paying to confirm pricing, when a URL returns HTTP 402 Payment Required, or when a user asks whether content is...1 params

Check if a URL or domain has an x402 payment gate. Returns gate status, accepted payment requirements (price, asset, network), and the seller wallet. Use this before paying to confirm pricing, when a URL returns HTTP 402 Payment Required, or when a user asks whether content is...

Parameters* required
urlstring
The URL or domain to check for an x402 payment gate. Accepts a full URL (https://example.com/article) or bare domain (example.com). Returns pricing in USD and payment requirements if gated.
xenarch_payPay an x402-gated URL with USDC on Base L2 and return the gated content. Signs an EIP-3009 transferWithAuthorization, settles on-chain, then re-fetches the resource with proof of payment. Returns the on-chain tx_hash, seller wallet, and the response body. Settles directly to t...1 params

Pay an x402-gated URL with USDC on Base L2 and return the gated content. Signs an EIP-3009 transferWithAuthorization, settles on-chain, then re-fetches the resource with proof of payment. Returns the on-chain tx_hash, seller wallet, and the response body. Settles directly to t...

Parameters* required
urlstring
The URL or domain to pay for. Must have an active x402 payment gate. Payment settles in USDC on Base L2, agent wallet to seller wallet direct. The agent wallet only ever holds USDC; no ETH or other gas coin needed.
xenarch_get_historyList past USDC micropayments made by this wallet through Xenarch. Returns transaction hashes, URLs, domains, amounts in USD, timestamps, total spend, and payment count. Optionally filter by domain. Use this to audit spending, check if you already paid for a resource, or track...2 params

List past USDC micropayments made by this wallet through Xenarch. Returns transaction hashes, URLs, domains, amounts in USD, timestamps, total spend, and payment count. Optionally filter by domain. Use this to audit spending, check if you already paid for a resource, or track...

Parameters* required
limitinteger
Maximum number of payment records to return (1-100, default 10). Use higher values to see full spending history.default: 10
domainstring
Filter payment history by domain (e.g. 'example.com'). Omit to return all payments across all domains.
xenarch_agent_loginSign in to the agent control plane using your browser wallet — no CLI needed. First call returns a link; open it, sign in with your wallet on the dashboard, and approve. Call this tool again to finish — the 7-day session is then used by every other xenarch_agent_* tool. Use th...

Sign in to the agent control plane using your browser wallet — no CLI needed. First call returns a link; open it, sign in with your wallet on the dashboard, and approve. Call this tool again to finish — the 7-day session is then used by every other xenarch_agent_* tool. Use th...

No parameter schema in public metadata yet.

xenarch_agent_statusShow the operator's agent profile (name, paused state) and spend summary for a period. Read-only. Needs a SIWE session from `xenarch agent login`.1 params

Show the operator's agent profile (name, paused state) and spend summary for a period. Read-only. Needs a SIWE session from `xenarch agent login`.

Parameters* required
periodstring
Spend-summary window.one of 24h · 7d · 30d · alldefault: 24h
xenarch_agent_get_capsRead the agent's spending caps (per-transaction, daily, monthly) and remaining headroom. Read-only.

Read the agent's spending caps (per-transaction, daily, monthly) and remaining headroom. Read-only.

No parameter schema in public metadata yet.

xenarch_agent_set_capsSet spending caps. Pass per_tx/daily/monthly in USD ('none' disables an axis); omit an axis to leave it unchanged. RAISING or REMOVING a cap requires confirm: true (returns needs_confirmation otherwise). Tightening is free.4 params

Set spending caps. Pass per_tx/daily/monthly in USD ('none' disables an axis); omit an axis to leave it unchanged. RAISING or REMOVING a cap requires confirm: true (returns needs_confirmation otherwise). Tightening is free.

Parameters* required
dailystring
Daily cap in USD, or 'none' to disable. Omit to leave unchanged.
per_txstring
Per-transaction cap in USD, or 'none' to disable. Omit to leave unchanged.
confirmboolean
Required true to RAISE or REMOVE a cap (a loosening change).default: false
monthlystring
Monthly cap in USD, or 'none' to disable. Omit to leave unchanged.
xenarch_agent_reset_day_capReset today's daily-spend counter back to the full daily cap (recovery from accidental mid-day exhaustion).

Reset today's daily-spend counter back to the full daily cap (recovery from accidental mid-day exhaustion).

No parameter schema in public metadata yet.

xenarch_agent_get_scopeRead the agent's scope: default posture (allow/deny) and the allow/deny rule list. Read-only.

Read the agent's scope: default posture (allow/deny) and the allow/deny rule list. Read-only.

No parameter schema in public metadata yet.

xenarch_agent_add_scope_ruleAdd an allow/deny scope rule. A 'deny' rule tightens (free); an 'allow' rule loosens and requires confirm: true.4 params

Add an allow/deny scope rule. A 'deny' rule tightens (free); an 'allow' rule loosens and requires confirm: true.

Parameters* required
modestring
'deny' blocks (tightens); 'allow' permits (loosens — needs confirm).one of allow · deny
labelstring
Optional human label for the rule.
confirmboolean
Required true for an 'allow' rule (loosens scope).default: false
patternstring
URL/domain glob the rule matches, e.g. 'api.example.com/*'.
xenarch_agent_remove_scope_ruleRemove a scope rule by id (full UUID or unambiguous prefix). Removing a DENY rule loosens scope and requires confirm: true.2 params

Remove a scope rule by id (full UUID or unambiguous prefix). Removing a DENY rule loosens scope and requires confirm: true.

Parameters* required
idstring
Scope rule id (full UUID or unambiguous prefix from get_scope).
confirmboolean
Required true when removing a DENY rule (loosens scope).default: false
xenarch_agent_set_default_scopeSet the default scope posture for unmatched URLs. 'deny' tightens (free); 'allow' loosens and requires confirm: true.2 params

Set the default scope posture for unmatched URLs. 'deny' tightens (free); 'allow' loosens and requires confirm: true.

Parameters* required
modestring
Default posture for unmatched URLs. 'allow' loosens — needs confirm.one of allow · deny
confirmboolean
Required true to switch the default to 'allow'.default: false
xenarch_agent_pauseKill switch: pause the agent so all of its payments are blocked immediately. Tightening, so no confirm needed.

Kill switch: pause the agent so all of its payments are blocked immediately. Tightening, so no confirm needed.

No parameter schema in public metadata yet.

xenarch_agent_resumeLift the pause so the agent can spend again (subject to caps + scope). Requires confirm: true.1 params

Lift the pause so the agent can spend again (subject to caps + scope). Requires confirm: true.

Parameters* required
confirmboolean
Required true: resuming re-enables the agent's spending.default: false
xenarch_agent_list_keysList the agent's xa_live_ API keys (id, label, last-used, revoked state). Never returns plaintext. Read-only.

List the agent's xa_live_ API keys (id, label, last-used, revoked state). Never returns plaintext. Read-only.

No parameter schema in public metadata yet.

xenarch_agent_create_keyIssue a new xa_live_ API key (plaintext returned once). Issues a live spending credential — requires confirm: true.2 params

Issue a new xa_live_ API key (plaintext returned once). Issues a live spending credential — requires confirm: true.

Parameters* required
labelstring
Optional label for the new key.
confirmboolean
Required true: issues a live xa_live_ spending credential.default: false
xenarch_agent_rotate_keyRotate an API key by id (full UUID or prefix) — invalidates the old secret, returns a new one once. Requires confirm: true.2 params

Rotate an API key by id (full UUID or prefix) — invalidates the old secret, returns a new one once. Requires confirm: true.

Parameters* required
key_idstring
Key id (full UUID or unambiguous prefix).
confirmboolean
Required true: invalidates the key's current secret.default: false
xenarch_agent_revoke_keyPermanently revoke an API key by id (full UUID or prefix). Requires confirm: true.2 params

Permanently revoke an API key by id (full UUID or prefix). Requires confirm: true.

Parameters* required
key_idstring
Key id (full UUID or unambiguous prefix).
confirmboolean
Required true: permanently disables the key.default: false
xenarch_agent_get_receiptsList the agent's payment receipts with filters (period, status, source, domain) and pagination. Read-only.6 params

List the agent's payment receipts with filters (period, status, source, domain) and pagination. Read-only.

Parameters* required
pageinteger
Page number.default: 1
domainstring
Filter by domain.
periodstring
Time window.one of 24h · 7d · 30d · alldefault: all
sourcestring
Filter by source channel.one of cli · mcp · sdk · custom
statusstring
Filter by status.one of paid · pending · failed
per_pageinteger
Rows per page (max 100).default: 25
xenarch_list_linksList the merchant's pay-links (newest first), with cursor pagination. Read-only. Needs a SIWE session from `xenarch agent login`.2 params

List the merchant's pay-links (newest first), with cursor pagination. Read-only. Needs a SIWE session from `xenarch agent login`.

Parameters* required
limitinteger
Page size (default 25)
starting_afterstring
Cursor: last link_id of the previous page
xenarch_get_linkGet one pay-link's detail (status, params, stats) by id. Read-only.1 params

Get one pay-link's detail (status, params, stats) by id. Read-only.

Parameters* required
link_idstring
The pay-link id
xenarch_create_linkCreate a pay-link. VALIDATE-FIRST: call with mode:'validate' (default) to learn which fields are missing (each missing field includes a prompt to ask the user); once valid, call again with mode:'create' and confirm:true to sign + create. Signs with the agent's local key — the...6 params

Create a pay-link. VALIDATE-FIRST: call with mode:'validate' (default) to learn which fields are missing (each missing field includes a prompt to ask the user); once valid, call again with mode:'create' and confirm:true to sign + create. Signs with the agent's local key — the...

Parameters* required
kindstring
Pay-link kind: invoice, subscription, donation, ticket, bounty, paywall, api_metering, checkout, quick_charge
modestring
validate (default) returns missing fields; create signs + createsone of validate · create
amountstring
Amount in USDC, e.g. '0.99' (max 1.00), or 'open'
fieldsobject
Any additional create-body fields by name (see xenarch_create_link validate output / GET /v1/links/schema)
confirmboolean
Required to actually sign + create in create mode
product_namestring
Product / line label
xenarch_revoke_linkRevoke a pay-link by id so it can no longer be paid. Requires confirm: true (returns needs_confirmation otherwise).2 params

Revoke a pay-link by id so it can no longer be paid. Requires confirm: true (returns needs_confirmation otherwise).

Parameters* required
confirmboolean
Required to revoke
link_idstring
The pay-link id to revoke
xenarch_list_paymentsList payments RECEIVED across the merchant's pay-links (newest first), with cursor pagination. Read-only.2 params

List payments RECEIVED across the merchant's pay-links (newest first), with cursor pagination. Read-only.

Parameters* required
limitinteger
Page size (default 25)
starting_afterstring
Cursor: last payment id of the previous page
xenarch_list_subscribersList subscribers across the merchant's subscription pay-links, with optional filters (link_id, status, mode). Read-only.5 params

List subscribers across the merchant's subscription pay-links, with optional filters (link_id, status, mode). Read-only.

Parameters* required
modestring
reminder | permit | stream
limitinteger
Page size (default 50)
statusstring
active | cancelled | pending_email_verification | failed | exhausted
link_idstring
Filter by a subscription link
starting_afterstring
Cursor: last subscription_id of the previous page
xenarch_get_merchant_profileGet the merchant profile (issuer identity, domain verification status). Read-only. Returns null if none is set yet.

Get the merchant profile (issuer identity, domain verification status). Read-only. Returns null if none is set yet.

No parameter schema in public metadata yet.

xenarch_update_merchant_profileUpdate the merchant profile (issuer name, site, email, address, tax id, brand color, logo, payout rhythm). Only the fields you pass change; the rest are preserved (whole-state upsert).8 params

Update the merchant profile (issuer name, site, email, address, tax id, brand color, logo, payout rhythm). Only the fields you pass change; the rest are preserved (whole-state upsert).

Parameters* required
brand_colorstring
Accent color, e.g. #5a9fd4
issuer_namestring
issuer_emailstring
issuer_tax_idstring
merchant_sitestring
Your domain, e.g. example.com
issuer_addressstring
issuer_logo_urlstring
HTTPS logo URL (must match your domain)
collection_rhythmstring
one of daily · weekly · monthly · never
xenarch_verify_domainVerify the merchant's domain via its DNS TXT record at _xenarch.<merchant_site> (XEN-394). Set merchant_site first via xenarch_update_merchant_profile.

Verify the merchant's domain via its DNS TXT record at _xenarch.<merchant_site> (XEN-394). Set merchant_site first via xenarch_update_merchant_profile.

No parameter schema in public metadata yet.

xenarch_pay_linkPay a Xenarch pay-link by id (wrapped x402): fetches the link's payment envelope, settles EIP-3009 USDC on Base, and confirms the payment with the link. Use this for pay.xenarch.com/l/<id> links; use xenarch_pay for arbitrary x402-gated URLs. Pays from the agent wallet (USDC o...2 params

Pay a Xenarch pay-link by id (wrapped x402): fetches the link's payment envelope, settles EIP-3009 USDC on Base, and confirms the payment with the link. Use this for pay.xenarch.com/l/<id> links; use xenarch_pay for arbitrary x402-gated URLs. Pays from the agent wallet (USDC o...

Parameters* required
link_idstring
The Xenarch pay-link id to pay
max_price_usdnumber
Refuse to pay if the price exceeds this (default 1.00)

Xenarch — x402 MCP server for AI agent payments

npm License: MIT

Xenarch is a non-custodial x402 MCP server. AI agents — Claude, Cursor, LangChain, CrewAI — pay for HTTP 402—gated APIs and content with USDC micropayments on Base L2. No API keys, no subscriptions, no credit card on file. The agent wallet never needs ETH; USDC is the only token it ever holds. Payments settle on-chain: agent wallet → publisher wallet, direct. 0% Xenarch fee — there's no Xenarch contract in the money flow.

What makes Xenarch different

Cloudflare Pay-Per-CrawlStripeTollBitVercel x402-mcpOther x402 MCP serversXenarch
Works on any host× (Cloudflare only)✓× (enterprise)Vercel-first✓✓
Non-custodial×××platform-routedvaries✓ direct USDC transfer
Agent needs ETHn/an/an/avariesvaries✓ never
Feeplatform rate2.9% + $0.30platform rateplatform ratevaries0%, structurally
Open standardproprietaryproprietaryproprietaryx402x402x402 + pay.json (authored by Xenarch)
Publisher monetization✓ (Cloudflare-gated)✓ (any stack)✓ (enterprise only)××✓ (any stack)

How it works

1. Discover    xenarch_check_gate("example.com")
               → { gated: true, accepts: [...] }

2. Pay         xenarch_pay("example.com")
               → x402-fetch signs an EIP-3009 USDC transferWithAuthorization
               → Settlement goes on-chain
               → Re-fetches the resource with proof of payment
               → { tx_hash, content }

No API keys. No signup. The agent wallet only ever needs USDC — no ETH, no gas coin of any kind. Xenarch never holds funds and there is no Xenarch contract between the agent and the publisher.

MCP tools

29 tools across three groups. Group 1 (discovery & payments) works with just a wallet. Groups 2 and 3 (control plane + merchant) manage your Xenarch account and need a SIWE session — run xenarch agent login once (see Account tools auth).

1. Discovery & payments — agent wallet only

ToolDescription
xenarch_check_gateCheck if a URL/domain has an x402 payment gate. Returns the accepted payment requirements — price, asset, network, seller wallet.
xenarch_payPay for an x402-gated URL. Signs an EIP-3009 USDC transfer, settles on-chain, returns the tx hash and the gated content.
xenarch_pay_linkPay a Xenarch pay-link by id (pay.xenarch.com/l/<id>): fetches the envelope, settles USDC on Base, confirms with the link.
xenarch_get_historyView past payments made by this wallet (totals, per-domain, pagination).

2. Agent control plane — manage your spending agent (SIWE session)

Caps, scope, kill-switch, and API keys for the operator's agent. Privileged (loosening) operations require confirm: true; tightening is free.

ToolDescription
xenarch_agent_loginBrowser-wallet sign-in to the control plane. Returns a link; open it, approve, call again to finish. The 7-day session powers every other xenarch_agent_* tool.
xenarch_agent_statusAgent profile (name, paused state) + spend summary for a period. Read-only.
xenarch_agent_get_capsRead spending caps (per-tx, daily, monthly) + remaining headroom. Read-only.
xenarch_agent_set_capsSet caps in USD (none disables an axis). Raising/removing a cap needs confirm: true; tightening is free.
xenarch_agent_reset_day_capReset today's daily-spend counter to the full daily cap.
xenarch_agent_get_scopeRead scope: default posture (allow/deny) + the rule list. Read-only.
xenarch_agent_add_scope_ruleAdd an allow/deny rule. deny tightens (free); allow loosens (needs confirm).
xenarch_agent_remove_scope_ruleRemove a rule by id/prefix. Removing a deny loosens scope (needs confirm).
xenarch_agent_set_default_scopeSet the posture for unmatched URLs. deny tightens; allow loosens (needs confirm).
xenarch_agent_pauseKill switch — block all of the agent's payments immediately. No confirm.
xenarch_agent_resumeLift the pause (needs confirm).
xenarch_agent_list_keysList the agent's xa_live_ API keys (id, label, last-used, revoked). Never returns plaintext. Read-only.
xenarch_agent_create_keyIssue a new xa_live_ key (plaintext returned once). Needs confirm.
xenarch_agent_rotate_keyRotate a key by id/prefix — invalidates the old secret, returns a new one once. Needs confirm.
xenarch_agent_revoke_keyPermanently revoke a key by id/prefix. Needs confirm.
xenarch_agent_get_receiptsList the agent's payment receipts with filters (period, status, source, domain). Read-only.

3. Merchant — get paid (SIWE session)

Create and manage pay-links, see payments and subscribers, set the merchant profile. Same SIWE session as the control plane.

ToolDescription
xenarch_create_linkCreate a pay-link. VALIDATE-FIRST: mode:'validate' reports missing fields; then mode:'create' + confirm:true signs + creates. Amount is USDC (max 1.00).
xenarch_list_linksList the merchant's pay-links (newest first), cursor-paginated. Read-only.
xenarch_get_linkGet one pay-link's detail (status, params, stats) by id. Read-only.
xenarch_revoke_linkRevoke a pay-link by id so it can no longer be paid. Needs confirm.
xenarch_list_paymentsList payments received across the merchant's links (newest first), cursor-paginated. Read-only.
xenarch_list_subscribersList subscribers across subscription links, with filters (link_id, status, mode). Read-only.
xenarch_get_merchant_profileGet the merchant profile (issuer identity, domain-verification status). Read-only.
xenarch_update_merchant_profileUpdate the merchant profile (name, site, email, address, tax id, brand color, logo, payout rhythm). Whole-state upsert.
xenarch_verify_domainVerify the merchant's domain via its _xenarch.<site> DNS TXT record. Set the site first via xenarch_update_merchant_profile.

Account tools auth

  • Payments (group 1) need a funded wallet (XENARCH_PRIVATE_KEY) and a control-plane link (XENARCH_API_TOKEN) — the official MCP refuses to pay without the token (XEN-480: an unlinked agent has no caps). A local per-call cap (XENARCH_MAX_PAYMENT_USD, default $1) applies on top of the managed per-tx / daily / monthly caps.
  • Control plane + merchant (groups 2–3) need a SIWE session. Run xenarch agent login once — it writes a 7-day session_token to ~/.xenarch/config.json, which the MCP server reads automatically. Re-run when it expires, or call xenarch_agent_login directly from your client.
  • Set XENARCH_API_TOKEN (an xa_live_ agent key) so xenarch_pay is enforced against your managed caps/scope and every MCP payment shows up in the dashboard receipts feed. The dashboard is free — sign in with your wallet at dash.xenarch.dev (just a signature, nothing moves) for per-tx / daily / monthly caps, scope rules, a kill switch, and full history. Without the token, xenarch_pay refuses to pay (fail-closed) so an unlinked agent can't settle uncapped. Note: the dashboard sign-in wallet is your identity — separate from the agent's local spending wallet.

Example responses

xenarch_check_gate
{
  "gated": true,
  "gate_id": "7f3a1b2c-9d4e-4a8b-b6f1-2c3d4e5f6a7b",
  "accepts": [
    {
      "scheme": "exact",
      "network": "base",
      "maxAmountRequired": "3000",
      "resource": "https://example.com/article",
      "payTo": "0xabc123...publisher_wallet",
      "asset": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
      "maxTimeoutSeconds": 60
    }
  ],
  "seller_wallet": "0xabc123...publisher_wallet",
  "network": "base",
  "asset": "USDC"
}
xenarch_pay
{
  "success": true,
  "gate_id": "7f3a1b2c-9d4e-4a8b-b6f1-2c3d4e5f6a7b",
  "tx_hash": "0xdef456...abc789",
  "seller_wallet": "0xabc123...publisher_wallet",
  "url": "https://example.com/article",
  "wallet": "0x123...your_wallet",
  "content": "...gated content here..."
}
xenarch_get_history
{
  "payments": [
    {
      "domain": "example.com",
      "amount_usd": "0.003",
      "tx_hash": "0xdef456...abc789",
      "paid_at": "2026-04-10T14:35:00Z"
    }
  ],
  "total_spent_usd": "0.003000",
  "count": 1,
  "wallet": "0x123...your_wallet"
}

HTTP 402 — the unused status code that x402 finally activates

HTTP 402 Payment Required is a status code reserved in the HTTP spec since 1997 for machine-to-machine payment. It went unused for decades because there was no open protocol for how a client should pay a 402 response.

x402 is that protocol: a server returns HTTP 402 with a signed price and payment details, the client signs a USDC micropayment on Base L2, and retries the request with proof of payment. Xenarch's MCP server automates both halves for AI agents — it reads the 402 challenge, signs the payment via x402-fetch, and replays the request, returning the on-chain tx hash plus the gated content.

Learn more: the x402 spec defines the payment handshake; pay.json (authored by Xenarch) is the companion open standard for machine-readable pricing served at /.well-known/pay.json — think robots.txt for payments.

API monetization with HTTP 402

Xenarch is an API monetization primitive built on the HTTP 402 spec. Unlike API gateway monetization platforms (Apigee, Kong, AWS API Gateway) that require subscriptions, dashboards, and API keys, Xenarch lets any API charge per request with no account creation and no key provisioning — the caller pays USDC on Base L2, the API verifies the on-chain transaction, access is granted.

For publishers, this means:

  • No integration with Stripe/card processors
  • No subscription plans, pricing tiers, or quota dashboards
  • No custodial balance held by a platform
  • Per-request pricing that works for human users, bots, and AI agents uniformly
  • API monetization that settles on-chain in real time

The Python SDK includes a one-decorator FastAPI middleware; see xenarch-sdks/python for publisher integration.

Setup

  1. Configure your wallet:
mkdir -p ~/.xenarch
cat > ~/.xenarch/wallet.json << 'EOF'
{
  "privateKey": "0xYOUR_PRIVATE_KEY"
}
EOF
chmod 600 ~/.xenarch/wallet.json
  1. Add to Claude Code:
claude mcp add xenarch -- npx @xenarch/agent-mcp

Or add the same JSON to any MCP client's config file:

  • Claude Desktop — ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) / %APPDATA%\Claude\claude_desktop_config.json (Windows)
  • Cursor — ~/.cursor/mcp.json (global) or .cursor/mcp.json (per-project)
  • Cline (VS Code) — the MCP Servers panel → "Configure MCP Servers", or cline_mcp_settings.json
{
  "mcpServers": {
    "xenarch": {
      "command": "npx",
      "args": ["@xenarch/agent-mcp"],
      "env": {
        "XENARCH_PRIVATE_KEY": "0xYOUR_PRIVATE_KEY",
        "XENARCH_API_TOKEN": "xa_live_…optional, enforces caps/scope"
      }
    }
  }
}
  1. Fund the wallet with USDC on Base. That's it — no ETH, no other token needed.

  2. (Optional) To use the control-plane + merchant tools, run xenarch agent login once to create a SIWE session.

Environment variables

VariableDefaultDescription
XENARCH_PRIVATE_KEY—Wallet private key (overrides config file)
XENARCH_API_TOKEN—Required. Agent xa_live_ key. Enforces xenarch_pay against your caps/scope and feeds the dashboard receipts. Without it, xenarch_pay refuses to pay (fail-closed).
XENARCH_RPC_URLhttps://mainnet.base.orgBase RPC endpoint
XENARCH_API_BASEhttps://xenarch.devXenarch platform API
XENARCH_NETWORKbaseNetwork (base or base-sepolia)
XENARCH_MAX_PAYMENT_USD1.00Local per-call payment cap (USDC). The only spending ceiling in standalone mode — xenarch_pay refuses any single payment above it. Set 0 to remove the cap. For managed per-tx / daily / monthly caps, connect XENARCH_API_TOKEN.

The control-plane + merchant tools don't use an env var for auth — they read the SIWE session_token that xenarch agent login writes to ~/.xenarch/config.json.

Examples

See xenarch-examples for working integration examples — Python agents, LangChain, CrewAI, Claude Desktop setup, and publisher middleware.

Development

npm install
npm run build

Structure

packages/
  shared/    — Payment logic, types, config (reused across servers)
  agent/     — MCP server for AI agents

FAQ

How does Claude pay for APIs with Xenarch? Install the Xenarch MCP server (claude mcp add xenarch -- npx @xenarch/agent-mcp), give it a wallet, and Claude resolves any HTTP 402 response automatically with a USDC micropayment on Base L2.

Does Xenarch work with Cursor, LangChain, or CrewAI? Yes. Xenarch exposes an MCP server that any MCP-compatible client can use — Claude Code, Claude Desktop, Cursor, Cline, LangChain, CrewAI, and any other client that speaks Model Context Protocol.

Is FastAPI supported for publishers? Yes, via the Python SDK (pip install xenarch[fastapi]) — a one-decorator middleware returns HTTP 402 with the price and verifies the on-chain payment. See xenarch-sdks/python.

Is Xenarch custodial? No. Payments settle on-chain as a direct USDC transfer from the agent wallet to the publisher wallet. Funds never touch Xenarch infrastructure and there is no Xenarch contract in the money flow.

Does the agent need ETH for gas? No. USDC is the only token the agent wallet ever needs. Fund it with USDC and you're done — no ETH, no other gas coin.

What's the fee? 0%, structurally. Xenarch never sits in the money flow — there's no Xenarch contract that could charge a fee.

What's the maximum payment per call? $1 USD.

What is x402? x402 is an open protocol for HTTP 402 Payment Required. A server returns 402 with a price, the client signs a USDC micropayment on Base L2 (or other supported chain), and retries the request with proof of payment.

What is HTTP 402? HTTP 402 Payment Required is a status code reserved in the HTTP spec since 1997 for machine-to-machine payment. x402 is the open protocol that finally uses it.

How does Xenarch compare to Cloudflare Pay-Per-Crawl? Cloudflare Pay-Per-Crawl only works for sites behind Cloudflare and is custodial. Xenarch works on any host and is non-custodial — publishers are paid directly on-chain.

How does Xenarch compare to TollBit? TollBit is enterprise-licensing focused. Xenarch is self-serve, non-custodial, and works for the long tail of publishers and any AI agent without enterprise contracts.

Links

  • Website: https://xenarch.com
  • npm: https://www.npmjs.com/package/@xenarch/agent-mcp
  • PyPI: https://pypi.org/project/xenarch/
  • Smithery: https://smithery.ai/servers/xenarch/xenarch-mcp
  • GitHub: https://github.com/xenarch-ai/xenarch-mcp

License

MIT

Featured
CodeRabbit
CodeRabbit
AI writes the code. CodeRabbit catches the slop.
Try For Free →
Keep your Mac awake
Keep your Mac awake
Keep your Mac awake while Claude Code and 40+ AI agents run. Sleeps when they're idle.
One time payment $9 →
Context.devContext.dev
Context.dev
Integrate web data into your AI product. One API to scrape website & brand data.
Get API Key Now →
Make your agent a DeFi expert
Make your agent a DeFi expert
Agent, run crypto. Access onchain data & trade routes via 1inch.
Install now →
Make money from your Skills
Make money from your Skills
On Capafy, your Skill runs online 24/7 as an agent product, and you get paid every time someone uses it.
Start earning →
AppSignal
AppSignal
Monitor with ease. Code with confidence.
Start Free Trial →

Configuration

XENARCH_PRIVATE_KEYsecret

Wallet private key (hex, 0x-prefixed). Auto-generates on first run if omitted.

XENARCH_RPC_URL

Base RPC endpoint URL

XENARCH_NETWORK

Network for payments (base or base-sepolia)

XENARCH_AUTO_APPROVE_MAX

Max USD to auto-approve without prompting

PORT

Port for HTTP server (default: 3000)

TRANSPORT*

Set to 'http' to enable HTTP transport

Categories
AI & LLM Tools
Registryactive
Package@xenarch/agent-mcp
TransportSTDIO, HTTP
AuthRequired
UpdatedJun 4, 2026
View on GitHub

Related AI & LLM Tools MCP Servers

View all →
SkillFM LLM Cost Optimizer

io.github.ericm1018/skillfm-llm-cost-optimizer-openai-anthropic-usage

LLM cost optimizer for OpenAI, Anthropic, token usage, BYOK, and SkillFM Beacon audits.
Llm Orchestration Agent

io.github.mikerawsonnz/llm-orchestration-agent

Run a prompt through a LangChain (system + human) chain over Gemini on Vertex AI; optional LangSmith
Authenticated Llm Agent

io.github.mikerawsonnz/authenticated-llm-agent

JWT-gated LLM gateway: authenticate (bcrypt/JWT), then run a LangChain-on-Vertex Gemini completion.
Copilot Memory MCP

labforgedev/copilot-memory-mcp

Persistent semantic memory for AI agents using local ChromaDB vector search. No cloud required.
1
Agent Prompt Injection Firewall Mcp

csoai-org/agent-prompt-injection-firewall-mcp

The WAF for agents. Pattern-based + heuristic firewall scans prompts, RAG documents, tool argume...
Authenticated Multi Llm Agent

io.github.mikerawsonnz/authenticated-multi-llm-agent

Google-OAuth-gated LLM gateway: verify a Google ID token, then run a Gemini (Vertex AI) completion f