Create a job to generate csv files of IFTA mileage segments.
Rate limit: 100 requests/min (learn more about rate limits here).
To use this endpoint, select Write IFTA (US) under the Compliance category when creating or editing an API token. Learn More.
Submit Feedback: Likes, dislikes, and API feature requests should be filed as feedback in our API feedback form. If you encountered an issue or noticed inaccuracies in the API documentation, please submit a case to our support team.
curl --request POST \
--url https://api.samsara.com/ifta-detail/csv \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"endHour": "2019-06-13T19:00:00Z",
"startHour": "2019-06-13T19:00:00Z",
"vehicleIds": "1234,5678,samsara.vin:1HGBH41JXMN109186",
"vehicleParentTagIds": "1234,5678",
"vehicleTagIds": "1234,5678"
}
'{
"data": {
"args": {
"endHour": "2019-06-13T19:00:00Z",
"startHour": "2019-06-13T19:00:00Z",
"vehicleIds": [
12345678,
56789123
]
},
"jobId": "8cabba84-bef4-4951-8cd2-78ce898fd8e6",
"jobStatus": "Processing",
"requestedAtTime": "2019-06-13T19:00:00Z",
"completedAtTime": "2019-06-13T19:00:00Z",
"details": "Try limiting the number of vehicles requested per job to reduce the processing duration.",
"failedAtTime": "2019-06-13T19:00:00Z",
"files": [
{
"createdAtTime": "2019-06-13T19:00:00Z",
"downloadUrl": "https://s3.download-url.com",
"downloadUrlExpirationTime": "2019-06-13T19:00:00Z",
"name": "output-001.csv.gz",
"recordCount": 8126609865522604000
}
],
"startedAtTime": "2019-06-13T19:00:00Z"
}
}Documentation Index
Fetch the complete documentation index at: https://samsara-showcase.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
The payload to create a new IftaDetailJob.
An end time in RFC 3339 format. Hour precision and timezones are supported. Any minutes or seconds will be truncated down to the nearest hour. Note that the most recent 72 hours of data may still be processing and is subject to change and latency, so it is not recommended to request data for the most recent 72 hours. The maximum request duration is 1 month. Limit the number of vehicles to 1000 when requesting more than 24 hours of data. (Examples: 2019-06-13T19:00:00Z, 2019-06-13T19:00:00.000Z, OR 2015-09-15T14:00:00-04:00).
"2019-06-13T19:00:00Z"
A start time in RFC 3339 format. Hour precision and timezones are supported. Any minutes or seconds will be truncated down to the nearest hour. Note that the most recent 72 hours of data may still be processing and is subject to change and latency, so it is not recommended to request data for the most recent 72 hours. The maximum request duration is 1 month. Limit the number of vehicles to 1000 when requesting more than 24 hours of data. (Examples: 2019-06-13T19:00:00Z, 2019-06-13T19:00:00.000Z, OR 2015-09-15T14:00:00-04:00).
"2019-06-13T19:00:00Z"
A filter on the data based on this comma-separated list of vehicle IDs and external IDs. The number of vehicles requested per job shouldn't exceed 5000. Example: vehicleIds: '1234,5678,samsara.vin:1HGBH41JXMN109186'
"1234,5678,samsara.vin:1HGBH41JXMN109186"
A filter on the data based on this comma-separated list of vehicle parent tag IDs. The number of vehicles requested per job shouldn't exceed 5000. Example: vehicleParentTagIds: '1234,5678'
"1234,5678"
A filter on the data based on this comma-separated list of vehicle tag IDs. The number of vehicles requested per job shouldn't exceed 5000. Example: vehicleTagIds: '1234,5678'
"1234,5678"
Created response.
A job representing the async generation of IFTA mileage segments. The job should be polled until the state is terminal.
Show child attributes
curl --request POST \
--url https://api.samsara.com/ifta-detail/csv \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"endHour": "2019-06-13T19:00:00Z",
"startHour": "2019-06-13T19:00:00Z",
"vehicleIds": "1234,5678,samsara.vin:1HGBH41JXMN109186",
"vehicleParentTagIds": "1234,5678",
"vehicleTagIds": "1234,5678"
}
'{
"data": {
"args": {
"endHour": "2019-06-13T19:00:00Z",
"startHour": "2019-06-13T19:00:00Z",
"vehicleIds": [
12345678,
56789123
]
},
"jobId": "8cabba84-bef4-4951-8cd2-78ce898fd8e6",
"jobStatus": "Processing",
"requestedAtTime": "2019-06-13T19:00:00Z",
"completedAtTime": "2019-06-13T19:00:00Z",
"details": "Try limiting the number of vehicles requested per job to reduce the processing duration.",
"failedAtTime": "2019-06-13T19:00:00Z",
"files": [
{
"createdAtTime": "2019-06-13T19:00:00Z",
"downloadUrl": "https://s3.download-url.com",
"downloadUrlExpirationTime": "2019-06-13T19:00:00Z",
"name": "output-001.csv.gz",
"recordCount": 8126609865522604000
}
],
"startedAtTime": "2019-06-13T19:00:00Z"
}
}