πŸ‹Pool Information

This guide explains how to fetch pool data from the Dozer Pool Manager using the public Hathor Node API.

Contract IDs

  • Mainnet: 000080350ca5ef204bc29b3232bb197e12bec6b473f5e6bdb749a6921197e83c

  • Testnet: 00000eecf6a990576c12bfa9e12ee089a5b1ea65e6de1456687ba1f4dc7fd463


1. List All Pools

Get a list of all active pool keys in the contract.

Method: get_all_pools() Returns: List of strings (Pool Keys) Pool Key Format: TOKEN_A_UID/TOKEN_B_UID/FEE_INT

Example Request

curl -s -G "https://node1.mainnet.hathor.network/v1a/nano_contract/state" \
  --data-urlencode "id=000080350ca5ef204bc29b3232bb197e12bec6b473f5e6bdb749a6921197e83c" \
  --data-urlencode "calls[]=get_all_pools()" \
  | jq

Response

{
  "success": true,
  "calls": {
    "get_all_pools()": {
      "return": [
        "00000000.../00002b66.../50",
        "00000000.../0000abcd.../30"
      ]
    }
  }
}

2. Get Pool Details

Get detailed statistics and state for a specific pool.

Method: front_end_api_pool(pool_key) Args: pool_key (string) - The unique identifier from get_all_pools()

Example Request

Fetch details for a specific pool (replace POOL_KEY with actual key).

Response Structure

The response returns a PoolApiInfo object.

Note: All Amounts are integers. You typically need to apply token decimals (usually 2 or 8) to get human-readable values.

Last updated