Skip to main content
POST
/
pools
/
{poolId}
/
add-tx
Zap-In — Generate transaction to add liquidity to a pool
curl --request POST \
  --url https://api.lpagent.io/open-api/v1/pools/{poolId}/add-tx \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "stratergy": "Spot",
  "owner": "<string>",
  "inputSOL": 123,
  "percentX": 0.5,
  "fromBinId": 123,
  "toBinId": 123,
  "amountX": 123,
  "amountY": 123,
  "slippage_bps": 500,
  "provider": "JUPITER_ULTRA",
  "mode": "zap-in"
}
'
{
  "status": "success",
  "data": {
    "lastValidBlockHeight": 123,
    "swapTxsWithJito": [
      "<string>"
    ],
    "addLiquidityTxsWithJito": [
      "<string>"
    ],
    "meta": {}
  }
}

Authorizations

x-api-key
string
header
required

API key for authentication

Path Parameters

poolId
string
required

The pool address

Body

application/json
stratergy
enum<string>
required

The distribution strategy to use

Available options:
Spot,
Curve,
BidAsk
owner
string
required

Owner wallet address

inputSOL
number

Amount of SOL to input

percentX
number

Percentage of capital to allocate to token X (0-1)

Required range: 0 <= x <= 1
fromBinId
integer

Starting bin ID for liquidity distribution

toBinId
integer

Ending bin ID for liquidity distribution

amountX
number

Specific amount of token X (alternative to percentX)

amountY
number

Specific amount of token Y (required with amountX)

slippage_bps
integer
default:500

Slippage tolerance in basis points (e.g., 500 = 5%)

Required range: 0 <= x <= 10000
provider
enum<string>
default:JUPITER_ULTRA

Swap provider to use for token swaps

Available options:
OKX,
JUPITER_ULTRA
mode
enum<string>
default:zap-in

Add liquidity mode

Available options:
normal,
zap-in

Response

Successfully generated zap-in transactions

status
string
Example:

"success"

data
object