Skip to main content
POST
Build the unsigned open-leverage transaction

Authorizations

Authorization
string
header
required

Partner API key: Authorization: Bearer <key>.

Body

application/json
strategyId
string
required

Morpho market id (from /v1/strategies).

payToken
string
required

Token to pay in. Collateral (direct) or any token (zapped). ETH = zero address.

amount
string
required

Amount of payToken in human units, e.g. '10000'.

userAddress
string
required

Wallet that will sign; approvals + onBehalfOf are built for it.

leverage
number

Target leverage (e.g. 3). Provide this OR desiredLtv.

desiredLtv
string

Target LTV percent (e.g. '66.67'). Provide this OR leverage.

slippage
number

Ratio, default 0.005, capped at 0.01.

chainId
enum<integer>
Available options:
1,
4663

Response

Unsigned tx bundle

Unsigned transaction bundle. Non-custodial: sign approvals[] first, then tx, from userAddress.

chainId
integer
required
action
string
required
Example:

"open_leverage"

path
enum<string>
required
Available options:
leverage,
swapAndLeverage,
reallocateAndLeverage,
reallocateSwapAndLeverage,
deleverage,
increaseLeverage,
supplyCollateral,
swapAndSupplyCollateral,
repay,
swapAndRepay,
withdrawCollateral,
borrow
approvals
object[]
required
tx
object
required
meta
object
required