Method: selection.v1.projects.selectedRoutes.batchCreate

Creates multiple SelectedRoute resources and starts a schedule to periodically retrieve cache information for each of the routes.

HTTP request

POST https://roads.googleapis.com/selection/v1/{parent=projects/*}/selectedRoutes:batchCreate

The URL uses gRPC Transcoding syntax.

Path parameters

Parameters
parent

string

Required. The project resource shared by all selected routes in the batch. It's required because the batch request supports only a single parent. Format: projects/{project}

Request body

The request body contains data with the following structure:

JSON representation
{
  "requests": [
    {
      object (CreateSelectedRouteRequest)
    }
  ]
}
Fields
requests[]

object (CreateSelectedRouteRequest)

Required. The request message specifying the selected route to create. A maximum of 1,000 selected routes can be created in a batch. The parent resource of each request must either be empty or match the top-level parent.

Response body

Response from creating multiple SelectedRoutes.

If successful, the response body contains data with the following structure:

JSON representation
{
  "selectedRoutes": [
    {
      object (SelectedRoute)
    }
  ]
}
Fields
selectedRoutes[]

object (SelectedRoute)

SelectedRoute resources created.

Authorization scopes

Requires the following OAuth scope:

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

IAM Permissions

Requires the following IAM permission on the parent resource:

  • roads.selectedRoutes.batchCreate

For more information, see the IAM documentation.

CreateSelectedRouteRequest

Request to create a SelectedRoute.

JSON representation
{
  "parent": string,
  "selectedRoute": {
    object (SelectedRoute)
  },
  "selectedRouteId": string
}
Fields
parent

string

Required. The project that the SelectedRoute will be created under. Format: projects/{project}

selectedRoute

object (SelectedRoute)

Required. The SelectedRoute to create.

selectedRouteId

string

Optional. The ID to use for the SelectedRoute, which will become the final component of the SelectedRoute's resource name.

This value should be 4-63 characters, and valid characters are "a-z", "A-Z", "0-9", or "-". If it is not provided or empty, a UUID will be generated after resource creation.