@vrplatform/log 2.0.61 → 2.0.62

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.
@@ -1,3 +1,4 @@
1
+ import type { Maybe } from '@finalytic/utils';
1
2
  export type TrackProps<T extends TrackingEvent> = OptionalUser<{
2
3
  groupId: string;
3
4
  packageName: string;
@@ -5,6 +6,9 @@ export type TrackProps<T extends TrackingEvent> = OptionalUser<{
5
6
  event: T;
6
7
  properties: TrackingEventProps[T];
7
8
  }>;
9
+ type MaybePartial<T> = {
10
+ [P in keyof T]?: Maybe<T[P]>;
11
+ };
8
12
  export type IdentifyProps = {
9
13
  userId: string;
10
14
  traits?: {
@@ -136,45 +140,45 @@ export type TenantType = 'admin' | 'partner' | 'propertyManager';
136
140
  export type TenantStatus = 'active' | 'inactive';
137
141
  export type SubscriptionStatus = 'active' | 'cancelled' | 'draft' | 'errored' | 'paused' | 'pending' | 'voided';
138
142
  export type OwnerStatementStatus = 'preview' | 'draft' | 'inReview' | 'void' | 'published' | 'posted';
139
- export type TaxStatementStatus = 'draft' | 'ignored' | 'inReview' | 'ready' | 'submitted';
143
+ export type TaxStatementStatus = 'draft' | 'ignored' | 'inReview' | 'ready' | 'submitted' | 'error';
140
144
  export type PaymentMethodType = 'card' | 'direct_debit' | 'direct_debit_ach' | 'direct_debit_bacs' | 'transfer' | 'transfer_automated' | 'external';
141
- type AccountInvitationAcceptedProps = Partial<{
145
+ type AccountInvitationAcceptedProps = MaybePartial<{
142
146
  userId: string;
143
147
  userEmail: string;
144
148
  userRole: 'owner' | 'user' | 'admin';
145
149
  tenantId: string;
146
150
  isNewUser: boolean;
147
151
  }>;
148
- type AccountPasswordResetCompletedProps = Partial<{
152
+ type AccountPasswordResetCompletedProps = MaybePartial<{
149
153
  userEmail: string;
150
154
  }>;
151
- type AccountPasswordResetFailedProps = Partial<{
155
+ type AccountPasswordResetFailedProps = MaybePartial<{
152
156
  userEmail: string;
153
157
  status: 'needs_second_factor' | 'needs_identifier' | 'needs_first_factor' | 'needs_new_password' | null | any;
154
158
  }>;
155
- type AccountPasswordResetRequestedProps = Partial<{
159
+ type AccountPasswordResetRequestedProps = MaybePartial<{
156
160
  userEmail: string;
157
161
  }>;
158
- type AccountSignedOutProps = Partial<{
162
+ type AccountSignedOutProps = MaybePartial<{
159
163
  userId: string;
160
164
  userEmail: string;
161
165
  tenantId: string;
162
166
  firstName: string;
163
167
  lastName: string;
164
168
  }>;
165
- type AccountSigninCompletedProps = Partial<{
169
+ type AccountSigninCompletedProps = MaybePartial<{
166
170
  firstName: string;
167
171
  lastName: string;
168
172
  userEmail: string;
169
173
  }>;
170
- type AccountSignupCodeCompletedProps = Partial<{
174
+ type AccountSignupCodeCompletedProps = MaybePartial<{
171
175
  firstName: string;
172
176
  lastName: string;
173
177
  userEmail: string;
174
178
  companyName: string;
175
179
  type: 'property_manager' | 'partner';
176
180
  }>;
177
- type AccountSignupCodeFailedProps = Partial<{
181
+ type AccountSignupCodeFailedProps = MaybePartial<{
178
182
  firstName: string;
179
183
  lastName: string;
180
184
  userEmail: string;
@@ -182,21 +186,21 @@ type AccountSignupCodeFailedProps = Partial<{
182
186
  type: 'property_manager' | 'partner';
183
187
  status: 'missing_requirements' | 'abandoned' | null | any;
184
188
  }>;
185
- type AccountSignupCodeRequestedProps = Partial<{
189
+ type AccountSignupCodeRequestedProps = MaybePartial<{
186
190
  firstName: string;
187
191
  lastName: string;
188
192
  userEmail: string;
189
193
  companyName: string;
190
194
  type: 'property_manager' | 'partner';
191
195
  }>;
192
- type AccountSignupCompletedProps = Partial<{
196
+ type AccountSignupCompletedProps = MaybePartial<{
193
197
  tenantId: string;
194
198
  userEmail: string;
195
199
  firstName: string;
196
200
  lastName: string;
197
201
  userId: string;
198
202
  }>;
199
- type AutomationCreatedProps = Partial<{
203
+ type AutomationCreatedProps = MaybePartial<{
200
204
  automationId: string;
201
205
  templateId: string;
202
206
  type?: string | null;
@@ -205,7 +209,7 @@ type AutomationCreatedProps = Partial<{
205
209
  userEmail: string;
206
210
  tenantId: string;
207
211
  }>;
208
- type AutomationDeletedProps = Partial<{
212
+ type AutomationDeletedProps = MaybePartial<{
209
213
  automationId: string;
210
214
  templateId: string;
211
215
  type?: string | null;
@@ -215,7 +219,7 @@ type AutomationDeletedProps = Partial<{
215
219
  tenantId: string;
216
220
  }>;
217
221
  type AutomationUpdatedProps = any;
218
- type ConnectionCreatedProps = Partial<{
222
+ type ConnectionCreatedProps = MaybePartial<{
219
223
  connectionId: string;
220
224
  tenantId: string;
221
225
  userId: string;
@@ -223,7 +227,7 @@ type ConnectionCreatedProps = Partial<{
223
227
  appId: string;
224
228
  type?: string;
225
229
  }>;
226
- type ConnectionDeletedProps = Partial<{
230
+ type ConnectionDeletedProps = MaybePartial<{
227
231
  connectionId: string;
228
232
  tenantId: string;
229
233
  type?: string;
@@ -231,32 +235,32 @@ type ConnectionDeletedProps = Partial<{
231
235
  appId: string;
232
236
  userEmail: string;
233
237
  }>;
234
- type ConnectionReconnectedProps = Partial<{
238
+ type ConnectionReconnectedProps = MaybePartial<{
235
239
  connectionId: string;
236
240
  tenantId: string;
237
241
  userId: string;
238
242
  userEmail: string;
239
243
  appId: string;
240
244
  }>;
241
- type ConnectionRequestedProps = Partial<{
245
+ type ConnectionRequestedProps = MaybePartial<{
242
246
  type: 'PMS' | 'Accounting';
243
247
  website: string;
244
248
  userId: string;
245
249
  userEmail: string;
246
250
  tenantId: string;
247
251
  }>;
248
- type GlOwnerStatementDownloadedProps = Partial<{
252
+ type GlOwnerStatementDownloadedProps = MaybePartial<{
249
253
  ownerStatementId: string;
250
254
  ownerStatementUrls: string[];
251
255
  userType: 'owner' | 'property_manager';
252
256
  }>;
253
- type GlOwnerStatementPreviewOpenedProps = Partial<{
257
+ type GlOwnerStatementPreviewOpenedProps = MaybePartial<{
254
258
  ownerStatementStatus: string;
255
259
  ownerStatementId: string;
256
260
  ownerStatementUrls: string[];
257
261
  userType: 'owner' | 'property_manager';
258
262
  }>;
259
- type HyperlineCustomerCreatedProps = Partial<{
263
+ type HyperlineCustomerCreatedProps = MaybePartial<{
260
264
  tenantId: string;
261
265
  customerId: string;
262
266
  billingEmail: string;
@@ -266,7 +270,7 @@ type HyperlineCustomerCreatedProps = Partial<{
266
270
  vatNumber: string;
267
271
  webhookEventType: 'customer.created';
268
272
  }>;
269
- type HyperlineCustomerUpdatedProps = Partial<{
273
+ type HyperlineCustomerUpdatedProps = MaybePartial<{
270
274
  tenantId: string;
271
275
  customerId: string;
272
276
  billingEmail: string;
@@ -276,7 +280,7 @@ type HyperlineCustomerUpdatedProps = Partial<{
276
280
  vatNumber: string;
277
281
  webhookEventType: 'customer.updated';
278
282
  }>;
279
- type HyperlineInvoiceErroredProps = Partial<{
283
+ type HyperlineInvoiceErroredProps = MaybePartial<{
280
284
  status: 'errored';
281
285
  paymentMethodType: string;
282
286
  invoiceId: string;
@@ -285,7 +289,7 @@ type HyperlineInvoiceErroredProps = Partial<{
285
289
  customerId: string;
286
290
  erroredAt: string;
287
291
  }>;
288
- type HyperlineInvoiceReadyProps = Partial<{
292
+ type HyperlineInvoiceReadyProps = MaybePartial<{
289
293
  status: 'ready';
290
294
  paymentMethodType: string;
291
295
  invoiceId: string;
@@ -296,7 +300,7 @@ type HyperlineInvoiceReadyProps = Partial<{
296
300
  taxAmount: number;
297
301
  readyAt: string;
298
302
  }>;
299
- type HyperlineInvoiceSettledProps = Partial<{
303
+ type HyperlineInvoiceSettledProps = MaybePartial<{
300
304
  status: 'settled';
301
305
  paymentMethodType: string;
302
306
  invoiceId: string;
@@ -307,7 +311,7 @@ type HyperlineInvoiceSettledProps = Partial<{
307
311
  taxAmount: number;
308
312
  settledAt: string;
309
313
  }>;
310
- type HyperlineInvoiceVoidedProps = Partial<{
314
+ type HyperlineInvoiceVoidedProps = MaybePartial<{
311
315
  status: 'voided';
312
316
  paymentMethodType: string;
313
317
  invoiceId: string;
@@ -316,7 +320,7 @@ type HyperlineInvoiceVoidedProps = Partial<{
316
320
  customerId: string;
317
321
  voidedAt: string;
318
322
  }>;
319
- type HyperlinePaymentMethodCreatedProps = Partial<{
323
+ type HyperlinePaymentMethodCreatedProps = MaybePartial<{
320
324
  tenantId: string;
321
325
  subscriptionStartDate: string;
322
326
  paymentMethodType: PaymentMethodType;
@@ -325,7 +329,7 @@ type HyperlinePaymentMethodCreatedProps = Partial<{
325
329
  customerId: string;
326
330
  webhookEventType: 'payment_method.created';
327
331
  }>;
328
- type HyperlinePaymentMethodDeletedProps = Partial<{
332
+ type HyperlinePaymentMethodDeletedProps = MaybePartial<{
329
333
  tenantId: string;
330
334
  subscriptionStartDate: string;
331
335
  paymentMethodType: PaymentMethodType;
@@ -334,7 +338,7 @@ type HyperlinePaymentMethodDeletedProps = Partial<{
334
338
  customerId: string;
335
339
  webhookEventType: 'payment_method.deleted';
336
340
  }>;
337
- type HyperlinePaymentMethodErroredProps = Partial<{
341
+ type HyperlinePaymentMethodErroredProps = MaybePartial<{
338
342
  tenantId: string;
339
343
  subscriptionStartDate: string;
340
344
  paymentMethodType: PaymentMethodType;
@@ -343,7 +347,7 @@ type HyperlinePaymentMethodErroredProps = Partial<{
343
347
  customerId: string;
344
348
  webhookEventType: 'payment_method.errored';
345
349
  }>;
346
- type HyperlineSubscriptionCancellationScheduledProps = Partial<{
350
+ type HyperlineSubscriptionCancellationScheduledProps = MaybePartial<{
347
351
  subscriptionId: string;
348
352
  cancellationStrategy: 'charge_prorata' | 'charge_custom' | 'refund_prorata' | 'refund_custom' | 'end_of_period' | 'do_nothing';
349
353
  cancelledAt: string;
@@ -352,7 +356,7 @@ type HyperlineSubscriptionCancellationScheduledProps = Partial<{
352
356
  tenantId: string;
353
357
  webhookEventType: 'subscription.cancellation_scheduled';
354
358
  }>;
355
- type HyperlineSubscriptionChargedProps = Partial<{
359
+ type HyperlineSubscriptionChargedProps = MaybePartial<{
356
360
  plan: string;
357
361
  subscriptionId: string;
358
362
  subscriptionStartDate: string;
@@ -360,7 +364,7 @@ type HyperlineSubscriptionChargedProps = Partial<{
360
364
  paymentMethodType: string;
361
365
  customerId: string;
362
366
  }>;
363
- type HyperlineSubscriptionCreatedProps = Partial<{
367
+ type HyperlineSubscriptionCreatedProps = MaybePartial<{
364
368
  trialStartDate: string;
365
369
  plan: string;
366
370
  subscriptionId: string;
@@ -369,7 +373,7 @@ type HyperlineSubscriptionCreatedProps = Partial<{
369
373
  paymentMethodType: string;
370
374
  customerId: string;
371
375
  }>;
372
- type HyperlineSubscriptionStatusChangedProps = Partial<{
376
+ type HyperlineSubscriptionStatusChangedProps = MaybePartial<{
373
377
  subscriptionId: string;
374
378
  plan: string;
375
379
  tenantId: string;
@@ -380,7 +384,7 @@ type HyperlineSubscriptionStatusChangedProps = Partial<{
380
384
  mrr: number;
381
385
  customerId: string;
382
386
  }>;
383
- type HyperlineTrialEndedProps = Partial<{
387
+ type HyperlineTrialEndedProps = MaybePartial<{
384
388
  trialStartDate: string;
385
389
  trialEndDate: string;
386
390
  plan: string;
@@ -389,13 +393,13 @@ type HyperlineTrialEndedProps = Partial<{
389
393
  subscriptionStatus: SubscriptionStatus;
390
394
  paymentMethodType: PaymentMethodType;
391
395
  }>;
392
- type HyperlineTrialStartedProps = Partial<{
396
+ type HyperlineTrialStartedProps = MaybePartial<{
393
397
  tenantId: string;
394
398
  subscriptionStatus: SubscriptionStatus;
395
399
  trialUntil: string;
396
400
  webhookEventType: 'payment_method.created';
397
401
  }>;
398
- type OwnerCreatedProps = Partial<{
402
+ type OwnerCreatedProps = MaybePartial<{
399
403
  userId: string;
400
404
  tenantId: string;
401
405
  ownerId: string;
@@ -403,7 +407,7 @@ type OwnerCreatedProps = Partial<{
403
407
  withUserInvite: boolean;
404
408
  userEmail: string;
405
409
  }>;
406
- type OwnerDeletedProps = Partial<{
410
+ type OwnerDeletedProps = MaybePartial<{
407
411
  userId: string;
408
412
  tenantId: string;
409
413
  ownerId: string;
@@ -411,18 +415,18 @@ type OwnerDeletedProps = Partial<{
411
415
  listingId: string;
412
416
  ownershipId: string;
413
417
  }>;
414
- type OwnerTaxInfoModalOpenedProps = Partial<{
418
+ type OwnerTaxInfoModalOpenedProps = MaybePartial<{
415
419
  flag: string;
416
420
  }>;
417
- type OwnerTaxInfoModalSubmittedProps = Partial<{
421
+ type OwnerTaxInfoModalSubmittedProps = MaybePartial<{
418
422
  flag: string;
419
423
  }>;
420
- type OwnerUpdatedProps = Partial<{
424
+ type OwnerUpdatedProps = MaybePartial<{
421
425
  userId: string;
422
426
  tenantId: string;
423
427
  ownerId: string;
424
428
  }>;
425
- type OwnershipCreatedProps = Partial<{
429
+ type OwnershipCreatedProps = MaybePartial<{
426
430
  ownershipId: string;
427
431
  ownerId: string;
428
432
  listingId: string;
@@ -430,7 +434,7 @@ type OwnershipCreatedProps = Partial<{
430
434
  userEmail: string;
431
435
  tenantId: string;
432
436
  }>;
433
- type OwnershipDeletedProps = Partial<{
437
+ type OwnershipDeletedProps = MaybePartial<{
434
438
  ownershipId: string;
435
439
  ownerId: string;
436
440
  listingId: string;
@@ -438,7 +442,7 @@ type OwnershipDeletedProps = Partial<{
438
442
  userEmail: string;
439
443
  tenantId: string;
440
444
  }>;
441
- type OwnershipUpdatedProps = Partial<{
445
+ type OwnershipUpdatedProps = MaybePartial<{
442
446
  ownershipId: string;
443
447
  ownerId: string;
444
448
  listingId: string;
@@ -450,17 +454,17 @@ type SetupAccountingConfigCompletedProps = any;
450
454
  type SetupAccountingVersionCompletedProps = any;
451
455
  type SetupClassesSetProps = any;
452
456
  type SetupEntitiesSetProps = any;
453
- type SetupListingImportedProps = Partial<{
457
+ type SetupListingImportedProps = MaybePartial<{
454
458
  appId: string;
455
459
  }>;
456
- type SetupOwnerImportedProps = Partial<{
460
+ type SetupOwnerImportedProps = MaybePartial<{
457
461
  appId: string;
458
462
  }>;
459
- type SetupReservationImportedProps = Partial<{
463
+ type SetupReservationImportedProps = MaybePartial<{
460
464
  appId: string;
461
465
  }>;
462
466
  type SetupVendorsSetProps = any;
463
- type TaxStatementDownloadedProps = Partial<{
467
+ type TaxStatementDownloadedProps = MaybePartial<{
464
468
  taxStatementStatus?: TaxStatementStatus;
465
469
  taxStatementId: string;
466
470
  taxStatementUrl: string;
@@ -469,7 +473,7 @@ type TaxStatementDownloadedProps = Partial<{
469
473
  userEmail: string;
470
474
  tenantId: string;
471
475
  }>;
472
- type TaxStatementPreviewOpenedProps = Partial<{
476
+ type TaxStatementPreviewOpenedProps = MaybePartial<{
473
477
  taxStatementStatus?: TaxStatementStatus;
474
478
  taxStatementId: string;
475
479
  taxStatementUrl: string;
@@ -478,7 +482,7 @@ type TaxStatementPreviewOpenedProps = Partial<{
478
482
  userEmail: string;
479
483
  tenantId: string;
480
484
  }>;
481
- type TeamAddedProps = Partial<{
485
+ type TeamAddedProps = MaybePartial<{
482
486
  tenantId: string;
483
487
  tenantName: string;
484
488
  partnerId: string;
@@ -486,46 +490,46 @@ type TeamAddedProps = Partial<{
486
490
  userId: string;
487
491
  userEmail: string;
488
492
  }>;
489
- type TeamCanceledProps = Partial<{
493
+ type TeamCanceledProps = MaybePartial<{
490
494
  tenantId: string;
491
495
  customerId: string;
492
496
  subscriptionId: string;
493
497
  feedback: string;
494
498
  reason: string;
495
499
  }>;
496
- type TeamDeletedProps = Partial<{
500
+ type TeamDeletedProps = MaybePartial<{
497
501
  tenantId: string;
498
502
  userId: string;
499
503
  userEmail: string;
500
504
  }>;
501
- type TeamInfoUpdatedProps = Partial<{
505
+ type TeamInfoUpdatedProps = MaybePartial<{
502
506
  userId: string;
503
507
  tenantId: string;
504
508
  userEmail: string;
505
509
  }>;
506
- type TeamMemberRemovedProps = Partial<{
510
+ type TeamMemberRemovedProps = MaybePartial<{
507
511
  userId: string;
508
512
  removedUserId: string;
509
513
  tenantId: string;
510
514
  userEmail: string;
511
515
  }>;
512
- type TeamReinstatedProps = Partial<{
516
+ type TeamReinstatedProps = MaybePartial<{
513
517
  tenantId: string;
514
518
  subscriptionId: string;
515
519
  }>;
516
- type TestErrorProps = Partial<{
520
+ type TestErrorProps = MaybePartial<{
517
521
  userId: string;
518
522
  tenantId: string;
519
523
  [key: string]: any;
520
524
  }>;
521
- type TestEventProps = Partial<{
525
+ type TestEventProps = MaybePartial<{
522
526
  success: boolean;
523
527
  [key: string]: any;
524
528
  }>;
525
- type UpdateRefreshAcceptedProps = Partial<{
529
+ type UpdateRefreshAcceptedProps = MaybePartial<{
526
530
  appName: string;
527
531
  }>;
528
- type OwnerStatementStatusChangedProps = Partial<{
532
+ type OwnerStatementStatusChangedProps = MaybePartial<{
529
533
  userId: string;
530
534
  tenantId: string;
531
535
  userEmail: string;
@@ -535,10 +539,20 @@ type OwnerStatementStatusChangedProps = Partial<{
535
539
  startAt: string;
536
540
  status: OwnerStatementStatus;
537
541
  }>;
538
- type ListingActivatedProps = any;
539
- type ListingDeactivatedProps = any;
540
- type ListingsReportedProps = any;
541
- type IntercomConversationCreated = Partial<{
542
+ type ListingActivatedProps = MaybePartial<{
543
+ tenantId: string;
544
+ billingStatus: 'active' | 'inactive';
545
+ name: string;
546
+ vrpStatus: 'active' | 'disabled' | 'enabled' | 'inactive';
547
+ pmsStatus: string;
548
+ }>;
549
+ type ListingDeactivatedProps = ListingActivatedProps;
550
+ type ListingsReportedProps = MaybePartial<{
551
+ userId: string;
552
+ tenantId: string;
553
+ activeListings: number;
554
+ }>;
555
+ type IntercomConversationCreated = MaybePartial<{
542
556
  userId: string;
543
557
  tenantId: string;
544
558
  userEmail: string;
@@ -550,14 +564,14 @@ type IntercomConversationCreated = Partial<{
550
564
  submittedFrom: 'user' | 'admin';
551
565
  }>;
552
566
  type IntercomConversationReplied = IntercomConversationCreated;
553
- type IntercomConversationClosed = Partial<{
567
+ type IntercomConversationClosed = MaybePartial<{
554
568
  userId: string;
555
569
  tenantId: string;
556
570
  userEmail: string;
557
571
  conversationId: string;
558
572
  createdAt: string;
559
573
  }>;
560
- type IntercomConversationRated = Partial<{
574
+ type IntercomConversationRated = MaybePartial<{
561
575
  userId: string;
562
576
  tenantId: string;
563
577
  userEmail: string;
@@ -566,7 +580,7 @@ type IntercomConversationRated = Partial<{
566
580
  remark: string;
567
581
  createdAt: string;
568
582
  }>;
569
- type MrrReportedProps = Partial<{
583
+ type MrrReportedProps = MaybePartial<{
570
584
  mrr: number;
571
585
  subscriptionStatus: SubscriptionStatus;
572
586
  }>;