Stargate
/getliquidity
Get the balance of a particular token pair of an account.
GET
https://api.expand.network/bridge/getliquidity
Query Parameters
https://api.expand.network/bridge/getliquidity?bridgeId=100&poolAddress=0xdf0770dF86a8034b3EFEf0A1Bb3c889B8332FF56&srcChainId=1
/gettransaction
Get details of a transaction.
GET
https://api.expand.network/bridge/gettransaction
Query Parameters
https://api.expand.network/bridge/gettransaction?bridgeId=100&network=mainnet&srcChainId=137&transactionHash=0xe8a0ebe3d5c36879c5a951c9faf65608b8a9c8b2e7e3c8471e25f5767a390b28
/swap
Swap assets across multiple chains.
POST
https://api.expand.network/bridge/swap
Request Body
rpc
String
Remote procedural call URL.
srcTokenSymbol*
String
Symbol of token to swap.
amountIn*
String
Amount of token to be swapped.
from*
String
Address of the sender of the token.
amountOutMin*
String
Minimum amount accepted as the result of swap.
gas*
String
Maximum gas limit provided by the sender, for the transaction.
to
String
Address of the recipient of the token.
dstTokenSymbol
String
Symbol of token to be received as a result of swap.
srcChainId
String
Source Chain Id. By default, Ethereum mainnet. Refer to the Chain ID page for details.
srcChainSymbol
String
Source Chain Symbol.
slippage
String
Percentage of total swap value. By default, 1.
0 <= slippage value <= 10
gasPriority
String
low, medium, or high.
{
"srcTokenSymbol": "USDC",
"amountIn": "10000",
"amountOutMin": "1000",
"gas": "10000",
"from": "0xa67e9b68c41b0f26184d64c26e0b2b81466e5994",
"dstChainId": "137"
}
With gasPriority:
{
"srcChainId": "1",
"bridgeId": "100",
"srcTokenSymbol": "USDC",
"amountIn": "10000",
"gas": "900000",
"gasPriority": "low",
"from": "0xa67E9B68c41b0f26184D64C26e0b2B81466E5994",
"dstChainId": "137",
"amountOutMin": "100"
}
With slippage:
{
"srcChainId": "1",
"srcTokenSymbol": "USDC",
"amountIn": "10000",
"amountOutMin": "100",
"gas": "10000",
"slippage": "4",
"from": "0xa67e9b68c41b0f26184d64c26e0b2b81466e5994",
"dstChainId": "137"
}
/addliquidity
Loan your assets to the specified bridge.
POST
https://api.expand.network/bridge/addliquidity
Request Body
rpc
String
Remote procedural call URL.
srcChainId
String
Source Chain Id. By default, Ethereum mainnet. Refer to the Chain ID page for details.
srcTokenSymbol*
String
Symbol of token to add liquidity.
from*
String
Address of the sender of the token.
amountIn*
String
Amount of token to add liquidity.
gas*
String
Maximum gas limit provided by the sender, for the transaction.
srcChainSymbol
String
Source Chain Symbol.
gasPriority
String
low, medium, or high.
{
"srcChainId": "1",
"bridgeId": "100",
"srcTokenSymbol": "USDT",
"amountIn": "10000000",
"gas": "400000",
"from": "0xa67e9b68c41b0f26184d64c26e0b2b81466e5994"
}
With gasPriority:
{
"srcChainId": "1",
"bridgeId": "100",
"srcTokenSymbol": "USDC",
"amountIn": "10000",
"gas": "890000",
"gasPriority": "medium",
"from": "0xa67E9B68c41b0f26184D64C26e0b2B81466E5994"
}
/removeliquidity
Remove user liquidity across multiple chains.
POST
https://api.expand.network/bridge/removeliquidity
Request Body
rpc
String
Remote procedural call URL.
srcChainId
String
Source Chain Id. By default, Ethereum mainnet. Refer to the Chain ID page for details.
srcTokenSymbol*
String
Symbol of token to add liquidity.
from*
String
Address of the sender of the token.
amountOut*
String
Amount of token to remove liquidity.
gas*
String
Maximum gas limit provided by the sender, for the transaction.
srcChainSymbol
String
Source Chain Symbol.
gasPriority
String
low, medium, or high.
{
"srcChainId": "1",
"bridgeId": "100",
"srcTokenSymbol": "USDT",
"amountOut": "10000000",
"gas": "400000",
"from": "0xa67e9b68c41b0f26184d64c26e0b2b81466e5994"
}
With gasPriority:
{
"srcChainId": "1",
"bridgeId": "100",
"srcTokenSymbol": "USDC",
"amountOut": "10000",
"gas": "100000",
"gasPriority": "high",
"from": "0xa67e9b68c41b0f26184d64c26e0b2b81466e5994"
}
Last updated