Last updated
Last updated
We are currently updating the repository with more examples, so please hold on.
1.1 .Initialising The SDK
NOTE : SIGNER CAN BE A APTOS ACCOUNT INSTANCE DERIVED FROM PRIVATE KEY OR A SIGN AND SUBMIT FUNCTION FROM APTOS WALLET ADAPTER
1.2 .Getting Swap Quotes
Please note that the feature of switching fee from output token to input token is only available in aptos chain only
1.3 .Executing Swap Quotes
2.1 .Initialising The SDK```typescript
2.2 .Getting Swap Quotes
2.3 .Executing Swap Quotes
3.1 .Initialising The SDK```typescript
3.2 .Getting Swap Quotes
3.3 .Executing Swap Quotes
4.1 .Initialising The SDK
4.2 .Getting Swap Quotes
4.3 .Executing Swap Quotes
If you wish to execute the transaction using your own logic that fits your use case, please refer to our repository on Github
SameChainSwapParams
Description
inputToken
The input token for the swap operation.
outputToken
The output token to receive after the swap.
amountIn
The amount of input tokens to be swapped.
slippage
The allowed slippage percentage for the swap.
network
The network ID for the swap operation.
options
(Optional) Additional options for the swap.
executeSwapInstruction
Description
quote
A CommonRouteInterface
representing the quote response format.
address
The address related to the instruction.
options
(Optional) An object containing additional options.
options.provider
(Optional) The connection provider to use.
options.integrator
(Optional) A string identifying the integrator.