Fleet

/fleet/locations

Get current location of vehicles.

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

To use this endpoint, select Read Vehicle Statistics under the Vehicles 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>

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.

get/v1/fleet/locations

Request

  • Base URL
    https://api.samsara.com
  • Auth
    HTTP bearer

Query parameters

afterstring

Pagination parameter indicating the cursor position to continue returning results after. Used in conjunction with the 'limit' parameter.

limitinteger

Pagination parameter indicating the number of results to return in this request. Used in conjunction with 'after'.

vehicleIdsstring[]

A comma-separated list of vehicle IDs. Example: vehicleIds=1000,1001

tagIdsstring[]

A comma-separated list of tag IDs. Example: tagIds=1000,1001

Response

OK response.

Example response

{
  "pagination": {
    "endCursor": "MTA1MDc5MB==",
    "hasNextPage": true
  },
  "vehicles": [
    {
      "driverId": 1,
      "heading": 246.42,
      "id": 112,
      "latitude": 123.456,
      "location": "1 Main St, Dallas, TX",
      "longitude": 32.897,
      "name": "Truck A7",
      "odometerMeters": 71774705,
      "odometerType": "GPS",
      "onTrip": true,
      "routeIds": [
        2244514,
        2311654
      ],
      "speed": 64.37,
      "time": 1462881998034,
      "vin": "JTNBB46KX73011966"
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.