APIs, Bots & Automation

Make Your First Quote.Trade API Call in Python, JavaScript, and cURL

Call Quote.Trade’s public REST endpoints without an API key. Start with status, exchange information, ticker, and depth, and keep prices and quantities as decimal-safe values.

15 minutesBeginnerDevelopers and bot builders

What you will accomplish

  • Verify the public API is reachable
  • Retrieve current exchange information
  • Request a ticker for an active symbol
  • Parse errors and preserve timestamps

Before you begin

  • curl
  • Python 3.10+ with requests installed, or modern Node.js
  • Network access to https://app.quote.trade/api
  • No API key for public endpoints
Base URLhttps://app.quote.trade/api
AuthenticationNone for documented public routes
FreshnessserverTime, event time, updateTime, or local receive time
Not a timestamplastUpdateId
Step-by-step

Check platform status

Start with the documented public status route. Save local receive time and any serverTime returned.

bash
curl -sS https://app.quote.trade/api/status

Inspect current exchange information

Use exchangeInfo for current serverTime, rate limits, symbol status, USD quote asset, quantityScale, and identifiers. Do not infer minimum order size, payment currency, or leverage permission from fields that are not returned.

bash
curl -sS https://app.quote.trade/api/exchangeInfo

Call ticker with Python and Decimal-safe values

Install requests once before running this example, set a timeout, and preserve price strings as Decimal for calculations.

python
from datetime import datetime, timezone
from decimal import Decimal
import requests

url = 'https://app.quote.trade/api/ticker?symbol=BTC'
received_at = datetime.now(timezone.utc)
response = requests.get(url, timeout=10)
response.raise_for_status()
data = response.json()
price = Decimal(str(data['price']))
bid = Decimal(str(data['bid']))
ask = Decimal(str(data['ask']))
print({'receivedAt': received_at.isoformat(), 'symbol': data.get('symbol'), 'price': str(price), 'bid': str(bid), 'ask': str(ask)})

Call depth in JavaScript

Record the local receive time and keep price/quantity values as strings until a decimal library parses them.

javascript
const receivedAt = new Date().toISOString();
const response = await fetch('https://app.quote.trade/api/depth?symbol=BTC&limit=5');
if (!response.ok) throw new Error(`HTTP ${response.status}`);
const depth = await response.json();
console.log({ receivedAt, symbol: depth.symbol, lastUpdateId: depth.lastUpdateId, bids: depth.bids, asks: depth.asks });

Check whether the data is fresh

Use response serverTime, event/updateTime, or local receive time when available. lastUpdateId can help order updates but must not be compared to wall-clock time.

Troubleshooting

Common problems and fixes

The API returns Invalid symbol

Retrieve exchange information and use the exact symbol string returned by production.

Browser JavaScript reports a network or CORS error

Test from a server-side runtime or inspect current CORS headers; do not expose private credentials in browser code.

A 5xx response occurs

For public reads, back off and retry safely. For a trading operation, check the current order status before retrying because the first request may have executed.

Primary sources

Ready for the next step?

Open the public API documentation

Open the public API documentation