firebase-admin 13.9.0 → 14.0.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.
Files changed (281) hide show
  1. package/README.md +1 -2
  2. package/lib/app/core.d.ts +2 -38
  3. package/lib/app/core.js +1 -1
  4. package/lib/app/credential-factory.d.ts +1 -1
  5. package/lib/app/credential-factory.js +1 -1
  6. package/lib/app/credential-internal.d.ts +1 -1
  7. package/lib/app/credential-internal.js +48 -17
  8. package/lib/app/credential.d.ts +1 -1
  9. package/lib/app/credential.js +1 -1
  10. package/lib/app/error.d.ts +47 -0
  11. package/lib/app/error.js +57 -0
  12. package/lib/app/firebase-app.d.ts +1 -1
  13. package/lib/app/firebase-app.js +28 -12
  14. package/lib/app/index.d.ts +4 -3
  15. package/lib/app/index.js +6 -4
  16. package/lib/app/lifecycle.d.ts +2 -2
  17. package/lib/app/lifecycle.js +46 -21
  18. package/lib/app-check/app-check-api-client-internal.d.ts +2 -16
  19. package/lib/app-check/app-check-api-client-internal.js +71 -47
  20. package/lib/app-check/app-check-api.d.ts +19 -1
  21. package/lib/app-check/app-check-api.js +1 -1
  22. package/lib/app-check/app-check.d.ts +1 -1
  23. package/lib/app-check/app-check.js +7 -3
  24. package/lib/app-check/error.d.ts +47 -0
  25. package/lib/app-check/error.js +65 -0
  26. package/lib/app-check/index.d.ts +2 -1
  27. package/lib/app-check/index.js +5 -2
  28. package/lib/app-check/token-generator.d.ts +1 -1
  29. package/lib/app-check/token-generator.js +43 -13
  30. package/lib/app-check/token-verifier.d.ts +1 -1
  31. package/lib/app-check/token-verifier.js +39 -11
  32. package/lib/auth/action-code-settings-builder.d.ts +1 -1
  33. package/lib/auth/action-code-settings-builder.js +16 -16
  34. package/lib/auth/auth-api-request.d.ts +6 -4
  35. package/lib/auth/auth-api-request.js +277 -166
  36. package/lib/auth/auth-config.d.ts +31 -2
  37. package/lib/auth/auth-config.js +103 -103
  38. package/lib/auth/auth.d.ts +1 -1
  39. package/lib/auth/auth.js +1 -1
  40. package/lib/auth/base-auth.d.ts +2 -1
  41. package/lib/auth/base-auth.js +29 -27
  42. package/lib/auth/error.d.ts +137 -0
  43. package/lib/auth/error.js +690 -0
  44. package/lib/auth/identifier.d.ts +1 -1
  45. package/lib/auth/identifier.js +1 -1
  46. package/lib/auth/index.d.ts +2 -2
  47. package/lib/auth/index.js +4 -4
  48. package/lib/auth/project-config-manager.d.ts +1 -1
  49. package/lib/auth/project-config-manager.js +1 -1
  50. package/lib/auth/project-config.d.ts +1 -1
  51. package/lib/auth/project-config.js +4 -4
  52. package/lib/auth/tenant-manager.d.ts +2 -1
  53. package/lib/auth/tenant-manager.js +13 -10
  54. package/lib/auth/tenant.d.ts +1 -1
  55. package/lib/auth/tenant.js +7 -7
  56. package/lib/auth/token-generator.d.ts +1 -1
  57. package/lib/auth/token-generator.js +13 -13
  58. package/lib/auth/token-verifier.d.ts +1 -1
  59. package/lib/auth/token-verifier.js +22 -22
  60. package/lib/auth/user-import-builder.d.ts +1 -1
  61. package/lib/auth/user-import-builder.js +22 -22
  62. package/lib/auth/user-record.d.ts +1 -1
  63. package/lib/auth/user-record.js +6 -6
  64. package/lib/credential/index.d.ts +1 -1
  65. package/lib/credential/index.js +1 -1
  66. package/lib/data-connect/data-connect-api-client-internal.d.ts +1 -16
  67. package/lib/data-connect/data-connect-api-client-internal.js +122 -65
  68. package/lib/data-connect/data-connect-api.d.ts +1 -1
  69. package/lib/data-connect/data-connect-api.js +1 -1
  70. package/lib/data-connect/data-connect.d.ts +1 -1
  71. package/lib/data-connect/data-connect.js +1 -1
  72. package/lib/data-connect/error.d.ts +47 -0
  73. package/lib/data-connect/error.js +66 -0
  74. package/lib/data-connect/index.d.ts +2 -1
  75. package/lib/data-connect/index.js +5 -2
  76. package/lib/data-connect/validate-admin-args.d.ts +1 -1
  77. package/lib/data-connect/validate-admin-args.js +6 -3
  78. package/lib/database/database.d.ts +1 -1
  79. package/lib/database/database.js +11 -6
  80. package/lib/database/error.d.ts +39 -0
  81. package/lib/database/error.js +49 -0
  82. package/lib/database/index.d.ts +2 -2
  83. package/lib/database/index.js +4 -3
  84. package/lib/esm/app/index.js +2 -1
  85. package/lib/esm/app-check/index.js +2 -0
  86. package/lib/esm/auth/index.js +1 -1
  87. package/lib/esm/data-connect/index.js +2 -0
  88. package/lib/esm/database/index.js +1 -0
  89. package/lib/esm/eventarc/index.js +2 -0
  90. package/lib/esm/extensions/index.js +2 -0
  91. package/lib/esm/firebase-admin/index.js +13 -0
  92. package/lib/esm/firestore/index.js +1 -0
  93. package/lib/esm/functions/index.js +2 -0
  94. package/lib/esm/installations/index.js +1 -1
  95. package/lib/esm/machine-learning/index.js +2 -0
  96. package/lib/esm/messaging/index.js +1 -1
  97. package/lib/esm/phone-number-verification/index.js +2 -0
  98. package/lib/esm/project-management/index.js +1 -0
  99. package/lib/esm/remote-config/index.js +2 -0
  100. package/lib/esm/security-rules/index.js +2 -0
  101. package/lib/esm/storage/index.js +2 -0
  102. package/lib/eventarc/cloudevent.d.ts +1 -1
  103. package/lib/eventarc/cloudevent.js +1 -1
  104. package/lib/eventarc/error.d.ts +38 -0
  105. package/lib/eventarc/error.js +47 -0
  106. package/lib/eventarc/eventarc-client-internal.d.ts +1 -1
  107. package/lib/eventarc/eventarc-client-internal.js +24 -9
  108. package/lib/eventarc/eventarc-utils.d.ts +1 -13
  109. package/lib/eventarc/eventarc-utils.js +36 -26
  110. package/lib/eventarc/eventarc.d.ts +1 -1
  111. package/lib/eventarc/eventarc.js +18 -6
  112. package/lib/eventarc/index.d.ts +2 -1
  113. package/lib/eventarc/index.js +5 -2
  114. package/lib/extensions/error.d.ts +41 -0
  115. package/lib/extensions/error.js +50 -0
  116. package/lib/extensions/extensions-api-client-internal.d.ts +1 -13
  117. package/lib/extensions/extensions-api-client-internal.js +40 -28
  118. package/lib/extensions/extensions-api.d.ts +1 -1
  119. package/lib/extensions/extensions-api.js +1 -1
  120. package/lib/extensions/extensions.d.ts +1 -1
  121. package/lib/extensions/extensions.js +18 -5
  122. package/lib/extensions/index.d.ts +2 -1
  123. package/lib/extensions/index.js +5 -2
  124. package/lib/firestore/error.d.ts +41 -0
  125. package/lib/firestore/error.js +51 -0
  126. package/lib/firestore/firestore-internal.d.ts +2 -1
  127. package/lib/firestore/firestore-internal.js +6 -6
  128. package/lib/firestore/index.d.ts +2 -2
  129. package/lib/firestore/index.js +7 -7
  130. package/lib/functions/error.d.ts +48 -0
  131. package/lib/functions/error.js +67 -0
  132. package/lib/functions/functions-api-client-internal.d.ts +1 -16
  133. package/lib/functions/functions-api-client-internal.js +111 -71
  134. package/lib/functions/functions-api.d.ts +1 -1
  135. package/lib/functions/functions-api.js +1 -1
  136. package/lib/functions/functions.d.ts +1 -1
  137. package/lib/functions/functions.js +14 -4
  138. package/lib/functions/index.d.ts +2 -1
  139. package/lib/functions/index.js +5 -2
  140. package/lib/index.d.ts +13 -8
  141. package/lib/index.js +19 -3
  142. package/lib/installations/error.d.ts +48 -0
  143. package/lib/installations/error.js +73 -0
  144. package/lib/installations/index.d.ts +2 -2
  145. package/lib/installations/index.js +4 -4
  146. package/lib/installations/installations-request-handler.d.ts +1 -1
  147. package/lib/installations/installations-request-handler.js +11 -5
  148. package/lib/installations/installations.d.ts +1 -1
  149. package/lib/installations/installations.js +3 -3
  150. package/lib/machine-learning/error.d.ts +53 -0
  151. package/lib/machine-learning/error.js +84 -0
  152. package/lib/machine-learning/index.d.ts +2 -1
  153. package/lib/machine-learning/index.js +5 -2
  154. package/lib/machine-learning/machine-learning-api-client.d.ts +1 -1
  155. package/lib/machine-learning/machine-learning-api-client.js +61 -24
  156. package/lib/machine-learning/machine-learning.d.ts +1 -1
  157. package/lib/machine-learning/machine-learning.js +21 -9
  158. package/lib/messaging/error.d.ts +63 -0
  159. package/lib/messaging/error.js +286 -0
  160. package/lib/messaging/index.d.ts +3 -3
  161. package/lib/messaging/index.js +4 -4
  162. package/lib/messaging/messaging-api-request-internal.d.ts +1 -1
  163. package/lib/messaging/messaging-api-request-internal.js +1 -1
  164. package/lib/messaging/messaging-api.d.ts +1 -280
  165. package/lib/messaging/messaging-api.js +1 -1
  166. package/lib/messaging/messaging-errors-internal.d.ts +2 -2
  167. package/lib/messaging/messaging-errors-internal.js +11 -8
  168. package/lib/messaging/messaging-internal.d.ts +1 -1
  169. package/lib/messaging/messaging-internal.js +48 -48
  170. package/lib/messaging/messaging.d.ts +1 -1
  171. package/lib/messaging/messaging.js +47 -50
  172. package/lib/phone-number-verification/error.d.ts +43 -0
  173. package/lib/phone-number-verification/error.js +48 -0
  174. package/lib/phone-number-verification/index.d.ts +2 -1
  175. package/lib/phone-number-verification/index.js +5 -2
  176. package/lib/phone-number-verification/phone-number-verification-api-client-internal.d.ts +1 -18
  177. package/lib/phone-number-verification/phone-number-verification-api-client-internal.js +2 -26
  178. package/lib/phone-number-verification/phone-number-verification-api.d.ts +2 -2
  179. package/lib/phone-number-verification/phone-number-verification-api.js +5 -4
  180. package/lib/phone-number-verification/phone-number-verification.d.ts +1 -1
  181. package/lib/phone-number-verification/phone-number-verification.js +1 -1
  182. package/lib/phone-number-verification/token-verifier.d.ts +1 -1
  183. package/lib/phone-number-verification/token-verifier.js +68 -20
  184. package/lib/project-management/android-app.d.ts +1 -1
  185. package/lib/project-management/android-app.js +15 -6
  186. package/lib/project-management/app-metadata.d.ts +1 -1
  187. package/lib/project-management/app-metadata.js +1 -1
  188. package/lib/project-management/error.d.ts +45 -0
  189. package/lib/project-management/error.js +55 -0
  190. package/lib/project-management/index.d.ts +2 -2
  191. package/lib/project-management/index.js +4 -3
  192. package/lib/project-management/ios-app.d.ts +1 -1
  193. package/lib/project-management/ios-app.js +6 -3
  194. package/lib/project-management/project-management-api-request-internal.d.ts +1 -1
  195. package/lib/project-management/project-management-api-request-internal.js +18 -6
  196. package/lib/project-management/project-management.d.ts +1 -1
  197. package/lib/project-management/project-management.js +13 -7
  198. package/lib/remote-config/condition-evaluator-internal.d.ts +1 -1
  199. package/lib/remote-config/condition-evaluator-internal.js +4 -4
  200. package/lib/remote-config/error.d.ts +49 -0
  201. package/lib/remote-config/error.js +70 -0
  202. package/lib/remote-config/index.d.ts +2 -1
  203. package/lib/remote-config/index.js +5 -2
  204. package/lib/remote-config/internal/value-impl.d.ts +1 -1
  205. package/lib/remote-config/internal/value-impl.js +1 -1
  206. package/lib/remote-config/remote-config-api-client-internal.d.ts +2 -13
  207. package/lib/remote-config/remote-config-api-client-internal.js +80 -52
  208. package/lib/remote-config/remote-config-api.d.ts +1 -1
  209. package/lib/remote-config/remote-config-api.js +1 -1
  210. package/lib/remote-config/remote-config.d.ts +1 -1
  211. package/lib/remote-config/remote-config.js +92 -23
  212. package/lib/security-rules/error.d.ts +45 -0
  213. package/lib/security-rules/error.js +54 -0
  214. package/lib/security-rules/index.d.ts +2 -1
  215. package/lib/security-rules/index.js +5 -2
  216. package/lib/security-rules/security-rules-api-client-internal.d.ts +1 -1
  217. package/lib/security-rules/security-rules-api-client-internal.js +50 -18
  218. package/lib/security-rules/security-rules.d.ts +1 -1
  219. package/lib/security-rules/security-rules.js +32 -11
  220. package/lib/storage/error.d.ts +41 -0
  221. package/lib/storage/error.js +50 -0
  222. package/lib/storage/index.d.ts +2 -1
  223. package/lib/storage/index.js +8 -5
  224. package/lib/storage/storage.d.ts +1 -1
  225. package/lib/storage/storage.js +12 -12
  226. package/lib/storage/utils.d.ts +1 -1
  227. package/lib/storage/utils.js +1 -1
  228. package/lib/utils/api-request.d.ts +12 -12
  229. package/lib/utils/api-request.js +97 -55
  230. package/lib/utils/crypto-signer.d.ts +1 -1
  231. package/lib/utils/crypto-signer.js +2 -7
  232. package/lib/utils/deep-copy.d.ts +1 -1
  233. package/lib/utils/deep-copy.js +1 -1
  234. package/lib/utils/error.d.ts +75 -570
  235. package/lib/utils/error.js +53 -1047
  236. package/lib/utils/index.d.ts +1 -1
  237. package/lib/utils/index.js +2 -2
  238. package/lib/utils/jwt.d.ts +1 -1
  239. package/lib/utils/jwt.js +1 -2
  240. package/lib/utils/validator.d.ts +1 -1
  241. package/lib/utils/validator.js +1 -1
  242. package/package.json +25 -33
  243. package/lib/app/firebase-namespace.d.ts +0 -163
  244. package/lib/app/firebase-namespace.js +0 -335
  245. package/lib/app-check/app-check-namespace.d.ts +0 -72
  246. package/lib/app-check/app-check-namespace.js +0 -18
  247. package/lib/auth/auth-namespace.d.ts +0 -257
  248. package/lib/auth/auth-namespace.js +0 -18
  249. package/lib/database/database-namespace.d.ts +0 -95
  250. package/lib/database/database-namespace.js +0 -23
  251. package/lib/default-namespace.d.ts +0 -24
  252. package/lib/default-namespace.js +0 -30
  253. package/lib/esm/instance-id/index.js +0 -6
  254. package/lib/firebase-namespace-api.d.ts +0 -91
  255. package/lib/firebase-namespace-api.js +0 -58
  256. package/lib/firestore/firestore-namespace.d.ts +0 -71
  257. package/lib/firestore/firestore-namespace.js +0 -52
  258. package/lib/installations/installations-namespace.d.ts +0 -55
  259. package/lib/installations/installations-namespace.js +0 -18
  260. package/lib/instance-id/index.d.ts +0 -62
  261. package/lib/instance-id/index.js +0 -74
  262. package/lib/instance-id/instance-id-namespace.d.ts +0 -38
  263. package/lib/instance-id/instance-id-namespace.js +0 -3
  264. package/lib/instance-id/instance-id.d.ts +0 -47
  265. package/lib/instance-id/instance-id.js +0 -77
  266. package/lib/machine-learning/machine-learning-namespace.d.ts +0 -81
  267. package/lib/machine-learning/machine-learning-namespace.js +0 -18
  268. package/lib/machine-learning/machine-learning-utils.d.ts +0 -22
  269. package/lib/machine-learning/machine-learning-utils.js +0 -47
  270. package/lib/messaging/messaging-namespace.d.ts +0 -161
  271. package/lib/messaging/messaging-namespace.js +0 -18
  272. package/lib/project-management/project-management-namespace.d.ts +0 -82
  273. package/lib/project-management/project-management-namespace.js +0 -18
  274. package/lib/remote-config/remote-config-namespace.d.ts +0 -141
  275. package/lib/remote-config/remote-config-namespace.js +0 -18
  276. package/lib/security-rules/security-rules-internal.d.ts +0 -21
  277. package/lib/security-rules/security-rules-internal.js +0 -26
  278. package/lib/security-rules/security-rules-namespace.d.ts +0 -69
  279. package/lib/security-rules/security-rules-namespace.js +0 -18
  280. package/lib/storage/storage-namespace.d.ts +0 -45
  281. package/lib/storage/storage-namespace.js +0 -18
@@ -1,18 +0,0 @@
1
- /*! firebase-admin v13.9.0 */
2
- "use strict";
3
- /*!
4
- * Copyright 2021 Google LLC
5
- *
6
- * Licensed under the Apache License, Version 2.0 (the "License");
7
- * you may not use this file except in compliance with the License.
8
- * You may obtain a copy of the License at
9
- *
10
- * http://www.apache.org/licenses/LICENSE-2.0
11
- *
12
- * Unless required by applicable law or agreed to in writing, software
13
- * distributed under the License is distributed on an "AS IS" BASIS,
14
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
- * See the License for the specific language governing permissions and
16
- * limitations under the License.
17
- */
18
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,95 +0,0 @@
1
- /*! firebase-admin v13.9.0 */
2
- /*!
3
- * Copyright 2021 Google LLC
4
- *
5
- * Licensed under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License.
7
- * You may obtain a copy of the License at
8
- *
9
- * http://www.apache.org/licenses/LICENSE-2.0
10
- *
11
- * Unless required by applicable law or agreed to in writing, software
12
- * distributed under the License is distributed on an "AS IS" BASIS,
13
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- * See the License for the specific language governing permissions and
15
- * limitations under the License.
16
- */
17
- import * as rtdb from '@firebase/database-types';
18
- import { App } from '../app';
19
- import { Database as TDatabase } from './database';
20
- /**
21
- * Gets the {@link firebase-admin.database#Database} service for the default
22
- * app or a given app.
23
- *
24
- * `admin.database()` can be called with no arguments to access the default
25
- * app's `Database` service or as `admin.database(app)` to access the
26
- * `Database` service associated with a specific app.
27
- *
28
- * `admin.database` is also a namespace that can be used to access global
29
- * constants and methods associated with the `Database` service.
30
- *
31
- * @example
32
- * ```javascript
33
- * // Get the Database service for the default app
34
- * var defaultDatabase = admin.database();
35
- * ```
36
- *
37
- * @example
38
- * ```javascript
39
- * // Get the Database service for a specific app
40
- * var otherDatabase = admin.database(app);
41
- * ```
42
- *
43
- * @param App - whose `Database` service to
44
- * return. If not provided, the default `Database` service will be returned.
45
- *
46
- * @returns The default `Database` service if no app
47
- * is provided or the `Database` service associated with the provided app.
48
- */
49
- export declare function database(app?: App): database.Database;
50
- export declare namespace database {
51
- /**
52
- * Type alias to {@link firebase-admin.database#Database}.
53
- */
54
- type Database = TDatabase;
55
- /**
56
- * Type alias to {@link https://firebase.google.com/docs/reference/js/v8/firebase.database.DataSnapshot | DataSnapshot}
57
- * type from the `@firebase/database-compat` package.
58
- */
59
- type DataSnapshot = rtdb.DataSnapshot;
60
- /**
61
- * Type alias to the {@link https://firebase.google.com/docs/reference/js/v8/firebase.database#eventtype | EventType}
62
- * type from the `@firebase/database-compat` package.
63
- */
64
- type EventType = rtdb.EventType;
65
- /**
66
- * Type alias to {@link https://firebase.google.com/docs/reference/js/v8/firebase.database.OnDisconnect | OnDisconnect}
67
- * type from the `@firebase/database-compat` package.
68
- */
69
- type OnDisconnect = rtdb.OnDisconnect;
70
- /**
71
- * Type alias to {@link https://firebase.google.com/docs/reference/js/v8/firebase.database.Query | Query}
72
- * type from the `@firebase/database-compat` package.
73
- */
74
- type Query = rtdb.Query;
75
- /**
76
- * Type alias to {@link https://firebase.google.com/docs/reference/js/v8/firebase.database.Reference | Reference}
77
- * type from the `@firebase/database-compat` package.
78
- */
79
- type Reference = rtdb.Reference;
80
- /**
81
- * Type alias to {@link https://firebase.google.com/docs/reference/js/v8/firebase.database.ThenableReference |
82
- * ThenableReference} type from the `@firebase/database-compat` package.
83
- */
84
- type ThenableReference = rtdb.ThenableReference;
85
- /**
86
- * {@link https://firebase.google.com/docs/reference/js/v8/firebase.database#enablelogging | enableLogging}
87
- * function from the `@firebase/database-compat` package.
88
- */
89
- const enableLogging: typeof rtdb.enableLogging;
90
- /**
91
- * {@link https://firebase.google.com/docs/reference/js/v8/firebase.database.ServerValue | ServerValue}
92
- * constant from the `@firebase/database-compat` package.
93
- */
94
- const ServerValue: rtdb.ServerValue;
95
- }
@@ -1,23 +0,0 @@
1
- /*! firebase-admin v13.9.0 */
2
- "use strict";
3
- /*!
4
- * Copyright 2021 Google LLC
5
- *
6
- * Licensed under the Apache License, Version 2.0 (the "License");
7
- * you may not use this file except in compliance with the License.
8
- * You may obtain a copy of the License at
9
- *
10
- * http://www.apache.org/licenses/LICENSE-2.0
11
- *
12
- * Unless required by applicable law or agreed to in writing, software
13
- * distributed under the License is distributed on an "AS IS" BASIS,
14
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
- * See the License for the specific language governing permissions and
16
- * limitations under the License.
17
- */
18
- Object.defineProperty(exports, "__esModule", { value: true });
19
- exports.database = void 0;
20
- /* eslint-disable @typescript-eslint/no-namespace */
21
- var database;
22
- (function (database) {
23
- })(database || (exports.database = database = {}));
@@ -1,24 +0,0 @@
1
- /*! firebase-admin v13.9.0 */
2
- /*!
3
- * Copyright 2020 Google LLC
4
- *
5
- * Licensed under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License.
7
- * You may obtain a copy of the License at
8
- *
9
- * http://www.apache.org/licenses/LICENSE-2.0
10
- *
11
- * Unless required by applicable law or agreed to in writing, software
12
- * distributed under the License is distributed on an "AS IS" BASIS,
13
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- * See the License for the specific language governing permissions and
15
- * limitations under the License.
16
- */
17
-
18
- /**
19
- * Firebase namespaced API (legacy).
20
- *
21
- * @packageDocumentation
22
- */
23
-
24
- export * from './firebase-namespace-api';
@@ -1,30 +0,0 @@
1
- /*! firebase-admin v13.9.0 */
2
- "use strict";
3
- /*!
4
- * @license
5
- * Copyright 2017 Google LLC
6
- *
7
- * Licensed under the Apache License, Version 2.0 (the "License");
8
- * you may not use this file except in compliance with the License.
9
- * You may obtain a copy of the License at
10
- *
11
- * http://www.apache.org/licenses/LICENSE-2.0
12
- *
13
- * Unless required by applicable law or agreed to in writing, software
14
- * distributed under the License is distributed on an "AS IS" BASIS,
15
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
- * See the License for the specific language governing permissions and
17
- * limitations under the License.
18
- */
19
- const firebase_namespace_1 = require("./app/firebase-namespace");
20
- // Inject a circular default export to allow users to use both:
21
- //
22
- // import firebaseAdmin from 'firebase-admin';
23
- // which becomes: var firebaseAdmin = require('firebase-admin').default;
24
- //
25
- // as well as the more correct:
26
- //
27
- // import * as firebaseAdmin from 'firebase-admin';
28
- // which becomes: var firebaseAdmin = require('firebase-admin');
29
- firebase_namespace_1.defaultNamespace.default = firebase_namespace_1.defaultNamespace;
30
- module.exports = firebase_namespace_1.defaultNamespace;
@@ -1,6 +0,0 @@
1
- import mod from "../../instance-id/index.js";
2
-
3
- export const FirebaseInstanceIdError = mod.FirebaseInstanceIdError;
4
- export const InstanceId = mod.InstanceId;
5
- export const InstanceIdClientErrorCode = mod.InstanceIdClientErrorCode;
6
- export const getInstanceId = mod.getInstanceId;
@@ -1,91 +0,0 @@
1
- /*! firebase-admin v13.9.0 */
2
- /*!
3
- * Copyright 2021 Google LLC
4
- *
5
- * Licensed under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License.
7
- * You may obtain a copy of the License at
8
- *
9
- * http://www.apache.org/licenses/LICENSE-2.0
10
- *
11
- * Unless required by applicable law or agreed to in writing, software
12
- * distributed under the License is distributed on an "AS IS" BASIS,
13
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- * See the License for the specific language governing permissions and
15
- * limitations under the License.
16
- */
17
- import { appCheck } from './app-check/app-check-namespace';
18
- import { auth } from './auth/auth-namespace';
19
- import { database } from './database/database-namespace';
20
- import { firestore } from './firestore/firestore-namespace';
21
- import { instanceId } from './instance-id/instance-id-namespace';
22
- import { installations } from './installations/installations-namespace';
23
- import { machineLearning } from './machine-learning/machine-learning-namespace';
24
- import { messaging } from './messaging/messaging-namespace';
25
- import { projectManagement } from './project-management/project-management-namespace';
26
- import { remoteConfig } from './remote-config/remote-config-namespace';
27
- import { securityRules } from './security-rules/security-rules-namespace';
28
- import { storage } from './storage/storage-namespace';
29
- import { App as AppCore, AppOptions } from './app/index';
30
- export { AppOptions, FirebaseError, FirebaseArrayIndexError } from './app/index';
31
- export declare namespace app {
32
- /**
33
- * A Firebase app holds the initialization information for a collection of
34
- * services.
35
- *
36
- * Do not call this constructor directly. Instead, use
37
- * {@link firebase-admin.app#initializeApp} to create an app.
38
- */
39
- interface App extends AppCore {
40
- appCheck(): appCheck.AppCheck;
41
- auth(): auth.Auth;
42
- database(url?: string): database.Database;
43
- firestore(): firestore.Firestore;
44
- installations(): installations.Installations;
45
- /**
46
- * @deprecated Use {@link firebase-admin.installations#Installations} instead.
47
- */
48
- instanceId(): instanceId.InstanceId;
49
- machineLearning(): machineLearning.MachineLearning;
50
- messaging(): messaging.Messaging;
51
- projectManagement(): projectManagement.ProjectManagement;
52
- remoteConfig(): remoteConfig.RemoteConfig;
53
- securityRules(): securityRules.SecurityRules;
54
- storage(): storage.Storage;
55
- /**
56
- * Renders this local `FirebaseApp` unusable and frees the resources of
57
- * all associated services (though it does *not* clean up any backend
58
- * resources). When running the SDK locally, this method
59
- * must be called to ensure graceful termination of the process.
60
- *
61
- * @example
62
- * ```javascript
63
- * app.delete()
64
- * .then(function() {
65
- * console.log("App deleted successfully");
66
- * })
67
- * .catch(function(error) {
68
- * console.log("Error deleting app:", error);
69
- * });
70
- * ```
71
- */
72
- delete(): Promise<void>;
73
- }
74
- }
75
- export * from './credential/index';
76
- export { appCheck } from './app-check/app-check-namespace';
77
- export { auth } from './auth/auth-namespace';
78
- export { database } from './database/database-namespace';
79
- export { firestore } from './firestore/firestore-namespace';
80
- export { instanceId } from './instance-id/instance-id-namespace';
81
- export { installations } from './installations/installations-namespace';
82
- export { machineLearning } from './machine-learning/machine-learning-namespace';
83
- export { messaging } from './messaging/messaging-namespace';
84
- export { projectManagement } from './project-management/project-management-namespace';
85
- export { remoteConfig } from './remote-config/remote-config-namespace';
86
- export { securityRules } from './security-rules/security-rules-namespace';
87
- export { storage } from './storage/storage-namespace';
88
- export declare const SDK_VERSION: string;
89
- export declare const apps: (app.App | null)[];
90
- export declare function app(name?: string): app.App;
91
- export declare function initializeApp(options?: AppOptions, name?: string): app.App;
@@ -1,58 +0,0 @@
1
- /*! firebase-admin v13.9.0 */
2
- "use strict";
3
- /*!
4
- * Copyright 2021 Google LLC
5
- *
6
- * Licensed under the Apache License, Version 2.0 (the "License");
7
- * you may not use this file except in compliance with the License.
8
- * You may obtain a copy of the License at
9
- *
10
- * http://www.apache.org/licenses/LICENSE-2.0
11
- *
12
- * Unless required by applicable law or agreed to in writing, software
13
- * distributed under the License is distributed on an "AS IS" BASIS,
14
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
- * See the License for the specific language governing permissions and
16
- * limitations under the License.
17
- */
18
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
19
- if (k2 === undefined) k2 = k;
20
- var desc = Object.getOwnPropertyDescriptor(m, k);
21
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
22
- desc = { enumerable: true, get: function() { return m[k]; } };
23
- }
24
- Object.defineProperty(o, k2, desc);
25
- }) : (function(o, m, k, k2) {
26
- if (k2 === undefined) k2 = k;
27
- o[k2] = m[k];
28
- }));
29
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
30
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
31
- };
32
- Object.defineProperty(exports, "__esModule", { value: true });
33
- exports.storage = exports.securityRules = exports.remoteConfig = exports.projectManagement = exports.messaging = exports.machineLearning = exports.installations = exports.instanceId = exports.firestore = exports.database = exports.auth = exports.appCheck = void 0;
34
- __exportStar(require("./credential/index"), exports);
35
- var app_check_namespace_1 = require("./app-check/app-check-namespace");
36
- Object.defineProperty(exports, "appCheck", { enumerable: true, get: function () { return app_check_namespace_1.appCheck; } });
37
- var auth_namespace_1 = require("./auth/auth-namespace");
38
- Object.defineProperty(exports, "auth", { enumerable: true, get: function () { return auth_namespace_1.auth; } });
39
- var database_namespace_1 = require("./database/database-namespace");
40
- Object.defineProperty(exports, "database", { enumerable: true, get: function () { return database_namespace_1.database; } });
41
- var firestore_namespace_1 = require("./firestore/firestore-namespace");
42
- Object.defineProperty(exports, "firestore", { enumerable: true, get: function () { return firestore_namespace_1.firestore; } });
43
- var instance_id_namespace_1 = require("./instance-id/instance-id-namespace");
44
- Object.defineProperty(exports, "instanceId", { enumerable: true, get: function () { return instance_id_namespace_1.instanceId; } });
45
- var installations_namespace_1 = require("./installations/installations-namespace");
46
- Object.defineProperty(exports, "installations", { enumerable: true, get: function () { return installations_namespace_1.installations; } });
47
- var machine_learning_namespace_1 = require("./machine-learning/machine-learning-namespace");
48
- Object.defineProperty(exports, "machineLearning", { enumerable: true, get: function () { return machine_learning_namespace_1.machineLearning; } });
49
- var messaging_namespace_1 = require("./messaging/messaging-namespace");
50
- Object.defineProperty(exports, "messaging", { enumerable: true, get: function () { return messaging_namespace_1.messaging; } });
51
- var project_management_namespace_1 = require("./project-management/project-management-namespace");
52
- Object.defineProperty(exports, "projectManagement", { enumerable: true, get: function () { return project_management_namespace_1.projectManagement; } });
53
- var remote_config_namespace_1 = require("./remote-config/remote-config-namespace");
54
- Object.defineProperty(exports, "remoteConfig", { enumerable: true, get: function () { return remote_config_namespace_1.remoteConfig; } });
55
- var security_rules_namespace_1 = require("./security-rules/security-rules-namespace");
56
- Object.defineProperty(exports, "securityRules", { enumerable: true, get: function () { return security_rules_namespace_1.securityRules; } });
57
- var storage_namespace_1 = require("./storage/storage-namespace");
58
- Object.defineProperty(exports, "storage", { enumerable: true, get: function () { return storage_namespace_1.storage; } });
@@ -1,71 +0,0 @@
1
- /*! firebase-admin v13.9.0 */
2
- /*!
3
- * Copyright 2021 Google LLC
4
- *
5
- * Licensed under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License.
7
- * You may obtain a copy of the License at
8
- *
9
- * http://www.apache.org/licenses/LICENSE-2.0
10
- *
11
- * Unless required by applicable law or agreed to in writing, software
12
- * distributed under the License is distributed on an "AS IS" BASIS,
13
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- * See the License for the specific language governing permissions and
15
- * limitations under the License.
16
- */
17
- import * as _firestore from '@google-cloud/firestore';
18
- import { App } from '../app';
19
- export declare function firestore(app?: App): _firestore.Firestore;
20
- export declare namespace firestore {
21
- export import v1beta1 = _firestore.v1beta1;
22
- export import v1 = _firestore.v1;
23
- export import AggregateField = _firestore.AggregateField;
24
- export import AggregateFieldType = _firestore.AggregateFieldType;
25
- export import AggregateQuery = _firestore.AggregateQuery;
26
- export import AggregateQuerySnapshot = _firestore.AggregateQuerySnapshot;
27
- export import AggregateSpecData = _firestore.AggregateSpecData;
28
- export import AggregateSpec = _firestore.AggregateSpec;
29
- export import AggregateType = _firestore.AggregateType;
30
- export import BulkWriter = _firestore.BulkWriter;
31
- export import BulkWriterOptions = _firestore.BulkWriterOptions;
32
- export import BundleBuilder = _firestore.BundleBuilder;
33
- export import CollectionGroup = _firestore.CollectionGroup;
34
- export import CollectionReference = _firestore.CollectionReference;
35
- export import DocumentChange = _firestore.DocumentChange;
36
- export import DocumentChangeType = _firestore.DocumentChangeType;
37
- export import DocumentData = _firestore.DocumentData;
38
- export import DocumentReference = _firestore.DocumentReference;
39
- export import DocumentSnapshot = _firestore.DocumentSnapshot;
40
- export import FieldPath = _firestore.FieldPath;
41
- export import FieldValue = _firestore.FieldValue;
42
- export import Filter = _firestore.Filter;
43
- export import Firestore = _firestore.Firestore;
44
- export import FirestoreDataConverter = _firestore.FirestoreDataConverter;
45
- export import GeoPoint = _firestore.GeoPoint;
46
- export import GrpcStatus = _firestore.GrpcStatus;
47
- export import OrderByDirection = _firestore.OrderByDirection;
48
- export import Precondition = _firestore.Precondition;
49
- export import Query = _firestore.Query;
50
- export import QueryDocumentSnapshot = _firestore.QueryDocumentSnapshot;
51
- export import QueryPartition = _firestore.QueryPartition;
52
- export import QuerySnapshot = _firestore.QuerySnapshot;
53
- export import ReadOptions = _firestore.ReadOptions;
54
- export import Settings = _firestore.Settings;
55
- export import SetOptions = _firestore.SetOptions;
56
- export import Timestamp = _firestore.Timestamp;
57
- export import Transaction = _firestore.Transaction;
58
- export import UpdateData = _firestore.UpdateData;
59
- export import WhereFilterOp = _firestore.WhereFilterOp;
60
- export import WriteBatch = _firestore.WriteBatch;
61
- export import WriteResult = _firestore.WriteResult;
62
- export import PartialWithFieldValue = _firestore.PartialWithFieldValue;
63
- export import WithFieldValue = _firestore.WithFieldValue;
64
- export import Primitive = _firestore.Primitive;
65
- export import NestedUpdateFields = _firestore.NestedUpdateFields;
66
- export import ChildUpdateFields = _firestore.ChildUpdateFields;
67
- export import AddPrefixToKeys = _firestore.AddPrefixToKeys;
68
- export import UnionToIntersection = _firestore.UnionToIntersection;
69
- export import ReadOnlyTransactionOptions = _firestore.ReadOnlyTransactionOptions;
70
- export import setLogFunction = _firestore.setLogFunction;
71
- }
@@ -1,52 +0,0 @@
1
- /*! firebase-admin v13.9.0 */
2
- "use strict";
3
- /*!
4
- * Copyright 2021 Google LLC
5
- *
6
- * Licensed under the Apache License, Version 2.0 (the "License");
7
- * you may not use this file except in compliance with the License.
8
- * You may obtain a copy of the License at
9
- *
10
- * http://www.apache.org/licenses/LICENSE-2.0
11
- *
12
- * Unless required by applicable law or agreed to in writing, software
13
- * distributed under the License is distributed on an "AS IS" BASIS,
14
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
- * See the License for the specific language governing permissions and
16
- * limitations under the License.
17
- */
18
- Object.defineProperty(exports, "__esModule", { value: true });
19
- exports.firestore = void 0;
20
- const _firestore = require("@google-cloud/firestore");
21
- /* eslint-disable @typescript-eslint/no-namespace */
22
- var firestore;
23
- (function (firestore) {
24
- /* eslint-disable @typescript-eslint/no-unused-vars */
25
- // See https://github.com/typescript-eslint/typescript-eslint/issues/363
26
- firestore.v1beta1 = _firestore.v1beta1;
27
- firestore.v1 = _firestore.v1;
28
- firestore.AggregateField = _firestore.AggregateField;
29
- firestore.AggregateQuery = _firestore.AggregateQuery;
30
- firestore.AggregateQuerySnapshot = _firestore.AggregateQuerySnapshot;
31
- firestore.BulkWriter = _firestore.BulkWriter;
32
- firestore.BundleBuilder = _firestore.BundleBuilder;
33
- firestore.CollectionGroup = _firestore.CollectionGroup;
34
- firestore.CollectionReference = _firestore.CollectionReference;
35
- firestore.DocumentReference = _firestore.DocumentReference;
36
- firestore.DocumentSnapshot = _firestore.DocumentSnapshot;
37
- firestore.FieldPath = _firestore.FieldPath;
38
- firestore.FieldValue = _firestore.FieldValue;
39
- firestore.Filter = _firestore.Filter;
40
- firestore.Firestore = _firestore.Firestore;
41
- firestore.GeoPoint = _firestore.GeoPoint;
42
- firestore.GrpcStatus = _firestore.GrpcStatus;
43
- firestore.Query = _firestore.Query;
44
- firestore.QueryDocumentSnapshot = _firestore.QueryDocumentSnapshot;
45
- firestore.QueryPartition = _firestore.QueryPartition;
46
- firestore.QuerySnapshot = _firestore.QuerySnapshot;
47
- firestore.Timestamp = _firestore.Timestamp;
48
- firestore.Transaction = _firestore.Transaction;
49
- firestore.WriteBatch = _firestore.WriteBatch;
50
- firestore.WriteResult = _firestore.WriteResult;
51
- firestore.setLogFunction = _firestore.setLogFunction;
52
- })(firestore || (exports.firestore = firestore = {}));
@@ -1,55 +0,0 @@
1
- /*! firebase-admin v13.9.0 */
2
- /*!
3
- * Copyright 2021 Google LLC
4
- *
5
- * Licensed under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License.
7
- * You may obtain a copy of the License at
8
- *
9
- * http://www.apache.org/licenses/LICENSE-2.0
10
- *
11
- * Unless required by applicable law or agreed to in writing, software
12
- * distributed under the License is distributed on an "AS IS" BASIS,
13
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- * See the License for the specific language governing permissions and
15
- * limitations under the License.
16
- */
17
- import { App } from '../app/index';
18
- import { Installations as TInstallations } from './installations';
19
- /**
20
- * Gets the {@link firebase-admin.installations#Installations} service for the
21
- * default app or a given app.
22
- *
23
- * `admin.installations()` can be called with no arguments to access the default
24
- * app's {@link firebase-admin.installations#Installations} service or as
25
- * `admin.installations(app)` to access the
26
- * {@link firebase-admin.installations#Installations} service associated with a
27
- * specific app.
28
- *
29
- * @example
30
- * ```javascript
31
- * // Get the Installations service for the default app
32
- * var defaultInstallations = admin.installations();
33
- * ```
34
- *
35
- * @example
36
- * ```javascript
37
- * // Get the Installations service for a given app
38
- * var otherInstallations = admin.installations(otherApp);
39
- *```
40
- *
41
- * @param app - Optional app whose `Installations` service to
42
- * return. If not provided, the default `Installations` service is
43
- * returned.
44
- *
45
- * @returns The default `Installations` service if
46
- * no app is provided or the `Installations` service associated with the
47
- * provided app.
48
- */
49
- export declare function installations(app?: App): installations.Installations;
50
- export declare namespace installations {
51
- /**
52
- * Type alias to {@link firebase-admin.installations#Installations}.
53
- */
54
- type Installations = TInstallations;
55
- }
@@ -1,18 +0,0 @@
1
- /*! firebase-admin v13.9.0 */
2
- "use strict";
3
- /*!
4
- * Copyright 2021 Google LLC
5
- *
6
- * Licensed under the Apache License, Version 2.0 (the "License");
7
- * you may not use this file except in compliance with the License.
8
- * You may obtain a copy of the License at
9
- *
10
- * http://www.apache.org/licenses/LICENSE-2.0
11
- *
12
- * Unless required by applicable law or agreed to in writing, software
13
- * distributed under the License is distributed on an "AS IS" BASIS,
14
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
- * See the License for the specific language governing permissions and
16
- * limitations under the License.
17
- */
18
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,62 +0,0 @@
1
- /*! firebase-admin v13.9.0 */
2
- /*!
3
- * Copyright 2020 Google LLC
4
- *
5
- * Licensed under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License.
7
- * You may obtain a copy of the License at
8
- *
9
- * http://www.apache.org/licenses/LICENSE-2.0
10
- *
11
- * Unless required by applicable law or agreed to in writing, software
12
- * distributed under the License is distributed on an "AS IS" BASIS,
13
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- * See the License for the specific language governing permissions and
15
- * limitations under the License.
16
- */
17
- /**
18
- * Firebase Instance ID service.
19
- *
20
- * @packageDocumentation
21
- */
22
- import { App } from '../app/index';
23
- import { InstanceId } from './instance-id';
24
- export { InstanceId };
25
- /**
26
- * Gets the {@link InstanceId} service for the default app or a given app.
27
- *
28
- * This API is deprecated. Developers are advised to use the
29
- * {@link firebase-admin.installations#getInstallations}
30
- * API to delete their instance IDs and Firebase installation IDs.
31
- *
32
- * `getInstanceId()` can be called with no arguments to access the default
33
- * app's `InstanceId` service or as `getInstanceId(app)` to access the
34
- * `InstanceId` service associated with a specific app.
35
- *
36
- * @example
37
- * ```javascript
38
- * // Get the Instance ID service for the default app
39
- * const defaultInstanceId = getInstanceId();
40
- * ```
41
- *
42
- * @example
43
- * ```javascript
44
- * // Get the Instance ID service for a given app
45
- * const otherInstanceId = getInstanceId(otherApp);
46
- *```
47
- *
48
- * This API is deprecated. Developers are advised to use the `admin.installations()`
49
- * API to delete their instance IDs and Firebase installation IDs.
50
- *
51
- * @param app - Optional app whose `InstanceId` service to
52
- * return. If not provided, the default `InstanceId` service will be
53
- * returned.
54
- *
55
- * @returns The default `InstanceId` service if
56
- * no app is provided or the `InstanceId` service associated with the
57
- * provided app.
58
- *
59
- * @deprecated Use {@link firebase-admin.installations#getInstallations} instead.
60
- */
61
- export declare function getInstanceId(app?: App): InstanceId;
62
- export { FirebaseInstanceIdError, InstanceIdClientErrorCode } from '../utils/error';