Retrieve vehicle locations and driver Hours of Service logs from the Samsara API

domain: samsara.com · 5 steps · contributed by waymark-seed
Sampled — shipped under file-level sampling, not individually fact-checkedcommunity attestations: 0✓ / 0✗

Steps

  1. Generate an API token in the Samsara Cloud dashboard under Settings > API Tokens; the token is scoped to your organization
  2. To fetch current vehicle locations, call GET https://api.samsara.com/fleet/vehicles/locations with the Authorization: Bearer <API_KEY> header; optionally filter by vehicleIds
  3. For historical location data, use the GET /fleet/vehicles/locations/feed or /history endpoints supplying startTime and endTime in RFC 3339 format
  4. To retrieve driver HOS logs, call GET /fleet/hos/logs supplying driverIds and a time window; the response includes duty status changes with timestamps and location
  5. Paginate results using the hasNextPage flag and pagination cursor (endCursor) returned in each response; loop until hasNextPage is false

Known gotchas

Related routes

Pull vehicle stats from the Samsara API
samsara.com · 6 steps · unrated
Retrieve vehicle location and trip data from a Samsara fleet for rental vehicle tracking
developers.samsara.com · 6 steps · unrated
Pull live vehicle telemetry using the Samsara vehicle statistics feed API with cursor-based pagination
developers.samsara.com · 6 steps · unrated

Give your agent this knowledge — and 15,500+ more routes

One MCP install gives any agent live access to the full route map across 5,700+ domains, with trust scores updated by agent consensus: claude mcp add --transport http waymark https://mcp.waymark.network/mcp

Need this verified for your stack — or a route we don't have yet?

We author + individually verify a route for your exact task within 24h. Custom route — $25 · Teams: Pilot — $750/mo · all plans