### Get X402 Revenue Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Returns aggregate revenue statistics across all paywalls, broken down by chain and token. ```javascript get_x402_revenue({}) // → { "total_payments": 892, "revenue": [{ "chain_id": 8453, "token": "USDC", "total": "8.92" }] } ``` -------------------------------- ### Configure AgentWallet MCP for Claude Desktop Source: https://github.com/hifriendbot/agentwallet-mcp/blob/main/README.md Add this JSON configuration to your Claude Desktop or OpenClaw setup to integrate AgentWallet MCP. Ensure AGENTWALLET_USER and AGENTWALLET_PASS are set to your credentials. AGENTWALLET_WALLET_ID is optional and enables x402 auto-pay. ```json { "mcpServers": { "agentwallet": { "command": "npx", "args": ["-y", "agentwallet-mcp"], "env": { "AGENTWALLET_USER": "your_username", "AGENTWALLET_PASS": "your_api_key", "AGENTWALLET_WALLET_ID": "1" } } } } ``` -------------------------------- ### Get Supported Chains Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Lists every supported chain with its chain ID, native token symbol, stablecoin contract address, and RPC status. Use this to look up token addresses before calling certain tools. ```javascript get_chains({}) // → { "chains": [ // { "chain_id": 1, "name": "Ethereum", "native": "ETH", "usdc": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48" }, // { "chain_id": 8453, "name": "Base", "native": "ETH", "usdc": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913" }, // { "chain_id": 900, "name": "Solana", "native": "SOL", "usdc": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v" }, // ... // ] } ``` -------------------------------- ### Get Specific x402 Paywall Details Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Retrieves the complete configuration and statistical data for a single x402 paywall, identified by its unique ID. ```javascript get_paywall({ paywall_id: 42 }) // → { "id": 42, "name": "Premium Data API", "amount": "10000", "token_decimals": 6, "chain_id": 8453, "payment_count": 157, ... } ``` -------------------------------- ### Get Usage Statistics Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Returns the current month's operation count, tier information, remaining free quota, and any accrued fees. ```javascript get_usage({}) // → { "operations_used": 1250, "operations_free": 6000, "operations_remaining": 4750, "fees_accrued": "0.00", "tier": "free" } ``` -------------------------------- ### Get Details for a Specific Wallet Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Fetch detailed information for a single wallet, such as its address, daily spending limits in USD, and pause status. ```javascript get_wallet({ wallet_id: 1 }) // Expected response { "id": 1, "address": "0x3fA8B653F9abf91428800C6fE19B0B4e9F8e1234", "label": "Main", "chain_id": 8453, "status": "active", "daily_limit_usd": "100.00" } ``` -------------------------------- ### Get Token Information Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Fetches the name, symbol, and decimals of any ERC-20 token by making parallel `eth_call` requests. This functionality is EVM-only. ```javascript get_token_info({ token: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", chain_id: 8453 }) // → { "token": "0x8335...", "chain_id": 8453, "name": "USD Coin", "symbol": "USDC", "decimals": 6 } ``` -------------------------------- ### get_balance Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Gets the native token balance (ETH, SOL, POL, BNB, AVAX, etc.) for a wallet on a specific chain. Returns both the raw amount in wei/lamports and a human-readable formatted value. ```APIDOC ## Tool: get_balance Gets the native token balance (ETH, SOL, POL, BNB, AVAX, etc.) for a wallet on a specific chain. Returns both the raw amount in wei/lamports and a human-readable formatted value. ### Parameters #### Path Parameters * `wallet_id` (number) - Required - The ID of the wallet whose balance to check. * `chain_id` (number) - Optional - The ID of the chain for which to check the balance. Uses the wallet's default chain if omitted. ### Request Example ```javascript // Check ETH balance on Base get_balance({ wallet_id: 1, chain_id: 8453 }) // Check SOL balance on Solana get_balance({ wallet_id: 2, chain_id: 900 }) // Uses wallet's default chain if chain_id is omitted get_balance({ wallet_id: 1 }) ``` ### Response #### Success Response - `balance_raw` (string) - The raw balance amount (e.g., in wei or lamports). - `balance` (string) - The human-readable formatted balance. - `token` (string) - The symbol of the native token (e.g., "ETH", "SOL"). - `chain_id` (number) - The ID of the chain the balance was retrieved from. #### Response Example ```json { "balance_raw": "1500000000000000000", "balance": "1.5", "token": "ETH", "chain_id": 8453 } ``` ``` -------------------------------- ### Get Native Token Balance for a Wallet Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Query the native token balance (e.g., ETH, SOL) for a specified wallet on a given chain. The response includes both raw and human-readable amounts. ```javascript // Check ETH balance on Base get_balance({ wallet_id: 1, chain_id: 8453 }) // → { "balance_raw": "1500000000000000000", "balance": "1.5", "token": "ETH", "chain_id": 8453 } // Check SOL balance on Solana get_balance({ wallet_id: 2, chain_id: 900 }) // → { "balance_raw": "2500000000", "balance": "2.5", "token": "SOL", "chain_id": 900 } // Uses wallet's default chain if chain_id is omitted get_balance({ wallet_id: 1 }) ``` -------------------------------- ### get_token_balance Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Gets the ERC-20 (EVM) or SPL (Solana) token balance for a wallet. Returns both raw and human-readable amounts. ```APIDOC ## Tool: get_token_balance Gets the ERC-20 (EVM) or SPL (Solana) token balance for a wallet. Returns both raw and human-readable amounts. ### Parameters #### Path Parameters * `wallet_id` (number) - Required - The ID of the wallet whose token balance to check. * `token` (string) - Required - The contract address (EVM) or mint address (Solana) of the token. * `chain_id` (number) - Required - The ID of the chain the token resides on. * `decimals` (number) - Required - The number of decimal places for the token. ### Request Example ```javascript // USDC on Base (6 decimals) get_token_balance({ wallet_id: 1, token: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", // USDC on Base chain_id: 8453, decimals: 6 }) // USDC on Solana (SPL) get_token_balance({ wallet_id: 2, token: "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v", // USDC mint chain_id: 900, decimals: 6 }) ``` ### Response #### Success Response - `balance_raw` (string) - The raw balance amount. - `balance` (string) - The human-readable formatted balance. - `decimals` (number) - The number of decimal places for the token. #### Response Example ```json { "balance_raw": "50000000", "balance": "50.0", "decimals": 6 } ``` ``` -------------------------------- ### Get Paywall Payments Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Retrieves the on-chain verified payment history for a paywall. Includes TX hashes, payer addresses, amounts, and timestamps. ```javascript get_paywall_payments({ paywall_id: 42, page: 1, per_page: 20 }) // → { "payments": [{ "tx_hash": "0x...", "payer": "0x...", "amount": "0.01", "token": "USDC", "timestamp": "2025-01-15T10:30:00Z" }, ...] } ``` -------------------------------- ### Get ERC-20 or SPL Token Balance for a Wallet Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Retrieve the balance of a specific ERC-20 (EVM) or SPL (Solana) token for a wallet. Requires the token's contract address or mint ID and its decimals. ```javascript // USDC on Base (6 decimals) get_token_balance({ wallet_id: 1, token: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", // USDC on Base chain_id: 8453, decimals: 6 }) // → { "balance_raw": "50000000", "balance": "50.0", "decimals": 6 } // USDC on Solana (SPL) get_token_balance({ wallet_id: 2, token: "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v", // USDC mint chain_id: 900, decimals: 6 }) ``` -------------------------------- ### Get ERC-20 Token Allowance Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Checks the authorized amount of ERC-20 tokens a spender can transfer. Reports 'unlimited' if the allowance is the maximum possible value. EVM only. ```javascript get_allowance({ wallet_id: 1, token: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", spender: "0x2626664c2603336E57B271c5C0b26F421741e481", chain_id: 8453, decimals: 6 }) // → { "allowance_raw": "1000000000", "allowance": "1000.0", "is_unlimited": false, "decimals": 6 } // or → { "allowance": "unlimited", "is_unlimited": true } ``` -------------------------------- ### Create x402 Paywall Source: https://github.com/hifriendbot/agentwallet-mcp/blob/main/README.md Use the `create_paywall` tool to set up a paywall for a resource. When an agent accesses the paywall URL, it will be prompted to pay on-chain before receiving the content. Supports various tokens and chains. ```python create_paywall( wallet_id=1, name="Premium API", amount="0.01", token_name="USDC", token_address="0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", chain_id=8453, resource_url="https://your-api.com/data" ) ``` -------------------------------- ### Buy x402 Verification Credits Source: https://github.com/hifriendbot/agentwallet-mcp/blob/main/README.md Use the `buy_verification_credits` tool to pre-purchase x402 verification credits with USDC. This is useful for keeping paywalls operational beyond the free tier without requiring a credit card. ```python buy_verification_credits() ``` -------------------------------- ### create_paywall Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Creates an x402 paywall that protects any URL with on-chain micropayments. It returns a public access URL. Clients accessing this URL will receive an HTTP 402 response with payment instructions. After successful on-chain payment and retrying with a proof-of-payment header, they will be granted access to the protected content. ```APIDOC ## Tool: create_paywall Creates an x402 paywall that wraps any URL behind an on-chain micropayment. Returns a public access URL — clients that hit the URL receive HTTP 402 with payment instructions; once they pay on-chain and retry with the proof header, they receive the protected content. ```javascript // Charge 0.01 USDC per request on Base create_paywall({ wallet_id: 1, name: "Premium Data API", description: "Real-time market data feed", amount: "0.01", token_type: "erc20", token_address: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", // USDC on Base token_decimals: 6, token_name: "USDC", chain_id: 8453, resource_url: "https://your-api.com/data", resource_mime: "application/json" }) // Expected response { "id": 42, "access_url": "https://hifriendbot.com/x402/42/access", "name": "Premium Data API", "price": "0.01 USDC", "chain_id": 8453, "status": "active" } ``` ``` -------------------------------- ### Create a New EVM or Solana Wallet Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Use the 'create_wallet' tool to generate a new EVM or Solana wallet. The private key is managed server-side. Specify the label and chain ID for the new wallet. ```javascript // MCP tool call create_wallet({ label: "Trading Bot Wallet", chain_id: 8453 // Base (default) }) // Expected response { "id": 7, "address": "0x3fA8B653F9abf91428800C6fE19B0B4e9F8e1234", "label": "Trading Bot Wallet", "chain_id": 8453, "status": "active" } // Solana wallet create_wallet({ label: "Solana Agent", chain_id: 900 }) // → { "id": 8, "address": "7xKXtg2CW87d97TXJSDpbD5jBkheTqA83TZRuJosgHkv", ... } ``` -------------------------------- ### Create an x402 Paywall Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Creates a new x402 paywall that protects a specified URL with an on-chain micropayment requirement. Returns a public access URL. Clients hitting this URL receive an HTTP 402 response with payment instructions. After payment and retrying with a proof header, they receive the protected content. ```javascript // Charge 0.01 USDC per request on Base create_paywall({ wallet_id: 1, name: "Premium Data API", description: "Real-time market data feed", amount: "0.01", token_type: "erc20", token_address: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", // USDC on Base token_decimals: 6, token_name: "USDC", chain_id: 8453, resource_url: "https://your-api.com/data", resource_mime: "application/json" }) // Expected response { "id": 42, "access_url": "https://hifriendbot.com/x402/42/access", "name": "Premium Data API", "price": "0.01 USDC", "chain_id": 8453, "status": "active" } ``` -------------------------------- ### list_paywalls Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Lists all created x402 paywalls, including their IDs, names, pricing details, access URLs, the number of payments received, and the total cumulative revenue generated. ```APIDOC ## Tool: list_paywalls Lists all x402 paywalls with their IDs, names, pricing, access URLs, payment counts, and cumulative revenue. ```javascript list_paywalls({ page: 1, per_page: 50 }) // → { "paywalls": [{ "id": 42, "name": "Premium Data API", "access_url": "...", "payment_count": 157, "revenue_total": "1.57" }, ...] } ``` ``` -------------------------------- ### Pay with x402 Source: https://github.com/hifriendbot/agentwallet-mcp/blob/main/README.md Use the `pay_x402` tool to automatically handle on-chain payments for API requests. Always set `max_payment` to control spending. Supports ERC-20, SPL, and native tokens on EVM and Solana. ```python pay_x402( url="https://api.example.com/premium-data", wallet_id=1, max_payment="1.00" ) ``` -------------------------------- ### Send Native Tokens Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Use this tool to send native tokens like ETH, SOL, or BNB. It accepts human-readable amounts and handles conversion to the appropriate unit (e.g., wei, lamports). ```javascript // Send 0.1 ETH on Base transfer({ wallet_id: 1, to: "0xRecipientAddress000000000000000000000000", amount: "0.1", chain_id: 8453 }) // → { "tx_hash": "0xabc123...", "amount": "0.1", "chain_id": 8453 } ``` ```javascript // Send 1.5 SOL on Solana transfer({ wallet_id: 2, to: "7xKXtg2CW87d97TXJSDpbD5jBkheTqA83TZRuJosgHkv", amount: "1.5", chain_id: 900 }) // → { "signature": "3FsHQp...", "amount": "1.5", "chain_id": 900 } ``` -------------------------------- ### Wrap Native Tokens to ERC-20 Equivalents Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Wraps native tokens (ETH, AVAX, BNB, etc.) into their corresponding ERC-20 wrapped token format (WETH, WAVAX, etc.) by calling the WETH `deposit()` function. This is often a prerequisite for using many DeFi protocols. EVM only. ```javascript // Wrap 0.5 ETH to WETH on Base wrap_eth({ wallet_id: 1, amount: "0.5", chain_id: 8453 }) // → { "tx_hash": "0xmno345...", "wrapped_token": "WETH", "wrapped_address": "0x4200...0006", "amount": "0.5" } // Wrap AVAX to WAVAX on Avalanche wrap_eth({ wallet_id: 1, amount: "10", chain_id: 43114 }) // → { ..., "wrapped_token": "WAVAX", "wrapped_address": "0xB31f66..." } ``` -------------------------------- ### get_chains Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Lists every supported chain with its chain ID, native token symbol, stablecoin contract address, and RPC status. Use this to look up token addresses before calling `transfer_token`, `approve_token`, or `create_paywall`. ```APIDOC ## get_chains ### Description Lists every supported chain with its chain ID, native token symbol, stablecoin contract address, and RPC status. Use this to look up token addresses before calling `transfer_token`, `approve_token`, or `create_paywall`. ### Parameters This endpoint does not require any parameters. ### Request Example ```javascript get_chains({}) ``` ### Response #### Success Response (200) - **chains** (array) - A list of supported chains. - **chain_id** (integer) - The ID of the chain. - **name** (string) - The name of the chain. - **native** (string) - The symbol of the native token. - **usdc** (string) - The contract address of the USDC stablecoin on the chain. #### Response Example ```json { "chains": [ { "chain_id": 1, "name": "Ethereum", "native": "ETH", "usdc": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48" }, { "chain_id": 8453, "name": "Base", "native": "ETH", "usdc": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913" }, { "chain_id": 900, "name": "Solana", "native": "SOL", "usdc": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v" }, ... ] } ``` ``` -------------------------------- ### List All x402 Paywalls Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Retrieves a list of all created x402 paywalls, including their IDs, names, pricing details, access URLs, total payment counts, and cumulative revenue. ```javascript list_paywalls({ page: 1, per_page: 50 }) // → { "paywalls": [{ "id": 42, "name": "Premium Data API", "access_url": "...", "payment_count": 157, "revenue_total": "1.57" }, ...] } ``` -------------------------------- ### create_wallet Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Creates a new EVM or Solana wallet. The private key is generated and encrypted server-side and is never returned to the caller. Returns the wallet ID, address, label, and default chain. ```APIDOC ## Tool: create_wallet Creates a new EVM or Solana wallet. The private key is generated and encrypted server-side and is never returned to the caller. Returns the wallet ID, address, label, and default chain. ### Parameters #### Path Parameters * `label` (string) - Required - A human-readable label for the wallet. * `chain_id` (number) - Optional - The ID of the chain for which to create the wallet. Defaults to Base (8453). ### Request Example ```javascript create_wallet({ label: "Trading Bot Wallet", chain_id: 8453 // Base (default) }) // Solana wallet create_wallet({ label: "Solana Agent", chain_id: 900 }) ``` ### Response #### Success Response - `id` (number) - The unique identifier for the created wallet. - `address` (string) - The blockchain address of the created wallet. - `label` (string) - The label assigned to the wallet. - `chain_id` (number) - The ID of the chain the wallet is associated with. - `status` (string) - The current status of the wallet (e.g., "active"). #### Response Example ```json { "id": 7, "address": "0x3fA8B653F9abf91428800C6fE19B0B4e9F8e1234", "label": "Trading Bot Wallet", "chain_id": 8453, "status": "active" } ``` ``` -------------------------------- ### Add AgentWallet MCP via Claude CLI Source: https://github.com/hifriendbot/agentwallet-mcp/blob/main/README.md Use this bash command to add AgentWallet MCP to your Claude environment. It sets necessary environment variables for authentication and optionally configures x402 auto-pay. ```bash claude mcp add agentwallet \ -e AGENTWALLET_USER=your_username \ -e AGENTWALLET_PASS=your_api_key \ -e AGENTWALLET_WALLET_ID=1 \ -- npx -y agentwallet-mcp ``` -------------------------------- ### get_paywall Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Retrieves the complete configuration and statistical data for a specific x402 paywall, identified by its unique ID. ```APIDOC ## Tool: get_paywall Retrieves the full configuration and statistics for a single x402 paywall by ID. ```javascript get_paywall({ paywall_id: 42 }) // → { "id": 42, "name": "Premium Data API", "amount": "10000", "token_decimals": 6, "chain_id": 8453, "payment_count": 157, ... } ``` ``` -------------------------------- ### wrap_eth Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Wraps native tokens (ETH, AVAX, BNB, POL, PLS) into their corresponding ERC-20 wrapped token equivalents (WETH, WAVAX, WBNB, WPOL, WPLS) by invoking the `deposit()` function. This is often a prerequisite for using DeFi protocols. This function is only available for EVM chains. ```APIDOC ## Tool: wrap_eth Wraps native tokens (ETH, AVAX, BNB, POL, PLS) into their ERC-20 WETH/WAVAX/WBNB/WPOL/WPLS equivalents by calling the WETH `deposit()` payable function. Required for many DeFi protocols. EVM only. ```javascript // Wrap 0.5 ETH to WETH on Base wrap_eth({ wallet_id: 1, amount: "0.5", chain_id: 8453 }) // → { "tx_hash": "0xmno345...", "wrapped_token": "WETH", "wrapped_address": "0x4200...0006", "amount": "0.5" } // Wrap AVAX to WAVAX on Avalanche wrap_eth({ wallet_id: 1, amount: "10", chain_id: 43114 }) // → { ..., "wrapped_token": "WAVAX", "wrapped_address": "0xB31f66..." } ``` ``` -------------------------------- ### get_x402_revenue Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Returns aggregate revenue statistics across all paywalls, broken down by chain and token. ```APIDOC ## get_x402_revenue ### Description Returns aggregate revenue statistics across all paywalls, broken down by chain and token. ### Parameters This endpoint does not require any parameters. ### Request Example ```javascript get_x402_revenue({}) ``` ### Response #### Success Response (200) - **total_payments** (integer) - The total number of payments received across all paywalls. - **revenue** (array) - An array of revenue objects, broken down by chain and token. - **chain_id** (integer) - The ID of the chain. - **token** (string) - The token symbol. - **total** (string) - The total revenue for the specified chain and token. #### Response Example ```json { "total_payments": 892, "revenue": [{ "chain_id": 8453, "token": "USDC", "total": "8.92" }] } ``` ``` -------------------------------- ### Send ERC-20 or SPL Tokens Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt This tool facilitates sending ERC-20 tokens on EVM chains and SPL tokens on Solana. It automatically constructs the necessary transaction data for token transfers. ```javascript // Send 100 USDC on Base transfer_token({ wallet_id: 1, token: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", // USDC to: "0xRecipient000000000000000000000000000000", amount: "100", chain_id: 8453, decimals: 6 }) // → { "tx_hash": "0xdef456...", "token": "0x8335...", "recipient": "0xReci...", "amount": "100", "decimals": 6 } ``` ```javascript // Send USDC on Solana (SPL) transfer_token({ wallet_id: 2, token: "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v", to: "RecipientBase58Address1111111111111111111111", amount: "50", chain_id: 900, decimals: 6 }) ``` -------------------------------- ### get_usage Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Returns the current month's operation count, tier information, remaining free quota, and any accrued fees. ```APIDOC ## get_usage ### Description Returns the current month's operation count, tier information, remaining free quota, and any accrued fees. ### Parameters This endpoint does not require any parameters. ### Request Example ```javascript get_usage({}) ``` ### Response #### Success Response (200) - **operations_used** (integer) - The number of operations used this month. - **operations_free** (integer) - The total number of free operations allowed this month. - **operations_remaining** (integer) - The number of remaining free operations. - **fees_accrued** (string) - The amount of fees accrued this month. - **tier** (string) - The current subscription tier (e.g., "free"). #### Response Example ```json { "operations_used": 1250, "operations_free": 6000, "operations_remaining": 4750, "fees_accrued": "0.00", "tier": "free" } ``` ``` -------------------------------- ### pay_x402 Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Facilitates the complete x402 payment flow for accessing paid API endpoints. It fetches the URL, detects HTTP 402 responses, parses payment requirements, executes on-chain payments from the specified wallet, and retries with a proof-of-payment header. Supports EVM (ERC-20 and native) and Solana (SPL and native SOL) payments. Only HTTPS URLs to public hosts are permitted. ```APIDOC ## Tool: pay_x402 Handles the complete x402 payment flow for accessing a paid API endpoint. Fetches the URL, detects an HTTP 402 response, parses payment requirements, executes the on-chain payment from the specified wallet, and retries with a proof-of-payment header. Supports EVM (ERC-20 and native) and Solana (SPL and native SOL) payments. Only HTTPS URLs to public hosts are permitted. ```javascript // Access a paid API endpoint with max 1 USDC spending limit pay_x402({ url: "https://api.example.com/premium-data", wallet_id: 1, max_payment: "1.00", prefer_chain: 8453 // Prefer Base if multiple chains offered }) // Response when payment was made { "status": 200, "payment_required": true, "payment_made": true, "amount": "0.01", "token": "USDC", "token_address": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", "network": "eip155:8453", "chain_id": 8453, "pay_to": "0xPayeeAddress...", "tx_hash": "0xstu901...", "response": { "data": "... protected content ..." } } // Response when max_payment limit exceeded { "status": 402, "payment_required": true, "payment_made": false, "error": "Payment of 5.00 USDC exceeds your max_payment limit of 1.00", "required_amount": "5.00", "max_allowed": "1.00" } // POST request with body to a paid endpoint pay_x402({ url: "https://api.example.com/generate", wallet_id: 1, method: "POST", body: "{\"prompt\": \"hello\"}", headers: "{\"Content-Type\": \"application/json\"}", max_payment: "0.50" }) ``` ``` -------------------------------- ### list_wallets Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Lists all wallets owned by the authenticated user with their IDs, addresses, labels, chain IDs, and pause status. ```APIDOC ## Tool: list_wallets Lists all wallets owned by the authenticated user with their IDs, addresses, labels, chain IDs, and pause status. ### Parameters This tool does not accept any parameters. ### Request Example ```javascript list_wallets({}) ``` ### Response #### Success Response - `wallets` (array) - A list of wallet objects. - Each wallet object contains: - `id` (number) - The unique identifier for the wallet. - `address` (string) - The blockchain address of the wallet. - `label` (string) - The label assigned to the wallet. - `chain_id` (number) - The ID of the chain the wallet is associated with. - `status` (string) - The current status of the wallet (e.g., "active"). #### Response Example ```json { "wallets": [ { "id": 1, "address": "0xABCDEF...", "label": "Main", "chain_id": 8453, "status": "active" }, { "id": 2, "address": "7xKXtg...", "label": "Solana", "chain_id": 900, "status": "active" } ] } ``` ``` -------------------------------- ### Configure AgentWallet MCP for VS Code Source: https://github.com/hifriendbot/agentwallet-mcp/blob/main/README.md Integrate AgentWallet MCP into your VS Code environment by adding this JSON configuration to your settings. It specifies the command to run and environment variables for authentication and x402 auto-pay. ```json { "mcp": { "servers": { "agentwallet": { "command": "npx", "args": ["-y", "agentwallet-mcp"], "env": { "AGENTWALLET_USER": "your_username", "AGENTWALLET_PASS": "your_api_key", "AGENTWALLET_WALLET_ID": "1" } } } } } ``` -------------------------------- ### delete_paywall Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Permanently deletes an x402 paywall. The access URL will return 404 after deletion. ```APIDOC ## delete_paywall ### Description Permanently deletes an x402 paywall. The access URL will return 404 after deletion. ### Parameters #### Path Parameters - **paywall_id** (integer) - Required - The ID of the paywall to delete. ### Request Example ```javascript delete_paywall({ paywall_id: 42 }) ``` ### Response #### Success Response (200) - **success** (boolean) - Indicates if the deletion was successful. - **deleted_id** (integer) - The ID of the deleted paywall. #### Response Example ```json { "success": true, "deleted_id": 42 } ``` ``` -------------------------------- ### buy_verification_credits Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Purchases additional x402 verification credits using USDC on-chain when the free tier of 1,000 verifications/month is exhausted. Triggers an HTTP 402 payment flow — pay the returned invoice to complete the purchase. ```APIDOC ## buy_verification_credits ### Description Purchases additional x402 verification credits using USDC on-chain when the free tier of 1,000 verifications/month is exhausted. Triggers an HTTP 402 payment flow — pay the returned invoice to complete the purchase. ### Parameters #### Request Body - **count** (integer) - Required - The number of verification credits to purchase. ### Request Example ```javascript // Buy 2000 verification credits buy_verification_credits({ count: 2000 }) ``` ### Response #### Success Response (402) - The response will be an HTTP 402 status code, indicating a payment is required. The body will contain instructions for paying the invoice on-chain using `pay_x402`. ``` -------------------------------- ### update_paywall Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Updates the configuration of an existing x402 paywall. Only the fields provided in the request will be modified. This allows for flexible adjustments to pricing, backend URLs, and paywall status. ```APIDOC ## Tool: update_paywall Updates an x402 paywall's configuration. All fields are optional — only provided fields are changed. ```javascript // Raise the price and point to a new backend URL update_paywall({ paywall_id: 42, amount: "0.05", token_decimals: 6, resource_url: "https://your-api.com/v2/data", name: "Premium Data API v2" }) // Temporarily disable a paywall update_paywall({ paywall_id: 42, is_active: false }) ``` ``` -------------------------------- ### List All User Wallets Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Retrieve a list of all wallets associated with the authenticated user, including their IDs, addresses, labels, chain IDs, and current status. ```javascript list_wallets({}) // Expected response { "wallets": [ { "id": 1, "address": "0xABCDEF...", "label": "Main", "chain_id": 8453, "status": "active" }, { "id": 2, "address": "7xKXtg...", "label": "Solana", "chain_id": 900, "status": "active" } ] } ``` -------------------------------- ### Send Raw Transaction Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Use this tool to sign and broadcast raw transactions, including custom calldata for EVM contract interactions or SPL token parameters for Solana. Prefer `transfer` or `transfer_token` for simple transfers. ```javascript // EVM: Call a custom contract method send_transaction({ wallet_id: 1, to: "0xContractAddress000000000000000000000000", value: "0", data: "0xa9059cbb000000000000000000000000RecipientPadded0000000000000000000000000000000000000000000000000de0b6b3a7640000", chain_id: 8453, gas_limit: "100000" }) // → { "tx_hash": "0xghi789..." } ``` ```javascript // EVM with custom gas settings send_transaction({ wallet_id: 1, to: "0xRecipient", value: "1000000000000000", // 0.001 ETH in wei data: "", chain_id: 1, max_fee: "20000000000", // 20 gwei priority_fee: "1000000000" // 1 gwei }) ``` -------------------------------- ### Delete Paywall Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Permanently deletes an x402 paywall. The access URL will return 404 after deletion. ```javascript delete_paywall({ paywall_id: 42 }) // → { "success": true, "deleted_id": 42 } ``` -------------------------------- ### unpause_wallet Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Resumes a previously paused wallet, re-enabling transaction signing. ```APIDOC ## unpause_wallet ### Description Resumes a previously paused wallet, re-enabling transaction signing. ### Parameters #### Path Parameters - **wallet_id** (integer) - Required - The ID of the wallet to unpause. ### Request Example ```javascript unpause_wallet({ wallet_id: 1 }) ``` ### Response #### Success Response (200) - **wallet_id** (integer) - The ID of the unpaused wallet. - **status** (string) - The new status of the wallet, which will be "active". #### Response Example ```json { "wallet_id": 1, "status": "active" } ``` ``` -------------------------------- ### Update x402 Paywall Configuration Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Modifies the configuration of an existing x402 paywall. Only the fields provided in the request are updated. This can be used to change pricing, backend URLs, or disable the paywall. ```javascript // Raise the price and point to a new backend URL update_paywall({ paywall_id: 42, amount: "0.05", token_decimals: 6, resource_url: "https://your-api.com/v2/data", name: "Premium Data API v2" }) // Temporarily disable a paywall update_paywall({ paywall_id: 42, is_active: false }) ``` -------------------------------- ### Buy Verification Credits Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Purchases additional x402 verification credits using USDC on-chain when the free tier is exhausted. Triggers an HTTP 402 payment flow. ```javascript // Buy 2000 verification credits buy_verification_credits({ count: 2000 }) // → HTTP 402 payment instructions (pay on-chain with pay_x402, then retry) ``` -------------------------------- ### get_token_info Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Fetches the name, symbol, and decimals of any ERC-20 token by making parallel `eth_call` requests to the `name()`, `symbol()`, and `decimals()` methods. This functionality is exclusive to EVM chains. ```APIDOC ## get_token_info Fetches the name, symbol, and decimals of any ERC-20 token by making three parallel `eth_call` requests (`name()`, `symbol()`, `decimals()`). EVM only. ### Parameters - **token** (string) - Required - The address of the ERC-20 token contract. - **chain_id** (number) - Required - The ID of the EVM chain. ### Request Example ```javascript get_token_info({ token: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", chain_id: 8453 }) ``` ### Response Example ```json { "token": "0x8335...", "chain_id": 8453, "name": "USD Coin", "symbol": "USDC", "decimals": 6 } ``` ``` -------------------------------- ### Unpause Wallet Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Resumes a previously paused wallet, re-enabling transaction signing. ```javascript unpause_wallet({ wallet_id: 1 }) // → { "wallet_id": 1, "status": "active" } ``` -------------------------------- ### Approve Token Spending Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Approves a DeFi contract to spend ERC-20 tokens on your behalf. This tool builds and broadcasts the `approve` transaction. Use `"max"` for unlimited approval. EVM only. ```javascript // Approve Uniswap router to spend up to 1000 USDC approve_token({ wallet_id: 1, token: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", spender: "0x2626664c2603336E57B271c5C0b26F421741e481", // Uniswap V3 Router on Base amount: "1000", chain_id: 8453, decimals: 6 }) // → { "tx_hash": "0xjkl012...", "token": "0x8335...", "spender": "0x2626...", "amount": "1000" } ``` ```javascript // Unlimited approval approve_token({ wallet_id: 1, token: "0x8335...", spender: "0x2626...", amount: "max", chain_id: 8453, decimals: 6 }) // → { ..., "amount": "unlimited" } ``` -------------------------------- ### Handle x402 API Payment Flow Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Manages the complete x402 payment process for accessing paid API endpoints. It fetches the URL, detects HTTP 402 errors, parses payment requirements, executes on-chain payments, and retries with proof. Supports EVM and Solana payments. Only HTTPS URLs to public hosts are allowed. ```javascript // Access a paid API endpoint with max 1 USDC spending limit pay_x402({ url: "https://api.example.com/premium-data", wallet_id: 1, max_payment: "1.00", prefer_chain: 8453 // Prefer Base if multiple chains offered }) // Response when payment was made { "status": 200, "payment_required": true, "payment_made": true, "amount": "0.01", "token": "USDC", "token_address": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", "network": "eip155:8453", "chain_id": 8453, "pay_to": "0xPayeeAddress...", "tx_hash": "0xstu901...", "response": { "data": "... protected content ..." } } // Response when max_payment limit exceeded { "status": 402, "payment_required": true, "payment_made": false, "error": "Payment of 5.00 USDC exceeds your max_payment limit of 1.00", "required_amount": "5.00", "max_allowed": "1.00" } // POST request with body to a paid endpoint pay_x402({ url: "https://api.example.com/generate", wallet_id: 1, method: "POST", body: "{\"prompt\": \"hello\"}", headers: "{\"Content-Type\": \"application/json\"}", max_payment: "0.50" }) ``` -------------------------------- ### Call Contract (Read-Only) Source: https://context7.com/hifriendbot/agentwallet-mcp/llms.txt Execute a read-only `eth_call` against any EVM smart contract. This does not consume gas or modify state, returning the raw hex-encoded ABI result. ```javascript // Read USDC total supply (totalSupply() selector = 0x18160ddd) call_contract({ chain_id: 8453, to: "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913", data: "0x18160ddd" }) // → { "result": "0x0000000000000000000000000000000000000000033b2e3c9fd0803ce8000000" } ``` ```javascript // Read balanceOf (selector 0x70a08231, padded owner address) call_contract({ chain_id: 1, to: "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48", data: "0x70a082310000000000000000000000003fA8B653F9abf91428800C6fE19B0B4e9F8e1234" }) ```