Public quote (no key)
A public, unauthenticated quote endpoint for price-display and comparison sites (aggregators, wallets, dashboards). It returns GhostSwap's standard rate, needs no API key, and is rate-limited so it can be polled safely.
Use this for displaying prices. To execute a swap and earn commission,
use the authenticated POST /v1/quotes +
POST /v1/swaps endpoints with your Bearer key.
GET
/v1/public/quoteQuery parameters
| Name | Type | Required | Description |
|---|---|---|---|
from | string | required | Source ticker (canonical ticker from /v1/currencies, e.g. xmr). Common aliases like usdttrx are accepted and normalized. |
to | string | required | Destination ticker (e.g. usdtrx for USDT-TRON, usdt20 for USDT-ERC20, btc). |
amount | string | optional | Source amount as a decimal string. Defaults to "1". |
Example
curl "https://partners-api.ghostswap.io/v1/public/quote?from=xmr&to=usdtrx&amount=1"{
"quote": {
"from": "xmr",
"to": "usdtrx",
"amountFrom": "1",
"amountTo": "285.35",
"networkFee": "0.94",
"amountUserReceives": "284.41",
"rate": "285.63",
"min": "0.10",
"max": "2337.97",
"rateType": "float",
"feeNote": "Standard GhostSwap rate (service fee included)."
}
}Display rate as the unit price, or amountTo as the "you get" amount. The
rate already includes GhostSwap's standard service fee, so it is the real,
executable number — do not add anything on top for display.
Authentication
None. This is the only /v1 endpoint that does not require a Bearer key.
Rate limits & caching
- 60 requests per minute per IP. Responses carry standard
RateLimit-Limit/RateLimit-Remaining/RateLimit-Resetheaders. - Responses set
Cache-Control: public, max-age=10. Cache each(from, to, amount)result for 10–30s and serve cached values to your visitors instead of calling per page view. - On
429, back off and retry afterRateLimit-Reset. - CORS is open (
Access-Control-Allow-Origin: *), so it can be called from a browser — but a small server-side cache is strongly recommended.
Errors
| Status | Meaning |
|---|---|
400 | Invalid params (bad/missing ticker, non-positive amount, or from == to). |
429 | Rate limit exceeded — retry after RateLimit-Reset. |
503 | Service temporarily unavailable — retry later. |