Skip to main content
GET
/
cameras
/
media
List uploaded media by time range.
curl --request GET \
  --url https://api.samsara.com/cameras/media \
  --header 'Authorization: Bearer <token>'
{
  "data": {
    "media": [
      {
        "availableAtTime": "2019-11-11T14:00:12-04:00",
        "endTime": "2019-06-13T19:08:25Z",
        "input": "dashcamForwardFacing",
        "mediaType": "image",
        "startTime": "2019-06-13T19:08:25Z",
        "triggerReason": "api",
        "vehicleId": "1234",
        "cameraRole": "leftMirrorMount",
        "urlInfo": {
          "url": "https://sample.s3.url.com/image.jpeg",
          "urlExpiryTime": "2019-11-11T14:00:12-04:00"
        }
      }
    ]
  },
  "pagination": {
    "endCursor": "MjkY",
    "hasNextPage": true
  }
}

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.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

vehicleIds
string
required

A filter on the data based on this comma-separated list of vehicle IDs and externalIds. You can specify up to 20 vehicles. Example: vehicleIds=1234,5678,samsara.vin:1HGBH41JXMN109186

inputs
enum<string>[]

An optional list of desired camera inputs for which to return captured media. If empty, media for all available inputs will be returned.

Available options:
dashcamRoadFacing,
dashcamDriverFacing,
analog1,
analog2,
analog3,
analog4
mediaTypes
enum<string>[]

An optional list of desired media types for which to return captured media. If empty, media for all available media types will be returned. Possible options include: image, videoHighRes.

Available options:
image,
videoHighRes
triggerReasons
enum<string>[]

An optional list of desired trigger reasons for which to return captured media. If empty, media for all available trigger reasons will be returned. Possible options include: api, panicButton, periodicStill, rfidEvent, safetyEvent, tripEndStill, tripStartStill, videoRetrieval. videoRetrieval represents media captured for a dashboard video retrieval request.

Available options:
api,
panicButton,
periodicStill,
rfidEvent,
safetyEvent,
tripEndStill,
tripStartStill,
videoRetrieval
startTime
string
required

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).

endTime
string
required

An end time in RFC 3339 format. End time cannot be more than 24 hours after startTime. 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).

availableAfterTime
string

An optional timestamp in RFC 3339 format that can act as a cursor to track which media has previously been retrieved; only media whose availableAtTime comes after this parameter will be returned. Examples: 2019-06-13T19:08:25Z, 2019-06-13T19:08:25.455Z, OR 2015-09-15T14:00:12-04:00

after
string

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.

Response

OK response.

data
object
required
pagination
object
required

Pagination parameters.