@visa/cli
v1.0.2
Published
AI-powered payments for Claude Code
Readme
Visa CLI
Enable AI agents to make real payments. Two commands to start, zero build steps.
npm install -g @visa/cli
visa-cli setupThen ask Claude:
Generate me an image of a sunsetQuick Start
1. Install
npm install -g @visa/cli2. Setup
visa-cli setupThis does three things in one step:
- Registers the MCP server with Claude Code
- Opens a browser for GitHub sign-in + card enrollment
- Generates a Secure Enclave attestation key (for Touch ID verification)
Restart Claude Code or run /mcp to connect, then start using it.
3. Start Using It
Ask Claude naturally:
Generate me an image of a sunsetWhat's the price of SOL right now?Make me a lofi jazz beatAll payments are handled automatically with your enrolled card. Touch ID confirms each transaction. Result URLs (images, track pages) open automatically in your browser.
Available Tools
| Tool | What it does |
|------|-------------|
| pay | Pay a merchant URL (auto-detects payment rail) |
| generate_image_card | Generate an AI image via fal.ai |
| generate_music_tempo_card | Generate a music track via Suno AI |
| check_music_status_tempo_card | Check music generation status and get audio URLs |
| query_onchain_prices_card | Query real-time token prices from 150+ blockchains |
| batch | Run any tool multiple times in parallel with one Touch ID approval |
| get_status | Check enrollment, cards, and spending controls |
| transaction_history | View recent transactions |
| update_spending_controls | Set daily limit, max per-transaction, approval mode |
| add_card | Add a payment card |
| login | GitHub sign-in + card enrollment |
| feedback | Submit feedback about Visa CLI |
| reset | Clear all credentials from this device |
Security
Every payment requires Touch ID (macOS) via Secure Enclave. This cannot be disabled or bypassed — attestation is verified server-side.
| Layer | Protection | |-------|------------| | Session token | macOS Keychain (only credential on device) | | Touch ID | Secure Enclave ECDSA signing (hardware-backed) | | Spending limits | Server-side enforcement | | Rate limiting | Server-side per-session | | Card data | Server-side only (never touches the client) |
Spending Controls
| Setting | Default | Description | |---------|---------|-------------| | Max per transaction | $100 | Per-transaction ceiling | | Daily limit | $500 | Daily spend ceiling | | Daily transaction count | 50 | Daily transaction count ceiling |
Adjust with: "Set my daily limit to $200"
CLI Commands
visa-cli setup # Install, login, and enroll card
visa-cli install claude # Register MCP server with Claude Code
visa-cli status # Show enrollment and spending controls
visa-cli login # Re-authenticate
visa-cli add-card # Add a new payment card
visa-cli feedback "msg" # Submit feedback about Visa CLI
visa-cli reset --confirm # Clear session and attestation keyTroubleshooting
"Authentication required" — Run visa-cli setup to log in and enroll a card.
"Session expired" — Run visa-cli setup to re-authenticate.
"Amount exceeds limit" — Ask Claude to increase your spending limit, or use update_spending_controls.
"Rate limited" — Wait a few seconds and try again.
Batch request failed / "Merchant server error" — The upstream API (e.g. fal.ai) may be temporarily overloaded. Wait a minute and retry with a smaller batch. Timeouts scale automatically with batch size.
Tools not showing in Claude Code — Run /mcp in Claude Code to reconnect, or restart Claude Code.
Requirements
- macOS (Touch ID or system password required for payment approval)
- Node.js 18+
- Claude Code
Legal
Use of this software is governed by the Visa CLI Terms of Use and Privacy Notice.
