Agent ID
This guide explains how to resolve Agent IDs in both directions:
Forward resolution: handle → wallet address (
alice→0x1111…)Reverse resolution: wallet address → handle (
0x1111…→alice)
You can resolve through the Agent ID HTTP API or by reading the registry contract on BNB Smart Chain directly. Both return the same data.
What is Agent ID
Agent ID is a human-readable name for a Binance Agent Wallet on BNB Smart Chain. SPACE ID built it with Binance. Each Agent ID is a handle such as alice that is minted as an ERC-721 NFT in the SPACE ID Agent ID (AI) collection.
Addresses and endpoints
Chain
BNB Smart Chain Mainnet (chain ID 56)
Registry contract
Deployed at block
127950748
Collection
SPACE ID Agent ID (AI)
API base URL
https://agentid.prd.space.id
NFT metadata
https://agentid.prd.space.id/metadata/{handle}.json
Option 1: Resolve through the API
Use the API when you already integrate with Agent ID registration, or when you want the NFT token ID, registration transaction, and block number with the result.
Both lookups are public and need no API key. Each API instance applies a request-rate limit, so cache results; they never change once registered.
Forward: GET /v1/handles/{handle}
Reverse: GET /v1/addresses/{address}
Response
Both endpoints return the same schema (200 OK):
handle
The registered handle.
owner
The address that holds the handle.
tokenId
ERC-721 token ID as a base-10 string. It equals uint256(keccak256(handle)).
txHash, blockNumber
The registration transaction and its block.
asOfBlock
The last finalized block indexed by the API.
Errors
404
not_found
No Agent ID exists for this handle or address as of asOfBlock. Treat it as "no name".
400
invalid_handle / invalid_owner
The input is malformed. The handle path is not normalized; lowercase it before calling.
429
rate_limited
Retry after the Retry-After interval.
503
indexer_not_ready
Temporary; retry later.
Option 2: Resolve on-chain directly
Use the contract when you want no SPACE ID dependency, or the latest block rather than the finalized block. Any BSC Mainnet RPC works.
Contract interface
Pass the normalized handle (lowercase a-z0-9) to ownerOfHandle. The contract does not normalize input, so Alice resolves to address(0).
Because handles are soulbound and permanent, a reverse result from handleOf is authoritative. It does not need a forward check, unlike ENS reverse records.
Command line (Foundry cast)
TypeScript (viem)
Indexing events
To build your own index, subscribe to these events from the registry deployment block:
Each event is final for that handle and address; no later event removes or changes a registration.
Choosing an option
Freshness
Finalized blocks only
Any block, including latest
Extra data
tokenId, txHash, blockNumber
Handle or address only; tokenId can be derived
Dependency
SPACE ID service availability
Your BSC RPC
Display Agent IDs as the plain handle, for example alice. Link to the NFT through tokenURI or https://agentid.prd.space.id/metadata/{handle}.json.
Last updated
