0.0.20250610 • Published 10 months ago

@maxim_mazurok/gapi.client.verifiedaccess-v2 v0.0.20250610

Weekly downloads
-
License
MIT
Repository
github
Last release
10 months ago

TypeScript typings for Chrome Verified Access API v2

API for Verified Access chrome extension to provide credential verification for chrome devices connecting to an enterprise network For detailed description please check documentation.

Installing

Install typings for Chrome Verified Access API:

npm install @types/gapi.client.verifiedaccess-v2 --save-dev

Usage

You need to initialize Google API client in your code:

gapi.load('client', () => {
  // now we can use gapi.client
  // ...
});

Then load api client wrapper:

gapi.client.load(
  'https://verifiedaccess.googleapis.com/$discovery/rest?version=v2',
  () => {
    // now we can use:
    // gapi.client.verifiedaccess
  },
);
// Deprecated, use discovery document URL, see https://github.com/google/google-api-javascript-client/blob/master/docs/reference.md#----gapiclientloadname----version----callback--
gapi.client.load('verifiedaccess', 'v2', () => {
  // now we can use:
  // gapi.client.verifiedaccess
});

Don't forget to authenticate your client before sending any request to resources:

// declare client_id registered in Google Developers Console
var client_id = '',
  scope = [
    // Verify your enterprise credentials
    'https://www.googleapis.com/auth/verifiedaccess',
  ],
  immediate = true;
// ...

gapi.auth.authorize(
  {client_id: client_id, scope: scope, immediate: immediate},
  authResult => {
    if (authResult && !authResult.error) {
      /* handle successful authorization */
    } else {
      /* handle authorization error */
    }
  },
);

After that you can use Chrome Verified Access API resources:

/*
Generates a new challenge.
*/
await gapi.client.verifiedaccess.challenge.generate({});

/*
Verifies the challenge response.
*/
await gapi.client.verifiedaccess.challenge.verify({});
0.0.20250409

12 months ago

0.0.20250128

1 year ago

0.0.20250401

12 months ago

0.0.20241112

1 year ago

0.0.20250218

1 year ago

0.0.20250415

12 months ago

0.0.20250610

10 months ago

0.0.20241029

1 year ago

0.0.20250506

11 months ago

0.0.20250429

11 months ago

0.0.20250107

1 year ago

0.0.20250225

1 year ago

0.0.20250422

11 months ago

0.0.20241119

1 year ago

0.0.20241210

1 year ago

0.0.20250318

1 year ago

0.0.20250513

11 months ago

0.0.20250311

1 year ago

0.0.20241022

1 year ago

0.0.20241020

1 year ago

0.0.20240924

2 years ago

0.0.20241001

1 year ago

0.0.20241008

1 year ago

0.0.20240903

2 years ago

0.0.20240917

2 years ago

0.0.20240830

2 years ago

0.0.20240531

2 years ago

0.0.20240806

2 years ago

0.0.20240605

2 years ago

0.0.20240819

2 years ago

0.0.20240618

2 years ago

0.0.20240730

2 years ago

0.0.20240709

2 years ago

0.0.20240702

2 years ago

0.0.20240514

2 years ago

0.0.20240507

2 years ago

0.0.20240430

2 years ago

0.0.20240423

2 years ago

0.0.20240409

2 years ago

0.0.20240402

2 years ago

0.0.20240319

2 years ago

0.0.20240305

2 years ago

0.0.20240227

2 years ago

0.0.20240220

2 years ago

0.0.20240213

2 years ago

0.0.20240130

2 years ago

0.0.20240119

2 years ago

0.0.20231128

2 years ago

0.0.20230718

3 years ago

0.0.20230711

3 years ago

0.0.20231107

2 years ago

0.0.20230815

3 years ago

0.0.20230912

3 years ago

0.0.20231031

2 years ago

0.0.20230906

3 years ago

0.0.20230807

3 years ago

0.0.20230921

3 years ago

0.0.20230822

3 years ago

0.0.20230801

3 years ago

0.0.20231001

3 years ago

0.0.20231003

2 years ago

0.0.20231024

2 years ago

0.0.20230622

3 years ago

0.0.20230516

3 years ago

0.0.20230425

3 years ago

0.0.20230503

3 years ago

0.0.20230606

3 years ago

0.0.20230530

3 years ago

0.0.20230404

3 years ago

0.0.20230228

3 years ago

0.0.20230401

3 years ago

0.0.20230413

3 years ago

0.0.20230314

3 years ago

0.0.20230307

3 years ago

0.0.20230322

3 years ago

0.0.20230221

3 years ago

0.0.20230214

3 years ago

0.0.20230131

3 years ago

0.0.20230124

3 years ago

0.0.20230213

3 years ago

0.0.20230117

3 years ago

0.0.20221214

3 years ago

0.0.20221202

3 years ago

0.0.20221101

3 years ago

0.0.20221110

3 years ago

0.0.20221018

3 years ago

0.0.20221004

3 years ago

0.0.20221025

3 years ago

0.0.20220519

4 years ago