Router
Movemement testnet is unstable by the time of writing and using the contracts below are for testing and development purposes only
Contract Info
Contract Name:
yuzu::router
Contract Address: [tba]
Admin Multi Sig: [tba]
Public Functions
Create Pair
Creates a new liquidity pair for tokens X and Y. Reverts if the pair already exists.
sender
signer
The sender's signer.
Register Fee On Transfer in Pair
Adds fee-on-transfer functionality to a token pair (only callable by token owners).
sender
signer
The sender's signer.
Stake Tokens in Pool
Deposit tokens into the staking pool for a liquidity pair.
sender
signer
The sender's signer.
amount
u64
The amount of tokens to stake.
Unstake Tokens from Pool
Withdraw tokens from the staking pool for a liquidity pair.
sender
signer
The sender's signer.
amount
u64
The amount of tokens to withdraw.
Claim Rewards from Pool
Claim staking rewards from the rewards pool.
sender
signer
The sender's signer.
Add Liquidity
Add liquidity to a pair or create the pair if it doesn't exist.
sender
signer
The sender's signer.
amount_x_desired
u64
The amount of token X desired.
amount_y_desired
u64
The amount of token Y desired.
amount_x_min
u64
The minimum amount of token X to add.
amount_y_min
u64
The minimum amount of token Y to add.
Remove Liquidity
Remove liquidity from a pair.
sender
signer
The sender's signer.
liquidity
u64
The amount of liquidity to remove.
amount_x_min
u64
The minimum amount of token X to receive.
amount_y_min
u64
The minimum amount of token Y to receive.
Swap Exact Input
Swap an exact input amount of token X for the maximum possible amount of token Y.
sender
signer
The sender's signer.
x_in
u64
The exact amount of token X to swap.
y_min_out
u64
The minimum amount of token Y to receive.
Swap Exact Output
Swap the minimum possible amount of token X to receive an exact output amount of token Y.
sender
signer
The sender's signer.
y_out
u64
The exact amount of token Y to receive.
x_max_in
u64
The maximum amount of token X to swap.
Multi-Hop Exact Input
Swap token X for token Y through an intermediate token Z.
sender
signer
The sender's signer.
x_in
u64
The exact amount of token X to swap.
y_min_out
u64
The minimum amount of token Y to receive.
Register LP
Register the LP token for a pair to the sender's account.
sender
signer
The sender's signer.
Update Fee Tier
Update the fee tier for a liquidity pair.
signer_ref
signer
The sender's signer.
Last updated