swap
Get swap price estimate. (admin access required, mainnet only)
Get a swap price estimate from the SundaeSwap pool. Returns the conversion rate based on current pool reserves.
get/swap/estimate
Request
- Base URL: ./../api/v1/ (relative, and the document was published on a file host, not at the API’s origin)
- URL: ./../api/v1/swap/estimate
- Auth: API key in header token
Query parameters
fromPolicyIdstring required
Policy ID of the source token. Use empty string "" for ADA
fromAssetNamestring required
Asset name (hex) of the source token. Use empty string "" for ADA
toPolicyIdstring required
Policy ID of the destination token. Use empty string "" for ADA
toAssetNamestring required
Asset name (hex) of the destination token. Use empty string "" for ADA
poolIdstring required
SundaeSwap pool identifier
Response
Swap estimate
Example response
{
"rate": 2.45,
"fee": 0.003,
"fromDecimals": 6,
"toDecimals": 6
}Changes
No recorded changes to this operation across all 50 revisions of this API.