Method: networks.sites.batchCreate

  • This API allows for the batch creation of Site objects using an HTTP POST request.

  • The request requires a parent path parameter specifying the network code and a request body containing a list of CreateSiteRequest objects.

  • The response body contains a list of the successfully created Site objects.

  • The API requires the https://www.googleapis.com/auth/admanager OAuth scope for authorization.

API to batch create Site objects.

HTTP request

POST https://admanager.googleapis.com/v1/{parent}/sites:batchCreate

Path parameters

Parameters
parent

string

Required. The parent resource where Sites will be created. Format: networks/{networkCode} The parent field in the CreateSiteRequest must match this field.

Request body

The request body contains data with the following structure:

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

object (CreateSiteRequest)

Required. The Site objects to create. A maximum of 100 objects can be created in a batch.

Response body

Response object for sites.batchCreate method.

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

JSON representation
{
  "sites": [
    {
      object (Site)
    }
  ]
}
Fields
sites[]

object (Site)

The Site objects created.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/admanager

For more information, see the OAuth 2.0 Overview.

CreateSiteRequest

Request object for sites.create method.

JSON representation
{
  "parent": string,
  "site": {
    object (Site)
  }
}
Fields
parent

string

Required. The parent resource where this Site will be created. Format: networks/{networkCode}

site

object (Site)

Required. The Site to create.