Skip to main content

Documentation Index

Fetch the complete documentation index at: https://tradewatch.io/docs/llms.txt

Use this file to discover all available pages before exploring further.

Stock price data is available at three levels of granularity: real-time quotes for the latest bid/ask, OHLC candles for aggregated historical analysis, and raw ticks for full-resolution historical replay. Use symbol discovery to find available instruments before querying price data.

Endpoints

EndpointSummaryKey use case
GET /stocks/quoteLast quote (single)Display current bid/ask for one symbol
GET /stocks/quotesLast quotes (batch)Dashboard with multiple symbols at once
GET /stocks/{symbol}Full stock snapshotRich metadata + current price in one call
GET /stocks/{symbol}/ohlcHistorical OHLC candlesCharts, technical analysis, backtesting
GET /stocks/{symbol}/ticksHistorical raw ticksMicrostructure research, full-resolution replay
GET /stocks/symbolsSymbol discoveryFind available instruments

Last Quotes

Endpoint: GET /stocks/quote · GET /stocks/quotes The quote endpoints return the most recent bid and ask prices for a symbol. /stocks/quote takes a single symbol query parameter; /stocks/quotes accepts a comma-separated symbols list for fetching multiple instruments in one request. The precision parameter controls the number of decimal places in the response. Omit it to receive the full native precision. Key fields
FieldTypeWhat it means
bidnumberHighest price a buyer is willing to pay
asknumberLowest price a seller is willing to accept
midnumberMidpoint between bid and ask
timestampintegerUnix timestamp of the quote
When to use
  • Displaying the current price of a stock on a dashboard or ticker
  • Checking the latest price before placing a simulated trade
  • Fetching prices for a portfolio of holdings in a single request (use /quotes)
Example
curl "https://api.tradewatch.io/stocks/quote?symbol=AAPL" \
  -H "api-key: YOUR_API_KEY"

Historical OHLC

Endpoint: GET /stocks/{symbol}/ohlc Returns aggregated OHLC (Open, High, Low, Close) candles for a symbol in a selected resolution and time range. Both ask-side and bid-side OHLC values are returned. The resolution parameter specifies the candle width in seconds — for example, 60 for 1-minute candles, 3600 for 1-hour candles, 86400 for daily candles. start and end are Unix timestamps (inclusive and exclusive respectively). Key fields
FieldTypeWhat it means
timeintegerUnix timestamp of the candle open
open_ask / open_bidnumberOpening ask/bid price for the period
high_ask / high_bidnumberHighest ask/bid reached during the period
low_ask / low_bidnumberLowest ask/bid reached during the period
close_ask / close_bidnumberClosing ask/bid price for the period
When to use
  • Rendering price charts (candlestick or OHLC bar charts)
  • Backtesting strategies against historical price data
  • Computing technical indicators manually from raw OHLC values
Example
# Daily candles for AAPL — adjust start/end Unix timestamps to your desired range
curl "https://api.tradewatch.io/stocks/AAPL/ohlc?resolution=86400&start=1714521600&end=1717113600" \
  -H "api-key: YOUR_API_KEY"

Raw Ticks

Endpoint: GET /stocks/{symbol}/ticks Returns every individual price tick for a symbol within a time range, using cursor pagination. Each tick contains the bid, ask, and mid price at a specific moment. Unlike OHLC, ticks are not aggregated — you receive every recorded price change. Key fields
FieldTypeWhat it means
timestringISO 8601 timestamp of the tick
asknumberAsk price at this moment
bidnumberBid price at this moment
midnumberMidpoint at this moment
When to use
  • High-resolution backtesting where candle granularity is insufficient
  • Microstructure research (spread analysis, intraday volatility)
  • Building a local tick database for a specific symbol and period
Use OHLC instead of ticks when you only need aggregated price action — ticks produce much larger datasets for the same time range. Example
curl "https://api.tradewatch.io/stocks/AAPL/ticks?start=1717027200&end=1717113600&limit=100" \
  -H "api-key: YOUR_API_KEY"

Symbol Discovery

Endpoint: GET /stocks/symbols Returns a paginated list of available stock symbols. Use the country parameter to filter by market, type to filter by instrument type, and cursor to page through results. When to use
  • Building a symbol search or autocomplete feature
  • Discovering which symbols are available for a specific market before requesting price data
Example
# List US stocks, 50 per page
curl "https://api.tradewatch.io/stocks/symbols?country=US&size=50" \
  -H "api-key: YOUR_API_KEY"