This guide walks you through creating your first subscription and exporting data from Ticksupply. By the end, you’ll have downloaded historical trade data for analysis.
After your subscription has been collecting data (even for just a few minutes), you can export it.
Timestamps are in nanoseconds since Unix epoch. You can use integers or strings for large numbers.
Create an export for a specific time range. By default, exports use the raw schema (timestamp + raw JSON). For structured columns, you can specify a built-in or custom schema.
# Export last hour of data# Calculate timestamps: now - 1 hour to now, in nanosecondscurl -X POST -H "X-Api-Key: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "datastream_id": 123, "start_time": "1703116800000000000", "end_time": "1703120400000000000" }' \ https://api.ticksupply.com/v1/exports
# Check statuscurl -H "X-Api-Key: YOUR_API_KEY" \ https://api.ticksupply.com/v1/exports/exp_0194a1b2c3d4e5f6a7b8c9d0e1f2a3b4# When status is "succeeded", get download URLscurl -H "X-Api-Key: YOUR_API_KEY" \ https://api.ticksupply.com/v1/exports/exp_0194a1b2c3d4e5f6a7b8c9d0e1f2a3b4/download
The download endpoint returns presigned URLs (valid for 5 minutes) for all export artifacts: