Hinkal API

Balance

Get shielded token balances

GET/balance
https://api.hinkal.io/balance

Read-only — requires an active session. Pass sessionId and nonce as query parameters and include x-hinkal-request-signature: secp256k1_sign(SHA256("GET /balance\n" + queryString)) in the headers. Works for EVM, Tron, and Solana chains.

Query parameters

NameTypeDescription
sessionIdrequiredstring (uuid)Session identifier UUID from POST /create-session
noncerequiredstring (uuid)Per-request UUID. Echoed back in the response.
chainIdrequiredstringChain ID (e.g. 10 for Optimism, 501 for Solana mainnet, 728126428 for Tron mainnet)

Header parameters

NameTypeDescription
x-hinkal-request-signaturerequiredstringHex-encoded compact secp256k1 signature: secp256k1_sign(SHA256(binding + "\n" + payload)), where binding is "<METHOD> <routePath>" (this route's own method and path, e.g. "POST /deposit" or "GET /balance") and payload is JSON.stringify(body) for POST requests or the raw query string for GET requests. Binding the route into the signed digest stops a signature captured for one endpoint from being replayed against another. See Authentication for the full signing scheme.

Responses

200Shielded balances
NameTypeDescription
successrequiredboolean
One of: true
balancesrequiredobject[]
balances[].chainIdrequiredinteger
balances[].tokenAddressrequiredstring
balances[].balancerequiredstringBalance in the token's smallest unit
noncerequiredstringEchoed per-request nonce from the request.
401Invalid signature or reused nonce
NameTypeDescription
successrequiredboolean
One of: false
errorrequiredstring
500Server error
NameTypeDescription
successrequiredboolean
One of: false
errorrequiredstring