- [HTTP request](https://developers.google.com/maps/documentation/roads-management-insights/reference/rest/v1/selection.v1.projects.selectedRoutes/patch#body.HTTP_TEMPLATE)
- [Path parameters](https://developers.google.com/maps/documentation/roads-management-insights/reference/rest/v1/selection.v1.projects.selectedRoutes/patch#body.PATH_PARAMETERS)
- [Query parameters](https://developers.google.com/maps/documentation/roads-management-insights/reference/rest/v1/selection.v1.projects.selectedRoutes/patch#body.QUERY_PARAMETERS)
- [Request body](https://developers.google.com/maps/documentation/roads-management-insights/reference/rest/v1/selection.v1.projects.selectedRoutes/patch#body.request_body)
- [Response body](https://developers.google.com/maps/documentation/roads-management-insights/reference/rest/v1/selection.v1.projects.selectedRoutes/patch#body.response_body)
- [Authorization scopes](https://developers.google.com/maps/documentation/roads-management-insights/reference/rest/v1/selection.v1.projects.selectedRoutes/patch#body.aspect)
- [IAM Permissions](https://developers.google.com/maps/documentation/roads-management-insights/reference/rest/v1/selection.v1.projects.selectedRoutes/patch#body.aspect_1)

Updates a SelectedRoute as specified by its name.

### HTTP request

`PATCH https://roads.googleapis.com/selection/v1/{selectedRoute.name=projects/*/selectedRoutes/*}`

The URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.

### Path parameters

| Parameters ||
|---|---|
| `selectedRoute.name` | `string` Identifier. Resource name of the `SelectedRoute`. Format: projects/{project}/selectedRoutes/{selectedRoute} |

### Query parameters

| Parameters ||
|---|---|
| `updateMask` | ``string (`https://protobuf.dev/reference/protobuf/google.protobuf#field-mask` format)`` Optional. The list of fields to update. Field paths are relative to `SelectedRoute`. You should only update `displayName`, `routeAttributes`, `dynamicRouting`, and `https://developers.google.com/maps/documentation/roads-management-insights/reference/rest/v1/selection.v1.projects.selectedRoutes#SelectedRoute.FIELDS.dynamic_route` (including `origin`, `destination`, and `intermediates`). Example: `"displayName,routeAttributes,dynamicRouting,dynamicRoute"`. If `*` is specified, a full replacement for all updatable fields is performed. If `updateMask` is omitted, all updatable fields that are populated in `selectedRoute` are implied to be updated. |

### Request body

The request body contains an instance of `https://developers.google.com/maps/documentation/roads-management-insights/reference/rest/v1/selection.v1.projects.selectedRoutes#SelectedRoute`.

### Response body

If successful, the response body contains an instance of `https://developers.google.com/maps/documentation/roads-management-insights/reference/rest/v1/selection.v1.projects.selectedRoutes#SelectedRoute`.

### Authorization scopes

Requires the following OAuth scope:

- `https://www.googleapis.com/auth/cloud-platform`

### IAM Permissions

Requires the following [IAM](https://cloud.google.com/iam/docs) permission on the `name` resource:

- `roads.selectedRoutes.update`

For more information, see the [IAM documentation](https://cloud.google.com/iam/docs).