Skip to main content

Max open range (with body)

POST 

/v1/data/lending/range

Compute the maximum amount that can be opened in a leverage position.

Single-pair mode (provide marketUidIn + marketUidOut): returns the max open amount for one specific pair.

Multi-pair mode (provide lender + chainId): returns the max open amount for all leverage pairs of a lender, optionally filtered by marketUidIn / marketUidOut.

GET fetches user balances on-chain (requires account). POST accepts a SimulationBody in the request body.

POST accepts a JSON body with the user's current portfolio state, avoiding an on-chain fetch.

Request

Responses

Max open range for one or more leverage pairs