Nubit
Nubit
  • Overview
    • Introduction
  • BitVM
    • BitVM IDE
    • Learn More
  • Modular Indexer
    • Introduction
    • Developer Guide
      • API Documentation
        • Modular Indexer API
        • Light Client API
      • Wallet Integration Guide
    • Learn More
  • External resources
    • Github
    • Linktree
    • X (Twitter)
    • Telegram
    • Discord
Powered by GitBook
On this page
  1. Modular Indexer
  2. Developer Guide
  3. API Documentation

Modular Indexer API

Streamlined interfaces for querying balances, verifying transactions, and accessing brc-20 data efficiently.

PreviousAPI DocumentationNextLight Client API

Last updated 11 months ago

Note: We are in the Alpha Testnet stage, so the API may undergo incompatible changes in the future. If you encounter any issues, please join our to get in touch with the Nubit Team.


Discord

brc20_verifiable_block_height

get

Get the latest synced block height of the brc20 indexer.

Responses
200
Success
*/*
Responseobject
get
GET /v1/brc20_verifiable/block_height HTTP/1.1
Host: 
Accept: */*
200

Success

800000

brc20_verifiable_latest_state_proof

get

Get the state difference, proof, and the transactions between the last block height and the current one.

Responses
200
Success
application/json
500
Failed
application/json
get
GET /v1/brc20_verifiable/latest_state_proof HTTP/1.1
Host: 
Accept: */*
{
  "error": null,
  "result": {
    "ordTransfers": [
      {
        "ID": 1,
        "inscriptionID": "text",
        "newSatpoint": "text",
        "newPkscript": "text",
        "newWallet": "text",
        "sentAsFee": true,
        "content": "text",
        "contentType": "text"
      }
    ],
    "stateDiff": [
      "text"
    ]
  },
  "proof": "text"
}
  • GETbrc20_verifiable_current_balance_of_wallet
  • GETbrc20_verifiable_current_balance_of_pkscript
  • GETbrc20_verifiable_block_height
  • GETbrc20_verifiable_latest_state_proof

brc20_verifiable_current_balance_of_wallet

get

Get the latest balance of the wallet on its latest pkscript.

Query parameters
tickstringOptional
walletstringOptional
Body
objectOptional
Responses
200
Success
application/json
500
Failed
application/json
get
GET /v1/brc20_verifiable/current_balance_of_wallet HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 2

{}
{
  "error": null,
  "result": {
    "availableBalance": "text",
    "overallBalance": "text",
    "pkscript": "text"
  },
  "proof": "text"
}

brc20_verifiable_current_balance_of_pkscript

get

Get the latest balance of the wallet on its latest pkscript.

Query parameters
tickstringOptional
pkscriptstringOptional
Body
objectOptional
Responses
200
Success
application/json
500
Failed
application/json
get
GET /v1/brc20_verifiable/current_balance_of_pkscript HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 2

{}
{
  "error": null,
  "result": {
    "availableBalance": "text",
    "overallBalance": "text",
    "pkscript": "text"
  },
  "proof": "text"
}