Optional
receiver: stringOptional
in?: SymbiosisTradeTypeOptional
out?: SymbiosisTradeTypeReadonly
bridgeContains bridge provider's type used in route.
Readonly
feeSwap fee information.
Readonly
fromToken to sell with input amount.
Readonly
gasGas fee info in source blockchain.
Readonly
isTrue, if provider is aggregator.
Readonly
onContains on-chain providers' type used in route.
Readonly
priceOverall price impact, fetched from symbiosis api.
Readonly
toToken to get with output amount.
Readonly
toMinimum amount of output token user will get in Eth units.
Readonly
typeType of calculated cross-chain trade.
Gets gas fee in source blockchain.
Sends approve transaction with connected wallet.
Transaction options.
If true, first allowance is checked.
Builds transaction config, with encoded data.
Encode transaction options.
Build encoded approve transaction config.
Encoded approve transaction config.
Address of the smart-contract corresponding to the token.
Wallet or contract address to approve.
Token amount to approve in wei.
Additional options.
Sends swap transaction with connected wallet. If user has not enough allowance, then approve transaction will be called first.
const onConfirm = (hash: string) => console.log(hash);
const receipt = await trade.swap({ onConfirm });
Transaction options.
Generated using TypeDoc
Calculated Symbiosis cross-chain trade.