{"id":6181,"date":"2025-08-04T06:05:12","date_gmt":"2025-08-04T06:05:12","guid":{"rendered":"https:\/\/blog.mathwallet.xyz\/?p=6181"},"modified":"2026-04-23T09:03:25","modified_gmt":"2026-04-23T09:03:25","slug":"math-ai-agent-%e4%bd%bf%e7%94%a8%e6%95%99%e7%a8%8b","status":"publish","type":"post","link":"https:\/\/blog.mathwallet.xyz\/?p=6181","title":{"rendered":"MathWallet Agent CLI \u4f7f\u7528\u6559\u7a0b"},"content":{"rendered":"\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/\">https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/<\/a><\/p>\n\n\n\n<p>\u9762\u5411 AI Agent \u81ea\u52a8\u5316\u7684\u591a\u94fe Web3 \u94b1\u5305\u547d\u4ee4\u884c\u5de5\u5177\u3002\u4e00\u5957 BIP39 \u52a9\u8bb0\u8bcd\u6d3e\u751f\u6240\u6709\u94fe\u5730\u5740\uff0c\u652f\u6301&nbsp;<strong>EVM<\/strong>\uff08Ethereum\u3001BSC\u3001Polygon\u3001Arbitrum\u3001Optimism\u3001Base\u3001Avalanche \u7b49\uff09\u3001<strong>Solana<\/strong>\u3001<strong>Bitcoin<\/strong>\u3001<strong>TRON<\/strong>\u3001<strong>SUI<\/strong>\u3001<strong>TON<\/strong>\u3002\u529f\u80fd\u5305\u62ec\uff1aCAIP-2 \u94fe\u6807\u8bc6\u3001\u4f59\u989d\u67e5\u8be2\uff08\u542b USD \u4f30\u503c\uff09\u3001\u4ee3\u5e01\u53d1\u9001\u3001\u4ea4\u6613\u8bb0\u5f55\u3001\u79bb\u7ebf\u7b7e\u540d\u3001MathSwap \u4ee3\u5e01\u5151\u6362\u3001x402 HTTP \u652f\u4ed8\u534f\u8bae\uff0c\u4ee5\u53ca\u9762\u5411 AI Agent \u4e92\u8054\u7684&nbsp;<strong>A2A JSON-RPC \u670d\u52a1\u5668<\/strong>\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2>\u73af\u5883\u8981\u6c42<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#%E7%8E%AF%E5%A2%83%E8%A6%81%E6%B1%82\"><\/a><\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>\u4f9d\u8d56<\/th><th>\u7248\u672c<\/th><\/tr><\/thead><tbody><tr><td>Node.js<\/td><td>\u2265 20.0.0<\/td><\/tr><tr><td>pnpm<\/td><td>\u63a8\u8350 8+<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2>\u5b89\u88c5<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#%E5%AE%89%E8%A3%85\"><\/a><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># 1. \u5b89\u88c5\u4f9d\u8d56\uff08\u5728\u9879\u76ee\u6839\u76ee\u5f55\uff09\npnpm install\n\n# 2. \u7f16\u8bd1\npnpm build\n\n# 3a. \u76f4\u63a5\u8fd0\u884c\uff08\u5f00\u53d1\u9636\u6bb5\uff09\nnode packages\/mathwallet-cli\/dist\/index.js &lt;\u547d\u4ee4&gt;\n\n# 3b. \u5168\u5c40\u94fe\u63a5\uff08\u63a8\u8350\u65e5\u5e38\u4f7f\u7528\uff09\ncd packages\/mathwallet-cli &amp;&amp; npm link\nmathwallet &lt;\u547d\u4ee4&gt;\n\n# 3c. npm \u5168\u5c40\u5b89\u88c5\uff08\u53d1\u5e03\u540e\uff09\nnpm install -g @mathwallet\/agent-cli<\/pre>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2>\u521d\u59cb\u5316\u94b1\u5305<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#%E5%88%9D%E5%A7%8B%E5%8C%96%E9%92%B1%E5%8C%85\"><\/a><\/p>\n\n\n\n<p>\u9996\u6b21\u4f7f\u7528\u524d\u5fc5\u987b\u6267\u884c\u4e00\u6b21\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">mathwallet init<\/pre>\n\n\n\n<p>\u5728&nbsp;<code>~\/.mathwallet\/<\/code>&nbsp;\u76ee\u5f55\u4e0b\u521b\u5efa\uff1a<\/p>\n\n\n\n<ul><li><code>.encryption-key<\/code>&nbsp;\u2014 32 \u5b57\u8282\u673a\u5668\u7ed1\u5b9a AES \u5bc6\u94a5\uff08\u6743\u9650 0600\uff09<\/li><li><code>wallet.enc<\/code>&nbsp;\u2014 AES-256-GCM \u52a0\u5bc6\u7684 BIP39 \u52a9\u8bb0\u8bcd\uff080600\uff09<\/li><\/ul>\n\n\n\n<blockquote class=\"wp-block-quote\"><p>\u52a9\u8bb0\u8bcd<strong>\u4e0d\u4f1a\u663e\u793a<\/strong>\u5728\u7ec8\u7aef\u3002\u8fc1\u79fb\u5230\u65b0\u673a\u5668\u65f6\uff0c\u5fc5\u987b\u540c\u65f6\u62f7\u8d1d&nbsp;<code>wallet.enc<\/code>&nbsp;\u548c&nbsp;<code>.encryption-key<\/code>&nbsp;\u4e24\u4e2a\u6587\u4ef6\u3002<\/p><\/blockquote>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2>\u94fe\u6807\u8bc6\u683c\u5f0f\uff08CAIP-2\uff09<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#%E9%93%BE%E6%A0%87%E8%AF%86%E6%A0%BC%E5%BC%8Fcaip-2\"><\/a><\/p>\n\n\n\n<p><code>--chain<\/code>&nbsp;\u53c2\u6570\u652f\u6301\u4e09\u79cd\u7b49\u4ef7\u683c\u5f0f\uff1a<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>\u683c\u5f0f<\/th><th>\u793a\u4f8b<\/th><th>\u8bf4\u660e<\/th><\/tr><\/thead><tbody><tr><td>CAIP-2<\/td><td><code>eip155:1<\/code><\/td><td>\u63a8\u8350\uff0c\u65e0\u6b67\u4e49<\/td><\/tr><tr><td>\u522b\u540d<\/td><td><code>ethereum<\/code><\/td><td>\u6613\u8bfb\u7b80\u5199<\/td><\/tr><tr><td>Chain ID<\/td><td><code>1<\/code><\/td><td>\u4ec5 EVM \u94fe\u53ef\u7528<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>\u7c7b\u578b\u5173\u952e\u8bcd\uff08<code>evm<\/code>\u3001<code>solana<\/code>\u3001<code>bitcoin<\/code>\u3001<code>tron<\/code>\u3001<code>sui<\/code>\u3001<code>ton<\/code>\uff09\u53ef\u5339\u914d\u8be5\u7c7b\u578b\u4e0b\u6240\u6709\u94fe\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2>\u547d\u4ee4\u53c2\u8003<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#%E5%91%BD%E4%BB%A4%E5%8F%82%E8%80%83\"><\/a><\/p>\n\n\n\n<p>\u5927\u591a\u6570\u547d\u4ee4\u652f\u6301&nbsp;<code>--json<\/code>&nbsp;\u53c2\u6570\uff0c\u4ee5\u7ed3\u6784\u5316 JSON \u683c\u5f0f\u8f93\u51fa\u7ed3\u679c\uff0c\u66ff\u4ee3\u9ed8\u8ba4\u7684\u4eba\u7c7b\u53ef\u8bfb\u6587\u672c\u3002\u683c\u5f0f\u7edf\u4e00\u4e3a\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">{ \"success\": true,  \"data\": { ... } }\n{ \"success\": false, \"error\": \"\u9519\u8bef\u4fe1\u606f\" }<\/pre>\n\n\n\n<p>\u51fa\u9519\u65f6\u9000\u51fa\u7801\u4e3a&nbsp;<code>1<\/code>\u3002\u652f\u6301 CAIP-2 \u7684\u94fe\u4f1a\u5728 JSON \u54cd\u5e94\u4e2d\u5305\u542b&nbsp;<code>caip2<\/code>&nbsp;\u5b57\u6bb5\uff08\u5982&nbsp;<code>\"caip2\": \"eip155:1\"<\/code>\uff09\u3002<code>export<\/code>&nbsp;\u547d\u4ee4\u4ec5\u652f\u6301\u4ea4\u4e92\u6a21\u5f0f\uff0c\u4e0d\u652f\u6301&nbsp;<code>--json<\/code>\u3002<\/p>\n\n\n\n<h3><code>status<\/code>&nbsp;\u2014 \u68c0\u67e5\u94b1\u5305\u72b6\u6001<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#status--%E6%A3%80%E6%9F%A5%E9%92%B1%E5%8C%85%E7%8A%B6%E6%80%81\"><\/a><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">mathwallet status\nmathwallet status --json<\/pre>\n\n\n\n<p>\u68c0\u67e5&nbsp;<code>wallet.enc<\/code>&nbsp;\u548c&nbsp;<code>.encryption-key<\/code>&nbsp;\u662f\u5426\u5b58\u5728\u3002\u6267\u884c\u4efb\u4f55\u94b1\u5305\u64cd\u4f5c\u524d\u5efa\u8bae\u5148\u8c03\u7528\u6b64\u547d\u4ee4\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h3><code>export<\/code>&nbsp;\u2014 \u5bfc\u51fa\u52a9\u8bb0\u8bcd<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#export--%E5%AF%BC%E5%87%BA%E5%8A%A9%E8%AE%B0%E8%AF%8D\"><\/a><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">mathwallet export<\/pre>\n\n\n\n<blockquote class=\"wp-block-quote\"><p>\u5fc5\u987b\u5728\u4ea4\u4e92\u5f0f\u7ec8\u7aef\u4e2d\u6267\u884c\uff0c\u5e76\u624b\u52a8\u8f93\u5165&nbsp;<code>EXPORT<\/code>&nbsp;\u786e\u8ba4\uff1b\u4e0d\u652f\u6301&nbsp;<code>--json<\/code>\u3002<\/p><\/blockquote>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h3><code>chain<\/code>&nbsp;\u2014 \u7ba1\u7406\u94fe\u914d\u7f6e<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#chain--%E7%AE%A1%E7%90%86%E9%93%BE%E9%85%8D%E7%BD%AE\"><\/a><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">mathwallet chain list                # \u5217\u51fa\u6240\u6709\u94fe\uff08CAIP-2 + \u522b\u540d + \u7c7b\u578b + \u7b26\u53f7\uff09\nmathwallet chain list --json\n\n# \u66f4\u6362 RPC \u8282\u70b9\nmathwallet chain rpc --chain eip155:1 --rpc https:\/\/mainnet.infura.io\/v3\/YOUR_KEY\nmathwallet chain rpc --chain ethereum  --rpc https:\/\/mainnet.infura.io\/v3\/YOUR_KEY\n\n# \u8bbe\u7f6e API Key\uff08TON\u3001TRON \u7b49\u9700\u8981\u8ba4\u8bc1\u7684\u8282\u70b9\uff09\nmathwallet chain apikey --chain ton --key YOUR_TONCENTER_KEY\n\n# \u6dfb\u52a0\u81ea\u5b9a\u4e49 EVM \u94fe\nmathwallet chain add \\\n  --name     mychain \\\n  --chain-id 999 \\\n  --rpc      https:\/\/rpc.mychain.com \\\n  --symbol   XYZ \\\n  --type     evm \\\n  --explorer https:\/\/explorer.mychain.com<\/pre>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h3><code>address<\/code>&nbsp;\u2014 \u67e5\u770b\u94b1\u5305\u5730\u5740<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#address--%E6%9F%A5%E7%9C%8B%E9%92%B1%E5%8C%85%E5%9C%B0%E5%9D%80\"><\/a><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">mathwallet address                   # \u6bcf\u79cd\u94fe\u7c7b\u578b\u5404\u663e\u793a\u4e00\u4e2a\u5730\u5740\nmathwallet address --chain ethereum  # \u6307\u5b9a\u5355\u6761\u94fe\nmathwallet address --chain eip155:1  # \u540c\u4e0a\uff0cCAIP-2 \u683c\u5f0f\nmathwallet address --json<\/pre>\n\n\n\n<p>\u6307\u5b9a&nbsp;<code>--chain<\/code>&nbsp;\u65f6\u53ea\u8f93\u51fa\u5730\u5740\u5b57\u7b26\u4e32\uff0c\u65b9\u4fbf\u811a\u672c\u7ba1\u9053\u8c03\u7528\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">ADDR=$(mathwallet address --chain ethereum)<\/pre>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h3><code>balance<\/code>&nbsp;\u2014 \u67e5\u8be2\u4f59\u989d\uff08\u542b USD \u4f30\u503c\uff09<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#balance--%E6%9F%A5%E8%AF%A2%E4%BD%99%E9%A2%9D%E5%90%AB-usd-%E4%BC%B0%E5%80%BC\"><\/a><\/p>\n\n\n\n<p><strong>\u9ed8\u8ba4\uff08\u4e0d\u4f20\u53c2\u6570\uff09\uff1a<\/strong>&nbsp;\u67e5\u8be2 10 \u6761\u5e38\u7528\u94fe \u2014 EVM\uff1aethereum\u3001bsc\u3001base\u3001polygon\u3001arbitrum\uff1b\u975e EVM\uff1abitcoin\u3001solana\u3001sui\u3001ton\u3001tron\u3002<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">mathwallet balance                                      # \u9ed8\u8ba4 10 \u6761\u94fe\nmathwallet balance --chain ethereum                     # \u5355\u6761\u94fe\nmathwallet balance --chain ethereum,base                # \u591a\u6761\u94fe\uff08\u9017\u53f7\u5206\u9694\uff09\nmathwallet balance --chain ethereum --chain base        # \u591a\u6761\u94fe\uff08\u91cd\u590d\u53c2\u6570\uff09\nmathwallet balance --chain evm                          # \u914d\u7f6e\u4e2d\u5168\u90e8 EVM \u94fe\nmathwallet balance --all                                # \u5168\u90e8\u5df2\u914d\u7f6e\u94fe\uff08\u6162\uff0c\u614e\u7528\uff09\nmathwallet balance --chain ethereum --sort-by-value --json\nmathwallet balance --refresh                            # \u5f3a\u5236\u5237\u65b0\u4ee3\u5e01\u5217\u8868\u7f13\u5b58\n\n# \u67e5\u8be2\u6307\u5b9a\u5408\u7ea6\u4ee3\u5e01\uff08\u9700\u5355\u4e00\u5177\u4f53 --chain\uff09\nmathwallet balance --chain eip155:1 --token-contract 0xdAC17F958D2ee523a2206206994597C13D831ec7 --json<\/pre>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>\u53c2\u6570<\/th><th>\u5fc5\u586b<\/th><th>\u8bf4\u660e<\/th><\/tr><\/thead><tbody><tr><td><code>--chain<\/code><\/td><td>\u5426<\/td><td>\u4e00\u6761\u6216\u591a\u6761\u94fe\u3002\u53ef\u91cd\u590d\u6216\u9017\u53f7\u5206\u9694\u3002<code>evm<\/code>&nbsp;\u5339\u914d\u6240\u6709 EVM \u94fe<\/td><\/tr><tr><td><code>--all<\/code><\/td><td>\u5426<\/td><td>\u67e5\u8be2\u5168\u90e8\u5df2\u914d\u7f6e\u94fe\uff0c\u975e\u5e38\u6162\uff0c\u5efa\u8bae\u7528&nbsp;<code>--chain<\/code>&nbsp;\u4ee3\u66ff<\/td><\/tr><tr><td><code>--token-contract<\/code><\/td><td>\u5426<\/td><td>\u67e5\u8be2\u6307\u5b9a\u5408\u7ea6\u5730\u5740\u7684\u4ee3\u5e01\u3002\u9700\u8981\u4e14\u4ec5\u80fd\u914d\u5408\u5355\u4e00\u5177\u4f53\u94fe\u4f7f\u7528<\/td><\/tr><tr><td><code>--sort-by-value<\/code><\/td><td>\u5426<\/td><td>\u6309 USD \u4f30\u503c\u4ece\u5927\u5230\u5c0f\u6392\u5e8f<\/td><\/tr><tr><td><code>--refresh<\/code><\/td><td>\u5426<\/td><td>\u5f3a\u5236\u91cd\u65b0\u83b7\u53d6\u4ee3\u5e01\u5217\u8868\uff0c\u5ffd\u7565\u7f13\u5b58<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<blockquote class=\"wp-block-quote\"><p>Assets API \u4e0d\u53ef\u7528\u65f6\u964d\u7ea7\u4f7f\u7528\u7f13\u5b58\u4ee3\u5e01\u5217\u8868\uff1b\u82e5\u65e0\u7f13\u5b58\u5219\u4ec5\u8fd4\u56de\u539f\u751f\u5e01\u4f59\u989d\u3002<\/p><p>Bitcoin \u4f59\u989d\u5305\u542b\u672a\u786e\u8ba4\uff08mempool\uff09UTXO\uff1b<code>send<\/code>&nbsp;\u53ea\u80fd\u82b1\u8d39\u5df2\u786e\u8ba4 UTXO\u3002<\/p><p>\u5355\u6761\u94fe\u5931\u8d25\u4e0d\u5f71\u54cd\u5176\u4ed6\u94fe\u7ee7\u7eed\u67e5\u8be2\uff08\u9519\u8bef\u8f93\u51fa\u5230 stderr\uff09\u3002<\/p><\/blockquote>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h3><code>send<\/code>&nbsp;\u2014 \u53d1\u9001\u4ee3\u5e01\u6216\u8c03\u7528\u5408\u7ea6<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#send--%E5%8F%91%E9%80%81%E4%BB%A3%E5%B8%81%E6%88%96%E8%B0%83%E7%94%A8%E5%90%88%E7%BA%A6\"><\/a><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># \u53d1\u9001\u524d\u52a1\u5fc5\u5148 dry-run \u786e\u8ba4\u624b\u7eed\u8d39\nmathwallet send --chain ethereum --to 0x\u6536\u6b3e\u5730\u5740 --token native --amount 0.1 --dry-run\n\n# \u53d1\u9001\u539f\u751f\u5e01\nmathwallet send --chain ethereum --to 0x\u6536\u6b3e\u5730\u5740 --token native --amount 0.1\n\n# \u53d1\u9001 ERC-20 \u4ee3\u5e01\uff08--token \u586b\u5408\u7ea6\u5730\u5740\uff09\nmathwallet send --chain ethereum --to 0x\u6536\u6b3e\u5730\u5740 \\\n  --token 0xdAC17F958D2ee523a2206206994597C13D831ec7 --amount 100\n\n# \u4efb\u610f\u5408\u7ea6\u8c03\u7528\uff08\u4ec5 EVM\/TRON\uff09\nmathwallet send --chain ethereum --to 0x\u5408\u7ea6\u5730\u5740 --data 0x7ff36ab5... --value 0.1 --dry-run<\/pre>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>\u53c2\u6570<\/th><th>\u5fc5\u586b<\/th><th>\u8bf4\u660e<\/th><\/tr><\/thead><tbody><tr><td><code>--chain<\/code><\/td><td>\u662f<\/td><td>CAIP-2\u3001\u522b\u540d\u6216 chainId<\/td><\/tr><tr><td><code>--to<\/code><\/td><td>\u662f<\/td><td>\u6536\u6b3e\u5730\u5740\u6216\u5408\u7ea6\u5730\u5740<\/td><\/tr><tr><td><code>--token<\/code><\/td><td>\u662f*<\/td><td><code>native<\/code>\u3001\u4ee3\u5e01\u7b26\u53f7\u6216 ERC-20 \u5408\u7ea6\u5730\u5740\u3002*\u4f7f\u7528&nbsp;<code>--data<\/code>&nbsp;\u65f6\u53ef\u7701\u7565<\/td><\/tr><tr><td><code>--amount<\/code><\/td><td>\u662f*<\/td><td>\u53d1\u9001\u6570\u91cf\uff0c\u4eba\u7c7b\u53ef\u8bfb\u683c\u5f0f\uff08\u5982&nbsp;<code>0.1<\/code>\u3001<code>100<\/code>\uff09\u3002*\u4f7f\u7528&nbsp;<code>--data<\/code>&nbsp;\u65f6\u53ef\u7701\u7565<\/td><\/tr><tr><td><code>--data<\/code><\/td><td>\u5426<\/td><td>\u5408\u7ea6\u8c03\u7528 hex calldata\uff08\u4ec5 EVM\/TRON\uff09\u3002\u586b\u5199\u540e&nbsp;<code>--token<\/code>\/<code>--amount<\/code>&nbsp;\u53d8\u4e3a\u53ef\u9009<\/td><\/tr><tr><td><code>--value<\/code><\/td><td>\u5426<\/td><td>\u968f&nbsp;<code>--data<\/code>&nbsp;\u9644\u5e26\u7684\u539f\u751f\u5e01\u6570\u91cf\uff08\u5982&nbsp;<code>\"0.1\"<\/code>&nbsp;ETH\uff09\u3002\u9ed8\u8ba4\u4e3a&nbsp;<code>0<\/code><\/td><\/tr><tr><td><code>--max-fee<\/code><\/td><td>\u5426<\/td><td>\u624b\u7eed\u8d39\u4e0a\u9650\uff0c\u5355\u4f4d\u4e3a\u539f\u751f\u5e01\uff08\u5404\u94fe\u542b\u4e49\u4e0d\u540c\uff0c\u89c1\u6ce8\u91ca\uff09<\/td><\/tr><tr><td><code>--dry-run<\/code><\/td><td>\u5426<\/td><td>\u53ea\u4f30\u7b97\u624b\u7eed\u8d39\uff0c\u4e0d\u5e7f\u64ad<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p><strong><code>--max-fee<\/code>&nbsp;\u5404\u94fe\u542b\u4e49\u8bf4\u660e\uff1a<\/strong><\/p>\n\n\n\n<ul><li><strong>EVM \/ Bitcoin<\/strong>&nbsp;\u2014 \u603b\u624b\u7eed\u8d39\u786c\u4e0a\u9650\uff1b\u8d85\u51fa\u5219\u62d2\u7edd\u6267\u884c\u3002<\/li><li><strong>Solana<\/strong>&nbsp;\u2014 \u8bbe\u7f6e\u8ba1\u7b97\u5355\u5143\u4ef7\u683c\uff08\u4f18\u5148\u8d39\uff09\uff0c\u4e0d\u5f3a\u5236\u9650\u5236\u603b\u8d39\u7528\u3002<\/li><li><strong>TRON<\/strong>&nbsp;\u2014 \u8bbe\u7f6e energy&nbsp;<code>feeLimit<\/code>\uff08\u5355\u4f4d TRX\uff09\u3002<\/li><li><strong>SUI<\/strong>&nbsp;\u2014 \u8bbe\u7f6e gas budget\uff08\u5355\u4f4d SUI\uff0c\u5185\u90e8\u8f6c\u6362\u4e3a MIST\uff09\u3002<\/li><li><strong>TON<\/strong>&nbsp;\u2014 \u5ffd\u7565\uff08\u624b\u7eed\u8d39\u56fa\u5b9a\u7ea6 0.005 TON\uff09\u3002<\/li><\/ul>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h3><code>history<\/code>&nbsp;\u2014 \u67e5\u770b\u4ea4\u6613\u8bb0\u5f55<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#history--%E6%9F%A5%E7%9C%8B%E4%BA%A4%E6%98%93%E8%AE%B0%E5%BD%95\"><\/a><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">mathwallet history --chain ethereum           # \u6700\u8fd1 20 \u6761\uff08\u9ed8\u8ba4\uff09\nmathwallet history --chain eip155:1 --limit 50\nmathwallet history --chain solana --token native --json\nmathwallet history --chain ethereum --refresh<\/pre>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>\u53c2\u6570<\/th><th>\u5fc5\u586b<\/th><th>\u8bf4\u660e<\/th><\/tr><\/thead><tbody><tr><td><code>--chain<\/code><\/td><td>\u662f<\/td><td>\u6307\u5b9a\u5177\u4f53\u94fe\uff0c\u4e0d\u652f\u6301\u8de8\u94fe\u5408\u5e76\u67e5\u8be2<\/td><\/tr><tr><td><code>--token<\/code><\/td><td>\u5426<\/td><td>\u6309\u4ee3\u5e01\u7b5b\u9009\uff1a<code>native<\/code>\u3001\u7b26\u53f7\uff08\u5982&nbsp;<code>USDT<\/code>\uff09\u6216\u5408\u7ea6\u5730\u5740<\/td><\/tr><tr><td><code>--limit<\/code><\/td><td>\u5426<\/td><td>\u8fd4\u56de\u6761\u6570\uff0c1\u2013100\uff0c\u9ed8\u8ba4 20<\/td><\/tr><tr><td><code>--refresh<\/code><\/td><td>\u5426<\/td><td>\u5f3a\u5236\u91cd\u65b0\u83b7\u53d6\uff0c\u5ffd\u7565 5 \u5206\u949f\u7f13\u5b58<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h3><code>sign<\/code>&nbsp;\u2014 \u79bb\u7ebf\u7b7e\u540d\uff08\u4e0d\u5e7f\u64ad\uff09<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#sign--%E7%A6%BB%E7%BA%BF%E7%AD%BE%E5%90%8D%E4%B8%8D%E5%B9%BF%E6%92%AD\"><\/a><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># EIP-712 \u7ed3\u6784\u5316\u6570\u636e\u7b7e\u540d\uff08\u4ec5 EVM\uff09\nmathwallet sign typed-data \\\n  --chain   eip155:1 \\\n  --domain  '{\"name\":\"MyApp\",\"version\":\"1\",\"chainId\":1,\"verifyingContract\":\"0x...\"}' \\\n  --types   '{\"Transfer\":[{\"name\":\"to\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}]}' \\\n  --message '{\"to\":\"0x...\",\"amount\":\"1000000\"}' \\\n  --json\n\n# \u6d88\u606f\u7b7e\u540d\uff08EVM \u8fd4\u56de 0x hex\uff0cSolana \u8fd4\u56de base64\uff09\nmathwallet sign message --chain ethereum --message \"Hello\" --json\nmathwallet sign message --chain solana   --message \"Hello\" --json\n\n# \u7b7e\u540d\u539f\u59cb\u4ea4\u6613\uff08\u4e0d\u5e7f\u64ad\uff09\nmathwallet sign transaction --chain eip155:1 --tx '{\"to\":\"0x...\",\"value\":\"0x0\",...}' --json\nmathwallet sign transaction --chain solana   --tx \"&lt;base64 \u672a\u7b7e\u540d\u4ea4\u6613&gt;\" --json<\/pre>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h3><code>swap<\/code>&nbsp;\u2014 \u4ee3\u5e01\u5151\u6362\uff08MathSwap\uff09<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#swap--%E4%BB%A3%E5%B8%81%E5%85%91%E6%8D%A2mathswap\"><\/a><\/p>\n\n\n\n<p>\u652f\u6301 MathSwap API \u8fd4\u56de\u7684\u6240\u6709\u94fe\u3002\u5b8c\u6574\u6267\u884c\uff08<code>swap exec<\/code>\uff09<strong>\u4ec5\u652f\u6301 EVM \u94fe<\/strong>\uff1b\u62a5\u4ef7\u3001\u72b6\u6001\u67e5\u8be2\u3001\u5386\u53f2\u8bb0\u5f55\u3001\u4ee3\u5e01\u641c\u7d22\u652f\u6301\u5168\u90e8\u94fe\u3002<\/p>\n\n\n\n<p><strong>\u539f\u751f\u5e01\u5730\u5740\uff1a<\/strong>&nbsp;<code>0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee<\/code>&nbsp;\u4ee3\u8868\u8be5\u94fe\u539f\u751f\u5e01\uff08ETH\u3001BNB \u7b49\uff09\u3002<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># \u5217\u51fa MathSwap \u652f\u6301\u7684\u6240\u6709\u94fe\nmathwallet swap chains --json\n\n# \u67e5\u770b\u652f\u6301 swap \u7684\u4ee3\u5e01\uff08\u5df2\u8fde\u63a5\u94b1\u5305\u65f6\u8fd4\u56de\u6709\u4f59\u989d\u7684\u4ee3\u5e01\uff0c\u5426\u5219\u8fd4\u56de\u9ed8\u8ba4\u63a8\u8350\u5217\u8868\uff09\nmathwallet swap tokens --chain ethereum --json\n\n# \u6309 symbol \u6216\u5408\u7ea6\u5730\u5740\u641c\u7d22\u53ef swap \u7684\u4ee3\u5e01\nmathwallet swap tokens --chain ethereum --search USDC --json\n\n# \u83b7\u53d6\u5b9e\u65f6\u62a5\u4ef7\nmathwallet swap quote \\\n  --chain  ethereum \\\n  --from   0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee \\\n  --to     0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48 \\\n  --amount 0.1 --json\n\n# Dry-run\uff1a\u6267\u884c\u5168\u90e8 API \u6b65\u9aa4\uff0c\u4e0d\u5e7f\u64ad\u4efb\u4f55\u4ea4\u6613\nmathwallet swap exec \\\n  --chain  ethereum \\\n  --from   0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee \\\n  --to     0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48 \\\n  --amount 0.1 --dry-run --json\n\n# \u6267\u884c\u5151\u6362\nmathwallet swap exec \\\n  --chain  ethereum \\\n  --from   0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee \\\n  --to     0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48 \\\n  --amount 0.1 --json\n\n# \u67e5\u8be2\u8ba2\u5355\u72b6\u6001\uff08exec \u8d85\u65f6\u65f6\u4f7f\u7528\uff09\nmathwallet swap status --chain ethereum --order &lt;order_no&gt; --json\n\n# \u67e5\u770b\u5386\u53f2\u8ba2\u5355\nmathwallet swap history --chain ethereum --json<\/pre>\n\n\n\n<p><strong><code>swap exec<\/code>&nbsp;\u53c2\u6570\uff1a<\/strong><\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>\u53c2\u6570<\/th><th>\u5fc5\u586b<\/th><th>\u8bf4\u660e<\/th><\/tr><\/thead><tbody><tr><td><code>--chain<\/code><\/td><td>\u662f<\/td><td>EVM \u94fe\uff08\u5982&nbsp;<code>ethereum<\/code>\u3001<code>bsc<\/code>\u3001<code>base<\/code>\uff09<\/td><\/tr><tr><td><code>--from<\/code><\/td><td>\u662f<\/td><td>\u5356\u51fa\u4ee3\u5e01\u5730\u5740\uff08\u539f\u751f\u5e01\u586b&nbsp;<code>0xeee\u2026eee<\/code>\uff09<\/td><\/tr><tr><td><code>--to<\/code><\/td><td>\u662f<\/td><td>\u4e70\u5165\u4ee3\u5e01\u5730\u5740<\/td><\/tr><tr><td><code>--amount<\/code><\/td><td>\u662f<\/td><td>\u5356\u51fa\u6570\u91cf\uff0c\u4eba\u7c7b\u53ef\u8bfb\u683c\u5f0f\uff08\u5982&nbsp;<code>0.1<\/code>\u3001<code>10<\/code>\uff09<\/td><\/tr><tr><td><code>--slippage<\/code><\/td><td>\u5426<\/td><td>\u6ed1\u70b9\u5bb9\u5fcd\u5ea6\uff0c\u767e\u5206\u6bd4\uff08\u5982&nbsp;<code>0.5<\/code>\uff09\u3002\u9ed8\u8ba4\u81ea\u52a8<\/td><\/tr><tr><td><code>--max-price-impact<\/code><\/td><td>\u5426<\/td><td>\u8d85\u8fc7\u6b64\u4ef7\u683c\u5f71\u54cd\u767e\u5206\u6bd4\u65f6\u4e2d\u6b62\uff08\u5982&nbsp;<code>5<\/code>\uff09\u3002\u975e JSON \u6a21\u5f0f\u4e0b\u8d85\u8fc7 5% \u4f1a\u81ea\u52a8\u663e\u793a\u8b66\u544a<\/td><\/tr><tr><td><code>--dry-run<\/code><\/td><td>\u5426<\/td><td>\u6267\u884c\u5168\u90e8 API \u6b65\u9aa4\uff08\u542b&nbsp;<code>create_order<\/code>\uff09\uff0c\u4f46\u4e0d\u5e7f\u64ad\u4efb\u4f55\u4ea4\u6613<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<blockquote class=\"wp-block-quote\"><p><code>swap exec<\/code>&nbsp;\u81ea\u52a8\u5904\u7406 ERC-20 \u6388\u6743\uff1a\u68c0\u67e5\u94fe\u4e0a allowance\uff0c\u4e0d\u8db3\u65f6\u5e7f\u64ad approve \u4ea4\u6613\u5e76\u7b49\u5f85\u786e\u8ba4\uff0c\u518d\u6267\u884c swap\u3002<\/p><p>\u5e7f\u64ad\u540e\u6bcf 3 \u79d2\u8f6e\u8be2\u8ba2\u5355\u72b6\u6001\uff0c\u6700\u591a\u7b49\u5f85 60 \u79d2\u3002\u8d85\u65f6\u540e\u53ef\u7528&nbsp;<code>swap status<\/code>&nbsp;\u624b\u52a8\u67e5\u8be2\u3002<\/p><\/blockquote>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h3><code>serve<\/code>&nbsp;\u2014 A2A Agent \u670d\u52a1\u5668<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#serve--a2a-agent-%E6%9C%8D%E5%8A%A1%E5%99%A8\"><\/a><\/p>\n\n\n\n<p>\u542f\u52a8\u4e00\u4e2a HTTP \u670d\u52a1\u5668\uff0c\u5c06\u6240\u6709\u94b1\u5305\u529f\u80fd\u901a\u8fc7&nbsp;<strong>A2A\uff08Agent-to-Agent\uff09\u534f\u8bae<\/strong>\uff08JSON-RPC 2.0\uff09\u66b4\u9732\u7ed9\u5176\u4ed6 AI Agent\u3002\u5176\u4ed6 AI Agent\uff08Claude\u3001Gemini \u7b49\uff09\u53ef\u901a\u8fc7\u6807\u51c6\u534f\u8bae\u53d1\u73b0\u5e76\u8c03\u7528\u94b1\u5305\u80fd\u529b\uff0c\u65e0\u9700\u4e86\u89e3 CLI \u547d\u4ee4\u3002<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">mathwallet serve                                  # \u76d1\u542c 127.0.0.1:3000\nmathwallet serve --port 8080                      # \u81ea\u5b9a\u4e49\u7aef\u53e3\nmathwallet serve --auth                           # \u542f\u7528\u8ba4\u8bc1\uff08\u81ea\u52a8\u751f\u6210 token\uff09\nmathwallet serve --auth my-secret-token           # \u542f\u7528\u8ba4\u8bc1\uff08\u6307\u5b9a token\uff09\nmathwallet serve --host 0.0.0.0 --auth            # \u76d1\u542c\u6240\u6709\u7f51\u5361\uff08\u5e26\u8ba4\u8bc1\uff09\nmathwallet serve --cors \"http:\/\/localhost:5173\"   # \u5141\u8bb8\u6307\u5b9a CORS \u6765\u6e90<\/pre>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>\u53c2\u6570<\/th><th>\u5fc5\u586b<\/th><th>\u8bf4\u660e<\/th><\/tr><\/thead><tbody><tr><td><code>--port<\/code><\/td><td>\u5426<\/td><td>\u76d1\u542c\u7aef\u53e3\uff0c\u9ed8\u8ba4&nbsp;<code>3000<\/code><\/td><\/tr><tr><td><code>--host<\/code><\/td><td>\u5426<\/td><td>\u7ed1\u5b9a\u5730\u5740\uff0c\u9ed8\u8ba4&nbsp;<code>127.0.0.1<\/code><\/td><\/tr><tr><td><code>--auth<\/code><\/td><td>\u5426<\/td><td>\u542f\u7528 Bearer Token \u8ba4\u8bc1\u3002\u4e0d\u4f20\u503c\u5219\u81ea\u52a8\u751f\u6210\uff0c\u4f20\u503c\u5219\u4f7f\u7528\u6307\u5b9a token<\/td><\/tr><tr><td><code>--cors<\/code><\/td><td>\u5426<\/td><td>\u5141\u8bb8\u7684 CORS \u6765\u6e90\uff08\u9017\u53f7\u5206\u9694\uff09\u3002\u9ed8\u8ba4\u4ec5\u5141\u8bb8\u540c\u6e90<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p><strong>\u63a5\u53e3\uff1a<\/strong><\/p>\n\n\n\n<ul><li><code>GET \/.well-known\/agent.json<\/code>&nbsp;\u2014 Agent Card\uff0c\u5305\u542b 16 \u4e2a skill \u5b9a\u4e49\uff08\u516c\u5f00\uff0c\u65e0\u9700\u8ba4\u8bc1\uff09<\/li><li><code>POST \/<\/code>&nbsp;\u2014 JSON-RPC 2.0\uff1a<code>tasks\/send<\/code>\u3001<code>tasks\/get<\/code>\u3001<code>tasks\/cancel<\/code>\u3001<code>tasks\/sendSubscribe<\/code>\uff08SSE \u6d41\u5f0f\uff09<\/li><\/ul>\n\n\n\n<p><strong>\u4f7f\u7528\u793a\u4f8b\uff1a<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># \u542f\u52a8\u670d\u52a1\uff08\u5e26\u8ba4\u8bc1\uff09\nmathwallet serve --auth\n# stderr: [a2a] auth token: &lt;generated-token&gt;\n\n# \u67e5\u770b\u6240\u6709 skill\uff08\u65e0\u9700\u8ba4\u8bc1\uff09\ncurl http:\/\/localhost:3000\/.well-known\/agent.json | jq '.skills[].id'\n\n# \u8c03\u7528 skill\uff08\u9700\u8ba4\u8bc1\uff09\ncurl -X POST http:\/\/localhost:3000 \\\n  -H \"Content-Type: application\/json\" \\\n  -H \"Authorization: Bearer &lt;token&gt;\" \\\n  -d '{\"jsonrpc\":\"2.0\",\"method\":\"tasks\/send\",\"params\":{\"id\":\"t1\",\"message\":{\"role\":\"user\",\"parts\":[{\"type\":\"data\",\"data\":{\"skill\":\"check_balance\",\"params\":{\"chain\":\"ethereum\"}}}]}},\"id\":1}'<\/pre>\n\n\n\n<p><strong>\u5b89\u5168\u673a\u5236\uff1a<\/strong><\/p>\n\n\n\n<ul><li>\u9ed8\u8ba4\u7ed1\u5b9a&nbsp;<code>127.0.0.1<\/code>\uff08\u4ec5\u672c\u5730\u8bbf\u95ee\uff09\uff0c\u7ed1\u5b9a\u5230\u5176\u4ed6\u5730\u5740\u65f6\u4f1a\u6253\u5370\u8b66\u544a\u3002<\/li><li>\u4f7f\u7528&nbsp;<code>--auth<\/code>&nbsp;\u53ef\u8981\u6c42\u6240\u6709 POST \u8bf7\u6c42\u643a\u5e26 Bearer Token \u8ba4\u8bc1\u3002<\/li><li>CORS \u9ed8\u8ba4\u4ec5\u5141\u8bb8\u540c\u6e90\u8bf7\u6c42\uff0c\u53ef\u901a\u8fc7&nbsp;<code>--cors<\/code>&nbsp;\u6307\u5b9a\u5141\u8bb8\u7684\u6765\u6e90\u3002<\/li><li>\u6240\u6709\u654f\u611f skill\uff08<code>send_token<\/code>\u3001<code>send_contract<\/code>\u3001<code>swap_exec<\/code>\u3001<code>sign_message<\/code>\u3001<code>sign_typed_data<\/code>\u3001<code>sign_transaction<\/code>\uff09\u6267\u884c\u524d\u5747\u9700&nbsp;<code>input-required<\/code>&nbsp;\u786e\u8ba4\u3002<\/li><li>\u9891\u7387\u9650\u5236\uff1a\u6bcf IP \u6bcf\u5206\u949f\u6700\u591a 60 \u6b21\u8bf7\u6c42\u3002<\/li><\/ul>\n\n\n\n<p>\u5b8c\u6574 A2A Skill \u6587\u6863\uff1a<a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/packages\/mathwallet-cli\/skills\/SKILL.md\"><code>packages\/mathwallet-cli\/skills\/SKILL.md<\/code><\/a><\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h3><code>x402<\/code>&nbsp;\u2014 x402 HTTP \u652f\u4ed8\u534f\u8bae<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#x402--x402-http-%E6%94%AF%E4%BB%98%E5%8D%8F%E8%AE%AE\"><\/a><\/p>\n\n\n\n<p>\u81ea\u52a8\u5904\u7406 HTTP 402 Payment Required\uff0c\u4f7f\u7528 EIP-3009 \u94fe\u4e0b\u6388\u6743\uff0c\u4e0d\u53d1\u94fe\u4e0a\u4ea4\u6613\u3002<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">mathwallet x402 pay --url \"https:\/\/api.example.com\/protected\" --json\nmathwallet x402 pay --url \"https:\/\/api.example.com\/data\" --chain eip155:8453 --json\nmathwallet x402 pay --url \"https:\/\/api.example.com\/data\" --method POST --body '{\"q\":\"hello\"}' --json<\/pre>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>\u53c2\u6570<\/th><th>\u5fc5\u586b<\/th><th>\u8bf4\u660e<\/th><\/tr><\/thead><tbody><tr><td><code>--url<\/code><\/td><td>\u662f<\/td><td>\u76ee\u6807 URL\uff0cCLI \u81ea\u52a8\u5904\u7406 402 \u6311\u6218\u540e\u91cd\u8bd5<\/td><\/tr><tr><td><code>--chain<\/code><\/td><td>\u5426<\/td><td>\u9996\u9009\u652f\u4ed8\u94fe\uff08CAIP-2 \u6216\u522b\u540d\uff09\uff0c\u4e0d\u4f20\u5219\u4ece 402 \u54cd\u5e94\u81ea\u52a8\u68c0\u6d4b<\/td><\/tr><tr><td><code>--method<\/code><\/td><td>\u5426<\/td><td>HTTP \u65b9\u6cd5\uff0c\u9ed8\u8ba4&nbsp;<code>GET<\/code><\/td><\/tr><tr><td><code>--body<\/code><\/td><td>\u5426<\/td><td>\u8bf7\u6c42\u4f53 JSON \u5b57\u7b26\u4e32\uff08\u7528\u4e8e POST\uff09<\/td><\/tr><tr><td><code>--header<\/code><\/td><td>\u5426<\/td><td>\u989d\u5916\u8bf7\u6c42\u5934\uff0c\u683c\u5f0f&nbsp;<code>Key:Value<\/code>\uff0c\u53ef\u91cd\u590d<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h3><code>cache<\/code>&nbsp;\u2014 \u7ba1\u7406\u672c\u5730\u7f13\u5b58<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#cache--%E7%AE%A1%E7%90%86%E6%9C%AC%E5%9C%B0%E7%BC%93%E5%AD%98\"><\/a><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">mathwallet cache status\nmathwallet cache status --json\n\nmathwallet cache clear\nmathwallet cache clear --type prices\nmathwallet cache clear --type tokens --json<\/pre>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2>\u652f\u6301\u7684\u94fe<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#%E6%94%AF%E6%8C%81%E7%9A%84%E9%93%BE\"><\/a><\/p>\n\n\n\n<h3>EVM \u94fe\uff08\u5171\u7528\u540c\u4e00\u4e2a&nbsp;<code>0x\u2026<\/code>&nbsp;\u5730\u5740\uff09<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#evm-%E9%93%BE%E5%85%B1%E7%94%A8%E5%90%8C%E4%B8%80%E4%B8%AA-0x-%E5%9C%B0%E5%9D%80\"><\/a><\/p>\n\n\n\n<blockquote class=\"wp-block-quote\"><p>EVM \u94fe\u5217\u8868\u4ece MathWallet API \u52a8\u6001\u52a0\u8f7d\uff0824 \u5c0f\u65f6\u7f13\u5b58\uff09\u3002\u6267\u884c&nbsp;<code>mathwallet chain list<\/code>&nbsp;\u67e5\u770b\u5b8c\u6574\u5217\u8868\u3002<\/p><\/blockquote>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>CAIP-2<\/th><th>\u522b\u540d<\/th><th>\u539f\u751f\u4ee3\u5e01<\/th><\/tr><\/thead><tbody><tr><td><code>eip155:1<\/code><\/td><td><code>ethereum<\/code><\/td><td>ETH<\/td><\/tr><tr><td><code>eip155:56<\/code><\/td><td><code>bsc<\/code><\/td><td>BNB<\/td><\/tr><tr><td><code>eip155:137<\/code><\/td><td><code>polygon<\/code><\/td><td>POL<\/td><\/tr><tr><td><code>eip155:42161<\/code><\/td><td><code>arbitrum<\/code><\/td><td>ETH<\/td><\/tr><tr><td><code>eip155:10<\/code><\/td><td><code>optimism<\/code><\/td><td>ETH<\/td><\/tr><tr><td><code>eip155:8453<\/code><\/td><td><code>base<\/code><\/td><td>ETH<\/td><\/tr><tr><td><code>eip155:43114<\/code><\/td><td><code>avalanche<\/code><\/td><td>AVAX<\/td><\/tr><tr><td><em>\uff08\u66f4\u591a \u2014 \u6267\u884c&nbsp;<code>mathwallet chain list<\/code>\uff09<\/em><\/td><td><\/td><td><\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<h3>\u975e EVM \u94fe\uff08\u9759\u6001\u914d\u7f6e\uff09<\/h3>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#%E9%9D%9E-evm-%E9%93%BE%E9%9D%99%E6%80%81%E9%85%8D%E7%BD%AE\"><\/a><\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>CAIP-2<\/th><th>\u522b\u540d<\/th><th>\u4ee3\u5e01<\/th><th>\u5730\u5740\u683c\u5f0f<\/th><\/tr><\/thead><tbody><tr><td><code>solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdpKuc147dw2N9d<\/code><\/td><td><code>solana<\/code><\/td><td>SOL<\/td><td>base58\uff0c\u7ea6 44 \u5b57\u7b26<\/td><\/tr><tr><td><code>bip122:000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f<\/code><\/td><td><code>bitcoin<\/code><\/td><td>BTC<\/td><td><code>bc1q\u2026<\/code>&nbsp;bech32<\/td><\/tr><tr><td><code>tron<\/code><\/td><td><code>tron<\/code><\/td><td>TRX<\/td><td><code>T\u2026<\/code>&nbsp;base58\uff0c34 \u5b57\u7b26<\/td><\/tr><tr><td><code>sui<\/code><\/td><td><code>sui<\/code><\/td><td>SUI<\/td><td><code>0x\u2026<\/code>&nbsp;64 \u4f4d hex<\/td><\/tr><tr><td><code>ton<\/code><\/td><td><code>ton<\/code><\/td><td>TON<\/td><td><code>UQ\u2026<\/code>&nbsp;base64url<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2>\u5e38\u89c1\u95ee\u9898<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#%E5%B8%B8%E8%A7%81%E9%97%AE%E9%A2%98\"><\/a><\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th>\u9519\u8bef<\/th><th>\u89e3\u51b3\u65b9\u6848<\/th><\/tr><\/thead><tbody><tr><td><code>Wallet not initialized<\/code><\/td><td>\u6267\u884c&nbsp;<code>mathwallet init<\/code><\/td><\/tr><tr><td><code>Failed to read encryption key<\/code><\/td><td><code>chmod 0600 ~\/.mathwallet\/.encryption-key<\/code>\uff0c\u6216\u91cd\u65b0\u6267\u884c&nbsp;<code>mathwallet init<\/code>\uff08\u539f\u6570\u636e\u4e0d\u53ef\u6062\u590d\uff09<\/td><\/tr><tr><td><code>No confirmed UTXOs available<\/code>\uff08Bitcoin\uff09<\/td><td>\u5145\u503c\u540e\u7b49\u5f85\u81f3\u5c11\u4e00\u4e2a\u533a\u5757\u786e\u8ba4<\/td><\/tr><tr><td>\u542f\u52a8\u65f6\u51fa\u73b0&nbsp;<code>bigint: Failed to load bindings<\/code><\/td><td>\u975e\u963b\u585e\u8b66\u544a\uff0c\u4e0d\u5f71\u54cd\u529f\u80fd\uff0c\u53ef\u5ffd\u7565<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2>\u5b89\u5168\u8bf4\u660e<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#%E5%AE%89%E5%85%A8%E8%AF%B4%E6%98%8E\"><\/a><\/p>\n\n\n\n<ul><li><strong>\u673a\u5668\u7ed1\u5b9a\u52a0\u5bc6<\/strong>&nbsp;\u2014&nbsp;<code>.encryption-key<\/code>&nbsp;\u4e0e\u672c\u673a\u7ed1\u5b9a\uff0c\u8fc1\u79fb\u65f6\u5fc5\u987b\u540c\u65f6\u62f7\u8d1d&nbsp;<code>wallet.enc<\/code>&nbsp;+&nbsp;<code>.encryption-key<\/code><\/li><li><strong>\u79c1\u94a5\u4e0d\u843d\u76d8<\/strong>&nbsp;\u2014 \u6bcf\u6b21\u547d\u4ee4\u5728\u5185\u5b58\u4e2d\u6d3e\u751f\uff0c\u4f7f\u7528\u540e\u7acb\u5373\u4e22\u5f03<\/li><li><strong>\u6587\u4ef6\u6743\u9650<\/strong>&nbsp;\u2014&nbsp;<code>~\/.mathwallet\/<\/code>&nbsp;\u4e3a 0700\uff0c\u6240\u6709\u94b1\u5305\u6587\u4ef6\u4e3a 0600<\/li><li><strong>\u65e0\u9700\u5bc6\u7801<\/strong>&nbsp;\u2014 \u4e13\u4e3a AI Agent \u81ea\u52a8\u5316\u8bbe\u8ba1\uff0c\u65e0\u4ea4\u4e92\u63d0\u793a<\/li><li><strong>\u53d1\u9001\u524d\u5148 dry-run<\/strong>&nbsp;\u2014 \u5e7f\u64ad\u4efb\u4f55\u4ea4\u6613\u524d\u5148\u7528&nbsp;<code>--dry-run<\/code>&nbsp;\u786e\u8ba4\u624b\u7eed\u8d39<\/li><\/ul>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2>\u9879\u76ee\u7ed3\u6784<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/blob\/main\/README.zh-CN.md#%E9%A1%B9%E7%9B%AE%E7%BB%93%E6%9E%84\"><\/a><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>mathwallet-agent-skill\/\n\u251c\u2500\u2500 packages\/\n\u2502   \u2514\u2500\u2500 mathwallet-cli\/\n\u2502       \u251c\u2500\u2500 src\/\n\u2502       \u2502   \u251c\u2500\u2500 index.ts         # CLI \u5165\u53e3\n\u2502       \u2502   \u251c\u2500\u2500 commands\/        # \u5404\u547d\u4ee4\u5b9e\u73b0\uff08\u542b serve\uff09\n\u2502       \u2502   \u251c\u2500\u2500 chains\/          # \u5404\u94fe\u9002\u914d\u5668\n\u2502       \u2502   \u251c\u2500\u2500 lib\/             # \u5de5\u5177\u5e93\uff08\u52a0\u5bc6\u3001\u914d\u7f6e\u3001\u4f59\u989d\u3001\u4ef7\u683c\u3001swap\uff09\n\u2502       \u2502   \u2514\u2500\u2500 a2a\/             # A2A \u534f\u8bae\u670d\u52a1\u5668\uff08skill\u3001JSON-RPC\u3001\u4efb\u52a1\u5b58\u50a8\uff09\n\u2502       \u251c\u2500\u2500 dist\/                # \u7f16\u8bd1\u4ea7\u7269\n\u2502       \u2514\u2500\u2500 skills\/SKILL.md      # AI Agent Skill \u53c2\u8003\u6587\u6863\n\u2514\u2500\u2500 README.md<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>https:\/\/github.com\/mathwallet\/mathwallet-agent-skill\/ \u9762\u5411 AI Agent \u81ea\u52a8\u5316\u7684\u591a\u94fe Web3 \u94b1\u5305\u547d\u4ee4\u884c\u5de5\u5177\u3002\u4e00\u5957 BIP39 \u52a9\u8bb0\u8bcd\u6d3e\u751f\u6240\u6709\u94fe\u5730\u5740\uff0c\u652f\u6301&nbsp;EVM\uff08Ethereum\u3001BSC\u3001Polygon\u3001Arbitrum\u3001Optimism\u3001Base\u3001Avalanche \u7b49\uff09\u3001Solana\u3001Bitcoin\u3001TRON\u3001SUI\u3001TON\u3002\u529f\u80fd\u5305\u62ec\uff1aCAIP-2 \u94fe\u6807\u8bc6\u3001\u4f59\u989d\u67e5\u8be2\uff08\u542b USD \u4f30\u503c\uff09\u3001\u4ee3\u5e01\u53d1\u9001\u3001\u4ea4\u6613\u8bb0\u5f55\u3001\u79bb\u7ebf\u7b7e\u540d\u3001MathSwap \u4ee3\u5e01\u5151\u6362\u3001x402 HTTP \u652f\u4ed8\u534f\u8bae\uff0c\u4ee5\u53ca\u9762\u5411 AI Agent \u4e92\u8054\u7684&nbsp;A2A JSON-RPC \u670d\u52a1\u5668\u3002 \u73af\u5883\u8981\u6c42 \u4f9d\u8d56 \u7248\u672c Node.js \u2265 20.0.0 pnpm \u63a8\u8350 8+ \u5b89\u88c5 # 1. \u5b89\u88c5\u4f9d\u8d56\uff08\u5728\u9879\u76ee\u6839\u76ee\u5f55\uff09 pnpm install # 2. \u7f16\u8bd1 pnpm build # 3a. \u76f4\u63a5\u8fd0\u884c\uff08\u5f00\u53d1\u9636\u6bb5\uff09 node packages\/mathwallet-cli\/dist\/index.js &lt;\u547d\u4ee4&gt; # 3b. \u5168\u5c40\u94fe\u63a5\uff08\u63a8\u8350\u65e5\u5e38\u4f7f\u7528\uff09 cd packages\/mathwallet-cli &amp;&amp; npm link [&hellip;]<\/p>\n","protected":false},"author":9,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[188,134],"_links":{"self":[{"href":"https:\/\/blog.mathwallet.xyz\/index.php?rest_route=\/wp\/v2\/posts\/6181"}],"collection":[{"href":"https:\/\/blog.mathwallet.xyz\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.mathwallet.xyz\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.mathwallet.xyz\/index.php?rest_route=\/wp\/v2\/users\/9"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.mathwallet.xyz\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=6181"}],"version-history":[{"count":4,"href":"https:\/\/blog.mathwallet.xyz\/index.php?rest_route=\/wp\/v2\/posts\/6181\/revisions"}],"predecessor-version":[{"id":6236,"href":"https:\/\/blog.mathwallet.xyz\/index.php?rest_route=\/wp\/v2\/posts\/6181\/revisions\/6236"}],"wp:attachment":[{"href":"https:\/\/blog.mathwallet.xyz\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=6181"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.mathwallet.xyz\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=6181"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.mathwallet.xyz\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=6181"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}