Constructs a new UniswapExchangeRateTask.
Optional
properties: IUniswapExchangeRateTaskProperties to set
UniswapExchangeRateTask factoryAddress.
The input token address.
The amount of tokens to swap.
The output token address.
The RPC provider to use for the swap.
UniswapExchangeRateTask quoterAddress.
UniswapExchangeRateTask routerAddress.
The allowable slippage in percent for the swap.
The version of the Uniswap exchange to use.
Static
createCreates a new UniswapExchangeRateTask instance using the specified properties.
Optional
properties: IUniswapExchangeRateTaskProperties to set
UniswapExchangeRateTask instance
Static
decodeDecodes an UniswapExchangeRateTask message from the specified reader or buffer.
Reader or buffer to decode from
Optional
length: numberMessage length if known beforehand
UniswapExchangeRateTask
If the payload is not a reader or valid buffer
If required fields are missing
Static
decodeDecodes an UniswapExchangeRateTask message from the specified reader or buffer, length delimited.
Reader or buffer to decode from
UniswapExchangeRateTask
If the payload is not a reader or valid buffer
If required fields are missing
Static
encodeEncodes the specified UniswapExchangeRateTask message. Does not implicitly verify messages.
UniswapExchangeRateTask message or plain object to encode
Optional
writer: WriterWriter to encode to
Writer
Static
encodeEncodes the specified UniswapExchangeRateTask message, length delimited. Does not implicitly verify messages.
UniswapExchangeRateTask message or plain object to encode
Optional
writer: WriterWriter to encode to
Writer
Static
fromCreates an UniswapExchangeRateTask message from a plain object. Also converts values to their respective internal types.
Plain object
UniswapExchangeRateTask
Static
getStatic
toCreates a plain object from an UniswapExchangeRateTask message. Also converts values to other types if specified.
UniswapExchangeRateTask
Optional
options: IConversionOptionsConversion options
Plain object
Static
verify
Fetch the swap price from UniSwap.