0.0.20240506 • Published 15 days ago

@maxim_mazurok/gapi.client.firebaseappcheck-v1 v0.0.20240506

Weekly downloads
-
License
MIT
Repository
github
Last release
15 days ago

TypeScript typings for Firebase App Check API v1

Firebase App Check works alongside other Firebase services to help protect your backend resources from abuse, such as billing fraud or phishing. For detailed description please check documentation.

Installing

Install typings for Firebase App Check API:

npm install @types/gapi.client.firebaseappcheck-v1 --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://firebaseappcheck.googleapis.com/$discovery/rest?version=v1',
  () => {
    // now we can use:
    // gapi.client.firebaseappcheck
  }
);
// 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('firebaseappcheck', 'v1', () => {
  // now we can use:
  // gapi.client.firebaseappcheck
});

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 = [
    // See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account.
    'https://www.googleapis.com/auth/cloud-platform',

    // View and administer all your Firebase data and settings
    'https://www.googleapis.com/auth/firebase',
  ],
  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 Firebase App Check API resources:

/*
Returns a public JWK set as specified by [RFC 7517](https://tools.ietf.org/html/rfc7517) that can be used to verify App Check tokens. Exactly one of the public keys in the returned set will successfully validate any App Check token that is currently valid.
*/
await gapi.client.firebaseappcheck.jwks.get({name: 'name'});
0.0.20240506

15 days ago

0.0.20240429

22 days ago

0.0.20240422

29 days ago

0.0.20240415

1 month ago

0.0.20240401

2 months ago

0.0.20240322

2 months ago

0.0.20240318

2 months ago

0.0.20240311

2 months ago

0.0.20240304

3 months ago

0.0.20240226

3 months ago

0.0.20240219

3 months ago

0.0.20240212

3 months ago

0.0.20240205

3 months ago

0.0.20240129

4 months ago

0.0.20240122

4 months ago

0.0.20240115

4 months ago

0.0.20240108

4 months ago

0.0.20240102

5 months ago

0.0.20231218

5 months ago

0.0.20231211

5 months ago

0.0.20231204

6 months ago

0.0.20231106

7 months ago

0.0.20230731

10 months ago

0.0.20230814

9 months ago

0.0.20231113

6 months ago

0.0.20230807

10 months ago

0.0.20230927

8 months ago

0.0.20230721

10 months ago

0.0.20230925

8 months ago

0.0.20231023

7 months ago

0.0.20230717

10 months ago

0.0.20231009

7 months ago

0.0.20230710

11 months ago

0.0.20230911

8 months ago

0.0.20231016

7 months ago

0.0.20230904

9 months ago

0.0.20230821

9 months ago

0.0.20230825

9 months ago

0.0.20230703

11 months ago

0.0.20231002

8 months ago

0.0.20230626

11 months ago

0.0.20230619

11 months ago

0.0.20230612

11 months ago

0.0.20230515

1 year ago

0.0.20230522

12 months ago

0.0.20230501

1 year ago

0.0.20230605

12 months ago

0.0.20230529

12 months ago

0.0.20230313

1 year ago

0.0.20230413

1 year ago

0.0.20230320

1 year ago

0.0.20230425

1 year ago

0.0.20230403

1 year ago

0.0.20230227

1 year ago

0.0.20230327

1 year ago

0.0.20230306

1 year ago

0.0.20230410

1 year ago

0.0.20230206

1 year ago

0.0.20230130

1 year ago

0.0.20230213

1 year ago

0.0.20221116

2 years ago

0.0.20230116

1 year ago

0.0.20221212

1 year ago

0.0.20230109

1 year ago

0.0.20221129

1 year ago

0.0.20221107

2 years ago

0.0.20230123

1 year ago

0.0.20221205

1 year ago

0.0.20221031

2 years ago

0.0.20221003

2 years ago

0.0.20221024

2 years ago

0.0.20220926

2 years ago

0.0.20220916

2 years ago

0.0.20220829

2 years ago

0.0.20220910

2 years ago

0.0.20220822

2 years ago

0.0.20220904

2 years ago

0.0.20220812

2 years ago

0.0.20220806

2 years ago