• Knowledge Base
    • Nothing Found
  • Knowledge Base
    Welcome to the Surfsight developer portal
    Getting Started
    Authentication
    Use Case Guides
    UI components
    React Components
    Sample Applications
    Troubleshooting
    Terminology
    API Changelog
    Firmware Changelog
    API Reference
      Surfsight API Reference
      Authentication
      Alarms
      Audit logs
      Authentication
      Device Operations
      Devices
      Drivers
      Events
        put
        Bulk configure events settings
        delete
        Delete event
        get
        Retrieve event
        get
        Retrieve file link
        get
        Retrieve list of events
        patch
        Update event review
        get
        Retrieve events settings
        put
        Set events settings
        delete
        Delete event notification recipient
        get
        Get device recipients
        put
        Update events notification recipients
        put
        Update event notification recipients in bulk
      Geofences
      Groups
      Health
      Organizations
      Partner Operation Statistics
      Partners
      Recordings
      Streaming
      Telemetry
      Users
      Virtual Event
      Webhooks

Retrieve file link

Retrieve the link to an event file generated by the device. The URL remains active for approximately several minutes to a few hours.

This API can be used in two ways:

1. For events in a given period of time. The files can then be downloaded. All the information required for this call is available in the event object received from the GET /devices/{imei}/events call

2. For virtual events, without using the GET /devices/{imei}/events call. You need additional information, such as the virtual event configuration on your device and the IDs of the cameras connected to the device

Request
Security:
bearerAuth
path Parameters
imei
required
string (IMEI)

The IMEI of the device. The IMEI number can be found on a sticker on the device itself or on the back of the device box.

Example: 357660101000198
query Parameters
fileId
required
string (File ID)

Filter by the ID of the requested file. Obtain this from the /devices/{imei}/events call or calculate the unix timestamp (seconds from epoch) of the event (applicable only to virtual events).

Example: fileId=1595077872
fileType
required
string (File type)

Filter by the file type of the requested file. Obtain this from the /devices/{imei}/events call or set to the value of video/snapshot if the device configuration is predefined.

Enum: "video" "snapshot"
cameraId
required
string

Filter by the ID of the in-cab or road-facing lens, or any paired auxiliary camera for the requested file. Obtain this from the /devices/{imei}/events call or set to the ID of the desired view if the configuration of the device is predefined: 1 - road-facing lens, 2 - in-cab lens, 50+ - auxiliary cameras.

Example: cameraId=1
Responses
200

Successful operation

400

Bad request error

401

Unauthorized error

403

Forbidden error

404

Not found error

500

Internal server error

get/devices/{imei}/event-file-link
Request samples
  • curl
  • JavaScript
  • Node.js
curl -i -X GET \
  'https://api-prod.surfsight.net/v2/devices/:imei/event-file-link?fileId=1595077872&fileType=video&cameraId=1' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'
Response samples
  • 200
  • 400
  • 401
  • 403
  • 404
  • 500
  • 1 more
    500
application/json
{
  • "data": {
    • "url": "https://sample.s3.aws.com/123/123.mp4?access_key=1234"
    }
}
Portals
  • User Interface - U.S. Customers
  • User Interface - E.U. Customers
  • Partner Portal - U.S. Partners
  • Partner Portal - E.U. Partners
Legal
  • Privacy Policy
  • Warranty
  • EULA
  • DPA
  • Driver Information
  • Safety Warnings
Social Media
  • Facebook
  • Twitter
  • YouTube
  • LinkedIn
  • Instagram
Contact Us
  • View and Subscribe to Notifications
  • Open a Ticket
  • Send an Email
© 2022 Lytx, Inc. All right reserved