@googleapis/verifiedaccess 2.0.0 → 3.1.0
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.
- package/CHANGELOG.md +18 -0
- package/build/v1.d.ts +0 -97
- package/build/v1.js.map +1 -1
- package/build/v2.d.ts +34 -109
- package/build/v2.js.map +1 -1
- package/index.ts +1 -1
- package/package.json +1 -1
- package/v1.ts +0 -97
- package/v2.ts +34 -109
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [3.1.0](https://github.com/googleapis/google-api-nodejs-client/compare/verifiedaccess-v3.0.0...verifiedaccess-v3.1.0) (2023-08-09)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* **verifiedaccess:** update the API ([d8e2234](https://github.com/googleapis/google-api-nodejs-client/commit/d8e22343e2eb2ad4112ca9c067a0e95457f81f76))
|
|
9
|
+
|
|
10
|
+
## [3.0.0](https://github.com/googleapis/google-api-nodejs-client/compare/verifiedaccess-v2.0.0...verifiedaccess-v3.0.0) (2023-06-22)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### ⚠ BREAKING CHANGES
|
|
14
|
+
|
|
15
|
+
* This release has breaking changes.
|
|
16
|
+
|
|
17
|
+
### Features
|
|
18
|
+
|
|
19
|
+
* run the generator ([#3260](https://github.com/googleapis/google-api-nodejs-client/issues/3260)) ([8efb786](https://github.com/googleapis/google-api-nodejs-client/commit/8efb7861b7da4bc1472a4b654e46f90b29fbff20))
|
|
20
|
+
|
|
3
21
|
## [2.0.0](https://github.com/googleapis/google-api-nodejs-client/compare/verifiedaccess-v1.0.0...verifiedaccess-v2.0.0) (2023-05-02)
|
|
4
22
|
|
|
5
23
|
|
package/build/v1.d.ts
CHANGED
|
@@ -141,52 +141,6 @@ export declare namespace verifiedaccess_v1 {
|
|
|
141
141
|
constructor(context: APIRequestContext);
|
|
142
142
|
/**
|
|
143
143
|
* CreateChallenge API
|
|
144
|
-
* @example
|
|
145
|
-
* ```js
|
|
146
|
-
* // Before running the sample:
|
|
147
|
-
* // - Enable the API at:
|
|
148
|
-
* // https://console.developers.google.com/apis/api/verifiedaccess.googleapis.com
|
|
149
|
-
* // - Login into gcloud by running:
|
|
150
|
-
* // `$ gcloud auth application-default login`
|
|
151
|
-
* // - Install the npm module by running:
|
|
152
|
-
* // `$ npm install googleapis`
|
|
153
|
-
*
|
|
154
|
-
* const {google} = require('googleapis');
|
|
155
|
-
* const verifiedaccess = google.verifiedaccess('v1');
|
|
156
|
-
*
|
|
157
|
-
* async function main() {
|
|
158
|
-
* const auth = new google.auth.GoogleAuth({
|
|
159
|
-
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
160
|
-
* scopes: ['https://www.googleapis.com/auth/verifiedaccess'],
|
|
161
|
-
* });
|
|
162
|
-
*
|
|
163
|
-
* // Acquire an auth client, and bind it to all future calls
|
|
164
|
-
* const authClient = await auth.getClient();
|
|
165
|
-
* google.options({auth: authClient});
|
|
166
|
-
*
|
|
167
|
-
* // Do the magic
|
|
168
|
-
* const res = await verifiedaccess.challenge.create({
|
|
169
|
-
* // Request body metadata
|
|
170
|
-
* requestBody: {
|
|
171
|
-
* // request body parameters
|
|
172
|
-
* // {}
|
|
173
|
-
* },
|
|
174
|
-
* });
|
|
175
|
-
* console.log(res.data);
|
|
176
|
-
*
|
|
177
|
-
* // Example response
|
|
178
|
-
* // {
|
|
179
|
-
* // "alternativeChallenge": {},
|
|
180
|
-
* // "challenge": {}
|
|
181
|
-
* // }
|
|
182
|
-
* }
|
|
183
|
-
*
|
|
184
|
-
* main().catch(e => {
|
|
185
|
-
* console.error(e);
|
|
186
|
-
* throw e;
|
|
187
|
-
* });
|
|
188
|
-
*
|
|
189
|
-
* ```
|
|
190
144
|
*
|
|
191
145
|
* @param params - Parameters for request
|
|
192
146
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -201,57 +155,6 @@ export declare namespace verifiedaccess_v1 {
|
|
|
201
155
|
create(callback: BodyResponseCallback<Schema$Challenge>): void;
|
|
202
156
|
/**
|
|
203
157
|
* VerifyChallengeResponse API
|
|
204
|
-
* @example
|
|
205
|
-
* ```js
|
|
206
|
-
* // Before running the sample:
|
|
207
|
-
* // - Enable the API at:
|
|
208
|
-
* // https://console.developers.google.com/apis/api/verifiedaccess.googleapis.com
|
|
209
|
-
* // - Login into gcloud by running:
|
|
210
|
-
* // `$ gcloud auth application-default login`
|
|
211
|
-
* // - Install the npm module by running:
|
|
212
|
-
* // `$ npm install googleapis`
|
|
213
|
-
*
|
|
214
|
-
* const {google} = require('googleapis');
|
|
215
|
-
* const verifiedaccess = google.verifiedaccess('v1');
|
|
216
|
-
*
|
|
217
|
-
* async function main() {
|
|
218
|
-
* const auth = new google.auth.GoogleAuth({
|
|
219
|
-
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
220
|
-
* scopes: ['https://www.googleapis.com/auth/verifiedaccess'],
|
|
221
|
-
* });
|
|
222
|
-
*
|
|
223
|
-
* // Acquire an auth client, and bind it to all future calls
|
|
224
|
-
* const authClient = await auth.getClient();
|
|
225
|
-
* google.options({auth: authClient});
|
|
226
|
-
*
|
|
227
|
-
* // Do the magic
|
|
228
|
-
* const res = await verifiedaccess.challenge.verify({
|
|
229
|
-
* // Request body metadata
|
|
230
|
-
* requestBody: {
|
|
231
|
-
* // request body parameters
|
|
232
|
-
* // {
|
|
233
|
-
* // "challengeResponse": {},
|
|
234
|
-
* // "expectedIdentity": "my_expectedIdentity"
|
|
235
|
-
* // }
|
|
236
|
-
* },
|
|
237
|
-
* });
|
|
238
|
-
* console.log(res.data);
|
|
239
|
-
*
|
|
240
|
-
* // Example response
|
|
241
|
-
* // {
|
|
242
|
-
* // "deviceEnrollmentId": "my_deviceEnrollmentId",
|
|
243
|
-
* // "devicePermanentId": "my_devicePermanentId",
|
|
244
|
-
* // "signedPublicKeyAndChallenge": "my_signedPublicKeyAndChallenge",
|
|
245
|
-
* // "verificationOutput": "my_verificationOutput"
|
|
246
|
-
* // }
|
|
247
|
-
* }
|
|
248
|
-
*
|
|
249
|
-
* main().catch(e => {
|
|
250
|
-
* console.error(e);
|
|
251
|
-
* throw e;
|
|
252
|
-
* });
|
|
253
|
-
*
|
|
254
|
-
* ```
|
|
255
158
|
*
|
|
256
159
|
* @param params - Parameters for request
|
|
257
160
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
package/build/v1.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"v1.js","sourceRoot":"","sources":["../v1.ts"],"names":[],"mappings":";AAAA,4BAA4B;AAC5B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,gDAAgD;AAChD,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;;;AAEjC,uDAAuD;AACvD,sDAAsD;AACtD,0DAA0D;AAC1D,oDAAoD;AACpD,4CAA4C;AAE5C,yDAe2B;AAG3B,IAAiB,iBAAiB,
|
|
1
|
+
{"version":3,"file":"v1.js","sourceRoot":"","sources":["../v1.ts"],"names":[],"mappings":";AAAA,4BAA4B;AAC5B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,gDAAgD;AAChD,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;;;AAEjC,uDAAuD;AACvD,sDAAsD;AACtD,0DAA0D;AAC1D,oDAAoD;AACpD,4CAA4C;AAE5C,yDAe2B;AAG3B,IAAiB,iBAAiB,CAiWjC;AAjWD,WAAiB,iBAAiB;IAgEhC;;;;;;;;;;OAUG;IACH,MAAa,cAAc;QAIzB,YAAY,OAAsB,EAAE,MAA2B;YAC7D,IAAI,CAAC,OAAO,GAAG;gBACb,QAAQ,EAAE,OAAO,IA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
|
|
97
|
-
* The device signals as reported by Chrome.
|
|
97
|
+
* The device signals as reported by Chrome. Unless otherwise specified, signals are available on all platforms.
|
|
98
98
|
*/
|
|
99
99
|
export interface Schema$DeviceSignals {
|
|
100
100
|
/**
|
|
101
|
-
* Value of the AllowScreenLock policy on the device. See https://chromeenterprise.google/policies/?policy=AllowScreenLock for more details.
|
|
101
|
+
* Value of the AllowScreenLock policy on the device. See https://chromeenterprise.google/policies/?policy=AllowScreenLock for more details. Available on ChromeOS only.
|
|
102
102
|
*/
|
|
103
103
|
allowScreenLock?: boolean | null;
|
|
104
104
|
/**
|
|
@@ -114,7 +114,7 @@ export declare namespace verifiedaccess_v2 {
|
|
|
114
114
|
*/
|
|
115
115
|
chromeRemoteDesktopAppBlocked?: boolean | null;
|
|
116
116
|
/**
|
|
117
|
-
* Crowdstrike agent properties installed on the device, if any.
|
|
117
|
+
* Crowdstrike agent properties installed on the device, if any. Available on Windows and MacOS only.
|
|
118
118
|
*/
|
|
119
119
|
crowdStrikeAgent?: Schema$CrowdStrikeAgent;
|
|
120
120
|
/**
|
|
@@ -146,7 +146,7 @@ export declare namespace verifiedaccess_v2 {
|
|
|
146
146
|
*/
|
|
147
147
|
hostname?: string | null;
|
|
148
148
|
/**
|
|
149
|
-
* International Mobile Equipment Identity (IMEI) of the device.
|
|
149
|
+
* International Mobile Equipment Identity (IMEI) of the device. Available on ChromeOS only.
|
|
150
150
|
*/
|
|
151
151
|
imei?: string[] | null;
|
|
152
152
|
/**
|
|
@@ -154,7 +154,7 @@ export declare namespace verifiedaccess_v2 {
|
|
|
154
154
|
*/
|
|
155
155
|
macAddresses?: string[] | null;
|
|
156
156
|
/**
|
|
157
|
-
* Mobile Equipment Identifier (MEID) of the device.
|
|
157
|
+
* Mobile Equipment Identifier (MEID) of the device. Available on ChromeOS only.
|
|
158
158
|
*/
|
|
159
159
|
meid?: string[] | null;
|
|
160
160
|
/**
|
|
@@ -190,11 +190,11 @@ export declare namespace verifiedaccess_v2 {
|
|
|
190
190
|
*/
|
|
191
191
|
screenLockSecured?: string | null;
|
|
192
192
|
/**
|
|
193
|
-
* Whether the device's startup software has its Secure Boot feature enabled.
|
|
193
|
+
* Whether the device's startup software has its Secure Boot feature enabled. Available on Windows only.
|
|
194
194
|
*/
|
|
195
195
|
secureBootMode?: string | null;
|
|
196
196
|
/**
|
|
197
|
-
* The serial number of the device. On Windows, this represents the BIOS's serial number.
|
|
197
|
+
* The serial number of the device. On Windows, this represents the BIOS's serial number. Not available on most Linux distributions.
|
|
198
198
|
*/
|
|
199
199
|
serialNumber?: string | null;
|
|
200
200
|
/**
|
|
@@ -206,15 +206,19 @@ export declare namespace verifiedaccess_v2 {
|
|
|
206
206
|
*/
|
|
207
207
|
systemDnsServers?: string[] | null;
|
|
208
208
|
/**
|
|
209
|
-
* Whether Chrome is blocking third-party software injection or not. This setting may be controlled by an enterprise policy: https://chromeenterprise.google/policies/?policy=ThirdPartyBlockingEnabled
|
|
209
|
+
* Whether Chrome is blocking third-party software injection or not. This setting may be controlled by an enterprise policy: https://chromeenterprise.google/policies/?policy=ThirdPartyBlockingEnabled. Available on Windows only.
|
|
210
210
|
*/
|
|
211
211
|
thirdPartyBlockingEnabled?: boolean | null;
|
|
212
212
|
/**
|
|
213
|
-
*
|
|
213
|
+
* The trigger which generated this set of signals.
|
|
214
|
+
*/
|
|
215
|
+
trigger?: string | null;
|
|
216
|
+
/**
|
|
217
|
+
* Windows domain that the current machine has joined. Available on Windows only.
|
|
214
218
|
*/
|
|
215
219
|
windowsMachineDomain?: string | null;
|
|
216
220
|
/**
|
|
217
|
-
* Windows domain for the current OS user.
|
|
221
|
+
* Windows domain for the current OS user. Available on Windows only.
|
|
218
222
|
*/
|
|
219
223
|
windowsUserDomain?: string | null;
|
|
220
224
|
}
|
|
@@ -240,10 +244,18 @@ export declare namespace verifiedaccess_v2 {
|
|
|
240
244
|
* Result message for VerifiedAccess.VerifyChallengeResponse.
|
|
241
245
|
*/
|
|
242
246
|
export interface Schema$VerifyChallengeResponseResult {
|
|
247
|
+
/**
|
|
248
|
+
* Attested device ID (ADID).
|
|
249
|
+
*/
|
|
250
|
+
attestedDeviceId?: string | null;
|
|
243
251
|
/**
|
|
244
252
|
* Unique customer id that this device belongs to, as defined by the Google Admin SDK at https://developers.google.com/admin-sdk/directory/v1/guides/manage-customers
|
|
245
253
|
*/
|
|
246
254
|
customerId?: string | null;
|
|
255
|
+
/**
|
|
256
|
+
* Device enrollment id for ChromeOS devices.
|
|
257
|
+
*/
|
|
258
|
+
deviceEnrollmentId?: string | null;
|
|
247
259
|
/**
|
|
248
260
|
* Device permanent id is returned in this field (for the machine response only).
|
|
249
261
|
*/
|
|
@@ -260,6 +272,14 @@ export declare namespace verifiedaccess_v2 {
|
|
|
260
272
|
* Device attested key trust level.
|
|
261
273
|
*/
|
|
262
274
|
keyTrustLevel?: string | null;
|
|
275
|
+
/**
|
|
276
|
+
* Unique customer id that this profile belongs to, as defined by the Google Admin SDK at https://developers.google.com/admin-sdk/directory/v1/guides/manage-customers
|
|
277
|
+
*/
|
|
278
|
+
profileCustomerId?: string | null;
|
|
279
|
+
/**
|
|
280
|
+
* Profile attested key trust level.
|
|
281
|
+
*/
|
|
282
|
+
profileKeyTrustLevel?: string | null;
|
|
263
283
|
/**
|
|
264
284
|
* Certificate Signing Request (in the SPKAC format, base64 encoded) is returned in this field. This field will be set only if device has included CSR in its challenge response. (the option to include CSR is now available for both user and machine responses)
|
|
265
285
|
*/
|
|
@@ -268,57 +288,16 @@ export declare namespace verifiedaccess_v2 {
|
|
|
268
288
|
* Virtual device id of the device. The definition of virtual device id is platform-specific.
|
|
269
289
|
*/
|
|
270
290
|
virtualDeviceId?: string | null;
|
|
291
|
+
/**
|
|
292
|
+
* The ID of a profile on the device.
|
|
293
|
+
*/
|
|
294
|
+
virtualProfileId?: string | null;
|
|
271
295
|
}
|
|
272
296
|
export class Resource$Challenge {
|
|
273
297
|
context: APIRequestContext;
|
|
274
298
|
constructor(context: APIRequestContext);
|
|
275
299
|
/**
|
|
276
300
|
* Generates a new challenge.
|
|
277
|
-
* @example
|
|
278
|
-
* ```js
|
|
279
|
-
* // Before running the sample:
|
|
280
|
-
* // - Enable the API at:
|
|
281
|
-
* // https://console.developers.google.com/apis/api/verifiedaccess.googleapis.com
|
|
282
|
-
* // - Login into gcloud by running:
|
|
283
|
-
* // `$ gcloud auth application-default login`
|
|
284
|
-
* // - Install the npm module by running:
|
|
285
|
-
* // `$ npm install googleapis`
|
|
286
|
-
*
|
|
287
|
-
* const {google} = require('googleapis');
|
|
288
|
-
* const verifiedaccess = google.verifiedaccess('v2');
|
|
289
|
-
*
|
|
290
|
-
* async function main() {
|
|
291
|
-
* const auth = new google.auth.GoogleAuth({
|
|
292
|
-
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
293
|
-
* scopes: ['https://www.googleapis.com/auth/verifiedaccess'],
|
|
294
|
-
* });
|
|
295
|
-
*
|
|
296
|
-
* // Acquire an auth client, and bind it to all future calls
|
|
297
|
-
* const authClient = await auth.getClient();
|
|
298
|
-
* google.options({auth: authClient});
|
|
299
|
-
*
|
|
300
|
-
* // Do the magic
|
|
301
|
-
* const res = await verifiedaccess.challenge.generate({
|
|
302
|
-
* // Request body metadata
|
|
303
|
-
* requestBody: {
|
|
304
|
-
* // request body parameters
|
|
305
|
-
* // {}
|
|
306
|
-
* },
|
|
307
|
-
* });
|
|
308
|
-
* console.log(res.data);
|
|
309
|
-
*
|
|
310
|
-
* // Example response
|
|
311
|
-
* // {
|
|
312
|
-
* // "challenge": "my_challenge"
|
|
313
|
-
* // }
|
|
314
|
-
* }
|
|
315
|
-
*
|
|
316
|
-
* main().catch(e => {
|
|
317
|
-
* console.error(e);
|
|
318
|
-
* throw e;
|
|
319
|
-
* });
|
|
320
|
-
*
|
|
321
|
-
* ```
|
|
322
301
|
*
|
|
323
302
|
* @param params - Parameters for request
|
|
324
303
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -333,60 +312,6 @@ export declare namespace verifiedaccess_v2 {
|
|
|
333
312
|
generate(callback: BodyResponseCallback<Schema$Challenge>): void;
|
|
334
313
|
/**
|
|
335
314
|
* Verifies the challenge response.
|
|
336
|
-
* @example
|
|
337
|
-
* ```js
|
|
338
|
-
* // Before running the sample:
|
|
339
|
-
* // - Enable the API at:
|
|
340
|
-
* // https://console.developers.google.com/apis/api/verifiedaccess.googleapis.com
|
|
341
|
-
* // - Login into gcloud by running:
|
|
342
|
-
* // `$ gcloud auth application-default login`
|
|
343
|
-
* // - Install the npm module by running:
|
|
344
|
-
* // `$ npm install googleapis`
|
|
345
|
-
*
|
|
346
|
-
* const {google} = require('googleapis');
|
|
347
|
-
* const verifiedaccess = google.verifiedaccess('v2');
|
|
348
|
-
*
|
|
349
|
-
* async function main() {
|
|
350
|
-
* const auth = new google.auth.GoogleAuth({
|
|
351
|
-
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
352
|
-
* scopes: ['https://www.googleapis.com/auth/verifiedaccess'],
|
|
353
|
-
* });
|
|
354
|
-
*
|
|
355
|
-
* // Acquire an auth client, and bind it to all future calls
|
|
356
|
-
* const authClient = await auth.getClient();
|
|
357
|
-
* google.options({auth: authClient});
|
|
358
|
-
*
|
|
359
|
-
* // Do the magic
|
|
360
|
-
* const res = await verifiedaccess.challenge.verify({
|
|
361
|
-
* // Request body metadata
|
|
362
|
-
* requestBody: {
|
|
363
|
-
* // request body parameters
|
|
364
|
-
* // {
|
|
365
|
-
* // "challengeResponse": "my_challengeResponse",
|
|
366
|
-
* // "expectedIdentity": "my_expectedIdentity"
|
|
367
|
-
* // }
|
|
368
|
-
* },
|
|
369
|
-
* });
|
|
370
|
-
* console.log(res.data);
|
|
371
|
-
*
|
|
372
|
-
* // Example response
|
|
373
|
-
* // {
|
|
374
|
-
* // "customerId": "my_customerId",
|
|
375
|
-
* // "devicePermanentId": "my_devicePermanentId",
|
|
376
|
-
* // "deviceSignal": "my_deviceSignal",
|
|
377
|
-
* // "deviceSignals": {},
|
|
378
|
-
* // "keyTrustLevel": "my_keyTrustLevel",
|
|
379
|
-
* // "signedPublicKeyAndChallenge": "my_signedPublicKeyAndChallenge",
|
|
380
|
-
* // "virtualDeviceId": "my_virtualDeviceId"
|
|
381
|
-
* // }
|
|
382
|
-
* }
|
|
383
|
-
*
|
|
384
|
-
* main().catch(e => {
|
|
385
|
-
* console.error(e);
|
|
386
|
-
* throw e;
|
|
387
|
-
* });
|
|
388
|
-
*
|
|
389
|
-
* ```
|
|
390
315
|
*
|
|
391
316
|
* @param params - Parameters for request
|
|
392
317
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
package/build/v2.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"v2.js","sourceRoot":"","sources":["../v2.ts"],"names":[],"mappings":";AAAA,4BAA4B;AAC5B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,gDAAgD;AAChD,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;;;AAEjC,uDAAuD;AACvD,sDAAsD;AACtD,0DAA0D;AAC1D,oDAAoD;AACpD,4CAA4C;AAE5C,yDAe2B;AAG3B,IAAiB,iBAAiB,
|
|
1
|
+
{"version":3,"file":"v2.js","sourceRoot":"","sources":["../v2.ts"],"names":[],"mappings":";AAAA,4BAA4B;AAC5B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,gDAAgD;AAChD,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;;;AAEjC,uDAAuD;AACvD,sDAAsD;AACtD,0DAA0D;AAC1D,oDAAoD;AACpD,4CAA4C;AAE5C,yDAe2B;AAG3B,IAAiB,iBAAiB,CAmgBjC;AAngBD,WAAiB,iBAAiB;IAgEhC;;;;;;;;;;OAUG;IACH,MAAa,cAAc;QAIzB,YAAY,O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verifiedaccess(
|
|
|
31
31
|
options: verifiedaccess_v2.Options
|
|
32
32
|
): verifiedaccess_v2.Verifiedaccess;
|
|
33
33
|
export function verifiedaccess<
|
|
34
|
-
T = verifiedaccess_v1.Verifiedaccess | verifiedaccess_v2.Verifiedaccess
|
|
34
|
+
T = verifiedaccess_v1.Verifiedaccess | verifiedaccess_v2.Verifiedaccess,
|
|
35
35
|
>(
|
|
36
36
|
this: GoogleConfigurable,
|
|
37
37
|
versionOrOptions:
|
package/package.json
CHANGED
package/v1.ts
CHANGED
|
@@ -197,52 +197,6 @@ export namespace verifiedaccess_v1 {
|
|
|
197
197
|
|
|
198
198
|
/**
|
|
199
199
|
* CreateChallenge API
|
|
200
|
-
* @example
|
|
201
|
-
* ```js
|
|
202
|
-
* // Before running the sample:
|
|
203
|
-
* // - Enable the API at:
|
|
204
|
-
* // https://console.developers.google.com/apis/api/verifiedaccess.googleapis.com
|
|
205
|
-
* // - Login into gcloud by running:
|
|
206
|
-
* // `$ gcloud auth application-default login`
|
|
207
|
-
* // - Install the npm module by running:
|
|
208
|
-
* // `$ npm install googleapis`
|
|
209
|
-
*
|
|
210
|
-
* const {google} = require('googleapis');
|
|
211
|
-
* const verifiedaccess = google.verifiedaccess('v1');
|
|
212
|
-
*
|
|
213
|
-
* async function main() {
|
|
214
|
-
* const auth = new google.auth.GoogleAuth({
|
|
215
|
-
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
216
|
-
* scopes: ['https://www.googleapis.com/auth/verifiedaccess'],
|
|
217
|
-
* });
|
|
218
|
-
*
|
|
219
|
-
* // Acquire an auth client, and bind it to all future calls
|
|
220
|
-
* const authClient = await auth.getClient();
|
|
221
|
-
* google.options({auth: authClient});
|
|
222
|
-
*
|
|
223
|
-
* // Do the magic
|
|
224
|
-
* const res = await verifiedaccess.challenge.create({
|
|
225
|
-
* // Request body metadata
|
|
226
|
-
* requestBody: {
|
|
227
|
-
* // request body parameters
|
|
228
|
-
* // {}
|
|
229
|
-
* },
|
|
230
|
-
* });
|
|
231
|
-
* console.log(res.data);
|
|
232
|
-
*
|
|
233
|
-
* // Example response
|
|
234
|
-
* // {
|
|
235
|
-
* // "alternativeChallenge": {},
|
|
236
|
-
* // "challenge": {}
|
|
237
|
-
* // }
|
|
238
|
-
* }
|
|
239
|
-
*
|
|
240
|
-
* main().catch(e => {
|
|
241
|
-
* console.error(e);
|
|
242
|
-
* throw e;
|
|
243
|
-
* });
|
|
244
|
-
*
|
|
245
|
-
* ```
|
|
246
200
|
*
|
|
247
201
|
* @param params - Parameters for request
|
|
248
202
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -327,57 +281,6 @@ export namespace verifiedaccess_v1 {
|
|
|
327
281
|
|
|
328
282
|
/**
|
|
329
283
|
* VerifyChallengeResponse API
|
|
330
|
-
* @example
|
|
331
|
-
* ```js
|
|
332
|
-
* // Before running the sample:
|
|
333
|
-
* // - Enable the API at:
|
|
334
|
-
* // https://console.developers.google.com/apis/api/verifiedaccess.googleapis.com
|
|
335
|
-
* // - Login into gcloud by running:
|
|
336
|
-
* // `$ gcloud auth application-default login`
|
|
337
|
-
* // - Install the npm module by running:
|
|
338
|
-
* // `$ npm install googleapis`
|
|
339
|
-
*
|
|
340
|
-
* const {google} = require('googleapis');
|
|
341
|
-
* const verifiedaccess = google.verifiedaccess('v1');
|
|
342
|
-
*
|
|
343
|
-
* async function main() {
|
|
344
|
-
* const auth = new google.auth.GoogleAuth({
|
|
345
|
-
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
346
|
-
* scopes: ['https://www.googleapis.com/auth/verifiedaccess'],
|
|
347
|
-
* });
|
|
348
|
-
*
|
|
349
|
-
* // Acquire an auth client, and bind it to all future calls
|
|
350
|
-
* const authClient = await auth.getClient();
|
|
351
|
-
* google.options({auth: authClient});
|
|
352
|
-
*
|
|
353
|
-
* // Do the magic
|
|
354
|
-
* const res = await verifiedaccess.challenge.verify({
|
|
355
|
-
* // Request body metadata
|
|
356
|
-
* requestBody: {
|
|
357
|
-
* // request body parameters
|
|
358
|
-
* // {
|
|
359
|
-
* // "challengeResponse": {},
|
|
360
|
-
* // "expectedIdentity": "my_expectedIdentity"
|
|
361
|
-
* // }
|
|
362
|
-
* },
|
|
363
|
-
* });
|
|
364
|
-
* console.log(res.data);
|
|
365
|
-
*
|
|
366
|
-
* // Example response
|
|
367
|
-
* // {
|
|
368
|
-
* // "deviceEnrollmentId": "my_deviceEnrollmentId",
|
|
369
|
-
* // "devicePermanentId": "my_devicePermanentId",
|
|
370
|
-
* // "signedPublicKeyAndChallenge": "my_signedPublicKeyAndChallenge",
|
|
371
|
-
* // "verificationOutput": "my_verificationOutput"
|
|
372
|
-
* // }
|
|
373
|
-
* }
|
|
374
|
-
*
|
|
375
|
-
* main().catch(e => {
|
|
376
|
-
* console.error(e);
|
|
377
|
-
* throw e;
|
|
378
|
-
* });
|
|
379
|
-
*
|
|
380
|
-
* ```
|
|
381
284
|
*
|
|
382
285
|
* @param params - Parameters for request
|
|
383
286
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
package/v2.ts
CHANGED
|
@@ -147,11 +147,11 @@ export namespace verifiedaccess_v2 {
|
|
|
147
147
|
customerId?: string | null;
|
|
148
148
|
}
|
|
149
149
|
/**
|
|
150
|
-
* The device signals as reported by Chrome.
|
|
150
|
+
* The device signals as reported by Chrome. Unless otherwise specified, signals are available on all platforms.
|
|
151
151
|
*/
|
|
152
152
|
export interface Schema$DeviceSignals {
|
|
153
153
|
/**
|
|
154
|
-
* Value of the AllowScreenLock policy on the device. See https://chromeenterprise.google/policies/?policy=AllowScreenLock for more details.
|
|
154
|
+
* Value of the AllowScreenLock policy on the device. See https://chromeenterprise.google/policies/?policy=AllowScreenLock for more details. Available on ChromeOS only.
|
|
155
155
|
*/
|
|
156
156
|
allowScreenLock?: boolean | null;
|
|
157
157
|
/**
|
|
@@ -167,7 +167,7 @@ export namespace verifiedaccess_v2 {
|
|
|
167
167
|
*/
|
|
168
168
|
chromeRemoteDesktopAppBlocked?: boolean | null;
|
|
169
169
|
/**
|
|
170
|
-
* Crowdstrike agent properties installed on the device, if any.
|
|
170
|
+
* Crowdstrike agent properties installed on the device, if any. Available on Windows and MacOS only.
|
|
171
171
|
*/
|
|
172
172
|
crowdStrikeAgent?: Schema$CrowdStrikeAgent;
|
|
173
173
|
/**
|
|
@@ -199,7 +199,7 @@ export namespace verifiedaccess_v2 {
|
|
|
199
199
|
*/
|
|
200
200
|
hostname?: string | null;
|
|
201
201
|
/**
|
|
202
|
-
* International Mobile Equipment Identity (IMEI) of the device.
|
|
202
|
+
* International Mobile Equipment Identity (IMEI) of the device. Available on ChromeOS only.
|
|
203
203
|
*/
|
|
204
204
|
imei?: string[] | null;
|
|
205
205
|
/**
|
|
@@ -207,7 +207,7 @@ export namespace verifiedaccess_v2 {
|
|
|
207
207
|
*/
|
|
208
208
|
macAddresses?: string[] | null;
|
|
209
209
|
/**
|
|
210
|
-
* Mobile Equipment Identifier (MEID) of the device.
|
|
210
|
+
* Mobile Equipment Identifier (MEID) of the device. Available on ChromeOS only.
|
|
211
211
|
*/
|
|
212
212
|
meid?: string[] | null;
|
|
213
213
|
/**
|
|
@@ -243,11 +243,11 @@ export namespace verifiedaccess_v2 {
|
|
|
243
243
|
*/
|
|
244
244
|
screenLockSecured?: string | null;
|
|
245
245
|
/**
|
|
246
|
-
* Whether the device's startup software has its Secure Boot feature enabled.
|
|
246
|
+
* Whether the device's startup software has its Secure Boot feature enabled. Available on Windows only.
|
|
247
247
|
*/
|
|
248
248
|
secureBootMode?: string | null;
|
|
249
249
|
/**
|
|
250
|
-
* The serial number of the device. On Windows, this represents the BIOS's serial number.
|
|
250
|
+
* The serial number of the device. On Windows, this represents the BIOS's serial number. Not available on most Linux distributions.
|
|
251
251
|
*/
|
|
252
252
|
serialNumber?: string | null;
|
|
253
253
|
/**
|
|
@@ -259,15 +259,19 @@ export namespace verifiedaccess_v2 {
|
|
|
259
259
|
*/
|
|
260
260
|
systemDnsServers?: string[] | null;
|
|
261
261
|
/**
|
|
262
|
-
* Whether Chrome is blocking third-party software injection or not. This setting may be controlled by an enterprise policy: https://chromeenterprise.google/policies/?policy=ThirdPartyBlockingEnabled
|
|
262
|
+
* Whether Chrome is blocking third-party software injection or not. This setting may be controlled by an enterprise policy: https://chromeenterprise.google/policies/?policy=ThirdPartyBlockingEnabled. Available on Windows only.
|
|
263
263
|
*/
|
|
264
264
|
thirdPartyBlockingEnabled?: boolean | null;
|
|
265
265
|
/**
|
|
266
|
-
*
|
|
266
|
+
* The trigger which generated this set of signals.
|
|
267
|
+
*/
|
|
268
|
+
trigger?: string | null;
|
|
269
|
+
/**
|
|
270
|
+
* Windows domain that the current machine has joined. Available on Windows only.
|
|
267
271
|
*/
|
|
268
272
|
windowsMachineDomain?: string | null;
|
|
269
273
|
/**
|
|
270
|
-
* Windows domain for the current OS user.
|
|
274
|
+
* Windows domain for the current OS user. Available on Windows only.
|
|
271
275
|
*/
|
|
272
276
|
windowsUserDomain?: string | null;
|
|
273
277
|
}
|
|
@@ -292,10 +296,18 @@ export namespace verifiedaccess_v2 {
|
|
|
292
296
|
* Result message for VerifiedAccess.VerifyChallengeResponse.
|
|
293
297
|
*/
|
|
294
298
|
export interface Schema$VerifyChallengeResponseResult {
|
|
299
|
+
/**
|
|
300
|
+
* Attested device ID (ADID).
|
|
301
|
+
*/
|
|
302
|
+
attestedDeviceId?: string | null;
|
|
295
303
|
/**
|
|
296
304
|
* Unique customer id that this device belongs to, as defined by the Google Admin SDK at https://developers.google.com/admin-sdk/directory/v1/guides/manage-customers
|
|
297
305
|
*/
|
|
298
306
|
customerId?: string | null;
|
|
307
|
+
/**
|
|
308
|
+
* Device enrollment id for ChromeOS devices.
|
|
309
|
+
*/
|
|
310
|
+
deviceEnrollmentId?: string | null;
|
|
299
311
|
/**
|
|
300
312
|
* Device permanent id is returned in this field (for the machine response only).
|
|
301
313
|
*/
|
|
@@ -312,6 +324,14 @@ export namespace verifiedaccess_v2 {
|
|
|
312
324
|
* Device attested key trust level.
|
|
313
325
|
*/
|
|
314
326
|
keyTrustLevel?: string | null;
|
|
327
|
+
/**
|
|
328
|
+
* Unique customer id that this profile belongs to, as defined by the Google Admin SDK at https://developers.google.com/admin-sdk/directory/v1/guides/manage-customers
|
|
329
|
+
*/
|
|
330
|
+
profileCustomerId?: string | null;
|
|
331
|
+
/**
|
|
332
|
+
* Profile attested key trust level.
|
|
333
|
+
*/
|
|
334
|
+
profileKeyTrustLevel?: string | null;
|
|
315
335
|
/**
|
|
316
336
|
* Certificate Signing Request (in the SPKAC format, base64 encoded) is returned in this field. This field will be set only if device has included CSR in its challenge response. (the option to include CSR is now available for both user and machine responses)
|
|
317
337
|
*/
|
|
@@ -320,6 +340,10 @@ export namespace verifiedaccess_v2 {
|
|
|
320
340
|
* Virtual device id of the device. The definition of virtual device id is platform-specific.
|
|
321
341
|
*/
|
|
322
342
|
virtualDeviceId?: string | null;
|
|
343
|
+
/**
|
|
344
|
+
* The ID of a profile on the device.
|
|
345
|
+
*/
|
|
346
|
+
virtualProfileId?: string | null;
|
|
323
347
|
}
|
|
324
348
|
|
|
325
349
|
export class Resource$Challenge {
|
|
@@ -330,51 +354,6 @@ export namespace verifiedaccess_v2 {
|
|
|
330
354
|
|
|
331
355
|
/**
|
|
332
356
|
* Generates a new challenge.
|
|
333
|
-
* @example
|
|
334
|
-
* ```js
|
|
335
|
-
* // Before running the sample:
|
|
336
|
-
* // - Enable the API at:
|
|
337
|
-
* // https://console.developers.google.com/apis/api/verifiedaccess.googleapis.com
|
|
338
|
-
* // - Login into gcloud by running:
|
|
339
|
-
* // `$ gcloud auth application-default login`
|
|
340
|
-
* // - Install the npm module by running:
|
|
341
|
-
* // `$ npm install googleapis`
|
|
342
|
-
*
|
|
343
|
-
* const {google} = require('googleapis');
|
|
344
|
-
* const verifiedaccess = google.verifiedaccess('v2');
|
|
345
|
-
*
|
|
346
|
-
* async function main() {
|
|
347
|
-
* const auth = new google.auth.GoogleAuth({
|
|
348
|
-
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
349
|
-
* scopes: ['https://www.googleapis.com/auth/verifiedaccess'],
|
|
350
|
-
* });
|
|
351
|
-
*
|
|
352
|
-
* // Acquire an auth client, and bind it to all future calls
|
|
353
|
-
* const authClient = await auth.getClient();
|
|
354
|
-
* google.options({auth: authClient});
|
|
355
|
-
*
|
|
356
|
-
* // Do the magic
|
|
357
|
-
* const res = await verifiedaccess.challenge.generate({
|
|
358
|
-
* // Request body metadata
|
|
359
|
-
* requestBody: {
|
|
360
|
-
* // request body parameters
|
|
361
|
-
* // {}
|
|
362
|
-
* },
|
|
363
|
-
* });
|
|
364
|
-
* console.log(res.data);
|
|
365
|
-
*
|
|
366
|
-
* // Example response
|
|
367
|
-
* // {
|
|
368
|
-
* // "challenge": "my_challenge"
|
|
369
|
-
* // }
|
|
370
|
-
* }
|
|
371
|
-
*
|
|
372
|
-
* main().catch(e => {
|
|
373
|
-
* console.error(e);
|
|
374
|
-
* throw e;
|
|
375
|
-
* });
|
|
376
|
-
*
|
|
377
|
-
* ```
|
|
378
357
|
*
|
|
379
358
|
* @param params - Parameters for request
|
|
380
359
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|
|
@@ -463,60 +442,6 @@ export namespace verifiedaccess_v2 {
|
|
|
463
442
|
|
|
464
443
|
/**
|
|
465
444
|
* Verifies the challenge response.
|
|
466
|
-
* @example
|
|
467
|
-
* ```js
|
|
468
|
-
* // Before running the sample:
|
|
469
|
-
* // - Enable the API at:
|
|
470
|
-
* // https://console.developers.google.com/apis/api/verifiedaccess.googleapis.com
|
|
471
|
-
* // - Login into gcloud by running:
|
|
472
|
-
* // `$ gcloud auth application-default login`
|
|
473
|
-
* // - Install the npm module by running:
|
|
474
|
-
* // `$ npm install googleapis`
|
|
475
|
-
*
|
|
476
|
-
* const {google} = require('googleapis');
|
|
477
|
-
* const verifiedaccess = google.verifiedaccess('v2');
|
|
478
|
-
*
|
|
479
|
-
* async function main() {
|
|
480
|
-
* const auth = new google.auth.GoogleAuth({
|
|
481
|
-
* // Scopes can be specified either as an array or as a single, space-delimited string.
|
|
482
|
-
* scopes: ['https://www.googleapis.com/auth/verifiedaccess'],
|
|
483
|
-
* });
|
|
484
|
-
*
|
|
485
|
-
* // Acquire an auth client, and bind it to all future calls
|
|
486
|
-
* const authClient = await auth.getClient();
|
|
487
|
-
* google.options({auth: authClient});
|
|
488
|
-
*
|
|
489
|
-
* // Do the magic
|
|
490
|
-
* const res = await verifiedaccess.challenge.verify({
|
|
491
|
-
* // Request body metadata
|
|
492
|
-
* requestBody: {
|
|
493
|
-
* // request body parameters
|
|
494
|
-
* // {
|
|
495
|
-
* // "challengeResponse": "my_challengeResponse",
|
|
496
|
-
* // "expectedIdentity": "my_expectedIdentity"
|
|
497
|
-
* // }
|
|
498
|
-
* },
|
|
499
|
-
* });
|
|
500
|
-
* console.log(res.data);
|
|
501
|
-
*
|
|
502
|
-
* // Example response
|
|
503
|
-
* // {
|
|
504
|
-
* // "customerId": "my_customerId",
|
|
505
|
-
* // "devicePermanentId": "my_devicePermanentId",
|
|
506
|
-
* // "deviceSignal": "my_deviceSignal",
|
|
507
|
-
* // "deviceSignals": {},
|
|
508
|
-
* // "keyTrustLevel": "my_keyTrustLevel",
|
|
509
|
-
* // "signedPublicKeyAndChallenge": "my_signedPublicKeyAndChallenge",
|
|
510
|
-
* // "virtualDeviceId": "my_virtualDeviceId"
|
|
511
|
-
* // }
|
|
512
|
-
* }
|
|
513
|
-
*
|
|
514
|
-
* main().catch(e => {
|
|
515
|
-
* console.error(e);
|
|
516
|
-
* throw e;
|
|
517
|
-
* });
|
|
518
|
-
*
|
|
519
|
-
* ```
|
|
520
445
|
*
|
|
521
446
|
* @param params - Parameters for request
|
|
522
447
|
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
|