API Documentation

Complete REST API documentation for accessing real-time and historical market data, technical indicators, fundamentals, and more.

Quickstart

Authentication

All API requests require authentication using an API key. You can include your API key in two ways:

1. Query String Parameter:
GET https://mail.tradeiqai.com/api/v2/stocks/last/AAPL?api_key=YOUR_API_KEY
2. Authorization Header:
X-API-Key: YOUR_API_KEY
Note: Replace YOUR_API_KEY with your actual API key from your dashboard. Keep your API key secure and do not share it publicly.

Making Your First Request

Here's an example using curl to get the last quote for Apple (AAPL):

curl "https://mail.tradeiqai.com/api/v2/stocks/last/AAPL?api_key=YOUR_API_KEY"

Understanding API Responses

All REST API endpoints return data in a structured JSON format. Common fields include:

  • status - Response status (typically "OK")
  • results - Array of data records
  • request_id - Unique identifier for the request
  • next_url - URL for pagination (if applicable)

Stocks

Retrieve risk categories from SEC filings for public companies.

/stocks/filings/v1/risk-categories

Retrieve risk factors from SEC filings for public companies.

/stocks/filings/v1/risk-factors

Retrieve comprehensive balance sheet data for public companies, containing quarterly and annual financial positions.

/stocks/financials/v1/balance-sheets

Retrieve comprehensive cash flow statement data for public companies, including quarterly, annual, and trailing twelve-month cash flows.

/stocks/financials/v1/cash-flow-statements

Retrieve float data (shares available for trading) for public companies.

/stocks/financials/v1/float

Retrieve comprehensive income statement data for public companies.

/stocks/financials/v1/income-statements

Retrieve comprehensive financial ratios for public companies.

/stocks/financials/v1/ratios

Retrieve short interest data for public companies.

/stocks/financials/v1/short-interest

Retrieve short volume data for public companies.

/stocks/financials/v1/short-volume

Historical cash dividend distributions for a ticker.

/stocks/v1/dividends

Historical stock split events for a ticker.

/stocks/v1/splits

Daily open/close (+ pre/after-hours if available) for a stock ticker.

/v1/open-close/{stocksTicker}/{date}

Daily grouped OHLCV/VWAP for all U.S. stocks on a date.

/v2/aggs/grouped/locale/us/market/stocks/{date}

Previous trading day OHLC for a stock ticker.

/v2/aggs/ticker/{stocksTicker}/prev

Aggregated OHLCV bars for a stock ticker over a custom range.

/v2/aggs/ticker/{stocksTicker}/range/{multiplier}/{timespan}/{from}/{to}

News articles related to a ticker (with summaries/sentiment where available).

/v2/reference/news

Full U.S. market snapshot for stocks.

/v2/snapshot/locale/us/markets/stocks/tickers

Single ticker snapshot (trade/quote/min/day/prevDay).

/v2/snapshot/locale/us/markets/stocks/tickers/{stocksTicker}

Retrieve the most recent quote (bid/ask/last) for a stock ticker.

/v2/stocks/last/{ticker}

Historical NBBO quotes for a stock ticker over a time range.

/v3/quotes/{stockTicker}

Options

Daily open/close (+ pre/after-hours if available) for an options contract.

/v1/open-close/{optionsTicker}/{date}

Previous trading day OHLC for an options contract.

/v2/aggs/ticker/{optionsTicker}/prev

Aggregated OHLCV bars for an options contract over a custom range.

/v2/aggs/ticker/{optionsTicker}/range/{multiplier}/{timespan}/{from}/{to}

Latest trade for an options contract.

/v2/last/trade/{optionsTicker}

Historical quotes for an options contract over a time range.

/v3/quotes/{optionsTicker}

List options contracts (active + expired), filterable by underlying.

/v3/reference/options/contracts

Get details for a specific options contract.

/v3/reference/options/contracts/{options_ticker}

Snapshot of the full options chain for an underlying ticker.

/v3/snapshot/options/{underlyingAsset}

Snapshot for a specific options contract (incl greeks/IV/OI where available).

/v3/snapshot/options/{underlyingAsset}/{optionContract}

Forex

Most recent quote (bid/ask) for a forex pair.

/v1/last_quote/currencies/{from}/{to}

Previous day OHLC for a forex pair.

/v2/aggs/ticker/{forexTicker}/prev

Aggregated OHLCV bars for a forex pair over a custom range.

/v2/aggs/ticker/{forexTicker}/range/{multiplier}/{timespan}/{from}/{to}

Full forex market snapshot.

/v2/snapshot/locale/global/markets/forex/tickers

Single forex ticker snapshot (quote/min/day/prevDay).

/v2/snapshot/locale/global/markets/forex/tickers/{ticker}

Top 20 forex gainers/losers snapshot.

/v2/snapshot/locale/global/markets/forex/{direction}

List known exchanges and attributes.

/v3/reference/exchanges

Reference

Get ticker branding icon

/v1/reference/company-branding/icon/{filename}

Get ticker branding logo

/v1/reference/company-branding/logo/{filename}

List market condition codes.

/v3/reference/conditions

List tickers supported by (multi-asset; includes forex).

/v3/reference/tickers

List supported ticker types (filterable by asset class/locale).

/v3/reference/tickers/types

Ticker overview (multi-asset; used for forex tickers too).

/v3/reference/tickers/{ticker}

Technical Indicators

Real-time currency conversion using latest market rates.

/v1/conversion/{from}/{to}

Retrieve the Exponential Moving Average (EMA) for a specified ticker over a defined time range. The EMA places greater weight on recent prices, enabling quicker trend detection and more responsive signals.

/v1/indicators/ema/{ticker}

Retrieve the Moving Average Convergence/Divergence (MACD) for a specified ticker over a defined time range. MACD is a momentum indicator derived from two moving averages, helping to identify trend strength, direction, and potential trading signals.

/v1/indicators/macd/{ticker}

Retrieve the Relative Strength Index (RSI) for a specified ticker over a defined time range. The RSI measures the speed and magnitude of price changes, oscillating between 0 and 100 to help identify overbought or oversold conditions.

/v1/indicators/rsi/{ticker}

Retrieve the Simple Moving Average (SMA) for a specified ticker over a defined time range. The SMA calculates the average price across a set number of periods, smoothing price fluctuations to reveal underlying trends and potential signals.

/v1/indicators/sma/{ticker}

Economy

Retrieve key indicators of realized inflation, reflecting actual changes in consumer prices and spending behavior in the U.S. economy. Provides both headline and core inflation measures from the CPI and PCE indexes.

/fed/v1/inflation

Retrieve a broad view of how inflation is expected to evolve over time in the U.S. economy. Combines signals from financial markets and economic models to capture both near-term and long-term inflation outlooks.

/fed/v1/inflation-expectations

Retrieve historical U.S. Treasury yield data for standard timeframes ranging from 1-month to 30-years, with daily historical records back to 1962.

/fed/v1/treasury-yields

Other

Get Current Market Status

/v1/marketstatus/

Get Social Rankings

/v3/social/