Pipeyard

Samsara MCP Connector

Samsara
logisticsStatus: Active4.4 ratingSecurity score: 8/10Context size: Medium

Connect AI agents to Samsara for fleet management, vehicle tracking, driver safety, ELD compliance, and operations visibility.

Auth notes

API Token authentication. Generate tokens from Samsara Cloud Dashboard → Settings → API Tokens. Pass token as Authorization: Bearer {token} header. Supports granular scopes — configure read and write permissions separately per data category when generating token. Also supports OAuth 2.0 for partner integrations. Always pass X-Samsara-Version header to lock your integration to a specific API version and prevent breaking changes.

Rate limits

Global limit: 150 requests per second per API token, 200 requests per second per organization across all tokens. Per-endpoint limits also apply — HOS logs endpoint limited to 30 requests per second, Documents endpoint limited to 5 requests per second. Returns 429 with Retry-After header. Use provided Python retry script pattern with Retry-After header for graceful backoff.

Edge cases

API uses date-based versioning — always specify X-Samsara-Version header or your integration may break on version upgrades. Granular scopes must be configured correctly at token creation — requesting data outside token scope returns 403. Fleet data endpoints return driver information alongside vehicle data even if driver scope not explicitly requested. HOS (Hours of Service) data has strict compliance implications — validate data accuracy thoroughly before using in compliance workflows.

Sandbox testing

Run test calls against Samsara from Pipeyard. Try prompts below to see a simulated response; real MCP integration is coming in a future release.

Have a connector you'd like us to prioritize or a specific test flow you care about? Use the Requests page to submit new ideas.

Quick Start — curl example

curl
curl -X GET "https://api.samsara.com/fleet/vehicles?limit=10" \
  -H "Authorization: Bearer {api_token}" \
  -H "X-Samsara-Version: 2024-06-01" \
  -H "Content-Type: application/json"

Credential Setup Guide

  1. 11. Log in to Samsara Cloud at cloud.samsara.com
  2. 22. Go to Settings then API Tokens
  3. 33. Click Create API Token and configure required scopes
  4. 44. Enable read/write permissions separately per data category
  5. 55. Copy the token immediately — not shown again after creation
  6. 66. Always include X-Samsara-Version header to lock API version
  7. 77. For OAuth partner integrations go to cloud.samsara.com/oauth/apps
  8. 88. Test with GET /fleet/vehicles to verify connectivity

Example API Response

Sample data
curl
{
  "data": [
    {
      "id": "281474978006173",
      "name": "Truck 14 - Portland Route",
      "vin": "1FTFW1ET4EKF08705",
      "make": "Ford",
      "model": "F-150",
      "year": 2022,
      "licensePlate": "OR-TRK-4421",
      "fuelType": "diesel",
      "gps": {
        "latitude": 45.5051,
        "longitude": -122.675,
        "headingDegrees": 180,
        "speedMilesPerHour": 42.5,
        "time": "2025-03-13T09:15:00Z"
      },
      "engineState": "On"
    }
  ],
  "pagination": {
    "hasNextPage": false
  }
}
Samsara MCP Connector — MCP Connector | Pipeyard