cloudfire-auth 0.3.2 → 0.4.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.
@@ -68,6 +68,8 @@ export class CloudFireAuth {
68
68
  *
69
69
  * @returns A promise fulfilled with a custom token for the
70
70
  * provided `uid` and payload.
71
+ *
72
+ * @category Authentication
71
73
  */
72
74
  async createCustomToken(uid, developerClaims) {
73
75
  const oauth2Token = await this.getOauth2AccessToken();
@@ -96,6 +98,8 @@ export class CloudFireAuth {
96
98
  * @returns A promise fulfilled with the
97
99
  * token's decoded claims if the ID token is valid; otherwise, a rejected
98
100
  * promise.
101
+ *
102
+ * @category Authentication
99
103
  */
100
104
  async verifyIdToken(idToken, checkRevoked) {
101
105
  const oauth2Token = await this.getOauth2AccessToken();
@@ -111,6 +115,8 @@ export class CloudFireAuth {
111
115
  *
112
116
  * @returns A promise fulfilled with the user
113
117
  * data corresponding to the provided `uid`.
118
+ *
119
+ * @category User Management
114
120
  */
115
121
  async getUser(uid) {
116
122
  const oauth2Token = await this.getOauth2AccessToken();
@@ -127,6 +133,8 @@ export class CloudFireAuth {
127
133
  *
128
134
  * @returns A promise fulfilled with the user
129
135
  * data corresponding to the provided email.
136
+ *
137
+ * @category User Management
130
138
  */
131
139
  async getUserByEmail(email) {
132
140
  return await getUserByEmailHandler(email);
@@ -143,6 +151,8 @@ export class CloudFireAuth {
143
151
  *
144
152
  * @returns A promise fulfilled with the user
145
153
  * data corresponding to the provided phone number.
154
+ *
155
+ * @category User Management
146
156
  */
147
157
  async getUserByPhoneNumber(phoneNumber) {
148
158
  return await getUserByPhoneNumberHandler(phoneNumber);
@@ -159,6 +169,8 @@ export class CloudFireAuth {
159
169
  *
160
170
  * @returns A promise fulfilled with the user data corresponding to the
161
171
  * given provider id.
172
+ *
173
+ * @category User Management
162
174
  */
163
175
  async getUserByProviderUid(providerId, uid) {
164
176
  return await getUserByProviderUidHandler(providerId, uid);
@@ -177,6 +189,8 @@ export class CloudFireAuth {
177
189
  * @returns A promise that resolves to the corresponding user records.
178
190
  * @throws FirebaseAuthError If any of the identifiers are invalid or if more than 100
179
191
  * identifiers are specified.
192
+ *
193
+ * @category User Management
180
194
  */
181
195
  async getUsers(identifiers) {
182
196
  return await getUsersHandler(identifiers);
@@ -195,6 +209,8 @@ export class CloudFireAuth {
195
209
  * users starting without any offset.
196
210
  * @returns A promise that resolves with
197
211
  * the current batch of downloaded users and the next page token.
212
+ *
213
+ * @category User Management
198
214
  */
199
215
  async listUsers(maxResults, pageToken) {
200
216
  return await listUsersHandler(maxResults, pageToken);
@@ -210,6 +226,8 @@ export class CloudFireAuth {
210
226
  *
211
227
  * @returns A promise fulfilled with the user
212
228
  * data corresponding to the newly created user.
229
+ *
230
+ * @category User Management
213
231
  */
214
232
  async createUser(properties) {
215
233
  return await createUserHandler(properties);
@@ -224,6 +242,8 @@ export class CloudFireAuth {
224
242
  *
225
243
  * @returns An empty promise fulfilled once the user has been
226
244
  * deleted.
245
+ *
246
+ * @category User Management
227
247
  */
228
248
  async deleteUser(uid) {
229
249
  const oauth2Token = await this.getOauth2AccessToken();
@@ -250,6 +270,8 @@ export class CloudFireAuth {
250
270
  * @returns A Promise that resolves to the total number of successful/failed
251
271
  * deletions, as well as the array of errors that corresponds to the
252
272
  * failed deletions.
273
+ *
274
+ * @category User Management
253
275
  */
254
276
  async deleteUsers(uids) {
255
277
  return await deleteUsersHandler(uids);
@@ -266,6 +288,8 @@ export class CloudFireAuth {
266
288
  *
267
289
  * @returns A promise fulfilled with the
268
290
  * updated user data.
291
+ *
292
+ * @category User Management
269
293
  */
270
294
  async updateUser(uid, properties) {
271
295
  const oauth2Token = await this.getOauth2AccessToken();
@@ -293,6 +317,8 @@ export class CloudFireAuth {
293
317
  * separate storage systems.
294
318
  * @returns A promise that resolves when the operation completes
295
319
  * successfully.
320
+ *
321
+ * @category Token Management
296
322
  */
297
323
  async setCustomUserClaims(uid, customUserClaims) {
298
324
  const oauth2Token = await this.getOauth2AccessToken();
@@ -308,7 +334,7 @@ export class CloudFireAuth {
308
334
  * While this will revoke all sessions for a specified user and disable any
309
335
  * new ID tokens for existing sessions from getting minted, existing ID tokens
310
336
  * may remain active until their natural expiration (one hour). To verify that
311
- * ID tokens are revoked, use {@link BaseAuth.verifyIdToken}
337
+ * ID tokens are revoked, use {@link CloudFireAuth.verifyIdToken}
312
338
  * where `checkRevoked` is set to true.
313
339
  *
314
340
  * @param uid - The `uid` corresponding to the user whose refresh tokens
@@ -316,6 +342,8 @@ export class CloudFireAuth {
316
342
  *
317
343
  * @returns An empty promise fulfilled once the user's refresh
318
344
  * tokens have been revoked.
345
+ *
346
+ * @category Token Management
319
347
  */
320
348
  async revokeRefreshTokens(uid) {
321
349
  const oauth2Token = await this.getOauth2AccessToken();
@@ -337,6 +365,8 @@ export class CloudFireAuth {
337
365
  * the operation completes with the result of the import. This includes the
338
366
  * number of successful imports, the number of failed imports and their
339
367
  * corresponding errors.
368
+ *
369
+ * @category User Management
340
370
  */
341
371
  async importUsers(users, options) {
342
372
  const oauth2Token = await this.getOauth2AccessToken();
@@ -358,6 +388,8 @@ export class CloudFireAuth {
358
388
  *
359
389
  * @returns A promise that resolves on success with the
360
390
  * created session cookie.
391
+ *
392
+ * @category Authentication
361
393
  */
362
394
  async createSessionCookie(idToken, sessionCookieOptions) {
363
395
  const oauth2Token = await this.getOauth2AccessToken();
@@ -379,7 +411,7 @@ export class CloudFireAuth {
379
411
  * for code samples and detailed documentation
380
412
  *
381
413
  * @param sessionCookie - The session cookie to verify.
382
- * @param checkForRevocation - Whether to check if the session cookie was
414
+ * @param checkRevoked - Whether to check if the session cookie was
383
415
  * revoked. This requires an extra request to the Firebase Auth backend to
384
416
  * check the `tokensValidAfterTime` time for the corresponding user.
385
417
  * When not specified, this additional check is not performed.
@@ -387,6 +419,8 @@ export class CloudFireAuth {
387
419
  * @returns A promise fulfilled with the
388
420
  * session cookie's decoded claims if the session cookie is valid; otherwise,
389
421
  * a rejected promise.
422
+ *
423
+ * @category Authentication
390
424
  */
391
425
  async verifySessionCookie(sessionCookie, checkRevoked) {
392
426
  return await verifySessionCookieHandler(sessionCookie, checkRevoked);
@@ -439,6 +473,8 @@ export class CloudFireAuth {
439
473
  * The Android package name and iOS bundle ID are respected only if they
440
474
  * are configured in the same Firebase Auth project.
441
475
  * @returns A promise that resolves with the generated link.
476
+ *
477
+ * @category Email Actions
442
478
  */
443
479
  async generatePasswordResetLink(email, actionCodeSettings) {
444
480
  const oauth2Token = await this.getOauth2AccessToken();
@@ -491,6 +527,8 @@ export class CloudFireAuth {
491
527
  * The Android package name and iOS bundle ID are respected only if they
492
528
  * are configured in the same Firebase Auth project.
493
529
  * @returns A promise that resolves with the generated link.
530
+ *
531
+ * @category Email Actions
494
532
  */
495
533
  async generateEmailVerificationLink(email, actionCodeSettings) {
496
534
  const oauth2Token = await this.getOauth2AccessToken();
@@ -519,6 +557,8 @@ export class CloudFireAuth {
519
557
  * The Android package name and iOS bundle ID are respected only if they
520
558
  * are configured in the same Firebase Auth project.
521
559
  * @returns A promise that resolves with the generated link.
560
+ *
561
+ * @category Email Actions
522
562
  */
523
563
  async generateVerifyAndChangeEmailLink(email, newEmail, actionCodeSettings) {
524
564
  const oauth2Token = await this.getOauth2AccessToken();
@@ -571,6 +611,8 @@ export class CloudFireAuth {
571
611
  * The Android package name and iOS bundle ID are respected only if they
572
612
  * are configured in the same Firebase Auth project.
573
613
  * @returns A promise that resolves with the generated link.
614
+ *
615
+ * @category Email Actions
574
616
  */
575
617
  async generateSignInWithEmailLink(email, actionCodeSettings) {
576
618
  const oauth2Token = await this.getOauth2AccessToken();
@@ -587,6 +629,8 @@ export class CloudFireAuth {
587
629
  * @param options - The provider config filter to apply.
588
630
  * @returns A promise that resolves with the list of provider configs meeting the
589
631
  * filter requirements.
632
+ *
633
+ * @category Provider Configuration
590
634
  */
591
635
  async listProviderConfigs(options) {
592
636
  const oauth2Token = await this.getOauth2AccessToken();
@@ -606,6 +650,8 @@ export class CloudFireAuth {
606
650
  * config to return.
607
651
  * @returns A promise that resolves
608
652
  * with the configuration corresponding to the provided ID.
653
+ *
654
+ * @category Provider Configuration
609
655
  */
610
656
  async getProviderConfig(providerId) {
611
657
  const oauth2Token = await this.getOauth2AccessToken();
@@ -623,6 +669,8 @@ export class CloudFireAuth {
623
669
  * @param providerId - The provider ID corresponding to the provider
624
670
  * config to delete.
625
671
  * @returns A promise that resolves on completion.
672
+ *
673
+ * @category Provider Configuration
626
674
  */
627
675
  async deleteProviderConfig(providerId) {
628
676
  const oauth2Token = await this.getOauth2AccessToken();
@@ -642,6 +690,8 @@ export class CloudFireAuth {
642
690
  * config to update.
643
691
  * @param updatedConfig - The updated configuration.
644
692
  * @returns A promise that resolves with the updated provider configuration.
693
+ *
694
+ * @category Provider Configuration
645
695
  */
646
696
  async updateProviderConfig(providerId, updatedConfig) {
647
697
  const oauth2Token = await this.getOauth2AccessToken();
@@ -657,6 +707,8 @@ export class CloudFireAuth {
657
707
  *
658
708
  * @param config - The provider configuration to create.
659
709
  * @returns A promise that resolves with the created provider configuration.
710
+ *
711
+ * @category Provider Configuration
660
712
  */
661
713
  async createProviderConfig(config) {
662
714
  const oauth2Token = await this.getOauth2AccessToken();
@@ -209,7 +209,7 @@ export interface CreateRequest extends UpdateRequest {
209
209
  /**
210
210
  * The response interface for listing provider configs. This is only available
211
211
  * when listing all identity providers' configurations via
212
- * {@link BaseAuth.listProviderConfigs}.
212
+ * {@link CloudFireAuth.listProviderConfigs}.
213
213
  */
214
214
  export interface ListProviderConfigResults {
215
215
  /**
@@ -224,7 +224,7 @@ export interface ListProviderConfigResults {
224
224
  /**
225
225
  * The filter interface used for listing provider configurations. This is used
226
226
  * when specifying how to list configured identity providers via
227
- * {@link BaseAuth.listProviderConfigs}.
227
+ * {@link CloudFireAuth.listProviderConfigs}.
228
228
  */
229
229
  export interface AuthProviderConfigFilter {
230
230
  /**
@@ -247,7 +247,7 @@ export interface AuthProviderConfigFilter {
247
247
  /**
248
248
  * The request interface for updating a SAML Auth provider. This is used
249
249
  * when updating a SAML provider's configuration via
250
- * {@link BaseAuth.updateProviderConfig}.
250
+ * {@link CloudFireAuth.updateProviderConfig}.
251
251
  */
252
252
  export interface SAMLUpdateAuthProviderRequest {
253
253
  /**
@@ -289,7 +289,7 @@ export interface SAMLUpdateAuthProviderRequest {
289
289
  /**
290
290
  * The request interface for updating an OIDC Auth provider. This is used
291
291
  * when updating an OIDC provider's configuration via
292
- * {@link BaseAuth.updateProviderConfig}.
292
+ * {@link CloudFireAuth.updateProviderConfig}.
293
293
  */
294
294
  export interface OIDCUpdateAuthProviderRequest {
295
295
  /**
@@ -489,7 +489,7 @@ export interface BaseAuthProviderConfig {
489
489
  * The
490
490
  * [SAML](http://docs.oasis-open.org/security/saml/Post2.0/sstc-saml-tech-overview-2.0.html)
491
491
  * Auth provider configuration interface. A SAML provider can be created via
492
- * {@link BaseAuth.createProviderConfig}.
492
+ * {@link CloudFireAuth.createProviderConfig}.
493
493
  */
494
494
  export interface SAMLAuthProviderConfig extends BaseAuthProviderConfig {
495
495
  /**
@@ -547,7 +547,7 @@ export interface OAuthResponseType {
547
547
  /**
548
548
  * The [OIDC](https://openid.net/specs/openid-connect-core-1_0-final.html) Auth
549
549
  * provider configuration interface. An OIDC provider can be created via
550
- * {@link BaseAuth.createProviderConfig}.
550
+ * {@link CloudFireAuth.createProviderConfig}.
551
551
  */
552
552
  export interface OIDCAuthProviderConfig extends BaseAuthProviderConfig {
553
553
  /**
@@ -585,7 +585,7 @@ export interface OIDCAuthProviderConfig extends BaseAuthProviderConfig {
585
585
  }
586
586
  /**
587
587
  * The Auth provider configuration type.
588
- * {@link BaseAuth.createProviderConfig}.
588
+ * {@link CloudFireAuth.createProviderConfig}.
589
589
  */
590
590
  export type AuthProviderConfig = SAMLAuthProviderConfig | OIDCAuthProviderConfig;
591
591
  /**
@@ -23,7 +23,7 @@
23
23
  /**
24
24
  * Used for looking up an account by uid.
25
25
  *
26
- * See {@link BaseAuth.getUsers}.
26
+ * See {@link CloudFireAuth.getUsers}.
27
27
  */
28
28
  export interface UidIdentifier {
29
29
  uid: string;
@@ -31,7 +31,7 @@ export interface UidIdentifier {
31
31
  /**
32
32
  * Used for looking up an account by email.
33
33
  *
34
- * See {@link BaseAuth.getUsers}.
34
+ * See {@link CloudFireAuth.getUsers}.
35
35
  */
36
36
  export interface EmailIdentifier {
37
37
  email: string;
@@ -39,7 +39,7 @@ export interface EmailIdentifier {
39
39
  /**
40
40
  * Used for looking up an account by phone number.
41
41
  *
42
- * See {@link BaseAuth.getUsers}.
42
+ * See {@link CloudFireAuth.getUsers}.
43
43
  */
44
44
  export interface PhoneIdentifier {
45
45
  phoneNumber: string;
@@ -47,7 +47,7 @@ export interface PhoneIdentifier {
47
47
  /**
48
48
  * Used for looking up an account by federated provider.
49
49
  *
50
- * See {@link BaseAuth.getUsers}.
50
+ * See {@link CloudFireAuth.getUsers}.
51
51
  */
52
52
  export interface ProviderIdentifier {
53
53
  providerId: string;
@@ -23,11 +23,13 @@
23
23
  */
24
24
  import type { DecodedIdToken } from "./token-verifier.js";
25
25
  import type { UserRecord } from "./user-record.js";
26
- import type { CreateRequest, UpdateRequest, AuthProviderConfig, UpdateAuthProviderRequest, AuthProviderConfigFilter, ListProviderConfigResults } from "./auth-config.js";
27
- import type { UserIdentifier } from "./identifier.js";
26
+ import type { UserMetadata, MultiFactorSettings, UserInfo, MultiFactorInfo } from "./user-record.js";
27
+ import type { CreateRequest, UpdateRequest, AuthProviderConfig, UpdateAuthProviderRequest, AuthProviderConfigFilter, ListProviderConfigResults, SAMLAuthProviderConfig, OIDCAuthProviderConfig, SAMLUpdateAuthProviderRequest, OIDCUpdateAuthProviderRequest, MultiFactorCreateSettings, MultiFactorUpdateSettings, UserProvider, CreatePhoneMultiFactorInfoRequest, UpdatePhoneMultiFactorInfoRequest, OAuthResponseType } from "./auth-config.js";
28
+ import type { UserIdentifier, UidIdentifier, EmailIdentifier, PhoneIdentifier, ProviderIdentifier } from "./identifier.js";
28
29
  import type { ActionCodeSettings } from "./action-code-settings.js";
29
30
  import type { UserImportRecord, UserImportOptions, UserImportResult, HashAlgorithmType, UserMetadataRequest, UserProviderRequest } from "./user-import.js";
30
- export type { DecodedIdToken, UserRecord, CreateRequest, UpdateRequest, UserIdentifier, AuthProviderConfig, UpdateAuthProviderRequest, AuthProviderConfigFilter, ListProviderConfigResults, ActionCodeSettings, UserImportRecord, UserImportOptions, UserImportResult, HashAlgorithmType, UserMetadataRequest, UserProviderRequest, };
31
+ export type { DecodedIdToken, UserRecord, CreateRequest, UpdateRequest, UserIdentifier, UidIdentifier, EmailIdentifier, PhoneIdentifier, ProviderIdentifier, AuthProviderConfig, SAMLAuthProviderConfig, OIDCAuthProviderConfig, UpdateAuthProviderRequest, SAMLUpdateAuthProviderRequest, OIDCUpdateAuthProviderRequest, AuthProviderConfigFilter, ListProviderConfigResults, ActionCodeSettings, UserImportRecord, UserImportOptions, UserImportResult, HashAlgorithmType, UserMetadataRequest, UserProviderRequest, MultiFactorCreateSettings, MultiFactorUpdateSettings, UserProvider, CreatePhoneMultiFactorInfoRequest, UpdatePhoneMultiFactorInfoRequest, OAuthResponseType, };
32
+ export type { UserMetadata, MultiFactorSettings, UserInfo, MultiFactorInfo };
31
33
  /**
32
34
  * `FirebaseError` is a subclass of the standard JavaScript `Error` object. In
33
35
  * addition to a message string and stack trace, it contains a string code.
@@ -100,7 +102,7 @@ export interface FirebaseArrayIndexError {
100
102
  */
101
103
  error: FirebaseError;
102
104
  }
103
- /** Represents the result of the {@link BaseAuth.getUsers} API. */
105
+ /** Represents the result of the {@link CloudFireAuth.getUsers} API. */
104
106
  export interface GetUsersResult {
105
107
  /**
106
108
  * Set of user records, corresponding to the set of users that were
@@ -113,7 +115,7 @@ export interface GetUsersResult {
113
115
  }
114
116
  /**
115
117
  * Interface representing the object returned from a
116
- * {@link BaseAuth.listUsers} operation. Contains the list
118
+ * {@link CloudFireAuth.listUsers} operation. Contains the list
117
119
  * of users for the current batch and the next page token if available.
118
120
  */
119
121
  export interface ListUsersResult {
@@ -128,7 +130,7 @@ export interface ListUsersResult {
128
130
  pageToken?: string;
129
131
  }
130
132
  /**
131
- * Represents the result of the {@link BaseAuth.deleteUsers}.
133
+ * Represents the result of the {@link CloudFireAuth.deleteUsers}.
132
134
  * API.
133
135
  */
134
136
  export interface DeleteUsersResult {
@@ -151,7 +153,7 @@ export interface DeleteUsersResult {
151
153
  }
152
154
  /**
153
155
  * Interface representing the session cookie options needed for the
154
- * {@link BaseAuth.createSessionCookie} method.
156
+ * {@link CloudFireAuth.createSessionCookie} method.
155
157
  */
156
158
  export interface SessionCookieOptions {
157
159
  /**
@@ -22,7 +22,7 @@
22
22
  */
23
23
  /**
24
24
  * Interface representing a decoded Firebase ID token, returned from the
25
- * {@link BaseAuth.verifyIdToken} method.
25
+ * {@link CloudFireAuth.verifyIdToken} method.
26
26
  *
27
27
  * Firebase ID tokens are OpenID Connect spec-compliant JSON Web Tokens (JWTs).
28
28
  * See the
@@ -36,7 +36,7 @@ import type { MultiFactorUpdateSettings } from "./auth-config.js";
36
36
  export type HashAlgorithmType = "SCRYPT" | "STANDARD_SCRYPT" | "HMAC_SHA512" | "HMAC_SHA256" | "HMAC_SHA1" | "HMAC_MD5" | "MD5" | "PBKDF_SHA1" | "BCRYPT" | "PBKDF2_SHA256" | "SHA512" | "SHA256" | "SHA1";
37
37
  /**
38
38
  * Interface representing the user import options needed for
39
- * {@link BaseAuth.importUsers} method. This is used to
39
+ * {@link CloudFireAuth.importUsers} method. This is used to
40
40
  * provide the password hashing algorithm information.
41
41
  */
42
42
  export interface UserImportOptions {
@@ -135,7 +135,7 @@ export interface UserProviderRequest {
135
135
  }
136
136
  /**
137
137
  * Interface representing a user to import to Firebase Auth via the
138
- * {@link BaseAuth.importUsers} method.
138
+ * {@link CloudFireAuth.importUsers} method.
139
139
  */
140
140
  export interface UserImportRecord {
141
141
  /**
@@ -207,7 +207,7 @@ export interface UserImportRecord {
207
207
  multiFactor?: MultiFactorUpdateSettings;
208
208
  }
209
209
  /**
210
- * Interface representing the result of the {@link BaseAuth.importUsers} API.
210
+ * Interface representing the result of the {@link CloudFireAuth.importUsers} API.
211
211
  */
212
212
  export interface UserImportResult {
213
213
  /**
@@ -251,7 +251,7 @@ export declare class UserRecord {
251
251
  * when uploading this user, as is typical when migrating from another Auth
252
252
  * system, this will be an empty string. If no password is set, this is
253
253
  * null. This is only available when the user is obtained from
254
- * {@link BaseAuth.listUsers}.
254
+ * {@link CloudFireAuth.listUsers}.
255
255
  */
256
256
  readonly passwordHash?: string;
257
257
  /**
@@ -259,13 +259,13 @@ export declare class UserRecord {
259
259
  * algorithm (SCRYPT) is used. If a different hashing algorithm had been used to
260
260
  * upload this user, typical when migrating from another Auth system, this will
261
261
  * be an empty string. If no password is set, this is null. This is only
262
- * available when the user is obtained from {@link BaseAuth.listUsers}.
262
+ * available when the user is obtained from {@link CloudFireAuth.listUsers}.
263
263
  */
264
264
  readonly passwordSalt?: string;
265
265
  /**
266
266
  * The user's custom claims object if available, typically used to define
267
267
  * user roles and propagated to an authenticated user's ID token.
268
- * This is set via {@link BaseAuth.setCustomUserClaims}
268
+ * This is set via {@link CloudFireAuth.setCustomUserClaims}
269
269
  */
270
270
  readonly customClaims?: {
271
271
  [key: string]: any;
@@ -277,7 +277,7 @@ export declare class UserRecord {
277
277
  /**
278
278
  * The date the user's tokens are valid after, formatted as a UTC string.
279
279
  * This is updated every time the user's refresh token are revoked either
280
- * from the {@link BaseAuth.revokeRefreshTokens}
280
+ * from the {@link CloudFireAuth.revokeRefreshTokens}
281
281
  * API or from the Firebase Auth backend on big account changes (password
282
282
  * resets, password or email updates, etc).
283
283
  */
@@ -1,4 +1,4 @@
1
- interface ProviderUserInfo {
1
+ export interface ProviderUserInfo {
2
2
  providerId: string;
3
3
  displayName?: string;
4
4
  photoUrl?: string;
@@ -22,4 +22,3 @@ export interface SetAccountInfoResponse {
22
22
  passwordHash: string;
23
23
  emailVerified: boolean;
24
24
  }
25
- export {};
package/dist/types.d.ts CHANGED
@@ -1,6 +1,3 @@
1
- import type { DecodedIdToken, UserRecord, UserIdentifier, GetUsersResult, ListUsersResult, CreateRequest, UpdateRequest, DeleteUsersResult, SessionCookieOptions, AuthProviderConfig, UpdateAuthProviderRequest, AuthProviderConfigFilter, ListProviderConfigResults, ActionCodeSettings, UserImportRecord, UserImportOptions, UserImportResult, HashAlgorithmType, UserMetadataRequest, UserProviderRequest } from "./types/firebase-admin/index.js";
2
- import type { ServiceAccountKey } from "./types/service-account-key.js";
3
- import type { SetAccountInfoResponse } from "./types/google-auth.js";
4
- export type { DecodedIdToken, UserRecord, UserIdentifier, GetUsersResult, ListUsersResult, CreateRequest, UpdateRequest, DeleteUsersResult, SessionCookieOptions, AuthProviderConfig, UpdateAuthProviderRequest, AuthProviderConfigFilter, ListProviderConfigResults, ActionCodeSettings, UserImportRecord, UserImportOptions, UserImportResult, HashAlgorithmType, UserMetadataRequest, UserProviderRequest, };
5
- export type { ServiceAccountKey };
6
- export type { SetAccountInfoResponse };
1
+ export type { DecodedIdToken, UserRecord, UserIdentifier, GetUsersResult, ListUsersResult, CreateRequest, UpdateRequest, DeleteUsersResult, SessionCookieOptions, AuthProviderConfig, UpdateAuthProviderRequest, AuthProviderConfigFilter, ListProviderConfigResults, ActionCodeSettings, UserImportRecord, UserImportOptions, UserImportResult, HashAlgorithmType, UserMetadataRequest, UserProviderRequest, SAMLAuthProviderConfig, OIDCAuthProviderConfig, SAMLUpdateAuthProviderRequest, OIDCUpdateAuthProviderRequest, MultiFactorCreateSettings, MultiFactorUpdateSettings, MultiFactorSettings, UserMetadata, UserInfo, UserProvider, FirebaseArrayIndexError, FirebaseError, UidIdentifier, EmailIdentifier, PhoneIdentifier, ProviderIdentifier, CreatePhoneMultiFactorInfoRequest, UpdatePhoneMultiFactorInfoRequest, OAuthResponseType, MultiFactorInfo, } from "./types/firebase-admin/index.js";
2
+ export type { ServiceAccountKey } from "./types/service-account-key.js";
3
+ export type { SetAccountInfoResponse, ProviderUserInfo } from "./types/google-auth.js";
package/package.json CHANGED
@@ -1,56 +1,68 @@
1
- {
2
- "name": "cloudfire-auth",
3
- "version": "0.3.2",
4
- "author": "Connor Skelland",
5
- "license": "MIT",
6
- "engines": {
7
- "node": ">=18.0.0"
8
- },
9
- "description": "Firebase Auth in Cloudflare Workers.",
10
- "homepage": "https://github.com/connor56/cloudfire-auth",
11
- "keywords": [
12
- "firebase",
13
- "auth",
14
- "cloudflare",
15
- "workers",
16
- "authentication",
17
- "jwt",
18
- "firebase-auth"
19
- ],
20
- "type": "module",
21
- "types": "dist/index.d.ts",
22
- "exports": {
23
- ".": {
24
- "import": "./dist/index.js",
25
- "types": "./dist/index.d.ts"
26
- }
27
- },
28
- "scripts": {
29
- "test": "vitest run",
30
- "test:integration": "RUN_INTEGRATION_TESTS=true vitest run",
31
- "build": "tsc",
32
- "clean": "tsx scripts/publishing/remove-dist.ts",
33
- "build:watch": "tsc --watch",
34
- "prepublishOnly": "npm run test && npm run clean && npm run build"
35
- },
36
- "devDependencies": {
37
- "@cloudflare/workers-types": "^4.20250816.0",
38
- "@types/node": "^24.3.0",
39
- "dotenv": "^17.2.1",
40
- "firebase-admin": "^13.4.0",
41
- "tsx": "^4.20.4",
42
- "typescript": "^5.9.2",
43
- "vitest": "^3.1.0"
44
- },
45
- "files": [
46
- "dist",
47
- "LICENSE",
48
- "NOTICE",
49
- "README.md",
50
- "package.json",
51
- "third_party/*"
52
- ],
53
- "dependencies": {
54
- "jose": "^6.0.12"
55
- }
56
- }
1
+ {
2
+ "name": "cloudfire-auth",
3
+ "version": "0.4.0",
4
+ "author": "Connor Skelland",
5
+ "license": "MIT",
6
+ "engines": {
7
+ "node": ">=18.0.0"
8
+ },
9
+ "description": "Firebase Auth in Cloudflare Workers.",
10
+ "homepage": "https://connor56.github.io/cloudfire-auth/",
11
+ "repository": {
12
+ "type": "git",
13
+ "url": "git+https://github.com/Connor56/cloudfire-auth.git"
14
+ },
15
+ "bugs": {
16
+ "url": "https://github.com/Connor56/cloudfire-auth/issues"
17
+ },
18
+ "keywords": [
19
+ "firebase",
20
+ "auth",
21
+ "cloudflare",
22
+ "workers",
23
+ "authentication",
24
+ "jwt",
25
+ "firebase-auth"
26
+ ],
27
+ "type": "module",
28
+ "types": "dist/index.d.ts",
29
+ "exports": {
30
+ ".": {
31
+ "import": "./dist/index.js",
32
+ "types": "./dist/index.d.ts"
33
+ }
34
+ },
35
+ "scripts": {
36
+ "test": "vitest run",
37
+ "test:integration": "npx tsx scripts/test-integration.ts",
38
+ "build": "tsc",
39
+ "clean": "tsx scripts/publishing/remove-dist.ts",
40
+ "build:watch": "tsc --watch",
41
+ "docs:build": "npx tsx scripts/docs/build-docs.ts",
42
+ "prepublishOnly": "npm run test && npm run clean && npm run build"
43
+ },
44
+ "devDependencies": {
45
+ "@cloudflare/workers-types": "^4.20250816.0",
46
+ "@types/node": "^24.3.0",
47
+ "dotenv": "^17.2.1",
48
+ "firebase-admin": "^13.4.0",
49
+ "tsx": "^4.20.4",
50
+ "typedoc": "^0.28.15",
51
+ "typedoc-plugin-markdown": "^4.9.0",
52
+ "typedoc-vitepress-theme": "^1.1.2",
53
+ "typescript": "^5.9.2",
54
+ "vitepress": "^1.6.4",
55
+ "vitest": "^3.1.0"
56
+ },
57
+ "files": [
58
+ "dist",
59
+ "LICENSE",
60
+ "NOTICE",
61
+ "README.md",
62
+ "package.json",
63
+ "third_party/*"
64
+ ],
65
+ "dependencies": {
66
+ "jose": "^6.0.12"
67
+ }
68
+ }