connect_wallet
Creates a local API wallet key and opens a page for the user's browser wallet to approve it with one signature, enabling trading (but not withdrawals). Poll with status=true to track the connect.
Instructions
Connect the user's Hyperliquid wallet so pathiel can trade: makes a new API wallet key on this machine, opens a local page where the user's browser wallet approves it with one signature, and saves the key to ~/.pathiel/.env.local. The API wallet can trade and never withdraw. status=true reports a connect in progress (waiting, done or failed) and starts nothing; cancel=true stops a waiting one; replace=true swaps a key already set, only when the user said so; open_browser=false prints the page link instead of opening it. Call only when the user asked; get_status shows whether trading is enabled. It returns at once and does not wait for the signature: poll with status=true. With a key already set it keeps that key unless replace=true. A failure returns {ok: false, state: failed, code, error, next} saying what to do. Returns the connect state (waiting, done or failed) and the page link.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "connect_wallet"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cancel | No | stop a waiting connect | |
| status | No | report the current connect, start nothing | |
| replace | No | swap out the key already set; only when the user said so | |
| open_browser | No | open the page (default true) |