
Samsara MCP
io.github.AutomationSquadOS由 GitHub 账号 AutomationSquadOS 发布v1.0.0-beta.1更新于 Oct 24, 2026
Samsara fleet management — vehicles, routes, drivers, HOS compliance. Unofficial, bring your token.
概览
非官方的 Samsara 车队管理集成,让助手读取和管理车辆、路线、司机、HOS 合规、地址、Webhook 与联系人。
- 可以做什么
- 通过 21 个工具把助手连接到 Samsara 车队管理 API,覆盖车辆、路线、司机、地址、Webhook 和联系人。车辆工具可列出车辆、详情、实时位置和统计;路线工具可创建、更新、删除、列出并优化路线,更新时保留站点 ID。司机工具涵盖详情、工时(HOS)合规跟踪和安全事件。还内置限流、重试和路线优化。
- 适用场景
- 适合希望用对话方式操作 Samsara 车队数据的场景:创建并优化配送路线、查看车辆实时位置,或检查司机 HOS 日志与安全事件。适合已经在使用 Samsara、想快速获得助手入口而不自行开发 API 集成的团队。
- 运行要求
- 以 stdio 方式在本地运行,面向 Claude Desktop 等桌面客户端。需要 Node.js 18+,且因 npm 包尚未发布,只能克隆仓库后自行构建安装。需要 Samsara API 令牌,放在 SAMSARA_API_TOKEN 中,可选 SAMSARA_BASE_URL(欧盟客户使用欧盟端点)。需要访问 Samsara API 的网络。
安装
在 SourceWeft 中
- 打开 控制台中的 Samsara MCP,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
Automation Squad - MCP for Samsara
Complete Samsara Fleet Management integration for Claude AI
21 tools | Expert knowledge built-in | Beta
⚠️ Important Disclaimer
UNOFFICIAL INTEGRATION: This is an unofficial third-party MCP server. It is:
- ❌ NOT affiliated with, endorsed by, or sponsored by Samsara Inc.
- ❌ NOT an official Samsara product
- ✅ Built using Samsara's public API with your own API credentials
- ✅ Fully compliant with Samsara's API terms of service
Samsara® is a registered trademark of Samsara Inc.
See NOTICE for the full third-party disclaimer. Licence: MIT.
🎯 What This Does
Connects Claude AI to the Samsara Fleet Management API with:
✅ 21 tools across vehicles, routes, drivers, addresses, webhooks and contacts
✅ Expert knowledge built into every tool description
✅ Automatic state preservation (stop IDs, route data)
✅ Smart rate limiting (won't hit API limits)
✅ Route optimization (built-in efficiency algorithms)
✅ Production best practices (error handling, retries)
Tools Included
Vehicle Management (4 tools)
- List vehicles, get vehicle details, real-time locations, statistics
Route Management (6 tools) ⭐ Our specialty
- Create, update, delete routes
- Auto-preserve stop state (critical for time tracking!)
- Route optimization (minimize distance/time)
- List and get route details
Driver Management (4 tools)
- List drivers, get driver details
- Hours of Service (HOS) compliance tracking
- Safety event monitoring
Address & Location (2 tools)
- Create and manage saved addresses
- Geofence integration
Webhook Integration (3 tools)
- Real-time event notifications
- Route updates, vehicle events, etc.
Contact Management (2 tools)
- Create and manage contacts for route stops
🚀 Quick Start
Prerequisites
- Node.js 18+ installed
- Samsara API Token (Get one here)
- Claude Desktop or any MCP-compatible client
Installation
Note: the npm package
@automationsquad/mcp-samsarais not published yet, so clone-and-build is the only install path that works today. When it ships, annpxone-liner will replace the steps above.
Configuration
Add to your Claude Desktop config file:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
Replace /absolute/path/to/mcp-samsara with wherever you cloned the repo. The path must
be absolute — Claude Desktop does not resolve ~ or relative paths.
EU customers: Use https://api.eu.samsara.com for SAMSARA_BASE_URL
Restart Claude
Quit and reopen Claude Desktop. You should see the Samsara tools available!
💡 Example Usage
Create a route with optimization
Claude will:
- Create the route with proper addresses
- Automatically optimize stop order
- Preserve all stop IDs for tracking
- Assign vehicle/driver if requested
Track vehicle locations
Monitor driver compliance
🔥 What Makes This Better
vs. Building Direct API Integration
vs. Official MCP (if one existed)
🛠️ Architecture
Rate Limiting
Conservative 5 requests/second with automatic throttling and retry logic.
Error Handling
- Automatic retry on 429 (rate limit)
- Clear error messages
- Graceful degradation
State Preservation
Critical feature: When updating routes, we automatically:
- Fetch existing route
- Extract stop IDs
- Preserve them in updates
- Prevent data loss
This is a best practice that prevents losing arrival/departure times.
📚 Documentation
Environment Variables
Tool Naming Convention
All tools are prefixed with samsara_ for clarity:
samsara_list_vehiclessamsara_create_routesamsara_get_driver_hos- etc.
🤝 TMS Integration
Use externalIds in routes/vehicles/drivers to link with your TMS:
Then query by external ID:
🐛 Troubleshooting
"Error: SAMSARA_API_TOKEN environment variable is required"
Set your API token in the Claude config file (see Configuration above).
"Samsara API error (401): Unauthorized"
Your API token is invalid or expired. Generate a new one in Samsara dashboard.
"Samsara API error (429): Too Many Requests"
The MCP will automatically retry. If you see this often, you may have other integrations hitting the API.
Tools not showing in Claude
- Check config file syntax (valid JSON)
- Restart Claude completely (quit and reopen)
- Check Claude logs for errors
📦 What's Included
🔐 Security
- Your credentials stay local - API token is stored on your machine
- No data collection - We don't see your Samsara data
- Open source - Review the code yourself
- No phone-home - MCP runs entirely locally
📈 Roadmap
- Add more tools (dispatch, assets, tags)
- Support for batch operations
- Enhanced optimization algorithms
- Multi-route optimization
- Fuel cost calculations
- Compliance reporting tools
🎓 Learn More
💬 Support
Beta Users:
- Join the Automation Squad community
- Email: [email protected]
- GitHub Issues: Report a bug
📝 License
MIT License - See LICENSE file for details
🙏 Credits
Built with ❤️ by Automation Squad
Not affiliated with Samsara Inc. This is an independent integration using Samsara's public API.
⭐ More from Automation Squad
Docs, install steps and what this server does not do: automationsquad.com/mcp/samsara
The AI Five — five things worth knowing about AI and automation, weekly. Subscribe free →
Ready to automate your fleet management? Let's go! 🚀
来源:README.md,提交 aa91fa0
工具
0版本历史
1- v1.0.0-beta.1最新Sep 16, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分