# Quote a deposit order on any pool

`POST /dex/pools/{poolNft}/orders/deposit/check` · Lithos client API · Lithos Dex

Source: https://lithosprotocol.org/docs/api/check-ld-pool-deposit-order

The shares a deposit order offering `amountX` and `amountY` would get now, and the excess of the side the pool cannot match, which comes back. X is ERG for an ERG/token pool.

## Parameters

| Name | In | Type | Required | Description |

|---|---|---|---|---|

| `poolNft` | path | string | yes | The pool's NFT id, 64 hex characters |

## Request body

`LDPoolDepositRequest`, application/json.

- `amountX` (string, required)
- `amountY` (string, required)
- `executorFee` (string): nanoERG the filler keeps. Omitted, from lithosdex.orders.
- `maxMinerFee` (string): Most of the executor fee a broadcast fill may pay as a network fee. Below executorFee.

## Responses

### 200: The quote

`LDPoolDepositQuote`

- `poolNFT` (string, required)
- `shares` (string, required)
- `takenX` (string, required)
- `takenY` (string, required)
- `excessX` (string, required): Returned, since the pool cannot match it
- `excessY` (string, required)
- `shareOfSupply` (number · double, required)
- `provisionBoxValue` (string, required)
- `executorFee` (string, required)
- `maxMinerFee` (string, required)
- `totalErgRequired` (string, required): nanoERG the order box holds
- `tokensRequired` (LDTokenAmount[], required): Tokens the order box holds
  - `tokenId` (string, required)
  - `amount` (string, required): Raw token units. Decimal string.
- `ergReturned` (string, required)
- `networkFee` (string, required)

### 400: The request is malformed, or names a token the pool does not hold.

`ApiError`

- `error` (integer, required): Error code
- `reason` (string, required): Error message explaining the reason of the error
- `detail` (string, required): Detailed error description

### 404: No LithosDex pool with that NFT, or no live provision with that id.

`ApiError`

- `error` (integer, required): Error code
- `reason` (string, required): Error message explaining the reason of the error
- `detail` (string, required): Detailed error description

### 503: The pool index is still building, or the node could not be read. Retry.

`ApiError`

- `error` (integer, required): Error code
- `reason` (string, required): Error message explaining the reason of the error
- `detail` (string, required): Detailed error description

### default: Error

`ApiError`

- `error` (integer, required): Error code
- `reason` (string, required): Error message explaining the reason of the error
- `detail` (string, required): Detailed error description

## Example request

```bash
curl -X POST "http://localhost:9000/dex/pools/{poolNft}/orders/deposit/check" \
  -H "Content-Type: application/json" \
  -d '{ "amountX": "string", "amountY": "string", "executorFee": "string", "maxMinerFee": "string" }'
```

## Example response

```json
{
  "poolNFT": "string",
  "shares": "string",
  "takenX": "string",
  "takenY": "string",
  "excessX": "string",
  "excessY": "string",
  "shareOfSupply": 0,
  "provisionBoxValue": "string",
  "executorFee": "string",
  "maxMinerFee": "string",
  "totalErgRequired": "string",
  "tokensRequired": [
    {
      "tokenId": "86e272f770aa4ef48ad7e6d6dbe98b5069edd8383a403a8edb3ceed8a3d5cea3",
      "amount": "152000000"
    }
  ],
  "ergReturned": "string",
  "networkFee": "string"
}
```
