Obtain the swap information, call up the wallet to send the specified amount of the original token to the specified address according to the return content, and complete the dialogue.
Request Address: /api/commonSwap
Request Method: POST
Request Parameters:
Field Name
Field Description
Type
Required or not
Notes
equipmentNo
Device number
string
Y
fromTokenAddress
Original token contract address
string
Y
toTokenAddress
Target token contract address
string
Y
fromAddress
Sender address
string
Y
toAddress
Recerver address
string
Y
amountOutMin
Min receiving amount
integer
Y
routerPath
Swap route, if no specific route, can set as null
array
Y
plarform like o3, and similar to uniswap must upload
amounts
Min amount receiving from all routes, if no specific route, can set as null
array
N
o3 must upload
dex
Swap platform name
string
Y
Use to distinguish usage channel
aggregator
Aggregator name
string
N
o3 must upload, represents the DEX name of original single chain swap