jediswap_v2_swap_router
Last updated
Last updated
Router for stateless execution of swaps against JediSwap V2
Swaps amount_in
of one token for as much as possible of another token
Parameters:
Name | Type | Description |
---|---|---|
Return Values:
Type | Description |
---|---|
Swaps amount_in
of one token for as much as possible of another along the specified path
Parameters:
Name | Type | Description |
---|---|---|
Return Values:
Type | Description |
---|---|
Swaps as little as possible of one token for amount_out
of another token
Parameters:
Return Values:
Swaps as little as possible of one token for amount_out
of another along the specified path (reversed)
path array will be in format [token_out, token_in, fee] if used for single hop (recommend using exact_output_single)
for multihop going from token_in to token_out via token_mid, path will be [token_out, token_mid, fee_out_mid, token_mid, token_in, fee_mid_in]
Parameters:
Return Values:
Parameters:
Name | Type | Description |
---|---|---|
Type | Description |
---|---|
Name | Type | Description |
---|---|---|
Type | Description |
---|---|
Name | Type | Description |
---|---|---|
params
ExactInputSingleParams
The parameters necessary for the swap
u256
The amount of the received token
params
ExactInputParams
The parameters necessary for the multi-hop swap
u256
The amount of the received token
params
ExactOutputSingleParams
The parameters necessary for the swap
u256
The amount of the input token
params
ExactOutputParams
The parameters necessary for the multi-hop swap
u256
The amount of the input token
amount0_delta
i256
amount1_delta
i256
callback_data_span
Span<felt252>