Samsara Files API
The Files API from Samsara — 2 operation(s) for files.
The Files API from Samsara — 2 operation(s) for files.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/samsara-files-api"
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
description: Gain greater visibility by connecting your fleets, equipment, sites, and people.
title: Samsara Files API
version: '2024-11-18'
servers:
- url: https://api.samsara.com/
- url: https://api.eu.samsara.com/
security:
- AccessTokenHeader: []
tags:
- name: Files
paths:
/fleet/drivers/tachograph-files/history:
get:
description: "Returns all known tachograph files for all specified drivers in the time range. \n\n <b>Rate limit:</b> 50 requests/sec (learn more about rate limits <a href=\"https://developers.samsara.com/docs/rate-limits\" target=\"_blank\">here</a>). \n\n **Submit Feedback**: Likes, dislikes, and API feature requests should be filed as feedback in our <a href=\"https://forms.gle/zkD4NCH7HjKb7mm69\" target=\"_blank\">API feedback form</a>. If you encountered an issue or noticed inaccuracies in the API documentation, please <a href=\"https://www.samsara.com/help\" target=\"_blank\">submit a case</a> to our support team.\n\nTo use this endpoint, select **Read Tachograph (EU)** under the Compliance category when creating or editing an API token. <a href=\"https://developers.samsara.com/docs/authentication#scopes-for-api-tokens\" target=\"_blank\">Learn More.</a>"
operationId: getDriverTachographFiles
parameters:
- description: If specified, this should be the endCursor value from the previous page of results. When present, this request will return the next page of results that occur immediately after the previous page of results.
in: query
name: after
schema:
type: string
- description: 'A start time in RFC 3339 format. Millisecond precision and timezones are supported. (Examples: 2019-06-13T19:08:25Z, 2019-06-13T19:08:25.455Z, OR 2015-09-15T14:00:12-04:00).'
in: query
name: startTime
required: true
schema:
type: string
- description: 'An end time in RFC 3339 format. Millisecond precision and timezones are supported. (Examples: 2019-06-13T19:08:25Z, 2019-06-13T19:08:25.455Z, OR 2015-09-15T14:00:12-04:00).'
in: query
name: endTime
required: true
schema:
type: string
- description: 'A filter on the data based on this comma-separated list of driver IDs. Example: `driverIds=1234,5678`'
explode: false
in: query
name: driverIds
schema:
items:
type: string
type: array
style: form
- description: 'A filter on the data based on this comma-separated list of parent tag IDs, for use by orgs with tag hierarchies. Specifying a parent tag will implicitly include all descendent tags of the parent tag. Example: `parentTagIds=345,678`'
explode: false
in: query
name: parentTagIds
schema:
items:
type: string
type: array
style: form
- description: 'A filter on the data based on this comma-separated list of tag IDs. Example: `tagIds=1234,5678`'
explode: false
in: query
name: tagIds
schema:
items:
type: string
type: array
style: form
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/TachographDriverFilesResponse'
description: List of all driver tachograph files in a specified time range.
default:
content:
application/json:
schema:
$ref: '#/components/schemas/standardErrorResponse'
description: Error response
summary: Get Tachograph Driver Files
tags:
- Files
/fleet/vehicles/tachograph-files/history:
get:
description: "Returns all known tachograph files for all specified vehicles in the time range. \n\n <b>Rate limit:</b> 150 requests/sec (learn more about rate limits <a href=\"https://developers.samsara.com/docs/rate-limits\" target=\"_blank\">here</a>). \n\n **Submit Feedback**: Likes, dislikes, and API feature requests should be filed as feedback in our <a href=\"https://forms.gle/zkD4NCH7HjKb7mm69\" target=\"_blank\">API feedback form</a>. If you encountered an issue or noticed inaccuracies in the API documentation, please <a href=\"https://www.samsara.com/help\" target=\"_blank\">submit a case</a> to our support team.\n\nTo use this endpoint, select **Read Tachograph (EU)** under the Compliance category when creating or editing an API token. <a href=\"https://developers.samsara.com/docs/authentication#scopes-for-api-tokens\" target=\"_blank\">Learn More.</a>"
operationId: getVehicleTachographFiles
parameters:
- description: If specified, this should be the endCursor value from the previous page of results. When present, this request will return the next page of results that occur immediately after the previous page of results.
in: query
name: after
schema:
type: string
- description: 'A start time in RFC 3339 format. Millisecond precision and timezones are supported. (Examples: 2019-06-13T19:08:25Z, 2019-06-13T19:08:25.455Z, OR 2015-09-15T14:00:12-04:00).'
in: query
name: startTime
required: true
schema:
type: string
- description: 'An end time in RFC 3339 format. Millisecond precision and timezones are supported. (Examples: 2019-06-13T19:08:25Z, 2019-06-13T19:08:25.455Z, OR 2015-09-15T14:00:12-04:00).'
in: query
name: endTime
required: true
schema:
type: string
- description: 'A filter on the data based on this comma-separated list of vehicle IDs. Example: `vehicleIds=1234,5678`'
explode: false
in: query
name: vehicleIds
schema:
items:
type: string
type: array
style: form
- description: 'A filter on the data based on this comma-separated list of parent tag IDs, for use by orgs with tag hierarchies. Specifying a parent tag will implicitly include all descendent tags of the parent tag. Example: `parentTagIds=345,678`'
explode: false
in: query
name: parentTagIds
schema:
items:
type: string
type: array
style: form
- description: 'A filter on the data based on this comma-separated list of tag IDs. Example: `tagIds=1234,5678`'
explode: false
in: query
name: tagIds
schema:
items:
type: string
type: array
style: form
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/TachographVehicleFilesResponse'
description: List of all vehicle tachograph files in a specified time range.
default:
content:
application/json:
schema:
$ref: '#/components/schemas/standardErrorResponse'
description: Error response
summary: Get Tachograph Vehicle Files
tags:
- Files
components:
schemas:
TachographDriverFilesResponse:
description: List of all driver tachograph files in a specified time range.
properties:
data:
$ref: '#/components/schemas/TachographDriverFileData'
pagination:
$ref: '#/components/schemas/paginationResponse'
type: object
TachographDriverFileData:
items:
$ref: '#/components/schemas/TachographDriverFileListWrapper'
type: array
standardErrorResponse:
description: Error response
properties:
message:
description: The message of the error.
example: An error has occurred.
type: string
requestId:
description: The ID of the request.
example: 8916e1c1
type: string
type: object
TachographVehicleFilesResponse:
description: List of all vehicle tachograph files in a specified time range.
properties:
data:
$ref: '#/components/schemas/TachographVehicleFileData'
pagination:
$ref: '#/components/schemas/paginationResponse'
type: object
TachographDriverFile:
description: Tachograph driver file
properties:
cardNumber:
description: Tachograph card number associated with the file.
example: '1000000492436002'
type: string
createdAtTime:
description: Creation time of files in RFC 3339 format. This is either the download time from the tachograph itself (for files downloaded via Samsara VG) or upload time (for files manually uploaded via Samsara UI).
example: 2020-01-02T15:04:05Z07:00
type: string
id:
description: ID of the file.
example: 4aff772c-a7bb-45e6-8e41-6a53e34feb83
type: string
url:
description: A temporary URL which can be used to download the file. The link can be used multiple times and expires after an hour.
example: https://samsara-tachograph-files.s3.us-west-2.amazonaws.com/123/456/789/4aff772c-a7bb-45e6-8e41-6a53e34feb83.ddd
type: string
type: object
TachographVehicleFileData:
items:
$ref: '#/components/schemas/TachographVehicleFileListWrapper'
type: array
TachographDriverFileListWrapper:
properties:
driver:
$ref: '#/components/schemas/driverTinyResponse'
files:
$ref: '#/components/schemas/TachographDriverFileList'
type: object
driverTinyResponse:
description: A minified driver object.
properties:
id:
description: ID of the driver.
example: '88668'
type: string
name:
description: Name of the driver.
example: Susan Bob
type: string
type: object
TachographDriverFileList:
description: List of all tachograph driver files in a specified time range.
items:
$ref: '#/components/schemas/TachographDriverFile'
type: array
TachographVehicleFile:
description: Tachograph vehicle file
properties:
createdAtTime:
description: Creation time of files in RFC 3339 format. This is either the download time from the tachograph itself (for files downloaded via Samsara VG) or upload time (for files manually uploaded via Samsara UI).
example: 2020-01-02T15:04:05Z07:00
type: string
id:
description: ID of the file.
example: 4aff772c-a7bb-45e6-8e41-6a53e34feb83
type: string
url:
description: A temporary URL which can be used to download the file. The link can be used multiple times and expires after an hour.
example: https://samsara-tachograph-files.s3.us-west-2.amazonaws.com/123/456/789/4aff772c-a7bb-45e6-8e41-6a53e34feb83.ddd
type: string
vehicleIdentificationNumber:
description: VIN associated with the vehicle file.
example: '1000000492436002'
type: string
type: object
TachographVehicleFileListWrapper:
properties:
files:
$ref: '#/components/schemas/TachographVehicleFileList'
vehicle:
$ref: '#/components/schemas/vehicleTinyResponse'
type: object
TachographVehicleFileList:
description: List of all tachograph vehicle files in a specified time range.
items:
$ref: '#/components/schemas/TachographVehicleFile'
type: array
vehicleTinyResponse:
description: A minified vehicle object.
properties:
ExternalIds:
additionalProperties:
type: string
description: The [external IDs](https://developers.samsara.com/docs/external-ids) for the given object.
example:
maintenanceId: '250020'
payrollId: ABFS18600
type: object
id:
description: ID of the vehicle.
example: '123456789'
type: string
name:
description: Name of the vehicle.
example: 'Midwest Truck #4'
type: string
type: object
paginationResponse:
description: Pagination parameters.
properties:
endCursor:
description: Cursor identifier representing the last element in the response. This value should be used in conjunction with a subsequent request's 'after' query parameter. This may be an empty string if there are no more pages left to view.
example: MjkY
format: string
type: string
hasNextPage:
description: True if there are more pages of results immediately available after this endCursor.
example: true
type: boolean
required:
- endCursor
- hasNextPage
type: object
securitySchemes:
AccessTokenHeader:
type: http
scheme: bearer
x-original-swagger-version: '2.0'
x-readme:
explorer-enabled: true
proxy-enabled: true