VeloraSwapTransaction

Documentation for eth_defi.velora.swap.VeloraSwapTransaction Python class.

class VeloraSwapTransaction

Bases: object

Velora swap transaction data.

Contains all information needed to execute a swap on Augustus Swapper.

Attributes summary

buy_token

Token we are going to receive (token out)

sell_token

Token we are losing (token in)

amount_in

Amount of sell_token to spend (human-readable decimals)

min_amount_out

Minimum amount of buy_token to receive (human-readable decimals)

to

Augustus Swapper contract address

calldata

Raw calldata to execute on Augustus Swapper

value

ETH value to send (usually 0 for ERC-20 swaps)

price_route

Original price route from quote (for reference)

Methods summary

__init__(buy_token, sell_token, amount_in, ...)

buy_token: eth_defi.token.TokenDetails

Token we are going to receive (token out)

sell_token: eth_defi.token.TokenDetails

Token we are losing (token in)

amount_in: decimal.Decimal

Amount of sell_token to spend (human-readable decimals)

min_amount_out: decimal.Decimal

Minimum amount of buy_token to receive (human-readable decimals)

to: eth_typing.evm.HexAddress

Augustus Swapper contract address

calldata: hexbytes.main.HexBytes

Raw calldata to execute on Augustus Swapper

value: int

ETH value to send (usually 0 for ERC-20 swaps)

price_route: dict

Original price route from quote (for reference)

__init__(buy_token, sell_token, amount_in, min_amount_out, to, calldata, value, price_route)
Parameters
Return type

None