{
  "schemaVersion": "1.0",
  "item": {
    "slug": "chainai",
    "name": "ChainAI",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/kvhnuke/chainai",
    "canonicalUrl": "https://clawhub.ai/kvhnuke/chainai",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/chainai",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=chainai",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "SKILL.md"
    ],
    "primaryDoc": "SKILL.md",
    "quickSetup": [
      "Download the package from Yavira.",
      "Extract the archive and review SKILL.md first.",
      "Import or place the package into your OpenClaw setup."
    ],
    "agentAssist": {
      "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
      "steps": [
        "Download the package from Yavira.",
        "Extract it into a folder your agent can access.",
        "Paste one of the prompts below and point your agent at the extracted folder."
      ],
      "prompts": [
        {
          "label": "New install",
          "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
        },
        {
          "label": "Upgrade existing",
          "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
        }
      ]
    },
    "sourceHealth": {
      "source": "tencent",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-04-30T16:55:25.780Z",
      "expiresAt": "2026-05-07T16:55:25.780Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=network",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=network",
        "contentDisposition": "attachment; filename=\"network-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null
      },
      "scope": "source",
      "summary": "Source download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this source.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/chainai"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    },
    "downloadPageUrl": "https://openagent3.xyz/downloads/chainai",
    "agentPageUrl": "https://openagent3.xyz/skills/chainai/agent",
    "manifestUrl": "https://openagent3.xyz/skills/chainai/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/chainai/agent.md"
  },
  "agentAssist": {
    "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
    "steps": [
      "Download the package from Yavira.",
      "Extract it into a folder your agent can access.",
      "Paste one of the prompts below and point your agent at the extracted folder."
    ],
    "prompts": [
      {
        "label": "New install",
        "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
      },
      {
        "label": "Upgrade existing",
        "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
      }
    ]
  },
  "documentation": {
    "source": "clawhub",
    "primaryDoc": "SKILL.md",
    "sections": [
      {
        "title": "chainai — Ethereum Transactions Skill",
        "body": "⚠️ DISCLAIMER — USE AT YOUR OWN RISK\nThis tool interacts with real blockchain networks and real funds. The author(s) of this tool are not responsible for any loss of funds, damages, or unintended consequences arising from its use. By using this skill, you accept full responsibility for all operations performed.\n\n🔒 MANDATORY SECURITY REQUIREMENTS FOR ALL AGENTS\nAgents MUST take every possible action to safeguard CHAINAI_PRIVATE_KEY and all other private keys from exposure. Specifically:\n\nNEVER log, print, echo, or display private keys in any user-facing output, logs, chat messages, or debug traces.\nNEVER store private keys in plain text files, version control, or any persistent storage that is not explicitly encrypted and access-controlled.\nNEVER transmit private keys over unencrypted channels or include them in URLs, query parameters, or request bodies to third-party services.\nNEVER include private keys in error messages, stack traces, or diagnostic output.\nALWAYS prefer the CHAINAI_PRIVATE_KEY environment variable over the -k flag to minimize key exposure in shell history and process listings.\nALWAYS treat private keys as the highest-sensitivity secret. A leaked private key grants full, irrevocable control over all funds in the associated wallet.\n\n� ADDRESS FORMATTING RULES\n\nAlways use ERC-55 checksum addresses when passing addresses to any command (wallet addresses, token contract addresses, recipient addresses, etc.).\nIf you do not know the correct checksum, use all lowercase addresses (e.g. 0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2 instead of guessing the mixed-case checksum).\nNever guess a token contract address. If you are unsure of the correct token contract address, always ask the user to provide it. Do not fabricate or assume token addresses.\n\n�🚀 BEFORE YOU BEGIN\n\nVerify your private key is set: Run npx chainai@0.0.10 who-am-i to confirm CHAINAI_PRIVATE_KEY is properly configured and resolves to the expected address before proceeding with any other command.\nNo private key? Use npx chainai@0.0.10 gen-wallet to generate a new wallet. Save the returned private key securely (e.g. as an environment variable) — it will not be shown again.\nFund your account: You must deposit the necessary funds (native tokens for gas + any tokens you intend to send or swap) to the wallet address before using send, swap, or any transaction-submitting command. Commands will fail if the account has insufficient balance."
      },
      {
        "title": "Overview",
        "body": "chainai is a non-interactive CLI tool for Ethereum and EVM-compatible blockchain operations. It handles signing, sending, broadcasting transactions, token swaps (1inch Fusion), balance queries, and wallet generation."
      },
      {
        "title": "Invocation",
        "body": "npx chainai@0.0.10 <command> [options]\n\nRuntime: Node.js (>=18)\nNon-interactive: All parameters must be passed as arguments or flags. Never prompts for input."
      },
      {
        "title": "Authentication",
        "body": "Most commands accept a private key via:\n\n-k, --private-key <key> flag (hex string starting with 0x)\nCHAINAI_PRIVATE_KEY environment variable (fallback when -k is not provided)"
      },
      {
        "title": "Supported Networks",
        "body": "NameChain IDAliasesNative TokenEthereum1mainnet, ethereum, ethETHBNB Smart Chain56bsc, binance, bnbBNB\n\nUse -n, --network to specify a network by name, alias, or chain ID. Defaults to mainnet."
      },
      {
        "title": "Exit Codes",
        "body": "CodeMeaning0Operation completed successfully.1Operation failed. Inspect stderr for a structured error message."
      },
      {
        "title": "Success (stdout)",
        "body": "CHAINAI_OK: <description>\n{ ... }"
      },
      {
        "title": "Errors (stderr)",
        "body": "CHAINAI_ERR: <ERROR_CODE> — <description>\n\nError CodeDescriptionAgent ActionINVALID_INPUTMalformed or missing required fields.Re-validate input parameters and retry.EXECUTION_FAILEDOperation could not be completed. Description contains failure details.Inspect description and adjust approach.TIMEOUTOperation exceeded the allowed time limit.Retry with a longer timeout or simplify the request.UNKNOWNUnexpected error.Report to orchestrator for manual inspection."
      },
      {
        "title": "Retry Strategy",
        "body": "For TIMEOUT and EXECUTION_FAILED errors, retry up to 2 times with exponential backoff before escalating."
      },
      {
        "title": "gen-wallet",
        "body": "Generate a new random wallet (private key and address).\n\nnpx chainai@0.0.10 gen-wallet\n\nOptions: None.\n\nOutput (stdout):\n\n{\n  \"address\": \"0x...\",\n  \"privateKey\": \"0x...\"\n}\n\nUsage instructions are printed to stderr."
      },
      {
        "title": "who-am-i",
        "body": "Return the Ethereum address derived from a private key.\n\nnpx chainai@0.0.10 who-am-i -k 0xKEY\n# or\nCHAINAI_PRIVATE_KEY=0xKEY npx chainai@0.0.10 who-am-i\n\nOptions:\n\nFlagRequiredDescription-k, --private-key <key>NoPrivate key. Falls back to CHAINAI_PRIVATE_KEY.\n\nOutput (stdout):\n\n{\n  \"address\": \"0x...\"\n}"
      },
      {
        "title": "sign-message",
        "body": "Sign a message using EIP-191 personal sign.\n\nnpx chainai@0.0.10 sign-message -k 0xKEY -m \"Hello World\"\nnpx chainai@0.0.10 sign-message -k 0xKEY -m 0x68656c6c6f --raw\n\nOptions:\n\nFlagRequiredDescription-k, --private-key <key>NoPrivate key. Falls back to CHAINAI_PRIVATE_KEY.-m, --message <message>YesThe message to sign.-r, --rawNoTreat message as raw hex data (0x-prefixed).\n\nOutput (stdout):\n\n{\n  \"address\": \"0x...\",\n  \"message\": \"<original message>\",\n  \"signature\": \"0x...\"\n}"
      },
      {
        "title": "sign",
        "body": "⚠️ CRITICAL SECURITY WARNING: Signs a raw hash (secp256k1) without any prefix. The resulting signature can authorize any on-chain action. Use sign-message instead unless raw hash signing is explicitly required. Before using, verify the hash is legitimate and no safer alternative exists.\n\nnpx chainai@0.0.10 sign -k 0xKEY -h 0xHASH\n\nOptions:\n\nFlagRequiredDescription-k, --private-key <key>NoPrivate key. Falls back to CHAINAI_PRIVATE_KEY.-h, --hash <hash>YesThe hash to sign (0x-prefixed hex string).\n\nOutput (stdout):\n\n{\n  \"address\": \"0x...\",\n  \"hash\": \"0x...\",\n  \"signature\": \"0x...\"\n}"
      },
      {
        "title": "sign-typed-data",
        "body": "Sign EIP-712 typed data.\n\nnpx chainai@0.0.10 sign-typed-data -k 0xKEY -d '<json>'\n\nOptions:\n\nFlagRequiredDescription-k, --private-key <key>NoPrivate key. Falls back to CHAINAI_PRIVATE_KEY.-d, --data <json>YesEIP-712 typed data as JSON with domain, types, primaryType, message.\n\nData Format:\n\n{\n  \"domain\": {\n    \"name\": \"AppName\",\n    \"version\": \"1\",\n    \"chainId\": 1,\n    \"verifyingContract\": \"0x...\"\n  },\n  \"types\": { \"TypeName\": [{ \"name\": \"fieldName\", \"type\": \"fieldType\" }] },\n  \"primaryType\": \"TypeName\",\n  \"message\": { \"fieldName\": \"value\" }\n}\n\nOutput (stdout):\n\n{\n  \"address\": \"0x...\",\n  \"signature\": \"0x...\"\n}"
      },
      {
        "title": "sign-transaction",
        "body": "Sign a transaction (legacy, EIP-2930, or EIP-1559). Returns a serialized signed transaction ready to broadcast.\n\nnpx chainai@0.0.10 sign-transaction -k 0xKEY -t '<json>'\n\nOptions:\n\nFlagRequiredDescription-k, --private-key <key>NoPrivate key. Falls back to CHAINAI_PRIVATE_KEY.-t, --transaction <json>YesTransaction object as JSON string.\n\nTransaction Formats:\n\nLegacy:\n\n{\n  \"to\": \"0x...\",\n  \"value\": \"1000000000000000000\",\n  \"gasPrice\": \"20000000000\",\n  \"gas\": \"21000\",\n  \"nonce\": 0,\n  \"chainId\": 1\n}\n\nEIP-1559:\n\n{\n  \"to\": \"0x...\",\n  \"value\": \"1000000000000000000\",\n  \"maxFeePerGas\": \"30000000000\",\n  \"maxPriorityFeePerGas\": \"1000000000\",\n  \"gas\": \"21000\",\n  \"nonce\": 0,\n  \"chainId\": 1\n}\n\nOmit to for contract deployment. Numeric values can be strings or numbers.\n\nOutput (stdout):\n\n{\n  \"address\": \"0x...\",\n  \"serializedTransaction\": \"0x...\"\n}"
      },
      {
        "title": "get-balance",
        "body": "Get native or ERC-20 token balances.\n\nnpx chainai@0.0.10 get-balance -a 0xADDRESS\nnpx chainai@0.0.10 get-balance -a 0xADDRESS -n bsc\nnpx chainai@0.0.10 get-balance -a 0xADDRESS -t 0xTOKEN_CONTRACT\nnpx chainai@0.0.10 get-balance -a 0xADDRESS --all\n\nOptions:\n\nFlagRequiredDescription-a, --address <address>NoWallet address. Falls back to address derived from CHAINAI_PRIVATE_KEY.-n, --network <network>NoNetwork (default: mainnet).-t, --token <token>NoToken contract address. Default: 0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee (native).--allNoReturn all token balances (native + ERC-20). -t is ignored when set.\n\nOutput (stdout) — single token:\n\n{\n  \"address\": \"0x...\",\n  \"network\": \"Ethereum\",\n  \"token\": \"ETH\",\n  \"balance\": \"1.5\",\n  \"rawBalance\": \"1500000000000000000\",\n  \"decimals\": 18,\n  \"contract\": null\n}\n\nWith --all, returns an array of balance objects."
      },
      {
        "title": "send",
        "body": "Build and sign a transaction to send native tokens or ERC-20 tokens. Automatically fetches nonce, gas, and fee data from the network.\n\nnpx chainai@0.0.10 send -k 0xKEY --to 0xRECIPIENT --amount 1.5 -t 0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee\nnpx chainai@0.0.10 send -k 0xKEY --to 0xRECIPIENT --amount 100 -t 0xTOKEN_CONTRACT -n bsc\n\nOptions:\n\nFlagRequiredDescription-k, --private-key <key>NoPrivate key. Falls back to CHAINAI_PRIVATE_KEY.--to <address>YesRecipient address.-t, --token <token>YesToken contract address. Use 0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee for native.--amount <amount>YesAmount in human-readable units (e.g. \"1.5\").-n, --network <network>NoNetwork (default: mainnet).-b, --broadcastNoAutomatically broadcast after signing.\n\nOutput (stdout):\n\n{\n  \"from\": \"0x...\",\n  \"to\": \"0x...\",\n  \"token\": \"0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee\",\n  \"amount\": \"1.5\",\n  \"network\": \"Ethereum\",\n  \"serializedTransaction\": \"0x...\"\n}"
      },
      {
        "title": "broadcast",
        "body": "Broadcast a serialized signed transaction to the network.\n\nnpx chainai@0.0.10 broadcast -s 0xSERIALIZED_TX\nnpx chainai@0.0.10 broadcast -s 0xSERIALIZED_TX -n bsc\n\nOptions:\n\nFlagRequiredDescription-s, --serialized-transaction <hex>YesSerialized signed transaction (0x-prefixed).-n, --network <network>NoNetwork (default: mainnet).\n\nOutput (stdout):\n\n{\n  \"transactionHash\": \"0x...\",\n  \"network\": \"Ethereum\",\n  \"explorerUrl\": \"https://etherscan.io/tx/0x...\"\n}"
      },
      {
        "title": "tx-status",
        "body": "Get the status of a transaction by hash.\n\nnpx chainai@0.0.10 tx-status -h 0xTX_HASH\nnpx chainai@0.0.10 tx-status -h 0xTX_HASH -n bsc\n\nOptions:\n\nFlagRequiredDescription-h, --hash <hash>YesTransaction hash (0x-prefixed, 32 bytes).-n, --network <network>NoNetwork (default: mainnet).\n\nOutput (stdout):\n\n{\n  \"transactionHash\": \"0x...\",\n  \"status\": \"success\",\n  \"network\": \"Ethereum\",\n  \"blockNumber\": \"12345678\",\n  \"from\": \"0x...\",\n  \"to\": \"0x...\",\n  \"gasUsed\": \"21000\",\n  \"effectiveGasPrice\": \"30000000000\",\n  \"explorerUrl\": \"https://etherscan.io/tx/0x...\"\n}\n\nFor pending transactions, status is \"pending\" and blockNumber, from, to, gasUsed, effectiveGasPrice will be null."
      },
      {
        "title": "swap",
        "body": "Swap tokens via 1inch Fusion. Gets a quote first, then optionally submits the order. Use -y to skip confirmation and submit immediately.\n\nnpx chainai@0.0.10 swap -k 0xKEY --from-token 0xFROM --to-token 0xTO --amount 1.5\nnpx chainai@0.0.10 swap -k 0xKEY --from-token 0xFROM --to-token 0xTO --amount 1.5 -y\nnpx chainai@0.0.10 swap -k 0xKEY --from-token 0xFROM --to-token 0xTO --amount 0.5 -n bsc\n\nUse 0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee for native tokens.\n\nOptions:\n\nFlagRequiredDescription-k, --private-key <key>NoPrivate key. Falls back to CHAINAI_PRIVATE_KEY.--from-token <address>YesSource token contract address.--to-token <address>YesDestination token contract address.--amount <amount>YesAmount in human-readable units (e.g. \"1.5\").-n, --network <network>NoNetwork (default: mainnet).-y, --yesNoSkip confirmation prompt and submit immediately.\n\nOutput (stdout) — quote:\n\n{\n  \"from\": \"0x...\",\n  \"fromToken\": \"0x...\",\n  \"toToken\": \"0x...\",\n  \"amount\": \"1.5\",\n  \"estimatedReturn\": \"1500\",\n  \"estimatedReturnMin\": \"1400\",\n  \"estimatedReturnAvg\": \"1450\",\n  \"network\": \"Ethereum\"\n}\n\nOutput (stdout) — order submission:\n\n{\n  \"from\": \"0x...\",\n  \"fromToken\": \"0x...\",\n  \"toToken\": \"0x...\",\n  \"amount\": \"1.5\",\n  \"estimatedReturn\": \"1500\",\n  \"estimatedReturnMin\": \"1400\",\n  \"estimatedReturnAvg\": \"1450\",\n  \"network\": \"Ethereum\",\n  \"orderHash\": \"0x...\",\n  \"approvalTxHash\": \"0x...\"\n}\n\napprovalTxHash is non-null only when an ERC-20 token approval was required. For native token swaps or already-approved tokens, it is null."
      },
      {
        "title": "swap-order-status",
        "body": "Get the status of a 1inch Fusion swap order by its order hash.\n\nnpx chainai@0.0.10 swap-order-status -k 0xKEY --order-hash 0xORDER_HASH\nnpx chainai@0.0.10 swap-order-status -k 0xKEY --order-hash 0xORDER_HASH -n bsc\n\nOptions:\n\nFlagRequiredDescription-k, --private-key <key>NoPrivate key. Falls back to CHAINAI_PRIVATE_KEY.--order-hash <hash>YesOrder hash returned from the swap command.-n, --network <network>NoNetwork (default: mainnet).\n\nOutput (stdout):\n\n{\n  \"orderHash\": \"0x...\",\n  \"status\": \"filled\",\n  \"network\": \"Ethereum\",\n  \"createdAt\": 1700000000,\n  \"duration\": 180,\n  \"fills\": [{ \"txHash\": \"0x...\" }],\n  \"cancelTx\": null,\n  \"finalToAmount\": \"1500000000\"\n}\n\nPossible status values: \"pending\", \"filled\", \"expired\", \"cancelled\". For pending/cancelled orders, finalToAmount is null and fills is empty."
      }
    ],
    "body": "chainai — Ethereum Transactions Skill\n\n⚠️ DISCLAIMER — USE AT YOUR OWN RISK\n\nThis tool interacts with real blockchain networks and real funds. The author(s) of this tool are not responsible for any loss of funds, damages, or unintended consequences arising from its use. By using this skill, you accept full responsibility for all operations performed.\n\n🔒 MANDATORY SECURITY REQUIREMENTS FOR ALL AGENTS\n\nAgents MUST take every possible action to safeguard CHAINAI_PRIVATE_KEY and all other private keys from exposure. Specifically:\n\nNEVER log, print, echo, or display private keys in any user-facing output, logs, chat messages, or debug traces.\nNEVER store private keys in plain text files, version control, or any persistent storage that is not explicitly encrypted and access-controlled.\nNEVER transmit private keys over unencrypted channels or include them in URLs, query parameters, or request bodies to third-party services.\nNEVER include private keys in error messages, stack traces, or diagnostic output.\nALWAYS prefer the CHAINAI_PRIVATE_KEY environment variable over the -k flag to minimize key exposure in shell history and process listings.\nALWAYS treat private keys as the highest-sensitivity secret. A leaked private key grants full, irrevocable control over all funds in the associated wallet.\n\n� ADDRESS FORMATTING RULES\n\nAlways use ERC-55 checksum addresses when passing addresses to any command (wallet addresses, token contract addresses, recipient addresses, etc.).\nIf you do not know the correct checksum, use all lowercase addresses (e.g. 0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2 instead of guessing the mixed-case checksum).\nNever guess a token contract address. If you are unsure of the correct token contract address, always ask the user to provide it. Do not fabricate or assume token addresses.\n\n�🚀 BEFORE YOU BEGIN\n\nVerify your private key is set: Run npx chainai@0.0.10 who-am-i to confirm CHAINAI_PRIVATE_KEY is properly configured and resolves to the expected address before proceeding with any other command.\nNo private key? Use npx chainai@0.0.10 gen-wallet to generate a new wallet. Save the returned private key securely (e.g. as an environment variable) — it will not be shown again.\nFund your account: You must deposit the necessary funds (native tokens for gas + any tokens you intend to send or swap) to the wallet address before using send, swap, or any transaction-submitting command. Commands will fail if the account has insufficient balance.\nOverview\n\nchainai is a non-interactive CLI tool for Ethereum and EVM-compatible blockchain operations. It handles signing, sending, broadcasting transactions, token swaps (1inch Fusion), balance queries, and wallet generation.\n\nInvocation\nnpx chainai@0.0.10 <command> [options]\n\nRuntime: Node.js (>=18)\nNon-interactive: All parameters must be passed as arguments or flags. Never prompts for input.\nAuthentication\n\nMost commands accept a private key via:\n\n-k, --private-key <key> flag (hex string starting with 0x)\nCHAINAI_PRIVATE_KEY environment variable (fallback when -k is not provided)\nSupported Networks\nName\tChain ID\tAliases\tNative Token\nEthereum\t1\tmainnet, ethereum, eth\tETH\nBNB Smart Chain\t56\tbsc, binance, bnb\tBNB\n\nUse -n, --network to specify a network by name, alias, or chain ID. Defaults to mainnet.\n\nExit Codes\nCode\tMeaning\n0\tOperation completed successfully.\n1\tOperation failed. Inspect stderr for a structured error message.\nMessage Contract\nSuccess (stdout)\nCHAINAI_OK: <description>\n{ ... }\n\nErrors (stderr)\nCHAINAI_ERR: <ERROR_CODE> — <description>\n\nError Code\tDescription\tAgent Action\nINVALID_INPUT\tMalformed or missing required fields.\tRe-validate input parameters and retry.\nEXECUTION_FAILED\tOperation could not be completed. Description contains failure details.\tInspect description and adjust approach.\nTIMEOUT\tOperation exceeded the allowed time limit.\tRetry with a longer timeout or simplify the request.\nUNKNOWN\tUnexpected error.\tReport to orchestrator for manual inspection.\nRetry Strategy\n\nFor TIMEOUT and EXECUTION_FAILED errors, retry up to 2 times with exponential backoff before escalating.\n\nCommands\ngen-wallet\n\nGenerate a new random wallet (private key and address).\n\nnpx chainai@0.0.10 gen-wallet\n\n\nOptions: None.\n\nOutput (stdout):\n\n{\n  \"address\": \"0x...\",\n  \"privateKey\": \"0x...\"\n}\n\n\nUsage instructions are printed to stderr.\n\nwho-am-i\n\nReturn the Ethereum address derived from a private key.\n\nnpx chainai@0.0.10 who-am-i -k 0xKEY\n# or\nCHAINAI_PRIVATE_KEY=0xKEY npx chainai@0.0.10 who-am-i\n\n\nOptions:\n\nFlag\tRequired\tDescription\n-k, --private-key <key>\tNo\tPrivate key. Falls back to CHAINAI_PRIVATE_KEY.\n\nOutput (stdout):\n\n{\n  \"address\": \"0x...\"\n}\n\nsign-message\n\nSign a message using EIP-191 personal sign.\n\nnpx chainai@0.0.10 sign-message -k 0xKEY -m \"Hello World\"\nnpx chainai@0.0.10 sign-message -k 0xKEY -m 0x68656c6c6f --raw\n\n\nOptions:\n\nFlag\tRequired\tDescription\n-k, --private-key <key>\tNo\tPrivate key. Falls back to CHAINAI_PRIVATE_KEY.\n-m, --message <message>\tYes\tThe message to sign.\n-r, --raw\tNo\tTreat message as raw hex data (0x-prefixed).\n\nOutput (stdout):\n\n{\n  \"address\": \"0x...\",\n  \"message\": \"<original message>\",\n  \"signature\": \"0x...\"\n}\n\nsign\n\n⚠️ CRITICAL SECURITY WARNING: Signs a raw hash (secp256k1) without any prefix. The resulting signature can authorize any on-chain action. Use sign-message instead unless raw hash signing is explicitly required. Before using, verify the hash is legitimate and no safer alternative exists.\n\nnpx chainai@0.0.10 sign -k 0xKEY -h 0xHASH\n\n\nOptions:\n\nFlag\tRequired\tDescription\n-k, --private-key <key>\tNo\tPrivate key. Falls back to CHAINAI_PRIVATE_KEY.\n-h, --hash <hash>\tYes\tThe hash to sign (0x-prefixed hex string).\n\nOutput (stdout):\n\n{\n  \"address\": \"0x...\",\n  \"hash\": \"0x...\",\n  \"signature\": \"0x...\"\n}\n\nsign-typed-data\n\nSign EIP-712 typed data.\n\nnpx chainai@0.0.10 sign-typed-data -k 0xKEY -d '<json>'\n\n\nOptions:\n\nFlag\tRequired\tDescription\n-k, --private-key <key>\tNo\tPrivate key. Falls back to CHAINAI_PRIVATE_KEY.\n-d, --data <json>\tYes\tEIP-712 typed data as JSON with domain, types, primaryType, message.\n\nData Format:\n\n{\n  \"domain\": {\n    \"name\": \"AppName\",\n    \"version\": \"1\",\n    \"chainId\": 1,\n    \"verifyingContract\": \"0x...\"\n  },\n  \"types\": { \"TypeName\": [{ \"name\": \"fieldName\", \"type\": \"fieldType\" }] },\n  \"primaryType\": \"TypeName\",\n  \"message\": { \"fieldName\": \"value\" }\n}\n\n\nOutput (stdout):\n\n{\n  \"address\": \"0x...\",\n  \"signature\": \"0x...\"\n}\n\nsign-transaction\n\nSign a transaction (legacy, EIP-2930, or EIP-1559). Returns a serialized signed transaction ready to broadcast.\n\nnpx chainai@0.0.10 sign-transaction -k 0xKEY -t '<json>'\n\n\nOptions:\n\nFlag\tRequired\tDescription\n-k, --private-key <key>\tNo\tPrivate key. Falls back to CHAINAI_PRIVATE_KEY.\n-t, --transaction <json>\tYes\tTransaction object as JSON string.\n\nTransaction Formats:\n\nLegacy:\n\n{\n  \"to\": \"0x...\",\n  \"value\": \"1000000000000000000\",\n  \"gasPrice\": \"20000000000\",\n  \"gas\": \"21000\",\n  \"nonce\": 0,\n  \"chainId\": 1\n}\n\n\nEIP-1559:\n\n{\n  \"to\": \"0x...\",\n  \"value\": \"1000000000000000000\",\n  \"maxFeePerGas\": \"30000000000\",\n  \"maxPriorityFeePerGas\": \"1000000000\",\n  \"gas\": \"21000\",\n  \"nonce\": 0,\n  \"chainId\": 1\n}\n\n\nOmit to for contract deployment. Numeric values can be strings or numbers.\n\nOutput (stdout):\n\n{\n  \"address\": \"0x...\",\n  \"serializedTransaction\": \"0x...\"\n}\n\nget-balance\n\nGet native or ERC-20 token balances.\n\nnpx chainai@0.0.10 get-balance -a 0xADDRESS\nnpx chainai@0.0.10 get-balance -a 0xADDRESS -n bsc\nnpx chainai@0.0.10 get-balance -a 0xADDRESS -t 0xTOKEN_CONTRACT\nnpx chainai@0.0.10 get-balance -a 0xADDRESS --all\n\n\nOptions:\n\nFlag\tRequired\tDescription\n-a, --address <address>\tNo\tWallet address. Falls back to address derived from CHAINAI_PRIVATE_KEY.\n-n, --network <network>\tNo\tNetwork (default: mainnet).\n-t, --token <token>\tNo\tToken contract address. Default: 0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee (native).\n--all\tNo\tReturn all token balances (native + ERC-20). -t is ignored when set.\n\nOutput (stdout) — single token:\n\n{\n  \"address\": \"0x...\",\n  \"network\": \"Ethereum\",\n  \"token\": \"ETH\",\n  \"balance\": \"1.5\",\n  \"rawBalance\": \"1500000000000000000\",\n  \"decimals\": 18,\n  \"contract\": null\n}\n\n\nWith --all, returns an array of balance objects.\n\nsend\n\nBuild and sign a transaction to send native tokens or ERC-20 tokens. Automatically fetches nonce, gas, and fee data from the network.\n\nnpx chainai@0.0.10 send -k 0xKEY --to 0xRECIPIENT --amount 1.5 -t 0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee\nnpx chainai@0.0.10 send -k 0xKEY --to 0xRECIPIENT --amount 100 -t 0xTOKEN_CONTRACT -n bsc\n\n\nOptions:\n\nFlag\tRequired\tDescription\n-k, --private-key <key>\tNo\tPrivate key. Falls back to CHAINAI_PRIVATE_KEY.\n--to <address>\tYes\tRecipient address.\n-t, --token <token>\tYes\tToken contract address. Use 0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee for native.\n--amount <amount>\tYes\tAmount in human-readable units (e.g. \"1.5\").\n-n, --network <network>\tNo\tNetwork (default: mainnet).\n-b, --broadcast\tNo\tAutomatically broadcast after signing.\n\nOutput (stdout):\n\n{\n  \"from\": \"0x...\",\n  \"to\": \"0x...\",\n  \"token\": \"0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee\",\n  \"amount\": \"1.5\",\n  \"network\": \"Ethereum\",\n  \"serializedTransaction\": \"0x...\"\n}\n\nbroadcast\n\nBroadcast a serialized signed transaction to the network.\n\nnpx chainai@0.0.10 broadcast -s 0xSERIALIZED_TX\nnpx chainai@0.0.10 broadcast -s 0xSERIALIZED_TX -n bsc\n\n\nOptions:\n\nFlag\tRequired\tDescription\n-s, --serialized-transaction <hex>\tYes\tSerialized signed transaction (0x-prefixed).\n-n, --network <network>\tNo\tNetwork (default: mainnet).\n\nOutput (stdout):\n\n{\n  \"transactionHash\": \"0x...\",\n  \"network\": \"Ethereum\",\n  \"explorerUrl\": \"https://etherscan.io/tx/0x...\"\n}\n\ntx-status\n\nGet the status of a transaction by hash.\n\nnpx chainai@0.0.10 tx-status -h 0xTX_HASH\nnpx chainai@0.0.10 tx-status -h 0xTX_HASH -n bsc\n\n\nOptions:\n\nFlag\tRequired\tDescription\n-h, --hash <hash>\tYes\tTransaction hash (0x-prefixed, 32 bytes).\n-n, --network <network>\tNo\tNetwork (default: mainnet).\n\nOutput (stdout):\n\n{\n  \"transactionHash\": \"0x...\",\n  \"status\": \"success\",\n  \"network\": \"Ethereum\",\n  \"blockNumber\": \"12345678\",\n  \"from\": \"0x...\",\n  \"to\": \"0x...\",\n  \"gasUsed\": \"21000\",\n  \"effectiveGasPrice\": \"30000000000\",\n  \"explorerUrl\": \"https://etherscan.io/tx/0x...\"\n}\n\n\nFor pending transactions, status is \"pending\" and blockNumber, from, to, gasUsed, effectiveGasPrice will be null.\n\nswap\n\nSwap tokens via 1inch Fusion. Gets a quote first, then optionally submits the order. Use -y to skip confirmation and submit immediately.\n\nnpx chainai@0.0.10 swap -k 0xKEY --from-token 0xFROM --to-token 0xTO --amount 1.5\nnpx chainai@0.0.10 swap -k 0xKEY --from-token 0xFROM --to-token 0xTO --amount 1.5 -y\nnpx chainai@0.0.10 swap -k 0xKEY --from-token 0xFROM --to-token 0xTO --amount 0.5 -n bsc\n\n\nUse 0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee for native tokens.\n\nOptions:\n\nFlag\tRequired\tDescription\n-k, --private-key <key>\tNo\tPrivate key. Falls back to CHAINAI_PRIVATE_KEY.\n--from-token <address>\tYes\tSource token contract address.\n--to-token <address>\tYes\tDestination token contract address.\n--amount <amount>\tYes\tAmount in human-readable units (e.g. \"1.5\").\n-n, --network <network>\tNo\tNetwork (default: mainnet).\n-y, --yes\tNo\tSkip confirmation prompt and submit immediately.\n\nOutput (stdout) — quote:\n\n{\n  \"from\": \"0x...\",\n  \"fromToken\": \"0x...\",\n  \"toToken\": \"0x...\",\n  \"amount\": \"1.5\",\n  \"estimatedReturn\": \"1500\",\n  \"estimatedReturnMin\": \"1400\",\n  \"estimatedReturnAvg\": \"1450\",\n  \"network\": \"Ethereum\"\n}\n\n\nOutput (stdout) — order submission:\n\n{\n  \"from\": \"0x...\",\n  \"fromToken\": \"0x...\",\n  \"toToken\": \"0x...\",\n  \"amount\": \"1.5\",\n  \"estimatedReturn\": \"1500\",\n  \"estimatedReturnMin\": \"1400\",\n  \"estimatedReturnAvg\": \"1450\",\n  \"network\": \"Ethereum\",\n  \"orderHash\": \"0x...\",\n  \"approvalTxHash\": \"0x...\"\n}\n\n\napprovalTxHash is non-null only when an ERC-20 token approval was required. For native token swaps or already-approved tokens, it is null.\n\nswap-order-status\n\nGet the status of a 1inch Fusion swap order by its order hash.\n\nnpx chainai@0.0.10 swap-order-status -k 0xKEY --order-hash 0xORDER_HASH\nnpx chainai@0.0.10 swap-order-status -k 0xKEY --order-hash 0xORDER_HASH -n bsc\n\n\nOptions:\n\nFlag\tRequired\tDescription\n-k, --private-key <key>\tNo\tPrivate key. Falls back to CHAINAI_PRIVATE_KEY.\n--order-hash <hash>\tYes\tOrder hash returned from the swap command.\n-n, --network <network>\tNo\tNetwork (default: mainnet).\n\nOutput (stdout):\n\n{\n  \"orderHash\": \"0x...\",\n  \"status\": \"filled\",\n  \"network\": \"Ethereum\",\n  \"createdAt\": 1700000000,\n  \"duration\": 180,\n  \"fills\": [{ \"txHash\": \"0x...\" }],\n  \"cancelTx\": null,\n  \"finalToAmount\": \"1500000000\"\n}\n\n\nPossible status values: \"pending\", \"filled\", \"expired\", \"cancelled\". For pending/cancelled orders, finalToAmount is null and fills is empty."
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/kvhnuke/chainai",
    "publisherUrl": "https://clawhub.ai/kvhnuke/chainai",
    "owner": "kvhnuke",
    "version": "0.0.12",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/chainai",
    "downloadUrl": "https://openagent3.xyz/downloads/chainai",
    "agentUrl": "https://openagent3.xyz/skills/chainai/agent",
    "manifestUrl": "https://openagent3.xyz/skills/chainai/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/chainai/agent.md"
  }
}