@maxim_mazurok/gapi.client.admin-directory_v1 0.0.20231128 → 0.0.20240102

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/index.d.ts +118 -2
  2. package/package.json +1 -1
  3. package/readme.md +1 -1
package/index.d.ts CHANGED
@@ -9,7 +9,7 @@
9
9
  // This file was generated by https://github.com/Maxim-Mazurok/google-api-typings-generator. Please do not edit it manually.
10
10
  // In case of any problems please post issue to https://github.com/Maxim-Mazurok/google-api-typings-generator
11
11
  // Generated from: https://admin.googleapis.com/$discovery/rest?version=directory_v1
12
- // Revision: 20231128
12
+ // Revision: 20240102
13
13
 
14
14
  /// <reference types="gapi.client" />
15
15
 
@@ -72,6 +72,18 @@ declare namespace gapi.client {
72
72
  /** Message severity */
73
73
  severity?: string;
74
74
  }
75
+ interface BatchChangeChromeOsDeviceStatusRequest {
76
+ /** Required. The action to take on the ChromeOS device in order to change its status. */
77
+ changeChromeOsDeviceStatusAction?: string;
78
+ /** 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. */
79
+ deprovisionReason?: string;
80
+ /** Required. List of the IDs of the ChromeOS devices to change. Maximum 50. */
81
+ deviceIds?: string[];
82
+ }
83
+ interface BatchChangeChromeOsDeviceStatusResponse {
84
+ /** The results for each of the ChromeOS devices provided in the request. */
85
+ changeChromeOsDeviceStatusResults?: ChangeChromeOsDeviceStatusResult[];
86
+ }
75
87
  interface BatchCreatePrintersRequest {
76
88
  /** A list of Printers to be created. Max 50 at a time. */
77
89
  requests?: CreatePrinterRequest[];
@@ -204,6 +216,15 @@ declare namespace gapi.client {
204
216
  /** The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results. */
205
217
  nextPageToken?: string;
206
218
  }
219
+ interface ChangeChromeOsDeviceStatusResult {
220
+ /** The unique ID of the ChromeOS device. */
221
+ deviceId?: string;
222
+ /** The error result of the operation in case of failure. */
223
+ error?: Status;
224
+ /** The device could change its status successfully. */
225
+ response?: any;
226
+ }
227
+ interface ChangeChromeOsDeviceStatusSucceeded {}
207
228
  interface Channel {
208
229
  /** The address where notifications are delivered for this channel. */
209
230
  address?: string;
@@ -1032,6 +1053,14 @@ declare namespace gapi.client {
1032
1053
  /** A list of UserSchema objects. */
1033
1054
  schemas?: Schema[];
1034
1055
  }
1056
+ interface Status {
1057
+ /** The status code, which should be an enum value of google.rpc.Code. */
1058
+ code?: number;
1059
+ /** A list of messages that carry the error details. There is a common set of message types for APIs to use. */
1060
+ details?: Array<{[P in string]: any}>;
1061
+ /** 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. */
1062
+ message?: string;
1063
+ }
1035
1064
  interface Token {
1036
1065
  /** Whether the application is registered with Google. The value is `true` if the application has an anonymous Client ID. */
1037
1066
  anonymous?: boolean;
@@ -1521,6 +1550,64 @@ declare namespace gapi.client {
1521
1550
  }): Request<DirectoryChromeosdevicesCommand>;
1522
1551
  }
1523
1552
  interface ChromeosResource {
1553
+ /** Changes the status of a batch of ChromeOS devices. For more information about changing a ChromeOS device state [Repair, repurpose, or retire ChromeOS devices](https://support.google.com/chrome/a/answer/3523633). */
1554
+ batchChangeStatus(request: {
1555
+ /** V1 error format. */
1556
+ '$.xgafv'?: string;
1557
+ /** OAuth access token. */
1558
+ access_token?: string;
1559
+ /** Data format for response. */
1560
+ alt?: string;
1561
+ /** JSONP */
1562
+ callback?: string;
1563
+ /** Required. Immutable ID of the Google Workspace account. */
1564
+ customerId: string;
1565
+ /** Selector specifying which fields to include in a partial response. */
1566
+ fields?: string;
1567
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
1568
+ key?: string;
1569
+ /** OAuth 2.0 token for the current user. */
1570
+ oauth_token?: string;
1571
+ /** Returns response with indentations and line breaks. */
1572
+ prettyPrint?: boolean;
1573
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
1574
+ quotaUser?: string;
1575
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
1576
+ upload_protocol?: string;
1577
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
1578
+ uploadType?: string;
1579
+ /** Request body */
1580
+ resource: BatchChangeChromeOsDeviceStatusRequest;
1581
+ }): Request<BatchChangeChromeOsDeviceStatusResponse>;
1582
+ batchChangeStatus(
1583
+ request: {
1584
+ /** V1 error format. */
1585
+ '$.xgafv'?: string;
1586
+ /** OAuth access token. */
1587
+ access_token?: string;
1588
+ /** Data format for response. */
1589
+ alt?: string;
1590
+ /** JSONP */
1591
+ callback?: string;
1592
+ /** Required. Immutable ID of the Google Workspace account. */
1593
+ customerId: string;
1594
+ /** Selector specifying which fields to include in a partial response. */
1595
+ fields?: string;
1596
+ /** API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token. */
1597
+ key?: string;
1598
+ /** OAuth 2.0 token for the current user. */
1599
+ oauth_token?: string;
1600
+ /** Returns response with indentations and line breaks. */
1601
+ prettyPrint?: boolean;
1602
+ /** Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. */
1603
+ quotaUser?: string;
1604
+ /** Upload protocol for media (e.g. "raw", "multipart"). */
1605
+ upload_protocol?: string;
1606
+ /** Legacy upload protocol for media (e.g. "media", "multipart"). */
1607
+ uploadType?: string;
1608
+ },
1609
+ body: BatchChangeChromeOsDeviceStatusRequest
1610
+ ): Request<BatchChangeChromeOsDeviceStatusResponse>;
1524
1611
  /** Issues a command for the device to execute. */
1525
1612
  issueCommand(request: {
1526
1613
  /** V1 error format. */
@@ -2345,6 +2432,18 @@ declare namespace gapi.client {
2345
2432
  /** Message severity */
2346
2433
  severity?: string;
2347
2434
  }
2435
+ interface BatchChangeChromeOsDeviceStatusRequest {
2436
+ /** Required. The action to take on the ChromeOS device in order to change its status. */
2437
+ changeChromeOsDeviceStatusAction?: string;
2438
+ /** 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. */
2439
+ deprovisionReason?: string;
2440
+ /** Required. List of the IDs of the ChromeOS devices to change. Maximum 50. */
2441
+ deviceIds?: string[];
2442
+ }
2443
+ interface BatchChangeChromeOsDeviceStatusResponse {
2444
+ /** The results for each of the ChromeOS devices provided in the request. */
2445
+ changeChromeOsDeviceStatusResults?: ChangeChromeOsDeviceStatusResult[];
2446
+ }
2348
2447
  interface BatchCreatePrintersRequest {
2349
2448
  /** A list of Printers to be created. Max 50 at a time. */
2350
2449
  requests?: CreatePrinterRequest[];
@@ -2477,6 +2576,15 @@ declare namespace gapi.client {
2477
2576
  /** The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results. */
2478
2577
  nextPageToken?: string;
2479
2578
  }
2579
+ interface ChangeChromeOsDeviceStatusResult {
2580
+ /** The unique ID of the ChromeOS device. */
2581
+ deviceId?: string;
2582
+ /** The error result of the operation in case of failure. */
2583
+ error?: Status;
2584
+ /** The device could change its status successfully. */
2585
+ response?: any;
2586
+ }
2587
+ interface ChangeChromeOsDeviceStatusSucceeded {}
2480
2588
  interface Channel {
2481
2589
  /** The address where notifications are delivered for this channel. */
2482
2590
  address?: string;
@@ -3305,6 +3413,14 @@ declare namespace gapi.client {
3305
3413
  /** A list of UserSchema objects. */
3306
3414
  schemas?: Schema[];
3307
3415
  }
3416
+ interface Status {
3417
+ /** The status code, which should be an enum value of google.rpc.Code. */
3418
+ code?: number;
3419
+ /** A list of messages that carry the error details. There is a common set of message types for APIs to use. */
3420
+ details?: Array<{[P in string]: any}>;
3421
+ /** 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. */
3422
+ message?: string;
3423
+ }
3308
3424
  interface Token {
3309
3425
  /** Whether the application is registered with Google. The value is `true` if the application has an anonymous Client ID. */
3310
3426
  anonymous?: boolean;
@@ -3792,7 +3908,7 @@ declare namespace gapi.client {
3792
3908
  }): Request<Asps>;
3793
3909
  }
3794
3910
  interface ChromeosdevicesResource {
3795
- /** Takes an action that affects a Chrome OS Device. This includes deprovisioning, disabling, and re-enabling devices. *Warning:* * Deprovisioning a device will stop device policy syncing and remove device-level printers. After a device is deprovisioned, it must be wiped before it can be re-enrolled. * Lost or stolen devices should use the disable action. * Re-enabling a disabled device will consume a device license. If you do not have sufficient licenses available when completing the re-enable action, you will receive an error. For more information about deprovisioning and disabling devices, visit the [help center](https://support.google.com/chrome/a/answer/3523633). */
3911
+ /** Use [BatchChangeChromeOsDeviceStatus](/admin-sdk/directory/reference/rest/v1/customer.devices.chromeos/batchChangeStatus) instead. Takes an action that affects a Chrome OS Device. This includes deprovisioning, disabling, and re-enabling devices. *Warning:* * Deprovisioning a device will stop device policy syncing and remove device-level printers. After a device is deprovisioned, it must be wiped before it can be re-enrolled. * Lost or stolen devices should use the disable action. * Re-enabling a disabled device will consume a device license. If you do not have sufficient licenses available when completing the re-enable action, you will receive an error. For more information about deprovisioning and disabling devices, visit the [help center](https://support.google.com/chrome/a/answer/3523633). */
3796
3912
  action(request: {
3797
3913
  /** V1 error format. */
3798
3914
  '$.xgafv'?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maxim_mazurok/gapi.client.admin-directory_v1",
3
- "version": "0.0.20231128",
3
+ "version": "0.0.20240102",
4
4
  "description": "TypeScript typings for Admin SDK API directory_v1",
5
5
  "repository": {
6
6
  "type": "git",
package/readme.md CHANGED
@@ -176,7 +176,7 @@ Stops watching resources through this channel.
176
176
  await gapi.client.admin.channels.stop({});
177
177
 
178
178
  /*
179
- Takes an action that affects a Chrome OS Device. This includes deprovisioning, disabling, and re-enabling devices. *Warning:* * Deprovisioning a device will stop device policy syncing and remove device-level printers. After a device is deprovisioned, it must be wiped before it can be re-enrolled. * Lost or stolen devices should use the disable action. * Re-enabling a disabled device will consume a device license. If you do not have sufficient licenses available when completing the re-enable action, you will receive an error. For more information about deprovisioning and disabling devices, visit the [help center](https://support.google.com/chrome/a/answer/3523633).
179
+ Use [BatchChangeChromeOsDeviceStatus](/admin-sdk/directory/reference/rest/v1/customer.devices.chromeos/batchChangeStatus) instead. Takes an action that affects a Chrome OS Device. This includes deprovisioning, disabling, and re-enabling devices. *Warning:* * Deprovisioning a device will stop device policy syncing and remove device-level printers. After a device is deprovisioned, it must be wiped before it can be re-enrolled. * Lost or stolen devices should use the disable action. * Re-enabling a disabled device will consume a device license. If you do not have sufficient licenses available when completing the re-enable action, you will receive an error. For more information about deprovisioning and disabling devices, visit the [help center](https://support.google.com/chrome/a/answer/3523633).
180
180
  */
181
181
  await gapi.client.directory.chromeosdevices.action({
182
182
  customerId: 'customerId',