Data Feeds
GET /api/data-feeds/download
Section titled “GET /api/data-feeds/download”Downloads bulk vehicle data as a ZIP archive containing CSV data feed files. You must subscribe to the Data Feed product through your dashboard before using this endpoint.
Sample Request
Section titled “Sample Request”curl "https://carapi.app/api/data-feeds/download" \ -H "Authorization: Bearer YOUR_JWT_TOKEN_HERE" \ -o vehicle-data.zipconst response = await fetch('https://carapi.app/api/data-feeds/download', { headers: { 'Authorization': `Bearer ${jwt}` }});
const buffer = await response.arrayBuffer();// Save buffer to a .zip file using your preferred file system libraryconsole.log('Downloaded data feed:', buffer.byteLength, 'bytes');import requests
headers = { 'Authorization': f'Bearer {jwt}'}
response = requests.get( 'https://carapi.app/api/data-feeds/download', headers=headers, stream=True)
with open('vehicle-data.zip', 'wb') as f: for chunk in response.iter_content(chunk_size=8192): f.write(chunk)
print('Data feed downloaded successfully')use GuzzleHttp\Client;
$client = new Client();
$client->get('https://carapi.app/api/data-feeds/download', [ 'headers' => [ 'Authorization' => 'Bearer YOUR_JWT_TOKEN_HERE', ], 'sink' => 'vehicle-data.zip',]);
echo 'Data feed downloaded successfully';$fp = fopen('vehicle-data.zip', 'wb');
$ch = curl_init();curl_setopt($ch, CURLOPT_URL, 'https://carapi.app/api/data-feeds/download');curl_setopt($ch, CURLOPT_FILE, $fp);curl_setopt($ch, CURLOPT_HTTPHEADER, [ 'Authorization: Bearer YOUR_JWT_TOKEN_HERE',]);
curl_exec($ch);curl_close($ch);fclose($fp);
echo 'Data feed downloaded successfully';Best Practices
Section titled “Best Practices”- Check last-updated first: Use
/api/data-feeds/last-updatedbefore downloading to avoid re-downloading unchanged data. - Stream large responses: The ZIP file can be large — use streaming downloads rather than loading the full response into memory.
GET /api/data-feeds/last-updated
Section titled “GET /api/data-feeds/last-updated”Returns the last modified timestamp of the data feed. All times are United States Eastern Standard Time (EST).
Sample Request
Section titled “Sample Request”curl "https://carapi.app/api/data-feeds/last-updated" \ -H "Authorization: Bearer YOUR_JWT_TOKEN_HERE"const response = await fetch('https://carapi.app/api/data-feeds/last-updated', { headers: { 'Authorization': `Bearer ${jwt}` }});
const data = await response.json();console.log('Data feed last updated:', data);import requests
headers = { 'Authorization': f'Bearer {jwt}'}
response = requests.get( 'https://carapi.app/api/data-feeds/last-updated', headers=headers)
data = response.json()print('Data feed last updated:', data)use GuzzleHttp\Client;
$client = new Client();
$response = $client->get('https://carapi.app/api/data-feeds/last-updated', [ 'headers' => [ 'Authorization' => 'Bearer YOUR_JWT_TOKEN_HERE', ],]);
$data = json_decode($response->getBody(), true);echo 'Last updated: ' . $data['last_updated'];$ch = curl_init();curl_setopt($ch, CURLOPT_URL, 'https://carapi.app/api/data-feeds/last-updated');curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);curl_setopt($ch, CURLOPT_HTTPHEADER, [ 'Authorization: Bearer YOUR_JWT_TOKEN_HERE',]);
$response = curl_exec($ch);curl_close($ch);
$data = json_decode($response, true);echo 'Last updated: ' . $data['last_updated'];Sample Response
Section titled “Sample Response”{ "last_updated": "2026-06-15 03:00:00"}