> ## Documentation Index
> Fetch the complete documentation index at: https://docs.gomaestro.org/llms.txt
> Use this file to discover all available pages before exploring further.

> Get Bitcoin address statistics with mempool awareness including balance, transaction count, and activity metrics.

# Address Statistics (Mempool-aware)



## OpenAPI

````yaml bitcoin/wallet-api/openapi.json get /wallet/addresses/{address}/statistics
openapi: 3.0.3
info:
  title: Bitcoin - Wallet API
  description: >-
    Maestro's Bitcoin Wallet API delivers detailed transaction activity data at
    the address level, spanning native Bitcoin (satoshis) and metaprotocol
    layers like inscriptions and runes. This API enables deep visibility into
    balance changes, token movements, and asset-specific behaviors. Useful for
    powering explorers, wallets, or dashboards with granular insight into
    address-level history and asset interactions.


    #### Key Features:

    - **Satoshi Activity Tracking:** Track and analyze satoshi-level balance
    changes—including increases, decreases, and self-transfers—with timestamped
    precision. Historical balances are itemized by either block height or
    timestamp, enabling accurate auditing, time-based analysis, and
    USD-denominated valuation over time.

    - **Inscription Insight:** Monitor Ordinals transactions, filtered by
    inscription ID, activity type (send/receive), or self-transfer logic to
    reduce noise from spam or internal moves.

    - **Rune Transaction Logging:** Track rune minting, transfers, etchings, and
    balance changes for a given address, including support for filtering by
    specific rune.

    - **Unified Metaprotocol View:** Fetch combined activity across satoshis,
    inscriptions, and runes in a single request to power holistic user or
    address histories.

    - **Mempool Awareness:** Provides insight into the latest activity from the
    mempool by _default_. The system monitors for block reorganizations and
    automatically rolls back unconfirmed or invalidated trades, ensuring the
    data reflects the confirmed state of the chain.


    #### Key Benefits for Developers: 

    Developers gain the ability to surface address-level insights without having
    to manually parse raw blockchain data. The Wallet API simplifies historical
    activity analysis, enables protocol-specific filtering, and lets developers
    build UX-enhancing features like transaction history views, asset trackers,
    and real-time alerts for wallet activity without managing indexing
    infrastructure.
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0.txt
  version: v0.2.0
servers:
  - url: https://xbt-mainnet.gomaestro-api.org/v0
    description: Bitcoin Mainnet
  - url: https://xbt-testnet.gomaestro-api.org/v0
    description: Bitcoin Testnet
security:
  - api-key: []
paths:
  /wallet/addresses/{address}/statistics:
    get:
      tags:
        - Addresses
      summary: Address Statistics (Mempool-aware)
      description: >-
        Returns all current statistics of the address: total txs the address was
        involved in, total unspent outputs controlled by the address, current
        satoshi, control of any runes and inscription balance, distinguishing
        between confirmed and pending (still in the mempool) data.
      operationId: wallet_address_statistics
      parameters:
        - name: address
          in: path
          description: Bitcoin address or hex encoded script pubkey
          required: true
          schema:
            type: string
          example: bc1qcx7ys0ahvtfqcc63sfn6axls0qrhkadnslpd94
      responses:
        '200':
          description: Requested data
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MempoolWalletTimestampedAddressStatistics'
              example:
                data:
                  pending:
                    inputs: 1
                    outputs: 1
                    sat_balance: '0'
                    sat_in_inputs: 89692768
                    sat_in_outputs: 89582068
                    txs: 1
                    usd_balance: '0.00'
                    utxos: 0
                  runes: false
                  sat_balance: '0'
                  total_inputs: 6
                  total_inscriptions: 0
                  total_outputs: 6
                  total_sat_in_inputs: 540481308
                  total_sat_in_outputs: 539817108
                  total_txs: 6
                  total_utxos: 0
                  usd_balance: '0.00'
                indexer_info:
                  chain_tip:
                    block_hash: >-
                      000000000000000000019f3ff6e0e9b59a5f13e9514c21c8912c92d7592de88c
                    block_height: 903987
                  estimated_blocks:
                    - block_height: 903988
                      sats_per_vb:
                        max: 120
                        median: 1
                        min: 1
                  mempool_timestamp: '2025-07-04 15:26:13'
        '400':
          description: Malformed query parameters
        '404':
          description: Requested entity not found on-chain
        '500':
          description: Internal server error
components:
  schemas:
    MempoolWalletTimestampedAddressStatistics:
      type: object
      required:
        - data
        - indexer_info
      properties:
        data:
          $ref: '#/components/schemas/WalletAddressStatistics'
        indexer_info:
          $ref: '#/components/schemas/MempoolLastUpdated'
    WalletAddressStatistics:
      type: object
      required:
        - total_txs
        - total_inputs
        - total_sat_in_inputs
        - total_outputs
        - total_sat_in_outputs
        - total_utxos
        - runes
        - total_inscriptions
        - sat_balance
        - usd_balance
        - pending
      properties:
        pending:
          $ref: '#/components/schemas/PendingAddressStatistics'
        runes:
          type: boolean
          description: Existence of runes controlled by the address.
        sat_balance:
          type: string
          description: >-
            Current confirmed sat balance (sat in unspent outputs) controlled by
            the address.
        total_inputs:
          type: integer
          format: int64
          description: >-
            Total number of confirmed inputs (i.e., number of all confirmed
            spending of outputs).
          minimum: 0
        total_inscriptions:
          type: integer
          format: int64
          description: Total number of inscriptions currently controlled by the address.
          minimum: 0
        total_outputs:
          type: integer
          format: int64
          description: Total number of confirmed spent or unspent outputs.
          minimum: 0
        total_sat_in_inputs:
          type: integer
          description: Total number of sats in confirmed inputs.
          minimum: 0
        total_sat_in_outputs:
          type: integer
          description: Total number of sats in confirmed spent or unspent outputs.
          minimum: 0
        total_txs:
          type: integer
          format: int64
          description: >-
            Total number of confirmed transactions where the address controlled
            at least an input or an output.
          minimum: 0
        total_utxos:
          type: integer
          format: int64
          description: Total number of confirmed unspent outputs.
          minimum: 0
        usd_balance:
          type: string
          description: >-
            Confirmed USD balance if sat balance was exchanged. The exchange
            rate is that between USD and BTC at the time the block at the tip of
            the chain was mined.
    MempoolLastUpdated:
      type: object
      required:
        - chain_tip
        - estimated_blocks
      properties:
        chain_tip:
          $ref: '#/components/schemas/ChainTip'
        estimated_blocks:
          type: array
          items:
            $ref: '#/components/schemas/EstimatedBlock'
          description: >-
            Information about any estimated blocks from the mempool that were
            indexed in addition to the mainchain
        mempool_timestamp:
          type: string
          description: >-
            Timestamp of the indexed mempool snapshot, if any estimated blocks
            from the mempool have been indexed
          nullable: true
    PendingAddressStatistics:
      type: object
      required:
        - txs
        - inputs
        - sat_in_inputs
        - outputs
        - sat_in_outputs
        - utxos
        - sat_balance
        - usd_balance
      properties:
        inputs:
          type: integer
          format: int64
          description: Estimated number of outputs spent in the mempool.
          minimum: 0
        outputs:
          type: integer
          format: int64
          description: Estimated number of new outputs (spent or unspent) in the mempool.
          minimum: 0
        sat_balance:
          type: string
          description: Estimated sat balance difference between mempool and confirmed data.
        sat_in_inputs:
          type: integer
          description: Estimated number of sats in outputs spent in the mempool.
          minimum: 0
        sat_in_outputs:
          type: integer
          description: >-
            Estimated number of sats in new outputs (spent or unspent) in the
            mempool.
          minimum: 0
        txs:
          type: integer
          format: int64
          description: >-
            Estimated number of new txs in the mempool where the address
            controls at least an input or an output.
          minimum: 0
        usd_balance:
          type: string
          description: >-
            Estimated USD balance difference between mempool and confirmed data,
            if sat balance was exchanged. The exchange rate is that between USD
            and BTC at the time the block at the tip of the chain was mined.
        utxos:
          type: integer
          format: int64
          description: Estimated number of new unspent outputs in the mempool.
    ChainTip:
      type: object
      required:
        - block_hash
        - block_height
      properties:
        block_hash:
          type: string
          description: The hash of the block
          example: 0000000000000000000a7f3b7b6b6e1d9a18db65a3b4a3f4f3bcb2e1f1b2d3e7
        block_height:
          type: integer
          format: int64
          description: The height of the block in the blockchain
          example: 707000
          minimum: 0
    EstimatedBlock:
      type: object
      required:
        - block_height
        - sats_per_vb
      properties:
        block_height:
          type: integer
          format: int64
          description: Height of the estimated block
          example: '707001'
          minimum: 0
        sats_per_vb:
          $ref: '#/components/schemas/BlockSatsPerVb'
    BlockSatsPerVb:
      type: object
      description: >-
        For transactions within a block, these are the lowest, median and
        highest

        satoshis per virtual-byte values.
      required:
        - min
        - median
        - max
      properties:
        max:
          type: integer
          format: int64
          description: Highest sat/vB value of the transactions within the block
          example: 255
          minimum: 0
        median:
          type: integer
          format: int64
          description: Median sat/vB value of the transactions within the block
          example: 15
          minimum: 0
        min:
          type: integer
          format: int64
          description: Lowest sat/vB value of the transactions within the block
          example: 11
          minimum: 0
  securitySchemes:
    api-key:
      type: apiKey
      in: header
      name: api-key
      description: Project API Key

````