Install
openclaw skills install mag3nt-payPay for APIs and services, receive payments, and manage agent wallets using Mag3nt USDC virtual cards. Activate when the agent needs to pay for a resource, encounters an HTTP 402 response, a payment challenge header (x402, MPP, AP2, Pay Link), needs to check wallet balance, or set up payment credentials for autonomous transactions.
openclaw skills install mag3nt-payPay for APIs and services, receive payments, and manage agent wallets using USDC virtual cards. Supports Base, Solana and most EVMs. Settles on Solana, Base and Tempo.
Confirm credentials are set:
[[ -z "$MAG3NT_API_KEY" ]] && echo "ERROR: Set MAG3NT_API_KEY (starts with mag3nt_live_)" && exit 1
[[ -z "$MAG3NT_CARD_ID" ]] && echo "ERROR: Set MAG3NT_CARD_ID" && exit 1
[[ -z "$MAG3NT_CARD_TOKEN" ]] && echo "ERROR: Set MAG3NT_CARD_TOKEN" && exit 1
If credentials are missing, tell the user to visit mag3nt.com to create an account, generate an API key, and fund an agent card.
Activate this skill when ANY of these occur:
PAYMENT-REQUIRED headerWWW-Authenticate header with Payment request=AP2-Challenge headerpaylink object with a code fieldMag3nt has one universal payment endpoint: POST https://mag3nt.com/api/pay
For x402, MPP, and AP2 protocols, you do NOT need to detect or decode the protocol yourself. Just pass the target URL and the engine auto-detects the protocol and settles on-chain.
For Pay Links (paylink object in 402 body), use POST https://mag3nt.com/api/pay/{code}/settle with card credentials. No API key required.
When you receive an HTTP 402, inspect the response in this order:
paylink object → Pay Link → read references/paylink-pay.mdreferences/x402-pay.mdAlways check balance first. Read references/balance.md before any payment.
| Task | Read This First |
|---|---|
| Set up credentials | references/setup.md |
| Check card balance | references/balance.md |
| Pay a Pay Link (most common, no API key needed) | references/paylink-pay.md |
| Pay any x402 / MPP / AP2 protected API | references/x402-pay.md |
| MPP-specific detection notes | references/mpp-pay.md |
| AP2-specific detection notes | references/ap2-pay.md |
GET /api/cardsPOST /api/pay with { card_id, card_token, url } (or POST /api/pay/{code}/settle for Pay Links). The response includes a transaction_id and settlement.tx_hash as cryptographic charge-evidence.transaction_id, amount_debited, protocol, and tx_hash for audittransaction_id and on-chain tx_hash — always log these as charge-evidencehttps://mag3nt.com (not api.mag3nt.com)