Export raw tracks with OData¶
Use the raw-track endpoint to export GPS tracks from a large Tracking Round. It avoids the whole-round 20 GB
estimate used by the standard track table. It also reads archived tracks.
The endpoint returns raw track data. It does not add Targeted Area or base-layer intersections, and it does not use the OData snapshot described in Open Data and Reporting (OData). Reads from archived files can take longer than reads from live storage.
Who can use it¶
Use a GTS Dashboard Account with API access and permission to view the Tracking Round. The account has the same access scope as other Open Data endpoints. See Who can use it.
The endpoint is:
https://gts.health/fastapi/odata/v1/raw_track/<tracking_round_id>
Replace <tracking_round_id> with the numeric ID of the Tracking Round.
Download a time window¶
Each request must filter GPS_Timestamp_UTC to a window greater than zero and at most 24 hours. Use timestamps
with a UTC offset. The lower bound is inclusive (ge); the upper bound is exclusive (lt).
This example requests one UTC day and asks for pages of up to 50,000 tracks:
curl --fail-with-body --get --user 'YOUR_USERNAME' \
'https://gts.health/fastapi/odata/v1/raw_track/123' \
--data-urlencode '$filter=GPS_Timestamp_UTC ge 2026-01-01T00:00:00Z and GPS_Timestamp_UTC lt 2026-01-02T00:00:00Z' \
--header 'Prefer: odata.maxpagesize=50000'
Curl prompts for the password. Replace 123 with an accessible Tracking Round ID.
The API keeps results within the dates of the Tracking Round.
To export more than one day, request non-overlapping windows. Use the previous window’s upper bound as the next window’s lower bound. This avoids gaps and duplicate tracks at window boundaries.
Page through results¶
The default page contains at most 10,000 tracks. The maximum page size is 50,000.
Set Prefer: odata.maxpagesize=<positive integer> to request a different size. The API caps larger values at
50,000 and reports the applied size in Preference-Applied.
If a response contains @odata.nextLink, request that exact URL with the same authentication and Prefer
header. Continue until the response has no @odata.nextLink. Do not edit the $skiptoken in that URL.
Use $top=<non-negative integer> to limit the total number of tracks across all pages. Omit $top to export
all matching tracks in the time window.
Filters and fields¶
The endpoint supports $filter, $select, $top, $skiptoken and $orderby. A filter must bound the
whole query to one window of at most 24 hours, including every or branch.
Supported comparisons are eq, ne, gt, ge, lt and le. Filters also support and, or,
not, parentheses, and string functions such as contains, startswith, endswith, tolower,
toupper and trim.
Available fields are id, Username, Team_Code, IMEI, GPS_Timestamp_UTC,
Phone_Timestamp_UTC, Lat, Lon, Accuracy, Speed_mps and Valid. Use $select to return
only the fields you need, for example $select=id,IMEI,GPS_Timestamp_UTC,Valid.
Valid is 1 when the speed meets the Tracking Round’s rules and the track has no suspicious flags.
Otherwise, it is 0. GPS_Status is not included.
The default order is ascending by GPS timestamp, phone timestamp and device ID. $orderby accepts only
ascending prefixes of this order. The endpoint does not support $skip, $count, $expand or entity-key
lookups. Unsupported options, properties or filters return HTTP 400.
Limits and data changes¶
The 24-hour filter limit applies to the entire filter, not just the first date condition. Split longer exports into
separate requests. The regular OData 20 GB estimate still applies to the standard track table and Targeted Area
indicators.
Each database statement has a 240-second timeout. This is not a time limit for the full export. Archived tracks can make a request slower because the API reads their files for each page.
Pages are not a snapshot of the Tracking Round. Late uploads can appear before a continuation key that the API already returned. For a consistent export, wait until uploads stop and repeat the export if data changes while you page through it.