[beta] Update a route template
Update an existing route template by its unique identifier. Only the fields provided in the request body are changed.
<b>Rate limit:</b> 5 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 Write Routes under the Driver Workflow 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.
Request
- Base URLhttps://api.samsara.com
- AuthHTTP bearer
Query parameters
The unique identifier of the route template to update.
Request body
Example request
{
"defaultDepotEndExternalId": "DEPOT-001",
"defaultDepotStartExternalId": "DEPOT-001",
"defaultStartTimeOfDay": "08:00",
"locationsByExternalIds": [
"LOC-123",
"LOC-123",
"LOC-123",
"LOC-123"
],
"name": "Downtown Delivery Route"
}Response
OK response.
Example response
{
"data": {
"createdAtTime": "2024-01-15T10:30:00Z",
"defaultDepotEnd": {
"externalId": "DEPOT-001",
"formattedAddress": "123 Industrial Blvd, Los Angeles, CA 90210, US",
"id": "750e8400-e29b-41d4-a716-446655440002",
"latitude": 34.0522,
"longitude": -118.2437,
"name": "Main Warehouse"
},
"defaultDepotStart": {
"externalId": "DEPOT-001",
"formattedAddress": "123 Industrial Blvd, Los Angeles, CA 90210, US",
"id": "750e8400-e29b-41d4-a716-446655440002",
"latitude": 34.0522,
"longitude": -118.2437,
"name": "Main Warehouse"
},
"defaultStartTimeOfDay": "08:00",
"distanceMeters": 15000,
"durationSeconds": 3600,
"hubId": "550e8400-e29b-41d4-a716-446655440000",
"hubTimezone": "America/Los_Angeles",
"id": "660e8400-e29b-41d4-a716-446655440001",
"locations": [
{
"externalId": "LOC-123",
"formattedAddress": "456 Main St, Los Angeles, CA 90210, US",
"latitude": 34.0522,
"longitude": -118.2437,
"name": "Customer ABC Warehouse",
"position": 1
}
],
"name": "Downtown Delivery Route",
"updatedAtTime": "2024-01-15T12:00:00Z"
}
}Changes
No recorded changes to this operation across all 1 revision of this API.