
Query Token Info
- 6k installs
- 942 repo stars
- Updated July 23, 2026
- binance/binance-skills-hub
query-token-info is a Binance Web3 CLI skill exposing four read-only token endpoints: search, meta, dynamic, and kline for multi-chain token research and market analysis.
About
Query Token Info is a Binance Web3 agent skill that fronts four read-only token endpoints through one Node.js CLI. Agents pick a subcommand and pass JSON parameters to search tokens by keyword, symbol, or contract address across Ethereum, BSC, Base, and Solana; fetch static metadata including name, logo, social links, and creator; pull real-time market data such as price, 24h change, volume, holder count, and liquidity; or retrieve OHLCV candlestick series for technical chart analysis. The skill documents required chainId values, CLI invocation patterns, icon URL prefixing with https://bin.bnbstatic.com, numeric string conversion before arithmetic, kline 2D array structure, and interval options from 1s through 1m. Use when users request token prices, contract lookups, holder distribution, creator attribution, social profiles, or candlestick windows with configurable limits and time bounds for market research workflows.
- Search tokens by keyword, symbol, or contract across Ethereum, BSC, Base, and Solana
- Four CLI subcommands: search, meta, dynamic, and kline with shared chainId values
- Static metadata covers logo, social links, creator info, and official website
- Real-time market data includes price, volume, holder count, and liquidity fields
- Kline returns OHLCV candles with intervals from 1s through 1m and configurable limits
Query Token Info by the numbers
- 5,985 all-time installs (skills.sh)
- +103 installs in the week ending Jul 28, 2026 (Skillselion tracking)
- Ranked #6 of 483 Web3 & Blockchain skills by installs in the Skillselion catalog
- Security screen: MEDIUM risk (skills.sh audit)
- Data as of Jul 28, 2026 (Skillselion catalog sync)
query-token-info capabilities & compatibility
- Capabilities
- search tokens by keyword, symbol, or contract ad · fetch static token metadata and social links · retrieve real time price, volume, holders, and l · return ohlcv candlestick arrays for chart analys · support ethereum, bsc, base, and solana chainid
- Use cases
- trading · data analysis · research
What query-token-info says it does
Four read-only token endpoints fronted by one CLI.
npx skills add https://github.com/binance/binance-skills-hub --skill query-token-infoAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 6k |
|---|---|
| repo stars | ★ 942 |
| Security audit | 2 / 3 scanners passed |
| Last updated | July 23, 2026 |
| Repository | binance/binance-skills-hub ↗ |
What it does
Per-token search, metadata, market data, and OHLCV candlesticks across Ethereum, BSC, Base, and Solana via one CLI.
Who is it for?
Crypto researchers and trading agents answering price, contract, holder, creator, social link, or candlestick questions on Ethereum, BSC, Base, or Solana.
Skip if: On-chain writes, wallet transactions, portfolio management, or tokens outside the four supported chains and documented CLI subcommands.
When should I use this skill?
User asks for token price, search by keyword or contract, kline chart data, creator info, social links, holder count, or liquidity for a specific token.
What you get
One documented CLI invocation returns chain-aware token search results, static profiles, real-time price and liquidity metrics, or OHLCV series ready for technical analysis.
- JSON token search results
- chain-filtered metadata
By the numbers
- Documents 3 exit codes: 0, 1, and 3
- search command accepts chainIds like 56, 1, 8453, and CT_501
Files
Query Token Info Skill
Overview
Four read-only token endpoints fronted by one CLI. The agent picks a subcommand and passes a JSON blob; with this skill user can:
Search Tokens: Find tokens by name, symbol, or contract address across chains. Token Research: Get token metadata, social links, and creator info. Market Analysis: Real-time price, volume, holder distribution, and liquidity data. Chart Analysis: K-Line candlestick data for technical analysis.
When to Use This Skill
| User intent | Command |
|---|---|
| Search a token by keyword, symbol, or contract address | search |
| Get static metadata (name, symbol, logo, social links, creator) | meta |
| Get real-time market data (price, volume, holders, liquidity) | dynamic |
| Get candlestick chart / OHLCV data | kline |
Supported Chains
| Chain | chainId |
|---|---|
| Ethereum | 1 |
| BSC | 56 |
| Base | 8453 |
| Solana | CT_501 |
All four commands (search, meta, dynamic, kline) use the same chainId values.
How to Call APIs
node <skill-dir>/scripts/cli.mjs <command> '<json_params>'Example:
node <skill-dir>/scripts/cli.mjs search '{"keyword":"<keyword>","chainIds":"56"}'Commands
| Command | Purpose | Required args | Example |
|---|---|---|---|
search | Search tokens by keyword | keyword (optional: chainIds, orderBy) | node <skill-dir>/scripts/cli.mjs search '{"keyword":"<keyword>","chainIds":"1,56,8453,CT_501"}' |
meta | Static token metadata | chainId, contractAddress | node <skill-dir>/scripts/cli.mjs meta '{"chainId":"56","contractAddress":"0x..."}' |
dynamic | Real-time market data | chainId, contractAddress | node <skill-dir>/scripts/cli.mjs dynamic '{"chainId":"56","contractAddress":"0x..."}' |
kline | Candlestick data | chainId, contractAddress, interval (optional: limit, from, to, pm) | node <skill-dir>/scripts/cli.mjs kline '{"chainId":"56","contractAddress":"0x...","interval":"1min","limit":500}' |
Rules
- Icon URL:
iconfields are relative paths. Prependhttps://bin.bnbstatic.comfor a usable URL. - Numbers as strings: All numeric market fields (
price,volume24h,marketCap, etc.) are
returned as strings. Convert before arithmetic.
- Kline is a 2D array, not JSON objects. Each candle:
[open, high, low, close, volume, timestamp_ms, count]. - Kline time window:
limittakes priority overfromwhen both are provided. Useto
with limit to fetch the N most recent candles ending at to. pm selects price (p, default) or market-cap (m) series.
- Intervals supported by
kline:1s,1min,3min,5min,15min,30min,1h,2h,
4h, 6h, 8h, 12h, 1d, 3d, 1w, 1m.
Full CLI Reference
See `references/cli.md` for per-subcommand invocations, parameter tables, return-field tables, and real response samples.
query-token-info — CLI Reference
Complete reference for every command in scripts/cli.mjs.
Invocation pattern: node <skill-dir>/scripts/cli.mjs <command> '<json_params>' Exit codes: 0 success · 1 usage/upstream error · 3 network failure
---
search — Search tokens by keyword
node <skill-dir>/scripts/cli.mjs search '{"keyword":"<keyword>","chainIds":"56"}'Parameters
| Param | Type | Required | Description |
|---|---|---|---|
keyword | string | yes | Name / symbol / contract address |
chainIds | string | no | Comma-separated chainIds (e.g. "56", "1,56,8453,CT_501"); default: all |
orderBy | string | no | Sort key, e.g. volume24h |
Return fields (under .data[])
| Field | Type | Description |
|---|---|---|
chainId | string | Chain identifier (e.g. "56" = BSC) |
contractAddress | string | Token contract address |
tokenId | string | Binance-internal token ID (stable across address changes) |
name, symbol | string | Token display names |
icon | string | Logo path — prefix with https://bin.bnbstatic.com |
price, percentChange24h | string | Latest USD price and 24h change (%) |
volume24h, marketCap, liquidity | string | All USD; string-encoded decimals |
tagsInfo | object | Risk / recognition tags, categorized (e.g. "Sensitive Events": [...], "Community Recognition Level": [...]) |
---
meta — Static token metadata
node <skill-dir>/scripts/cli.mjs meta '{"chainId":"56","contractAddress":"0x..."}'Parameters
| Param | Type | Required | Description |
|---|---|---|---|
chainId | string | yes | Chain identifier |
contractAddress | string | yes | Token contract address (case-insensitive) |
Return fields (under .data)
| Field | Type | Description |
|---|---|---|
tokenId | string | Binance-internal stable ID |
name, symbol, decimals | — | Display name, ticker, precision |
chainName, chainIconUrl | string | Chain display info |
links | array of {label, link} | Website / whitepaper / social links |
aiNarrativeFlag | number | 1 = AI has narrative summary available |
nativeAddressFlag | boolean | true = native chain coin (not an ERC-20) |
links[] entries are {label, link} — labels include "website", "whitepaper", social platforms.
---
dynamic — Real-time market data
node <skill-dir>/scripts/cli.mjs dynamic '{"chainId":"56","contractAddress":"0x..."}'Parameters
| Param | Type | Required | Description |
|---|---|---|---|
chainId | string | yes | Chain identifier |
contractAddress | string | yes | Token contract address |
Return fields (under .data)
Price + volume/buy/sell breakdowns across multiple windows (5m, 1h, 4h, 24h), separated by on-chain vs Binance-routed:
| Field pattern | Meaning |
|---|---|
price, nativeTokenPrice | Current USD price and chain-native price |
volume{5m,1h,4h,24h} | Total trading volume in window (USD) |
volume{window}{Buy,Sell} | Direction breakdown |
volume{window}Binance | Binance-routed subset |
volume{window}Net{Buy,Binance} | Net flow = Buy − Sell |
holders | Holder count (if available) |
liquidity | Current liquidity in USD |
---
kline — Candlestick OHLCV
node <skill-dir>/scripts/cli.mjs kline '{"chainId":"56","contractAddress":"0x...","interval":"1h","limit":24}'Parameters
| Param | Type | Required | Description |
|---|---|---|---|
chainId | string | yes | Chain identifier — 1 (Ethereum) / 56 (BSC) / 8453 (Base) / CT_501 (Solana) |
contractAddress | string | yes | Token contract address |
interval | string | yes | Candle size: 1s / 1min / 3min / 5min / 15min / 30min / 1h / 2h / 4h / 6h / 8h / 12h / 1d / 3d / 1w / 1m |
limit | number | no | Optional. Max 500 per request. Has higher priority than from when both provided. |
from | number | no | Optional. Start timestamp in milliseconds. |
to | number | no | Optional. End timestamp in milliseconds. |
pm | string | no | Optional. Price mode — p (price, default) or m (marketcap). |
Return shape (under .data[])
Each row is a 2D array (7 numbers):
| Index | Field |
|---|---|
[0] | open price (USD) |
[1] | high price |
[2] | low price |
[3] | close price |
[4] | volume |
[5] | timestamp (ms since epoch, start of candle) |
[6] | trade count |
Envelope is { data, status: {error_code, error_message} } — no code field (unlike other commands).
---
Errors
Exit codes: 0 ok · 1 upstream/usage (stderr: reason; stdout: body with business code) · 3 network. Business code: 000000 ok · 100004 rate-limited · 100002 bad param · 000400 token not found / unsupported chain.
#!/usr/bin/env node
// query-token-info CLI — self-contained, zero-dep, Node >= 22
// Usage: node cli.mjs <command> '<json_params>'
//
// Commands:
// search token search by keyword
// meta static token metadata
// dynamic real-time market data (price, volume, holders)
// kline candlestick data
//
// All 4 commands use the SAME parameter shape: { chainId, contractAddress, ... }.
// Internally, kline hits a different host and uses different upstream field names
// (platform/address) — this CLI handles the translation so the LLM caller sees
// one consistent interface.
// ---- inline HTTP helper (self-contained, zero dependency) ----
const TIMEOUT_MS = 10_000;
const UA = { 'Accept-Encoding': 'identity', 'User-Agent': 'binance-web3/2.0 (Skill)' };
// ---- chainId → upstream kline platform name ----
// Single source of truth for chain identity. Used only by kline (other commands
// pass chainId through as-is to the Binance Web3 API which accepts chainId directly).
const CHAIN_ID_TO_PLATFORM = {
'1': 'ethereum',
'56': 'bsc',
'8453': 'base',
'CT_501': 'solana',
};
const qs = (p) => Object.entries(p)
.filter(([, v]) => v != null)
.map(([k, v]) => `${encodeURIComponent(k)}=${encodeURIComponent(v)}`)
.join('&');
async function call({ url, method = 'GET', body, headers = {} }) {
const ctrl = new AbortController();
const timer = setTimeout(() => ctrl.abort(), TIMEOUT_MS);
const opts = { method, headers: { ...UA, ...headers }, signal: ctrl.signal };
if (method === 'POST') { opts.headers['content-type'] = 'application/json'; opts.body = JSON.stringify(body || {}); }
let res;
try { res = await fetch(url, opts); }
catch { clearTimeout(timer); throw Object.assign(new Error('Network request failed'), { exitCode: 3 }); }
clearTimeout(timer);
const data = await res.json();
if (res.status >= 400) throw Object.assign(new Error(`HTTP ${res.status}`), { exitCode: 1, body: data });
return data;
}
// ---- commands: (params) => { url, method?, body?, headers? } ----
const COMMANDS = {
search: (p) => ({
url: `https://web3.binance.com/bapi/defi/v5/public/wallet-direct/buw/wallet/market/token/search/ai?${qs(p)}`,
}),
meta: (p) => ({
url: `https://web3.binance.com/bapi/defi/v1/public/wallet-direct/buw/wallet/dex/market/token/meta/info/ai?${qs(p)}`,
}),
dynamic: (p) => ({
url: `https://web3.binance.com/bapi/defi/v4/public/wallet-direct/buw/wallet/market/token/dynamic/info/ai?${qs(p)}`,
}),
kline: (p) => {
// Translate unified interface → upstream kline field names.
// { chainId, contractAddress, interval, ... } → { platform, address, interval, ... }
const { chainId, contractAddress, ...rest } = p;
const platform = chainId == null ? undefined : CHAIN_ID_TO_PLATFORM[chainId];
if (chainId != null && platform === undefined) {
const supported = Object.keys(CHAIN_ID_TO_PLATFORM).map((k) => `"${k}"`).join(', ');
throw Object.assign(
new Error(`kline: unsupported chainId "${chainId}". Supported: ${supported}`),
{ exitCode: 1 },
);
}
const upstream = { ...rest };
if (platform !== undefined) upstream.platform = platform;
if (contractAddress !== undefined) upstream.address = contractAddress;
return {
url: `https://dquery.sintral.io/u-kline/v1/k-line/candles?${qs(upstream)}`,
};
},
};
// ---- exports (for unit testing; direct execution still works — see dispatch below) ----
export { COMMANDS, call, qs, UA, TIMEOUT_MS, CHAIN_ID_TO_PLATFORM };
// ---- CLI dispatch (only runs when executed directly, not when imported) ----
if (import.meta.url === `file://${process.argv[1]}`) {
const [cmd, paramsStr] = process.argv.slice(2);
if (!cmd || cmd === '--help' || cmd === '-h') {
console.log("Usage: node cli.mjs <command> '<json_params>'\n\nCommands:");
for (const name of Object.keys(COMMANDS)) console.log(` ${name}`);
process.exit(0);
}
const builder = COMMANDS[cmd];
if (!builder) { console.error(`Unknown command: ${cmd}\nRun with --help to see available commands.`); process.exit(1); }
let params = {};
if (paramsStr) {
try { params = JSON.parse(paramsStr); }
catch { console.error('Invalid JSON params'); process.exit(1); }
}
try {
const result = await call(builder(params));
console.log(JSON.stringify(result, null, 2));
} catch (err) {
console.error(err.message);
if (err.body) console.log(JSON.stringify(err.body, null, 2));
process.exit(err.exitCode || 1);
}
}
Related skills
How it compares
Use query-token-info when agents need a lightweight Binance token lookup CLI rather than full exchange trading SDKs or manual REST integration.
FAQ
Which chains does query-token-info support?
Ethereum (chainId 1), BSC (56), Base (8453), and Solana (CT_501). All four commands use the same chainId values.
How do I invoke the CLI?
Run node <skill-dir>/scripts/cli.mjs <command> '<json_params>' where command is search, meta, dynamic, or kline.
What kline intervals are available?
1s, 1min, 3min, 5min, 15min, 30min, 1h, 2h, 4h, 6h, 8h, 12h, 1d, 3d, 1w, and 1m with optional limit, from, to, and pm parameters.
Is Query Token Info safe to install?
skills.sh reports 2 of 3 security scanners passed. Review the Security Audits panel on this page before installing in production.