@react-native-firebase/analytics 18.3.2 → 18.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.
@@ -0,0 +1,1199 @@
1
+ import { ReactNativeFirebase } from '@react-native-firebase/app';
2
+ import { FirebaseAnalyticsTypes } from '..';
3
+ import Analytics = FirebaseAnalyticsTypes.Module;
4
+ import AnalyticsCallOptions = FirebaseAnalyticsTypes.AnalyticsCallOptions;
5
+ import EventParams = FirebaseAnalyticsTypes.EventParams;
6
+ import FirebaseApp = ReactNativeFirebase.FirebaseApp;
7
+
8
+ /**
9
+ * Returns an Analytics instance for the given app.
10
+ *
11
+ * @param app - FirebaseApp. Optional.
12
+ */
13
+ export declare function getAnalytics(app?: FirebaseApp): Analytics;
14
+
15
+ /**
16
+ * Returns an Analytics instance for the given app.
17
+ *
18
+ * @param app - FirebaseApp.
19
+ * @param options - `AnalyticsSettings`. Web only.
20
+ */
21
+ export declare function initializeAnalytics(
22
+ app: FirebaseApp,
23
+ options?: FirebaseAnalyticsTypes.AnalyticsSettings,
24
+ ): Analytics;
25
+
26
+ /**
27
+ * Log a custom event with optional params. Note that there are various limits that applied
28
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
29
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
30
+ * While integrating this API in your app you are strongly encouraged to enable
31
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
32
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
33
+ *
34
+ * @param analytics Analytics instance.
35
+ * @param name Event name must not conflict with any Reserved Events.
36
+ * @param params Parameters to be sent and displayed with the event.
37
+ * @param options Additional options that can be passed. Web only.
38
+ */
39
+ export declare function logEvent(
40
+ analytics: Analytics,
41
+ name: 'add_payment_info',
42
+ params?: {
43
+ coupon?: EventParams['coupon'];
44
+ currency?: EventParams['currency'];
45
+ items?: EventParams['items'];
46
+ payment_type?: EventParams['payment_type'];
47
+ value?: EventParams['value'];
48
+ [key: string]: any;
49
+ },
50
+ options?: AnalyticsCallOptions,
51
+ ): Promise<void>;
52
+
53
+ /**
54
+ * Log a custom event with optional params. Note that there are various limits that applied
55
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
56
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
57
+ * While integrating this API in your app you are strongly encouraged to enable
58
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
59
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
60
+ *
61
+ * @param analytics Analytics instance.
62
+ * @param name Event name must not conflict with any Reserved Events.
63
+ * @param params Parameters to be sent and displayed with the event.
64
+ * @param options Additional options that can be passed. Web only.
65
+ */
66
+ export declare function logEvent(
67
+ analytics: Analytics,
68
+ name: 'purchase' | 'refund',
69
+ params?: {
70
+ value?: EventParams['value'];
71
+ currency?: EventParams['currency'];
72
+ transaction_id: EventParams['transaction_id'];
73
+ tax?: EventParams['tax'];
74
+ shipping?: EventParams['shipping'];
75
+ items?: EventParams['items'];
76
+ coupon?: EventParams['coupon'];
77
+ affiliation?: EventParams['affiliation'];
78
+ [key: string]: any;
79
+ },
80
+ options?: AnalyticsCallOptions,
81
+ ): Promise<void>;
82
+
83
+ /**
84
+ * Log a custom event with optional params. Note that there are various limits that applied
85
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
86
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
87
+ * While integrating this API in your app you are strongly encouraged to enable
88
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
89
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
90
+ *
91
+ * @param analytics Analytics instance.
92
+ * @param name Event name must not conflict with any Reserved Events.
93
+ * @param params Parameters to be sent and displayed with the event.
94
+ * @param options Additional options that can be passed. Web only.
95
+ */
96
+ export declare function logEvent(
97
+ analytics: Analytics,
98
+ name: 'screen_view',
99
+ params?: {
100
+ firebase_screen: EventParams['firebase_screen'];
101
+ firebase_screen_class: EventParams['firebase_screen_class'];
102
+ [key: string]: any;
103
+ },
104
+ options?: AnalyticsCallOptions,
105
+ ): Promise<void>;
106
+
107
+ /**
108
+ * Log a custom event with optional params. Note that there are various limits that applied
109
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
110
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
111
+ * While integrating this API in your app you are strongly encouraged to enable
112
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
113
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
114
+ *
115
+ * @param analytics Analytics instance.
116
+ * @param name Event name must not conflict with any Reserved Events.
117
+ * @param params Parameters to be sent and displayed with the event.
118
+ * @param options Additional options that can be passed. Web only.
119
+ */
120
+ export declare function logEvent(
121
+ analytics: Analytics,
122
+ name: 'search' | 'view_search_results',
123
+ params?: {
124
+ search_term?: EventParams['search_term'];
125
+ [key: string]: any;
126
+ },
127
+ options?: AnalyticsCallOptions,
128
+ ): Promise<void>;
129
+
130
+ /**
131
+ * Log a custom event with optional params. Note that there are various limits that applied
132
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
133
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
134
+ * While integrating this API in your app you are strongly encouraged to enable
135
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
136
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
137
+ *
138
+ * @param analytics Analytics instance.
139
+ * @param name Event name must not conflict with any Reserved Events.
140
+ * @param params Parameters to be sent and displayed with the event.
141
+ * @param options Additional options that can be passed. Web only.
142
+ */
143
+ export declare function logEvent(
144
+ analytics: Analytics,
145
+ name: 'select_content',
146
+ params?: {
147
+ content_type?: EventParams['content_type'];
148
+ item_id?: EventParams['item_id'];
149
+ [key: string]: any;
150
+ },
151
+ options?: AnalyticsCallOptions,
152
+ ): Promise<void>;
153
+
154
+ /**
155
+ * Log a custom event with optional params. Note that there are various limits that applied
156
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
157
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
158
+ * While integrating this API in your app you are strongly encouraged to enable
159
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
160
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
161
+ *
162
+ * @param analytics Analytics instance.
163
+ * @param name Event name must not conflict with any Reserved Events.
164
+ * @param params Parameters to be sent and displayed with the event.
165
+ * @param options Additional options that can be passed. Web only.
166
+ */
167
+ export declare function logEvent(
168
+ analytics: Analytics,
169
+ name: 'select_item',
170
+ params?: {
171
+ items?: EventParams['items'];
172
+ item_list_name?: EventParams['item_list_name'];
173
+ item_list_id?: EventParams['item_list_id'];
174
+ [key: string]: any;
175
+ },
176
+ options?: AnalyticsCallOptions,
177
+ ): Promise<void>;
178
+
179
+ /**
180
+ * Log a custom event with optional params. Note that there are various limits that applied
181
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
182
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
183
+ * While integrating this API in your app you are strongly encouraged to enable
184
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
185
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
186
+ *
187
+ * @param analytics Analytics instance.
188
+ * @param name Event name must not conflict with any Reserved Events.
189
+ * @param params Parameters to be sent and displayed with the event.
190
+ * @param options Additional options that can be passed. Web only.
191
+ */
192
+ export declare function logEvent(
193
+ analytics: Analytics,
194
+ name: 'select_promotion' | 'view_promotion',
195
+ params?: {
196
+ items?: EventParams['items'];
197
+ promotion_id?: EventParams['promotion_id'];
198
+ promotion_name?: EventParams['promotion_name'];
199
+ [key: string]: any;
200
+ },
201
+ options?: AnalyticsCallOptions,
202
+ ): Promise<void>;
203
+
204
+ /**
205
+ * Log a custom event with optional params. Note that there are various limits that applied
206
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
207
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
208
+ * While integrating this API in your app you are strongly encouraged to enable
209
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
210
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
211
+ *
212
+ * @param analytics Analytics instance.
213
+ * @param name Event name must not conflict with any Reserved Events.
214
+ * @param params Parameters to be sent and displayed with the event.
215
+ * @param options Additional options that can be passed. Web only.
216
+ */
217
+ export declare function logEvent(
218
+ analytics: Analytics,
219
+ name: 'set_checkout_option',
220
+ params?: {
221
+ checkout_step?: EventParams['checkout_step'];
222
+ checkout_option?: EventParams['checkout_option'];
223
+ [key: string]: any;
224
+ },
225
+ options?: AnalyticsCallOptions,
226
+ ): Promise<void>;
227
+
228
+ /**
229
+ * Log a custom event with optional params. Note that there are various limits that applied
230
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
231
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
232
+ * While integrating this API in your app you are strongly encouraged to enable
233
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
234
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
235
+ *
236
+ * @param analytics Analytics instance.
237
+ * @param name Event name must not conflict with any Reserved Events.
238
+ * @param params Parameters to be sent and displayed with the event.
239
+ * @param options Additional options that can be passed. Web only.
240
+ */
241
+ export declare function logEvent(
242
+ analytics: Analytics,
243
+ name: 'share',
244
+ params?: {
245
+ method?: EventParams['method'];
246
+ content_type?: EventParams['content_type'];
247
+ item_id?: EventParams['item_id'];
248
+ [key: string]: any;
249
+ },
250
+ options?: AnalyticsCallOptions,
251
+ ): Promise<void>;
252
+
253
+ /**
254
+ * Log a custom event with optional params. Note that there are various limits that applied
255
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
256
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
257
+ * While integrating this API in your app you are strongly encouraged to enable
258
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
259
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
260
+ *
261
+ * @param analytics Analytics instance.
262
+ * @param name Event name must not conflict with any Reserved Events.
263
+ * @param params Parameters to be sent and displayed with the event.
264
+ * @param options Additional options that can be passed. Web only.
265
+ */
266
+ export declare function logEvent(
267
+ analytics: Analytics,
268
+ name: 'sign_up',
269
+ params?: {
270
+ method?: EventParams['method'];
271
+ [key: string]: any;
272
+ },
273
+ options?: AnalyticsCallOptions,
274
+ ): Promise<void>;
275
+
276
+ /**
277
+ * Log a custom event with optional params. Note that there are various limits that applied
278
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
279
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
280
+ * While integrating this API in your app you are strongly encouraged to enable
281
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
282
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
283
+ *
284
+ * @param analytics Analytics instance.
285
+ * @param name Event name must not conflict with any Reserved Events.
286
+ * @param params Parameters to be sent and displayed with the event.
287
+ * @param options Additional options that can be passed. Web only.
288
+ */
289
+ export declare function logEvent(
290
+ analytics: Analytics,
291
+ name: 'timing_complete',
292
+ params?: {
293
+ name: string;
294
+ value: number;
295
+ event_category?: string;
296
+ event_label?: string;
297
+ [key: string]: any;
298
+ },
299
+ options?: AnalyticsCallOptions,
300
+ ): Promise<void>;
301
+
302
+ /**
303
+ * Log a custom event with optional params. Note that there are various limits that applied
304
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
305
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
306
+ * While integrating this API in your app you are strongly encouraged to enable
307
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
308
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
309
+ *
310
+ * @param analytics Analytics instance.
311
+ * @param name Event name must not conflict with any Reserved Events.
312
+ * @param params Parameters to be sent and displayed with the event.
313
+ * @param options Additional options that can be passed. Web only.
314
+ */
315
+ export declare function logEvent(
316
+ analytics: Analytics,
317
+ name: 'add_shipping_info',
318
+ params?: {
319
+ coupon?: EventParams['coupon'];
320
+ currency?: EventParams['currency'];
321
+ items?: EventParams['items'];
322
+ shipping_tier?: EventParams['shipping_tier'];
323
+ value?: EventParams['value'];
324
+ [key: string]: any;
325
+ },
326
+ options?: AnalyticsCallOptions,
327
+ ): Promise<void>;
328
+
329
+ /**
330
+ * Log a custom event with optional params. Note that there are various limits that applied
331
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
332
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
333
+ * While integrating this API in your app you are strongly encouraged to enable
334
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
335
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
336
+ *
337
+ * @param analytics Analytics instance.
338
+ * @param name Event name must not conflict with any Reserved Events.
339
+ * @param params Parameters to be sent and displayed with the event.
340
+ * @param options Additional options that can be passed. Web only.
341
+ */
342
+ export declare function logEvent(
343
+ analytics: Analytics,
344
+ name: 'view_cart' | 'view_item',
345
+ params?: {
346
+ currency?: EventParams['currency'];
347
+ items?: EventParams['items'];
348
+ value?: EventParams['value'];
349
+ [key: string]: any;
350
+ },
351
+ options?: AnalyticsCallOptions,
352
+ ): Promise<void>;
353
+
354
+ /**
355
+ * Log a custom event with optional params. Note that there are various limits that applied
356
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
357
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
358
+ * While integrating this API in your app you are strongly encouraged to enable
359
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
360
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
361
+ *
362
+ * @param analytics Analytics instance.
363
+ * @param name Event name must not conflict with any Reserved Events.
364
+ * @param params Parameters to be sent and displayed with the event.
365
+ * @param options Additional options that can be passed. Web only.
366
+ */
367
+ export declare function logEvent(
368
+ analytics: Analytics,
369
+ name: 'view_item_list',
370
+ params?: {
371
+ items?: EventParams['items'];
372
+ item_list_name?: EventParams['item_list_name'];
373
+ item_list_id?: EventParams['item_list_id'];
374
+ [key: string]: any;
375
+ },
376
+ options?: AnalyticsCallOptions,
377
+ ): Promise<void>;
378
+
379
+ /**
380
+ * Log a custom event with optional params. Note that there are various limits that applied
381
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
382
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
383
+ * While integrating this API in your app you are strongly encouraged to enable
384
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
385
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
386
+ *
387
+ * @param analytics Analytics instance.
388
+ * @param name Event name must not conflict with any Reserved Events.
389
+ * @param params Parameters to be sent and displayed with the event.
390
+ * @param options Additional options that can be passed. Web only.
391
+ */
392
+ export declare function logEvent<T extends string>(
393
+ analytics: Analytics,
394
+ name: FirebaseAnalyticsTypes.CustomEventName<T>,
395
+ params?: {
396
+ [key: string]: any;
397
+ },
398
+ options?: AnalyticsCallOptions,
399
+ ): Promise<void>;
400
+
401
+ /**
402
+ * Log a custom event with optional params. Note that there are various limits that applied
403
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
404
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
405
+ * While integrating this API in your app you are strongly encouraged to enable
406
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
407
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
408
+ *
409
+ * @param analytics Analytics instance.
410
+ * @param name Event name must not conflict with any Reserved Events.
411
+ * @param params Parameters to be sent and displayed with the event.
412
+ * @param options Additional options that can be passed. Web only.
413
+ */
414
+ export declare function logEvent(
415
+ analytics: Analytics,
416
+ name: 'add_to_cart' | 'add_to_wishlist' | 'remove_from_cart',
417
+ params?: {
418
+ currency?: EventParams['currency'];
419
+ value?: EventParams['value'];
420
+ items?: EventParams['items'];
421
+ [key: string]: any;
422
+ },
423
+ options?: AnalyticsCallOptions,
424
+ ): Promise<void>;
425
+
426
+ /**
427
+ * Log a custom event with optional params. Note that there are various limits that applied
428
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
429
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
430
+ * While integrating this API in your app you are strongly encouraged to enable
431
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
432
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
433
+ *
434
+ * @param analytics Analytics instance.
435
+ * @param name Event name must not conflict with any Reserved Events.
436
+ * @param params Parameters to be sent and displayed with the event.
437
+ * @param options Additional options that can be passed. Web only.
438
+ */
439
+ export declare function logEvent(
440
+ analytics: Analytics,
441
+ name: 'begin_checkout',
442
+ params?: {
443
+ currency?: EventParams['currency'];
444
+ coupon?: EventParams['coupon'];
445
+ value?: EventParams['value'];
446
+ items?: EventParams['items'];
447
+ [key: string]: any;
448
+ },
449
+ options?: AnalyticsCallOptions,
450
+ ): Promise<void>;
451
+
452
+ /**
453
+ * Log a custom event with optional params. Note that there are various limits that applied
454
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
455
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
456
+ * While integrating this API in your app you are strongly encouraged to enable
457
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
458
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
459
+ *
460
+ * @param analytics Analytics instance.
461
+ * @param name Event name must not conflict with any Reserved Events.
462
+ * @param params Parameters to be sent and displayed with the event.
463
+ * @param options Additional options that can be passed. Web only.
464
+ */
465
+ export declare function logEvent(
466
+ analytics: Analytics,
467
+ name: 'checkout_progress',
468
+ params?: {
469
+ currency?: EventParams['currency'];
470
+ coupon?: EventParams['coupon'];
471
+ value?: EventParams['value'];
472
+ items?: EventParams['items'];
473
+ checkout_step?: EventParams['checkout_step'];
474
+ checkout_option?: EventParams['checkout_option'];
475
+ [key: string]: any;
476
+ },
477
+ options?: AnalyticsCallOptions,
478
+ ): Promise<void>;
479
+
480
+ /**
481
+ * Log a custom event with optional params. Note that there are various limits that applied
482
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
483
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
484
+ * While integrating this API in your app you are strongly encouraged to enable
485
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
486
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
487
+ *
488
+ * @param analytics Analytics instance.
489
+ * @param name Event name must not conflict with any Reserved Events.
490
+ * @param params Parameters to be sent and displayed with the event.
491
+ * @param options Additional options that can be passed. Web only.
492
+ */
493
+ export declare function logEvent(
494
+ analytics: Analytics,
495
+ name: 'exception',
496
+ params?: {
497
+ description?: EventParams['description'];
498
+ fatal?: EventParams['fatal'];
499
+ [key: string]: any;
500
+ },
501
+ options?: AnalyticsCallOptions,
502
+ ): Promise<void>;
503
+
504
+ /**
505
+ * Log a custom event with optional params. Note that there are various limits that applied
506
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
507
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
508
+ * While integrating this API in your app you are strongly encouraged to enable
509
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
510
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
511
+ *
512
+ * @param analytics Analytics instance.
513
+ * @param name Event name must not conflict with any Reserved Events.
514
+ * @param params Parameters to be sent and displayed with the event.
515
+ * @param options Additional options that can be passed. Web only.
516
+ */
517
+ export declare function logEvent(
518
+ analytics: Analytics,
519
+ name: 'generate_lead',
520
+ params?: {
521
+ value?: EventParams['value'];
522
+ currency?: EventParams['currency'];
523
+ [key: string]: any;
524
+ },
525
+ options?: AnalyticsCallOptions,
526
+ ): Promise<void>;
527
+
528
+ /**
529
+ * Log a custom event with optional params. Note that there are various limits that applied
530
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
531
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
532
+ * While integrating this API in your app you are strongly encouraged to enable
533
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
534
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
535
+ *
536
+ * @param analytics Analytics instance.
537
+ * @param name Event name must not conflict with any Reserved Events.
538
+ * @param params Parameters to be sent and displayed with the event.
539
+ * @param options Additional options that can be passed. Web only.
540
+ */
541
+ export declare function logEvent(
542
+ analytics: Analytics,
543
+ name: 'login',
544
+ params?: {
545
+ method?: EventParams['method'];
546
+ [key: string]: any;
547
+ },
548
+ options?: AnalyticsCallOptions,
549
+ ): Promise<void>;
550
+
551
+ /**
552
+ * Log a custom event with optional params. Note that there are various limits that applied
553
+ * to event parameters (total parameter count, etc), but analytics applies the limits during
554
+ * cloud processing, the errors will not be seen as Promise rejections when you call logEvent.
555
+ * While integrating this API in your app you are strongly encouraged to enable
556
+ * [DebugView](https://firebase.google.com/docs/analytics/debugview) -
557
+ * any errors in your events will show up in the firebase web console with links to relevant documentation
558
+ *
559
+ * @param analytics Analytics instance.
560
+ * @param name Event name must not conflict with any Reserved Events.
561
+ * @param params Parameters to be sent and displayed with the event.
562
+ * @param options Additional options that can be passed. Web only.
563
+ */
564
+ export declare function logEvent(
565
+ analytics: Analytics,
566
+ name: 'page_view',
567
+ params?: {
568
+ page_title?: string;
569
+ page_location?: string;
570
+ page_path?: string;
571
+ [key: string]: any;
572
+ },
573
+ options?: AnalyticsCallOptions,
574
+ ): Promise<void>;
575
+
576
+ /**
577
+ * If true, allows the device to collect analytical data and send it to
578
+ * Firebase. Useful for GDPR.
579
+ */
580
+ export declare function setAnalyticsCollectionEnabled(
581
+ analyticsInstance: Analytics,
582
+ enabled: boolean,
583
+ ): Promise<void>;
584
+
585
+ /**
586
+ * Sets the duration of inactivity that terminates the current session.
587
+ *
588
+ * @param analytics Analytics instance.
589
+ * @param milliseconds The default value is 1800000 (30 minutes).
590
+ */
591
+ export declare function setSessionTimeoutDuration(
592
+ analytics: Analytics,
593
+ milliseconds: number,
594
+ ): Promise<void>;
595
+
596
+ /**
597
+ * Retrieve the app instance id of the application.
598
+ *
599
+ * @param analytics Analytics instance.
600
+ * @returns Returns the app instance id or null on android if FirebaseAnalytics.ConsentType.ANALYTICS_STORAGE has been set to FirebaseAnalytics.ConsentStatus.DENIED and null on iOS if ConsentType.analyticsStorage has been set to ConsentStatus.denied.
601
+ */
602
+ export function getAppInstanceId(analytics: Analytics): Promise<string | null>;
603
+
604
+ /**
605
+ * Gives a user a unique identification.
606
+ *
607
+ * @param analytics Analytics instance.
608
+ * @param id Set to null to remove a previously assigned ID from analytics
609
+ * events
610
+ */
611
+ export function setUserId(analytics: Analytics, id: string | null): Promise<void>;
612
+
613
+ /**
614
+ * Sets a key/value pair of data on the current user. Each Firebase project can have up to 25 uniquely named (case-sensitive) user properties.
615
+ *
616
+ * @param analytics Analytics instance.
617
+ * @param name A user property identifier.
618
+ * @param value Set to null to remove a previously assigned ID from analytics events.
619
+ */
620
+ export function setUserProperty(
621
+ analytics: Analytics,
622
+ name: string,
623
+ value: string | null,
624
+ ): Promise<void>;
625
+
626
+ /**
627
+ * Sets multiple key/value pairs of data on the current user. Each Firebase project can have up to 25 uniquely named (case-sensitive) user properties.
628
+ *
629
+ * > When you set user properties, be sure to never include personally identifiable information such as names, social security numbers, or email addresses, even in hashed form.
630
+ *
631
+ * @param analytics Analytics instance.
632
+ * @param properties Set a property value to null to remove it.
633
+ * @param options `AnalyticsCallOptions`. Additional options that can be passed. Web only.
634
+ */
635
+ export function setUserProperties(
636
+ analytics: Analytics,
637
+ properties: { [key: string]: any },
638
+ options?: AnalyticsCallOptions,
639
+ ): Promise<void>;
640
+
641
+ /**
642
+ * Clears all analytics data for this instance from the device and resets the app instance ID.
643
+ *
644
+ * @param analytics Analytics instance.
645
+ */
646
+ export function resetAnalyticsData(analytics: Analytics): Promise<void>;
647
+
648
+ /**
649
+ * E-Commerce Purchase event. This event signifies that an item(s) was purchased by a user. Note: This is different from the in-app purchase event, which is reported
650
+ * automatically for Google Play-based apps.
651
+ *
652
+ * If you supply the `value` parameter, you must also supply the `currency` parameter so that revenue metrics can be computed accurately.
653
+ *
654
+ * Logged event name: `purchase`
655
+ *
656
+ * @param analytics Analytics instance.
657
+ * @param object See {@link analytics.AddPaymentInfoEventParameters}.
658
+ */
659
+ export function logAddPaymentInfo(
660
+ analytics: Analytics,
661
+ object: FirebaseAnalyticsTypes.AddPaymentInfoEventParameters,
662
+ ): Promise<void>;
663
+
664
+ /**
665
+ * Sets or clears the screen name and class the user is currently viewing
666
+ *
667
+ * @param analytics Analytics instance.
668
+ * @param params See {@link analytics.ScreenViewParameters}.
669
+ */
670
+ export function logScreenView(
671
+ analytics: Analytics,
672
+ params: FirebaseAnalyticsTypes.ScreenViewParameters,
673
+ ): Promise<void>;
674
+
675
+ /**
676
+ * Add Payment Info event. This event signifies that a user has submitted their payment information to your app.
677
+ *
678
+ * If you supply the `value` parameter, you must also supply the `currency` parameter so that revenue metrics can be computed accurately.
679
+ *
680
+ * Logged event name: `add_payment_info`
681
+ *
682
+ * @param analytics Analytics instance.
683
+ * @param params See {@link analytics.AddShippingInfoParameters}.
684
+ */
685
+ export function logAddShippingInfo(
686
+ analytics: Analytics,
687
+ params: FirebaseAnalyticsTypes.AddShippingInfoParameters,
688
+ ): Promise<void>;
689
+
690
+ /**
691
+ * E-Commerce Add To Cart event.
692
+ *
693
+ * If you supply the `value` parameter, you must also supply the `currency` parameter so that revenue metrics can be computed accurately.
694
+ *
695
+ * Logged event name: `add_to_cart`
696
+ *
697
+ * @param analytics Analytics instance.
698
+ * @param params See {@link analytics.AddToCartEventParameters}.
699
+ */
700
+ export function logAddToCart(
701
+ analytics: Analytics,
702
+ params: FirebaseAnalyticsTypes.AddToCartEventParameters,
703
+ ): Promise<void>;
704
+
705
+ /**
706
+ * E-Commerce Add To Wishlist event. This event signifies that an item was added to a wishlist.
707
+ * Use this event to identify popular gift items in your app.
708
+ *
709
+ * If you supply the `value` parameter, you must also supply the `currency` parameter so that revenue metrics can be computed accurately.
710
+ *
711
+ * Logged event name: `add_to_wishlist
712
+ *
713
+ * @param analytics Analytics instance.
714
+ * @param params See {@link analytics.AddToWishlistEventParameters}.
715
+ */
716
+ export function logAddToWishlist(
717
+ analytics,
718
+ params: FirebaseAnalyticsTypes.AddToWishlistEventParameters,
719
+ ): Promise<void>;
720
+
721
+ /**
722
+ * App Open event. By logging this event when an App is moved to the foreground, developers can
723
+ * understand how often users leave and return during the course of a Session. Although Sessions
724
+ * are automatically reported, this event can provide further clarification around the continuous
725
+ * engagement of app-users.
726
+ *
727
+ * @param analytics Analytics instance.
728
+ */
729
+ export function logAppOpen(analytics: Analytics): Promise<void>;
730
+
731
+ /**
732
+ * E-Commerce Begin Checkout event. This event signifies that a user has begun the process of
733
+ * checking out.
734
+ *
735
+ * If you supply the `value` parameter, you must also supply the `currency` parameter so that revenue metrics can be computed accurately.
736
+ *
737
+ * Logged event name: `begin_checkout`
738
+ *
739
+ * @param analytics Analytics instance.
740
+ * @param params See {@link analytics.BeginCheckoutEventParameters}.
741
+ */
742
+ export function logBeginCheckout(
743
+ analytics: Analytics,
744
+ params: FirebaseAnalyticsTypes.BeginCheckoutEventParameters,
745
+ ): Promise<void>;
746
+
747
+ /**
748
+ * Log this event to supply the referral details of a re-engagement campaign.
749
+ *
750
+ * Logged event name: `campaign_details`
751
+ *
752
+ * @param analytics Analytics instance.
753
+ * @param params See {@link analytics.CampaignDetailsEventParameters}.
754
+ */
755
+ export function logCampaignDetails(
756
+ analytics: Analytics,
757
+ params: FirebaseAnalyticsTypes.CampaignDetailsEventParameters,
758
+ ): Promise<void>;
759
+
760
+ /**
761
+ * Earn Virtual Currency event. This event tracks the awarding of virtual currency in your app. Log this along with
762
+ * {@link analytics.logSpendVirtualCurrency} to better understand your virtual economy.
763
+ *
764
+ * Logged event name: `earn_virtual_currency`
765
+ *
766
+ * @param analytics Analytics instance.
767
+ * @param params See {@link analytics.EarnVirtualCurrencyEventParameters}.
768
+ */
769
+ export function logEarnVirtualCurrency(
770
+ analytics: Analytics,
771
+ params: FirebaseAnalyticsTypes.EarnVirtualCurrencyEventParameters,
772
+ ): Promise<void>;
773
+
774
+ /**
775
+ * Generate Lead event. Log this event when a lead has been generated in the app to understand
776
+ * the efficacy of your install and re-engagement campaigns.
777
+ *
778
+ * If you supply the `value` parameter, you must also supply the `currency` parameter so that revenue metrics can be computed accurately.
779
+ *
780
+ * Logged event name: `generate_lead`
781
+ *
782
+ * @param analytics Analytics instance.
783
+ * @param params See {@link analytics.GenerateLeadEventParameters}.
784
+ */
785
+ export function logGenerateLead(
786
+ analytics: Analytics,
787
+ params: FirebaseAnalyticsTypes.GenerateLeadEventParameters,
788
+ ): Promise<void>;
789
+
790
+ /**
791
+ * Join Group event. Log this event when a user joins a group such as a guild, team or family.
792
+ * Use this event to analyze how popular certain groups or social features are in your app
793
+ *
794
+ * Logged event name: `join_group`
795
+ *
796
+ * @param analytics Analytics instance.
797
+ * @param params See {@link analytics.JoinGroupEventParameters}.
798
+ */
799
+ export function logJoinGroup(
800
+ analytics: Analytics,
801
+ params: FirebaseAnalyticsTypes.JoinGroupEventParameters,
802
+ ): Promise<void>;
803
+
804
+ /**
805
+ * Level End event.
806
+ *
807
+ * Logged event name: `level_end`
808
+ *
809
+ * @param analytics Analytics instance.
810
+ * @param params See {@link analytics.LevelEndEventParameters}.
811
+ */
812
+ export function logLevelEnd(
813
+ analytics: Analytics,
814
+ params: FirebaseAnalyticsTypes.LevelEndEventParameters,
815
+ ): Promise<void>;
816
+
817
+ /**
818
+ * Level Start event.
819
+ *
820
+ * Logged event name: `level_start`
821
+ *
822
+ * @param analytics Analytics instance.
823
+ * @param params See {@link analytics.LevelStartEventParameters}.
824
+ */
825
+ export function logLevelStart(
826
+ analytics: Analytics,
827
+ params: FirebaseAnalyticsTypes.LevelStartEventParameters,
828
+ ): Promise<void>;
829
+
830
+ /**
831
+ * Level Up event. This event signifies that a player has leveled up in your gaming app.
832
+ * It can help you gauge the level distribution of your userbase and help you identify certain levels that are difficult to pass.
833
+ *
834
+ * Logged event name: `level_up`
835
+ *
836
+ * @param analytics Analytics instance.
837
+ * @param params See {@link analytics.LevelUpEventParameters}.
838
+ */
839
+ export function logLevelUp(
840
+ analytics: Analytics,
841
+ params: FirebaseAnalyticsTypes.LevelUpEventParameters,
842
+ ): Promise<void>;
843
+
844
+ /**
845
+ * Login event. Apps with a login feature can report this event to signify that a user has logged in.
846
+ *
847
+ * Logged event name: `login`
848
+ *
849
+ * @param analytics Analytics instance.
850
+ * @param params See {@link analytics.LoginEventParameters}.
851
+ */
852
+ export function logLogin(
853
+ analytics: Analytics,
854
+ params: FirebaseAnalyticsTypes.LoginEventParameters,
855
+ ): Promise<void>;
856
+
857
+ /**
858
+ * Post Score event. Log this event when the user posts a score in your gaming app. This event can
859
+ * help you understand how users are actually performing in your game and it can help you correlate
860
+ * high scores with certain audiences or behaviors.
861
+ *
862
+ * Logged event name: `post_score`
863
+ *
864
+ * @param analytics Analytics instance.
865
+ * @param params See {@link analytics.PostScoreEventParameters}.
866
+ */
867
+ export function logPostScore(
868
+ analytics: Analytics,
869
+ params: FirebaseAnalyticsTypes.PostScoreEventParameters,
870
+ ): Promise<void>;
871
+
872
+ /**
873
+ * Select Content event. This general purpose event signifies that a user has selected some
874
+ * content of a certain type in an app. The content can be any object in your app. This event
875
+ * can help you identify popular content and categories of content in your app.
876
+ *
877
+ * Logged event name: `select_content`
878
+ *
879
+ * @param analytics Analytics instance.
880
+ * @param params See {@link analytics.SelectContentEventParameters}.
881
+ */
882
+ export function logSelectContent(
883
+ analytics: Analytics,
884
+ params: FirebaseAnalyticsTypes.SelectContentEventParameters,
885
+ ): Promise<void>;
886
+
887
+ /**
888
+ * E-Commerce Purchase event. This event signifies that an item(s) was purchased by a user. Note: This is different from the in-app purchase event, which is reported
889
+ * automatically for Google Play-based apps.
890
+ *
891
+ * If you supply the `value` parameter, you must also supply the `currency` parameter so that revenue metrics can be computed accurately.
892
+ *
893
+ * Logged event name: `purchase`
894
+ *
895
+ * @param analytics Analytics instance.
896
+ * @param params See {@link analytics.PurchaseEventParameters}.
897
+ */
898
+ export function logPurchase(
899
+ analytics: Analytics,
900
+ params: FirebaseAnalyticsTypes.PurchaseEventParameters,
901
+ ): Promise<void>;
902
+
903
+ /**
904
+ * E-Commerce Refund event. This event signifies that a refund was issued.
905
+ *
906
+ * Logged event name: `remove_from_cart`
907
+ *
908
+ * @param analytics Analytics instance.
909
+ * @param params See {@link analytics.RefundEventParameters}.
910
+ */
911
+ export function logRefund(
912
+ analytics: Analytics,
913
+ params: FirebaseAnalyticsTypes.RefundEventParameters,
914
+ ): Promise<void>;
915
+
916
+ /**
917
+ * Remove from cart event.
918
+ *
919
+ * Logged event name: `remove_from_cart`
920
+ *
921
+ * @param analytics Analytics instance.
922
+ * @param params See {@link analytics.RemoveFromCartEventParameters}.
923
+ */
924
+ export function logRemoveFromCart(
925
+ analytics: Analytics,
926
+ params: FirebaseAnalyticsTypes.RemoveFromCartEventParameters,
927
+ ): Promise<void>;
928
+
929
+ /**
930
+ * Search event. Apps that support search features can use this event to contextualize search
931
+ * operations by supplying the appropriate, corresponding parameters. This event can help you
932
+ * identify the most popular content in your app.
933
+ *
934
+ * Logged event name: `search`
935
+ *
936
+ * @param analytics Analytics instance.
937
+ * @param params See {@link analytics.SearchEventParameters}.
938
+ */
939
+ export function logSearch(
940
+ analytics: Analytics,
941
+ params: FirebaseAnalyticsTypes.SearchEventParameters,
942
+ ): Promise<void>;
943
+
944
+ /**
945
+ * Select Item event. This event signifies that an item was selected by a user from a list.
946
+ * Use the appropriate parameters to contextualize the event.
947
+ * Use this event to discover the most popular items selected.
948
+ *
949
+ * Logged event name: `select_item`
950
+ *
951
+ * @param analytics Analytics instance.
952
+ * @param params See {@link analytics.SelectItemEventParameters}.
953
+ */
954
+ export function logSelectItem(
955
+ analytics: Analytics,
956
+ params: FirebaseAnalyticsTypes.SelectItemEventParameters,
957
+ ): Promise<void>;
958
+
959
+ /**
960
+ * Set checkout option event.
961
+ *
962
+ * Logged event name: `set_checkout_option`
963
+ *
964
+ * @param analytics Analytics instance.
965
+ * @param params See {@link analytics.SetCheckoutOptionEventParameters}.
966
+ */
967
+ export function logSetCheckoutOption(
968
+ analytics: Analytics,
969
+ params: FirebaseAnalyticsTypes.SetCheckoutOptionEventParameters,
970
+ ): Promise<void>;
971
+
972
+ /**
973
+ * Select promotion event. This event signifies that a user has selected a promotion offer. Use the
974
+ * appropriate parameters to contextualize the event, such as the item(s) for which the promotion applies.
975
+ *
976
+ * Logged event name: `select_promotion`
977
+ *
978
+ * @param analytics Analytics instance.
979
+ * @param params See {@link analytics.SelectPromotionEventParameters}.
980
+ */
981
+ export function logSelectPromotion(
982
+ analytics: Analytics,
983
+ params: FirebaseAnalyticsTypes.SelectPromotionEventParameters,
984
+ ): Promise<void>;
985
+
986
+ /**
987
+ * Share event. Apps with social features can log the Share event to identify the most viral content.
988
+ *
989
+ * Logged event name: `share`
990
+ *
991
+ * @param analytics Analytics instance.
992
+ * @param params See {@link analytics.ShareEventParameters}.
993
+ */
994
+ export function logShare(
995
+ analytics: Analytics,
996
+ params: FirebaseAnalyticsTypes.ShareEventParameters,
997
+ ): Promise<void>;
998
+
999
+ /**
1000
+ * Sign Up event. This event indicates that a user has signed up for an account in your app.
1001
+ * The parameter signifies the method by which the user signed up. Use this event to understand
1002
+ * the different behaviors between logged in and logged out users.
1003
+ *
1004
+ * Logged event name: `sign_up`
1005
+ *
1006
+ * @param analytics Analytics instance.
1007
+ * @param params See {@link analytics.SignUpEventParameters}.
1008
+ */
1009
+ export function logSignUp(
1010
+ analytics: Analytics,
1011
+ params: FirebaseAnalyticsTypes.SignUpEventParameters,
1012
+ ): Promise<void>;
1013
+
1014
+ /**
1015
+ * Spend Virtual Currency event. This event tracks the sale of virtual goods in your app and can
1016
+ * help you identify which virtual goods are the most popular objects of purchase.
1017
+ *
1018
+ * Logged event name: `spend_virtual_currency`
1019
+ *
1020
+ * @param analytics Analytics instance.
1021
+ * @param params See {@link analytics.SpendVirtualCurrencyEventParameters}.
1022
+ */
1023
+ export function logSpendVirtualCurrency(
1024
+ analytics: Analytics,
1025
+ params: FirebaseAnalyticsTypes.SpendVirtualCurrencyEventParameters,
1026
+ ): Promise<void>;
1027
+
1028
+ /**
1029
+ * Tutorial Begin event. This event signifies the start of the on-boarding process in your app.
1030
+ * Use this in a funnel with {@link analytics#logTutorialComplete} to understand how many users
1031
+ * complete this process and move on to the full app experience.
1032
+ *
1033
+ * Logged event name: `tutorial_begin`
1034
+ *
1035
+ * @param analytics Analytics instance.
1036
+ */
1037
+ export function logTutorialBegin(analytics: Analytics): Promise<void>;
1038
+
1039
+ /**
1040
+ * Tutorial End event. Use this event to signify the user's completion of your app's on-boarding process.
1041
+ * Add this to a funnel with {@link analytics#logTutorialBegin} to understand how many users
1042
+ * complete this process and move on to the full app experience.
1043
+ *
1044
+ * Logged event name: `tutorial_complete`
1045
+ *
1046
+ * @param analytics Analytics instance.
1047
+ */
1048
+ export function logTutorialComplete(analytics: Analytics): Promise<void>;
1049
+
1050
+ /**
1051
+ * Unlock Achievement event. Log this event when the user has unlocked an achievement in your game.
1052
+ * Since achievements generally represent the breadth of a gaming experience, this event can help
1053
+ * you understand how many users are experiencing all that your game has to offer.
1054
+ *
1055
+ * Logged event name: `unlock_achievement`
1056
+ *
1057
+ * @param analytics Analytics instance.
1058
+ * @param params See {@link analytics.UnlockAchievementEventParameters}.
1059
+ */
1060
+ export function logUnlockAchievement(
1061
+ analytics: Analytics,
1062
+ params: FirebaseAnalyticsTypes.UnlockAchievementEventParameters,
1063
+ ): Promise<void>;
1064
+
1065
+ /**
1066
+ * E-commerce View Cart event. This event signifies that a user has viewed their cart. Use this to analyze your purchase funnel.
1067
+ *
1068
+ * If you supply the `value` parameter, you must also supply the `currency` parameter so that revenue metrics can be computed accurately.
1069
+ *
1070
+ * Logged event name: `view_cart`
1071
+ *
1072
+ * @param analytics Analytics instance.
1073
+ * @param params See {@link analytics.ViewCartEventParameters}.
1074
+ */
1075
+ export function logViewCart(
1076
+ analytics: Analytics,
1077
+ params: FirebaseAnalyticsTypes.ViewCartEventParameters,
1078
+ ): Promise<void>;
1079
+
1080
+ /**
1081
+ * View Item event. This event signifies that some content was shown to the user. This content
1082
+ * may be a product, a screen or just a simple image or text. Use the appropriate parameters
1083
+ * to contextualize the event. Use this event to discover the most popular items viewed in your app.
1084
+ *
1085
+ * If you supply the `value` parameter, you must also supply the `currency` parameter so that revenue metrics can be computed accurately.
1086
+ *
1087
+ * Logged event name: `view_item`
1088
+ *
1089
+ * @param analytics Analytics instance.
1090
+ * @param params See {@link analytics.ViewItemEventParameters}.
1091
+ */
1092
+ export function logViewItem(
1093
+ analytics: Analytics,
1094
+ params: FirebaseAnalyticsTypes.ViewItemEventParameters,
1095
+ ): Promise<void>;
1096
+
1097
+ /**
1098
+ * View Item List event. Log this event when the user has been presented with a list of items of a certain category.
1099
+ *
1100
+ * Logged event name: `view_item_list`
1101
+ *
1102
+ * @param analytics Analytics instance.
1103
+ * @param params See {@link analytics.ViewItemListEventParameters}.
1104
+ */
1105
+ export function logViewItemList(
1106
+ analytics: Analytics,
1107
+ params: FirebaseAnalyticsTypes.ViewItemListEventParameters,
1108
+ ): Promise<void>;
1109
+
1110
+ /**
1111
+ * View Promotion event. This event signifies that a promotion was shown to a user.
1112
+ *
1113
+ * Logged event name: `view_promotion`
1114
+ *
1115
+ * @param analytics Analytics instance.
1116
+ * @param params See {@link analytics.ViewPromotionEventParameters}.
1117
+ */
1118
+ export function logViewPromotion(
1119
+ analytics: Analytics,
1120
+ params: FirebaseAnalyticsTypes.ViewPromotionEventParameters,
1121
+ ): Promise<void>;
1122
+
1123
+ /**
1124
+ * View Search Results event. Log this event when the user has been presented with the results of a search.
1125
+ *
1126
+ * Logged event name: `view_search_results`
1127
+ *
1128
+ * @param analytics Analytics instance.
1129
+ * @param params See {@link analytics.ViewSearchResultsParameters}.
1130
+ */
1131
+ export function logViewSearchResults(
1132
+ analytics: Analytics,
1133
+ params: FirebaseAnalyticsTypes.ViewSearchResultsParameters,
1134
+ ): Promise<void>;
1135
+
1136
+ /**
1137
+ * Adds parameters that will be set on every event logged from the SDK, including automatic ones.
1138
+ *
1139
+ * They will be added to the map of default event parameters, replacing any existing
1140
+ * parameter with the same name. Valid parameter values are String, long, and double.
1141
+ * Setting a key's value to null will clear that parameter. Passing in a null bundle
1142
+ * will clear all parameters.
1143
+ * For Web, the values passed persist on the current page and are passed with all
1144
+ * subsequent events.
1145
+ *
1146
+ * @param analytics Analytics instance.
1147
+ * @param params Parameters to be added to the map of parameters added to every event.
1148
+ */
1149
+ export function setDefaultEventParameters(
1150
+ analytics: Analytics,
1151
+ params: { [p: string]: any },
1152
+ ): Promise<void>;
1153
+
1154
+ /**
1155
+ * start privacy-sensitive on-device conversion management.
1156
+ * This is iOS-only.
1157
+ * This is a no-op if you do not include '$RNFirebaseAnalyticsGoogleAppMeasurementOnDeviceConversion = true' in your Podfile
1158
+ *
1159
+ * @param analytics Analytics instance.
1160
+ * @param emailAddress email address, properly formatted complete with domain name e.g, 'user@example.com'
1161
+ */
1162
+ export function initiateOnDeviceConversionMeasurementWithEmailAddress(
1163
+ analytics: Analytics,
1164
+ emailAddress: string,
1165
+ ): Promise<void>;
1166
+
1167
+ /**
1168
+ * Checks four different things.
1169
+ * 1. Checks if it's not a browser extension environment.
1170
+ * 2. Checks if cookies are enabled in current browser.
1171
+ * 3. Checks if IndexedDB is supported by the browser environment.
1172
+ * 4. Checks if the current browser context is valid for using IndexedDB.open().
1173
+ *
1174
+ * @returns {Promise<boolean>}
1175
+ */
1176
+ export function isSupported(): Promise<boolean>;
1177
+
1178
+ /**
1179
+ * Sets the applicable end user consent state for this web app across all gtag
1180
+ * references once Firebase Analytics is initialized. Web only.
1181
+ * @param analytics Analytics instance.
1182
+ * @param consentSettings See {@link analytics.ConsentSettings}.
1183
+ * @returns {void}
1184
+ */
1185
+ export function setConsent(
1186
+ analytics: Analytics,
1187
+ consentSettings: FirebaseAnalyticsTypes.ConsentSettings,
1188
+ ): void;
1189
+
1190
+ /**
1191
+ * Configures Firebase Analytics to use custom gtag or dataLayer names.
1192
+ * Intended to be used if gtag.js script has been installed on this page
1193
+ * independently of Firebase Analytics, and is using non-default names for
1194
+ * either the gtag function or for dataLayer. Must be called before calling
1195
+ * `getAnalytics()` or it won't have any effect. Web only.
1196
+ * @param options See {@link analytics.SettingsOptions}.
1197
+ * @returns {void}
1198
+ */
1199
+ export function settings(options: FirebaseAnalyticsTypes.SettingsOptions): void;