v1

latestOpenAPI 3.0.02026-08-0451764.0 KB
Deposit

Deposit assets into liquidity pool

This endpoint allows users to deposit assets into a liquidity pool by submitting the required details, such as the pool contract address and the amount of assets to be deposited. This process is crucial for users who want to increase the liquidity of the pool and potentially earn rewards or fees. Use this endpoint to securely and efficiently add assets to the pool, contributing to the stability and performance of the ecosystem.

post/rfq/v2/deposit

Request body

senderstring required

The address of the user initiating the deposit transaction.

pool_addressstring required

The address of the pool

days_to_lockinteger

Number of days to lock the deposit in the liquidity pool. Required for all pools except Katana, which uses lock_time instead.

lock_timeinteger

Number of minutes to lock the deposit in the liquidity pool. Only supported by the Katana pool. For other pools, use days_to_lock.

depositobject

An object containing the asset address and the amount to deposit as a string. The amount should be in its machine-readable form. This parameter is required only if single_asset is false.

chain_idinteger required

The unique identifier of the blockchain network where the deposit will be made.

output_pool_tokensinteger

The total number of pool tokens the user wants to receive. It is only valid for single-asset deposits.

single_assetboolean

A boolean that indicates whether only one asset is being deposited.

single_tokenstring

Required only when single_asset is true. This represents the address of the single asset being deposited.

Example request

{
  "sender": "0x960376b3F62f41E7e66809a05D1C5afdFD60A0E9",
  "pool_address": "0x989E8F547FbCa65f4FB0af41e50e4058e6c68166",
  "days_to_lock": 5,
  "lock_time": 5,
  "deposit": {
    "0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599": "400000000",
    "0x6B175474E89094C44Da98b954EedeAC495271d0F": "2000000000000000000",
    "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2": "1000000000000000000",
    "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48": "2000000"
  },
  "chain_id": 1,
  "output_pool_tokens": 10000,
  "single_asset": true,
  "single_token": "0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599"
}

Response

Deposit processed successfully

senderstring required

The address of the user who initiated the deposit transaction.

n_daysinteger

The number of days the assets will be locked in the pool, matching the days_to_lock from the request. Supported for all pools except Katana. For katana, returns lock_time.

lock_timeinteger

The number of minutes the assets will be locked in the pool, matching the lock_time from the request. Only supported by the Katana pool. For other pools, returns n_days.

good_untilinteger required

The timestamp indicating how long the deposit details, including the signature, are valid.

pool_tokensstring required

The total number of pool tokens that will be given to the user as a result of the deposit.

clipper_exchange_addressstring required

The address of the Blade exchange contract where the deposit is being made.

deposit_amountsstring[]

A list of the amounts to be deposited for each asset. If an asset was not provided in the request, the amount returned will be 0. For example, if 3 assets were provided in a 4-asset pool, the response will include an amount of 0 for the missing asset. For single asset deposit this field is not present

amountstring

(Single-asset deposits only) The total amount of the single asset that is being deposited into the pool.

tokenstring

(Single-asset deposits only) The address of the token that is being deposited into the pool.

extra_datastring

Encode LP token price and prices list into ABI-compatible bytes. Only supported by the Katana pool.