0.0.20241018 • Published 8 months ago

@maxim_mazurok/gapi.client.firestore-v1 v0.0.20241018

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

TypeScript typings for Cloud Firestore API v1

Accesses the NoSQL document database built for automatic scaling, high performance, and ease of application development. For detailed description please check documentation.

Installing

Install typings for Cloud Firestore API:

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

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 manage your Google Cloud Datastore data
    'https://www.googleapis.com/auth/datastore',
  ],
  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 Cloud Firestore API resources:

0.0.20241018

8 months ago

0.0.20241002

9 months ago

0.0.20241008

9 months ago

0.0.20240917

10 months ago

0.0.20240904

10 months ago

0.0.20240822

10 months ago

0.0.20240804

11 months ago

0.0.20240521

1 year ago

0.0.20240617

1 year ago

0.0.20240610

1 year ago

0.0.20240630

12 months ago

0.0.20240626

1 year ago

0.0.20240713

12 months ago

0.0.20240512

1 year ago

0.0.20240430

1 year ago

0.0.20240420

1 year ago

0.0.20240324

1 year ago

0.0.20240317

1 year ago

0.0.20240307

1 year ago

0.0.20240226

1 year ago

0.0.20240215

1 year ago

0.0.20240208

1 year ago

0.0.20240131

1 year ago

0.0.20240117

1 year ago

0.0.20240109

1 year ago

0.0.20231221

1 year ago

0.0.20231214

2 years ago

0.0.20230812

2 years ago

0.0.20231031

2 years ago

0.0.20230806

2 years ago

0.0.20230729

2 years ago

0.0.20230722

2 years ago

0.0.20230921

2 years ago

0.0.20231021

2 years ago

0.0.20231103

2 years ago

0.0.20230918

2 years ago

0.0.20231009

2 years ago

0.0.20230716

2 years ago

0.0.20230912

2 years ago

0.0.20231015

2 years ago

0.0.20230708

2 years ago

0.0.20230629

2 years ago

0.0.20230905

2 years ago

0.0.20231002

2 years ago

0.0.20230621

2 years ago

0.0.20230611

2 years ago

0.0.20230515

2 years ago

0.0.20230508

2 years ago

0.0.20230523

2 years ago

0.0.20230605

2 years ago

0.0.20230429

2 years ago

0.0.20230527

2 years ago

0.0.20230315

2 years ago

0.0.20230415

2 years ago

0.0.20230421

2 years ago

0.0.20230322

2 years ago

0.0.20230228

2 years ago

0.0.20230402

2 years ago

0.0.20230408

2 years ago

0.0.20230328

2 years ago

0.0.20230307

2 years ago

0.0.20230214

2 years ago

0.0.20230126

2 years ago

0.0.20230201

2 years ago

0.0.20221130

3 years ago

0.0.20230118

2 years ago

0.0.20221210

3 years ago

0.0.20230110

2 years ago

0.0.20230102

2 years ago

0.0.20221108

3 years ago

0.0.20221029

3 years ago

0.0.20221017

3 years ago

0.0.20220819

3 years ago

0.0.20220831

3 years ago

0.0.20220915

3 years ago

0.0.20220808

3 years ago

0.0.20220715

3 years ago