Prerequisites
- macOS (Apple Silicon or Intel) or Linux (x64 or arm64)
- A terminal with
bash - USDC on Sui to spend (mainnet) — or use testnet to try it for free
1. Install
Install the prebuilt binary for your platform. This dropstpay into ~/.tpay/bin and adds it to your PATH:
--version:
2. Create a wallet
tpay setup generates a keypair, stores the secret in your OS keychain, and makes it the active wallet:
The secret key is stored in your operating system keychain, not in a file. On macOS, unlocking it requires Touch ID.
3. Fund the wallet
Send USDC to the address from the previous step. To check your balance at any time:--network testnet to check testnet:
4. Pay for an API
tpay curl works exactly like curl. When the server returns 402 Payment Required, tpay settles the payment from your wallet and retries the request:
Next steps
Paying for APIs
How
tpay curl handles x402, approvals, and receipts.Connect an agent
Let Claude and other MCP clients pay through the wallet.
Manage wallets
Create, import, export, and switch between wallets.
CLI reference
Every command and flag.