walletconnect-mcp

v0.0.4
io.github.DELIGHT-LABS/walletconnect-mcp Checked 2 days ago Published 5 months ago

Non-custodial EVM wallet bridge over WalletConnect: balances, signing, transactions.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

connect Connect wallet

Initiate a WalletConnect session. Returns the QR as an image block, the raw wc: URI, a deep link, the QR PNG path on disk, and a render guide for surfacing the QR per host. Does not wait for wallet approval — call status with wait_ms right after this to long-poll for the approval.

disconnect Disconnect wallet

Disconnect the active WalletConnect session.

status Connection status

Return the current WalletConnect session status: disconnected, connecting, or connected (with CAIP-10 address and chain id). Pass wait_ms (e.g. 50000) right after connect to long-poll: the call returns as soon as the wallet approves/rejects, or after wait_ms if still pending. No-op when not connecting.

ParameterTypeDescription
wait_msintegerMax ms to wait for a pending connect to settle before returning (long-poll; capped at 50000). Omit for an instant snapshot.

get_balance Get balance

Read native-coin balances within the connected session. Requires an active session — call connect first. Omit `chains` to sweep every granted chain; pass `chains` (CAIP-2 ids or numeric chain ids) to read specific granted chains. `account` defaults to the connected wallet address.

ParameterTypeDescription
accountstringAccount address to query. Defaults to the connected wallet address.
chainsarrayChains to read as CAIP-2 ids ("eip155:1") or numeric chain ids. Omit to read every granted chain.

send_transaction Send transaction

Send an EVM transaction via the connected WalletConnect wallet. The wallet will prompt the user to approve and sign. By default this waits for the on-chain receipt and returns the settled result (confirmed/reverted, block number, gas used). Set wait=false to return immediately with just the transaction hash. Requires an active session — call connect first.

ParameterTypeDescription
chain *string | numberTarget chain as a CAIP-2 id ("eip155:11155111") or numeric chain id. REQUIRED — there is no default chain; pick one of the granted chains from status.
to *stringRecipient address (0x…)
datastringHex-encoded calldata (e.g. "0x" for plain ETH transfer). Omit for plain transfer.
fromstringSender address. Defaults to the connected wallet address if omitted.
timeout_msintegerMax ms to wait for the receipt (default 120000). Ignored when wait=false.
valuestringValue in wei as a hex string (e.g. "0x38D7EA4C68000" for 0.001 ETH). Omit for 0.
waitbooleanWait for the receipt and return the settled result. Default true.

sign_transaction Sign transaction (no broadcast)

Sign an EVM transaction with the connected wallet WITHOUT broadcasting it (eth_signTransaction). Returns the signed raw transaction hex — nothing is sent on-chain. Use send_transaction to sign AND broadcast. Not all wallets support this method. Requires an active session — call connect first.

ParameterTypeDescription
chain *string | numberTarget chain as a CAIP-2 id ("eip155:11155111") or numeric chain id. REQUIRED — there is no default chain; pick one of the granted chains from status.
to *stringRecipient address (0x…)
datastringHex-encoded calldata (e.g. "0x" for plain ETH transfer). Omit for plain transfer.
fromstringSender address. Defaults to the connected wallet address if omitted.
valuestringValue in wei as a hex string (e.g. "0x38D7EA4C68000" for 0.001 ETH). Omit for 0.

personal_sign Sign message

Sign an arbitrary message with the connected wallet using personal_sign (adds the Ethereum message prefix). Returns the hex signature. Requires an active session — call connect first.

ParameterTypeDescription
message *stringMessage to sign. Either a plain UTF-8 string or a 0x-prefixed hex string.
addressstringSigner address. Defaults to the connected wallet address if omitted.

sign_typed_data Sign typed data (EIP-712)

Sign EIP-712 typed structured data with the connected wallet (eth_signTypedData_v4 by default). Off-chain: no gas, nothing is broadcast. Returns the hex signature. Requires an active session — call connect first.

ParameterTypeDescription
typed_data *stringEIP-712 payload as a JSON string with `domain`, `types`, `primaryType`, and `message` fields.
addressstringSigner address. Defaults to the connected wallet address if omitted.
versionstringTyped-data method version. "v4" (default) = eth_signTypedData_v4 — use this unless the dapp explicitly requires the legacy v1 method.