Skip to main content

teleport-sdk.teleportbridge.getamounts

Home > teleport-sdk > TeleportBridge > getAmounts

TeleportBridge.getAmounts() method

Calculate received token amounts on the target domain and fees to be paid both to the bridge and the relayer

Signature:
getAmounts(withdrawn: BigNumberish, isHighPriority?: boolean, relayAddress?: string): Promise<{
mintable: BigNumber;
bridgeFee: BigNumber;
relayFee?: BigNumber;
}>;

Parameters

ParameterTypeDescription
withdrawnBigNumberishamount of tokens to be taken from the user's address
isHighPriorityboolean(Optional) whether this teleportation is to be expedited
relayAddressstring(Optional) relayer's address
Returns:

Promise<{ mintable: BigNumber; bridgeFee: BigNumber; relayFee?: BigNumber; }>

Promise containing detailed amounts for both mintable amount and fees to be paid

Remarks

The fees will change depending on the source/target domain combination and whether expedited teleportation is indicated