query-address-info

Original🇺🇸 English
Translated

Query any on-chain wallet address token balances and positions. Retrieves all token holdings for a specified wallet address on a given chain, including token name, symbol, price, 24h price change, and holding quantity. Use this skill when users ask about wallet balance, token holds, portfolio, or asset positions for any blockchain address.

12installs
Added on

NPX Install

npx skill4agent add binance/binance-skills-hub query-address-info

Tags

Translated version includes tags in frontmatter

Query Address Info Skill

Overview

This skill queries any on-chain wallet address for token holdings, supporting:
  • List of all tokens held by a wallet address
  • Current price of each token
  • 24-hour price change percentage
  • Holding quantity

API Endpoint

Query Wallet Token Balance

Method: GET
URL:
https://web3.binance.com/bapi/defi/v3/public/wallet-direct/buw/wallet/address/pnl/active-position-list
Request Parameters:
ParameterTypeRequiredDescription
addressstringYesWallet address, e.g.,
0x02e9b4708d41ca10632918edd9e94e21edd82ed1
chainIdstringYesChain ID, e.g.,
56
(BSC),
1
(ETH),
8453
(Base)
offsetnumberNoPagination offset, default 0
Request Headers:
clienttype: web
clientversion: 1.2.0
Accept-Encoding: identity
Example Request:
bash
curl --location 'https://web3.binance.com/bapi/defi/v3/public/wallet-direct/buw/wallet/address/pnl/active-position-list?address=0x02e9b4708d41ca10632918edd9e94e21edd82ed1&chainId=56&offset=0' \
--header 'clienttype: web' \
--header 'clientversion: 1.2.0' \
--header 'Accept-Encoding: identity'
Response Example:
json
{
    "code": "000000",
    "message": null,
    "messageDetail": null,
    "data": {
        "offset": 0,
        "addressStatus": null,
        "list": [
            {
                "chainId": "56",
                "address": "0x02e9b4708d41ca10632918edd9e94e21edd82ed1",
                "contractAddress": "0xe97b7ba92e5058d0456894ff6f969683cfd44444",
                "name": "The Giraffes",
                "symbol": "GIRAFFES",
                "icon": "/images/web3-data/public/token/logos/A0B22474BF610AE1646962D05D2BE933.png",
                "decimals": 18,
                "price": "0.0000045375251839978",
                "percentChange24h": "6.84",
                "remainQty": "20"
            }
        ]
    },
    "success": true
}
Response Fields:
FieldTypeDescription
chainIdstringChain ID
addressstringWallet address
contractAddressstringToken contract address
namestringToken name
symbolstringToken symbol
iconstringToken icon URL path
decimalsnumberToken decimals
pricestringCurrent price (USD)
percentChange24hstring24-hour price change (%)
remainQtystringHolding quantity

Supported Chains

Chain NamechainId
BSC56
Ethereum1
Base8453
SolanaCT_501

Use Cases

  1. Query Wallet Assets: When users want to view tokens held by a wallet address
  2. Track Holdings: Monitor wallet token positions
  3. Portfolio Analysis: Understand wallet asset allocation

Notes

  1. Icon URL requires full domain prefix:
    bin.bnbstatic.com
    + icon path
  2. Price and quantity are string format, convert to numbers when using
  3. Use offset parameter for pagination