Method: customer.devices.chromeos.batchChangeStatus

Changes the status of a batch of ChromeOS devices. For more information about changing a ChromeOS device state Repair, repurpose, or retire ChromeOS devices.

HTTP request

POST https://admin.googleapis.com/admin/directory/v1/customer/{customerId}/devices/chromeos:batchChangeStatus

The URL uses gRPC Transcoding syntax.

Path parameters

Parameters
customerId

string

Required. Immutable ID of the Google Workspace account.

Request body

The request body contains data with the following structure:

JSON representation
{
  "deviceIds": [
    string
  ],
  "changeChromeOsDeviceStatusAction": enum (ChangeChromeOsDeviceStatusAction),
  "deprovisionReason": enum (DeprovisionReason)
}
Fields
deviceIds[]

string

Required. List of the IDs of the ChromeOS devices to change. Maximum 50.

changeChromeOsDeviceStatusAction

enum (ChangeChromeOsDeviceStatusAction)

Required. The action to take on the ChromeOS device in order to change its status.

deprovisionReason

enum (DeprovisionReason)

Optional. The reason behind a device deprovision. Must be provided if 'changeChromeOsDeviceStatusAction' is set to 'CHANGE_CHROME_OS_DEVICE_STATUS_ACTION_DEPROVISION'. Otherwise, omit this field.

Response body

The response of changing the status of a batch of ChromeOS devices.

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

JSON representation
{
  "changeChromeOsDeviceStatusResults": [
    {
      object (ChangeChromeOsDeviceStatusResult)
    }
  ]
}
Fields
changeChromeOsDeviceStatusResults[]

object (ChangeChromeOsDeviceStatusResult)

The results for each of the ChromeOS devices provided in the request.

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/admin.directory.device.chromeos

For more information, see the Authorization guide.

ChangeChromeOsDeviceStatusAction

The action to perform in order to change the status of a ChromeOS device.

Enums
CHANGE_CHROME_OS_DEVICE_STATUS_ACTION_UNSPECIFIED Default value. Value is unused.
CHANGE_CHROME_OS_DEVICE_STATUS_ACTION_DEPROVISION Deprovisions a ChromeOS device. If you have ChromeOS devices that are no longer being used in your organization, you should deprovision them so that you’re no longer managing them. Deprovisioning the device removes all policies that were on the device as well as device-level printers and the ability to use the device as a kiosk. Depending on the upgrade that’s associated with the device this action might release the license back into the license pool; which allows you to use the license on a different device.
CHANGE_CHROME_OS_DEVICE_STATUS_ACTION_DISABLE Disables a ChromeOS device. Use this action if a user loses their device or it’s stolen, this makes it such that the device is still managed, so it will still receive policies, but no one can use it. Depending on the upgrade that’s associated with the device this action might release the license back into the license pool; which allows you to use the license on a different device.
CHANGE_CHROME_OS_DEVICE_STATUS_ACTION_REENABLE Reenables a ChromeOS device to be used after being disabled. Reenables the device once it's no longer lost or it's been recovered. This allows the device to be used again. Depending on the upgrade associated with the device this might consume one license from the license pool, meaning that if there aren't enough licenses available the operation will fail.

ChangeChromeOsDeviceStatusResult

The result of a single ChromeOS device for a Change state operation.

JSON representation
{
  "deviceId": string,

  // Union field result can be only one of the following:
  "error": {
    object (Status)
  },
  "response": {
    object (ChangeChromeOsDeviceStatusSucceeded)
  }
  // End of list of possible types for union field result.
}
Fields
deviceId

string

The unique ID of the ChromeOS device.

Union field result.

result can be only one of the following:

error

object (Status)

The error result of the operation in case of failure.

response

object (ChangeChromeOsDeviceStatusSucceeded)

The device could change its status successfully.

Status

The Status type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by gRPC. Each Status message contains three pieces of data: error code, error message, and error details.

You can find out more about this error model and how to work with it in the API Design Guide.

JSON representation
{
  "code": integer,
  "message": string,
  "details": [
    {
      "@type": string,
      field1: ...,
      ...
    }
  ]
}
Fields
code

integer

The status code, which should be an enum value of google.rpc.Code.

message

string

A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.

details[]

object

A list of messages that carry the error details. There is a common set of message types for APIs to use.

An object containing fields of an arbitrary type. An additional field "@type" contains a URI identifying the type. Example: { "id": 1234, "@type": "types.example.com/standard/id" }.

ChangeChromeOsDeviceStatusSucceeded

This type has no fields.

Response for a successful ChromeOS device status change.