Skip to main content

Historical Tick Data

Similarly to making snapshots, you can request historical tick data by performing an HTTP request.

info

All endpoints listed below are relative to https://HOST:PORT/repo. The value of HOST:PORT is provided by Spotware's service assurance team upon request.

info

Note that all requests listed below return arrays of bytes that you can serialise into the required entities. For example, in Java this can be done by calling the parseFrom() method from a suitable static class.

Request Historical Tick Data

HTTP MethodURL
GET/tickData

Gets historical tick data for a symbol for a certain time period. The maximum period for which it is possible to request tick data via one request is 24 hours.

Parameters

ParameterParameter TypeRequired?Data TypeDescription
symbolIdqueryYesintegerThe ID of the symbol for which you would like to request historical tick data.
typequeryYesstringThe type of historical tick data you would like to request. This parameter can only take two possible values.
BID. The tick data for bid prices is requested.
ASK. The tick data for ask prices is requested.
fromTimestampqueryYesintegerThe Unix timestamp of the start of the period for which you would like to request tick data (including milliseconds).
toTimestampqueryYesintegerThe Unix timestamp of the end of the period for which you would like to request tick data (including milliseconds).
sizequeryNointegerThe total number of ticks to return; this parameter can only take values ranging from 1 to 500000. Defaults to 500000.

Request Body

No request body.

Output

An array of bytes representing the requested entity(-ies).

Request Examples

Requesting the first 100 ASK ticks for symbol whose ID equals 1 starting from 22/06/2019, 11:12:31.681 until 22/06/2019, 12:32:30.231.

curl -X GET "https://HOST:PORT/repo/tickData?symbolId=1&type=ASK&fromTimestamp=1563793951681&toTimestamp=1563798750231&size=100"

Response Example

As the response contains only an array of bytes, no specific example can be provided.