LithosDocs
ProtocolPayoutsTokenStatsDocs
Start mining
Documentation home
Protocol
  • Lithos Protocol
  • LFSM
    • Rollups
    • NISPs
    • Emissions
    • Mining on Lithos
    • Candidate building
    • Ergo Voting
  • LithosDex
    • Trading with orders
    • Providing liquidity
Run Lithos
  • Startup guide
    • Setting up an Ergo testnet node
  • Configuration
    • Node connection and security
    • Stratum and difficulty
    • Block packages
    • Batching and orders
    • Collateral and emission
    • Wallet and consolidation
    • Statistics and web panels
    • Synchronization and storage
    • Tasks and dispatchers
    • Failure modes
    • Reporting issues
Client API
  • Overview
    • getLithos client information
    • getList UTXO ids for blocks
    • getUTXO ids by block height
    • getBlock info by UTXO id
    • postBlock info for multiple UTXO ids
    • getGet a block's miner set
    • getList all pool blocks
    • getGet Lithos payouts
    • getStatistics overview
    • getMining and payment totals
    • getMining statistics by hour or day
    • getEstimate Lithos hashrate
    • getNetwork difficulty by epoch
    • getThis client's own hashrate
    • getThis client's hashrate over time
    • getThis client's payouts and claims
    • getCollateral inventory
    • getLocal mining activity
    • getCollateral market snapshot
    • getList queue boxes
    • getList the active set
    • getPermit price history
    • getYour locked block rewards
    • postClaim unlocked block rewards
    • postQuote joining the queue
    • postJoin the collateral queue
    • getLithosDex pool state
    • getLithosDex fee vault state
    • getList your outstanding orders
    • postQuote a swap order
    • postPlace a swap order
    • postQuote a deposit order
    • postPlace a deposit order
    • postQuote a redeem order
    • postPlace a redeem order
    • postCancel an order
    • postQuote a swap
    • postQuote a swap by desired output
    • postExecute a swap
    • postQuote a liquidity deposit
    • postDeposit liquidity
    • postQuote a liquidity redemption
    • postRedeem liquidity
    • getList liquidity provisions
    • postClaim settled fees for a provision
    • postQuote a provision resize
    • postResize a provision
    • postCheck a pending fee flush
    • postFlush pending fees to the vault
    • getPool-wide fee history
    • getPool price history
    • getRecent pool activity
    • getFee history for one provision
    • getWallet balances and lending status
    • getGet Stratum information
    • getGet candidate settings
    • getGet difficulty commitment
    • postCommit a difficulty
    • getGet best NISP at height
Lithos

A decentralized mining pool protocol on Ergo. Miners build their own blocks; contracts pay them for proven work.

Live on Ergo mainnet
Protocol
  • How Lithos works
  • Mining on Lithos
  • NISPs
  • Emissions
  • LFSM contracts
Run Lithos
  • Startup guide
  • Configuration
  • LithosDex
  • Client API
  • Failure modes
Network
  • Live stats
  • Public stats API
  • Ergo Platform↗
  • SOAT Miner↗
Community
  • Telegram↗
  • X / Twitter↗
  • GitHub↗
Lithos
© 2026 Lithos Protocol. Open source under the MIT licence.λίθος — stone
Docs/Client API/Lithos Dex

LithosDex pool state

get/dex/pool

Current state of the LithosDex pool. reservesX / reservesY are tradable; pendingX / pendingY are fees awaiting a flush.

Responses

200Current pool stateLDPoolInfo▶
  • poolNFTstringrequired

    Token id of the pool NFT

  • utxoIdstringrequired

    Pool box id. Send back as expectedPoolBoxId when executing.

  • tokenYstringrequired

    Token id of the pool's token side

  • tokenNamestring

    Display name of the pool's token, when known

  • tokenDecimalsinteger · int32

    Decimal places implied by raw token amounts

  • reservesXstringrequired

    nanoERG the AMM trades with — box value less pendingX. Decimal string.

  • reservesYstringrequired

    Raw token units the AMM trades with — token balance less pendingY. Decimal string.

  • pendingXstringrequired

    nanoERG fees accrued but not yet flushed to the vault. Decimal string.

  • pendingYstringrequired

    Token-side fees accrued but not yet flushed. Decimal string.

  • supplystringrequired

    LP shares outstanding. Decimal string.

  • ▶
    feeParamsLDFeeParamsrequired

    Fee numerators over feeDenom. dexFeeNum stays in the pool; ergFeeNum / tokenFeeNum are set aside for liquidity providers.

    • dexFeeNuminteger · int64required
    • ergFeeNuminteger · int64required
    • tokenFeeNuminteger · int64required
    • feeDenominteger · int64required

      Denominator of every numerator above

  • accXstringrequired

    Cumulative ERG fee per share, scaled by 1e27. Decimal string — this value exceeds the exact range of a double and must not be parsed as a JSON number.

  • accYstringrequired

    Cumulative token fee per share, same 1e27 scale. Decimal string.

  • provTokensLeftstringrequired

    Provision tokens left in the pool; one is used per deposit. Decimal string.

  • canFlushbooleanrequired

    Whether any fees are pending. A flush needs something to move.

  • canDepositbooleanrequired

    Whether a provision token remains to hand out

  • syncHeightinteger · int32required

    Block height this snapshot was taken at

404No pool box found on this network.ApiError▶
  • errorintegerrequired

    Error code

  • reasonstringrequired

    Error message explaining the reason of the error

  • detailstringrequirednullable

    Detailed error description

503Node unavailable. Retry.ApiError▶
  • errorintegerrequired

    Error code

  • reasonstringrequired

    Error message explaining the reason of the error

  • detailstringrequirednullable

    Detailed error description

defaultErrorApiError▶
  • errorintegerrequired

    Error code

  • reasonstringrequired

    Error message explaining the reason of the error

  • detailstringrequirednullable

    Detailed error description

← PreviousJoin the collateral queueNext →LithosDex fee vault state
Request
curl -X GET "http://localhost:9000/dex/pool"
Response
{
  "poolNFT": "720933ab10ef28eafd96a4e41f783c12b444ed81d6a08879f583266031c04dbd",
  "utxoId": "a1f4c2e8b7d93052416fbc8e07d21935a8c4f60b2e91d7385c06a4b1f2e83d97",
  "tokenY": "86e272f770aa4ef48ad7e6d6dbe98b5069edd8383a403a8edb3ceed8a3d5cea3",
  "tokenName": "LIT",
  "tokenDecimals": 4,
  "reservesX": "4250000000000",
  "reservesY": "128400000000",
  "pendingX": "3180000000",
  "pendingY": "96400000",
  "supply": "1000000000000",
  "feeParams": {
    "dexFeeNum": 9985,
    "ergFeeNum": 15,
    "tokenFeeNum": 15,
    "feeDenom": 10000
  },
  "accX": "41820000000000000000000000",
  "accY": "1264000000000000000000000",
  "provTokensLeft": "999999999999997",
  "canFlush": true,
  "canDeposit": true,
  "syncHeight": 1312460
}