install
source · Clone the upstream repo
git clone https://github.com/openclaw/skills
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/openclaw/skills "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/bdonglobal/tokenview-address-balance" ~/.claude/skills/openclaw-skills-tokenview-address-balance && rm -rf "$T"
OpenClaw · Install into ~/.openclaw/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/openclaw/skills "$T" && mkdir -p ~/.openclaw/skills && cp -r "$T/skills/bdonglobal/tokenview-address-balance" ~/.openclaw/skills/openclaw-skills-tokenview-address-balance && rm -rf "$T"
manifest:
skills/bdonglobal/tokenview-address-balance/SKILL.mdsource content
SKILL: getAddressBalance
Description
A skill for querying the balance of a specified blockchain address using the Tokenview API.
The default supported coin is BTC, and the API Key must be provided through the environment variable
TOKENVIEW_API_KEY.
Triggers
- "What is the balance of BTC address
?" or "How much BTC does<address>
have?"<address> - Any conversation where an address is detected and interpreted as a balance query
API Endpoint and Secret Handling
- Tokenview API:
https://services.tokenview.io/vipapi/addr/b/{lowercase-coin-abbr}/{address}?apikey={apikey} - Using environment variable
to config API Key。TOKENVIEW_API_KEY - Parameters:
is coin abbreviation in lowercase (default:lowercase-coin-abbr
),btc
blockchain address extracted from the conversationaddress - Output format:The script returns JSON
Parameters
- address:The Blockchain address
- coin:Coin abbreviation, default is btc
Output Format
- Success:The script returns JSON , and the user sees:"Balance is {balance} {COIN}"
- Failure:Example raw Tokenview API JSON:
will be like: "Balance query failed:Code=1, Msg=404, Data=NONE"{ "code": 1, "msg": "404", "data": "NONE" }
Implementation (execution plan)
- The skill executes the tokenview_api.py script to perform the API call:
- Example command (BTC):
python $OPENCLAW_STATE_DIR/workspace/skills/tokenview_balance_checker/tokenview_api.py <address> --coin btc
- Example command (BTC):
- Script information:
- Path:
$OPENCLAW_STATE_DIR/workspace/skills/tokenview_balance_checker/tokenview_api.py - Inputs: address (required),coin (optional, default is btc)
- Dependencies: requests
- API Key: Provided via environment variable TOKENVIEW_API_KEY
- Output: JSON printed to stdout, e.g.:
{"code":1,"msg":"success","data":"0.123 BTC"}
- Path:
Parameters (payload-driven)
- address: blockchain address to query
- coin: currency abbreviation (default: btc)
Output Mapping (to user-facing text)
- Success: "Balance is {balance} {COIN}"
- Failure: "Code={code}, Msg={msg}, Data={data}"
Example
- Input: "1A1zP1eP5QGefi2DMPTfTL5SLmv7DivfNa 余额多少?"
- Script output: {"code":1, "msg":"成功", "data":"0.12345678 BTC"}
- User visible: 余额为 0.12345678 BTC