Router architecture
MarginlyRouter
constructor
swapExactInput
swap with exact input
Parameters
swapCalldata
uint256
calldata for multiple swaps
tokenIn
address
address of a token to swap on dex
tokenOut
address
address of a token to receive from dex
amountIn
uint256
exact amount of tokenIn to swap
minAmountOut
uint256
minimal amount of tokenOut to receive
swapExactOutput
swap with exact output
Parameters
swapCalldata
uint256
calldata for multiple swaps
tokenIn
address
address of a token to swap on dex
tokenOut
address
address of a token to receive from dex
maxAmountIn
uint256
maximal amount of tokenIn to swap
amountOut
uint256
exact amount of tokenOut to receive
RouterActions
addDexAdapters
add dex adapters to router
Parameters
_adapters
struct AdapterInput[]
input to MarginlyRouter addDexAdapters
call
transferMarginlyRouterOwnership
Set a new owner of a Marginly router contract. Allowed only for MarginlyPoolAdmin owner
Parameters
to
address
Address of a new Marginly router owner
acceptMarginlyRouterOwnership
Accepts Marginly router contract ownership
Last updated