TickQuote logoTickQuoteDocs

Docs search

Search the current language documentation index.

Docs/Market Data·API

Latest quotes

Return latest quote states for compact tickers.

Method
GET
Path
/api/v1/market/quotes/latest
Auth
Bearer token

Overview

Returns the latest bid/ask quote state for one or more tickers. A quote is a price state, not a trade tick.

Common use cases

  • - Render quote lists
  • - Refresh latest prices in dashboards
  • - Fetch an initial value before opening a WebSocket subscription

Request URL

Send the request to the base API URL with your product API key in the Authorization bearer header.

GET/api/v1/market/quotes/latest?tickers=EURUSD%2CGBPUSD
HTTP request
GET https://api.tickquote.com/api/v1/market/quotes/latest?tickers=EURUSD%2CGBPUSD
Authorization: Bearer <tkp_api_key>
Parameter
Description
tickers
Required. Comma-separated compact ticker list, for example EURUSD,GBPUSD.

Try It Out

Edit query parameters and send a demo or authenticated request from this endpoint page.

GET/api/v1/market/quotes/latest
Live sandbox

Use demo_key to try it without an account.

Response

// Response will appear here after sending a request

Response

A successful REST response uses code 0 and message success. Always check code before reading data.

response.json
Sample payload
{
  "code": 0,
  "message": "success",
  "data": {
    "items": [
      {
        "type": "quote",
        "ticker": "EURUSD",
        "time_msc": 1777100000000,
        "bid": 1.10201,
        "ask": 1.10221,
        "mid": 1.10211,
        "spread": 0.0002
      }
    ]
  }
}

Examples

The examples below use compact tickers and the Authorization bearer header.

curl
cURL
curl "https://api.tickquote.com/api/v1/market/quotes/latest?tickers=EURUSD%2CGBPUSD" \
  -H "Authorization: Bearer $TICKQUOTE_API_KEY"
request.js
JavaScript
const response = await fetch("https://api.tickquote.com/api/v1/market/quotes/latest?tickers=EURUSD%2CGBPUSD", {
  headers: {
    Authorization: `Bearer ${process.env.TICKQUOTE_API_KEY}`,
  },
})

const payload = await response.json()
if (payload.code !== 0) {
  throw new Error(payload.message)
}

console.log(payload.data)

Field reference

Field
Sample
Description
type
quote
Always quote.
ticker
EURUSD
Compact ticker for this quote.
time_msc
1777100000000
Quote timestamp in Unix milliseconds.
bid
1.10201
Current bid price.
ask
1.10221
Current ask price.
mid
1.10211
Mid price derived from bid and ask.
spread
0.0002
Bid/ask spread.

Important notes

  • - tickers is comma-separated.
  • - Slash symbols such as EUR/USD are not accepted.
  • - When the quote cache is not ready yet, the API can return market_data_not_ready.