Cross Chain Swap
Last updated
Last updated
This section explains the integration and usage of bridge protocols for cross-chain swapping functionalities.
To initiate a swap, first determine if the Bridge has the necessary allowance to access the tokens. This can be done using the following API endpoint:
Sample Request:
Sample Response:
If the allowance is less than the token amount to be swapped, the user must approve the Bridge contract from the token contract. This can be done using the following API endpoint:
Sample Request:
Sample Response:
Sample Request:
Sample Response:
API URL:
API URL:
After the successful approval, we can do the swap. User can swap the tokens on their preferred Bridge by changing the "" parameter. This can be done using the following API endpoint:
API URL: