界面已本地化;技能介绍与说明文档按所选语言由 AI 自动翻译,代码、命令、路径和专业术语保留原文,以原作者文档为准。
探索技能
效率与协作 · SKILL.md

fluxa-agent-wallet

fluxa-agent-wallet

【效率与协作】FluxA Agent Wallet integration via CLI. Enables agents to make x402 payments for paid APIs, send USDC payouts to any wallet, and create payment links to receive payments — all through a standalone Node.js CLI tool. Use when the user asks about crypto payments, x402, USDC transfers, payment links, or interacting with the FluxA Agent Wallet.

独立 GitHub 快照 · 自动分类 · 以原作者文档为准

技能说明

GitHub

name: fluxa-agent-wallet description: >- FluxA Agent Wallet integration via CLI. Enables agents to make x402 payments for paid APIs, send USDC payouts to any wallet, and create payment links to receive payments — all through a standalone Node.js CLI tool. Use when the user asks about crypto payments, x402, USDC transfers, payment links, or interacting with the FluxA Agent Wallet.

FluxA Agent Wallet

FluxA Agent Wallet lets AI agents perform onchain financial operations — payments, payouts, and payment links — without managing private keys. This skill uses the FluxA CLI (fluxa-cli.bundle.js), a standalone Node.js script requiring no npm installation.

Setup

The CLI bundle is located at scripts/fluxa-cli.bundle.js within this skill directory. It requires Node.js v18+.

node scripts/fluxa-cli.bundle.js <command> [options]

All commands output JSON to stdout:

{ "success": true, "data": { ... } }

Or on error:

{ "success": false, "error": "Error message" }

Exit code 0 = success, 1 = failure.

Capabilities

CapabilityWhat it doesWhen to use
x402 Payment (v3)Pay for APIs using the x402 protocol with intent mandatesAgent hits HTTP 402, needs to pay for API access
PayoutSend USDC to any wallet addressAgent needs to transfer funds to a recipient
Payment LinkCreate shareable URLs to receive paymentsAgent needs to charge users, create invoices, sell content

Prerequisites — Register Agent ID

Before any operation, the agent must have an Agent ID. Register once:

node scripts/fluxa-cli.bundle.js init \
  --email "agent@example.com" \
  --name "My AI Agent" \
  --client "Agent v1.0"

Or pre-configure via environment variables:

export AGENT_ID="ag_xxxxxxxxxxxx"
export AGENT_TOKEN="tok_xxxxxxxxxxxx"
export AGENT_JWT="eyJhbGciOiJ..."

Verify status:

node scripts/fluxa-cli.bundle.js status

The CLI automatically refreshes expired JWTs.

Quick Decision Guide

  • Need to pay for an API that returned HTTP 402? → See X402-PAYMENT.md
  • Need to send funds to a wallet address? → See PAYOUT.md
  • Need to receive payments via a shareable link? → See PAYMENT-LINK.md

Amount Format

All amounts are in smallest units (atomic units). For USDC (6 decimals):

Human-readableAtomic units
0.01 USDC10000
0.10 USDC100000
1.00 USDC1000000
10.00 USDC10000000

All Commands

CommandDescription
statusCheck agent configuration
initRegister agent ID
mandate-createCreate an intent mandate
mandate-statusQuery mandate status
x402-v3Execute x402 v3 payment
payoutCreate a payout
payout-statusQuery payout status
paymentlink-createCreate a payment link
paymentlink-listList payment links
paymentlink-getGet payment link details
paymentlink-updateUpdate a payment link
paymentlink-deleteDelete a payment link
paymentlink-paymentsView payments received via a link

Environment Variables

VariableDescription
AGENT_IDPre-configured agent ID
AGENT_TOKENPre-configured agent token
AGENT_JWTPre-configured agent JWT
AGENT_EMAILEmail for auto-registration
AGENT_NAMEAgent name for auto-registration
CLIENT_INFOClient info for auto-registration
FLUXA_DATA_DIRCustom data directory (default: ~/.fluxa-ai-wallet-mcp)
WALLET_APIWallet API base URL (default: https://walletapi.fluxapay.xyz)
AGENT_ID_APIAgent ID API base URL (default: https://agentid.fluxapay.xyz)
我的收藏