LifiTradeAssetParams

data class LifiTradeAssetParams(val fromChain: String, val toChain: String, val fromToken: String, val toToken: String, val amount: String, val fromAddress: String? = null, val toAddress: String? = null, val routeIndex: Int? = null, val onProgress: LifiProgressHandler? = null)

Parameters for the high-level tradeAsset bridging method.

Constructors

Link copied to clipboard
constructor(fromChain: String, toChain: String, fromToken: String, toToken: String, amount: String, fromAddress: String? = null, toAddress: String? = null, routeIndex: Int? = null, onProgress: LifiProgressHandler? = null)

Properties

Link copied to clipboard

The amount that should be sent including all decimals.

Link copied to clipboard
val fromAddress: String? = null

The sending wallet address.

Link copied to clipboard

The sending chain. Can be the chain id or chain key (e.g. "8453").

Link copied to clipboard

The token that should be transferred. Can be the address or the symbol.

Link copied to clipboard

Optional callback that receives progress updates as the trade executes.

Link copied to clipboard
val routeIndex: Int? = null

The index of the route to execute from the routes response (defaults to 0).

Link copied to clipboard
val toAddress: String? = null

The receiving wallet address. If none is provided, the fromAddress will be used.

Link copied to clipboard

The receiving chain. Can be the chain id or chain key (e.g. "137").

Link copied to clipboard

The token that should be transferred to. Can be the address or the symbol.