Skip to main content
You can check whether an address is a contract or token, and fetch a verified contract’s ABI, by creating a BOTScan client with createExplorerClient.
Early release. This is published in @uzolabs/sdk 0.2.0 on npm and you can use it today. The API may change before 1.0, so pin the version.

What it does

BOTScan is BOT Chain’s block explorer. It runs Blockscout, which has a public JSON API. The explorer client wraps two of its endpoints and returns small, typed results: No API key is needed.

Why use it

  • Check before you call. Confirm a user-supplied address is a verified contract, or a token with the decimals you expect, before you send a transaction to it.
  • Load ABIs at runtime. For contracts the SDK doesn’t include, fetch the verified ABI instead of pasting it in by hand.
  • Clear errors. Network failures, HTTP errors and bad addresses all throw ExplorerError or InvalidAddressError with a message that says what to do.

createExplorerClient

Signature
677 | 968
required
Which BOTScan to query: 677 uses https://scan.botchain.ai/api/v2, 968 uses https://scan.bohr.life/api/v2. Any other value throws UnsupportedChainError.
The client is read-only and keeps no state, so you can create one per network and reuse it.

Example

explorer.ts
Output from a run on 2026-10-02:
Output

Limits

  • The client doesn’t retry or time out on its own. If BOTScan is slow, wrap calls in your own retry.
  • BOTScan’s rate limits aren’t documented. Cache results that don’t change, such as a verified ABI.
  • For anything else BOTScan offers, such as transaction history or logs, call its API directly. See Use the BOTScan API.

Next steps

getAddressInfo

Wallet, contract or token.

getContract

Verified ABI and proxy details.

getAddressInfo

Reference for the getAddressInfo method, which fetches details about an address from BOTScan.

getContract

Reference for the getContract method, which fetches a verified contract's details from BOTScan.
Last modified on October 2, 2026