heartraite 1.0.222 → 1.0.223

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.
@@ -43,3 +43,34 @@ export type EventOrderRefundView = Pick<EventOrderRefund, "amountOre" | "status"
43
43
  export type EventOrderView = Pick<EventOrder, "id" | "eventId" | "kind" | "status" | "amountOre" | "currency" | "createdAt" | "expiresAt" | "paidAt" | "cancelledAt"> & {
44
44
  refund?: EventOrderRefundView;
45
45
  };
46
+ export type TicketErrorReason = "sold_out" | "checkout_expired" | "already_ticketed" | "sales_closed" | "sales_not_open" | "refund_on_record" | "event_cancelled" | "payment_incomplete" | "payment_mismatch" | "quota_exceeded";
47
+ export type AdminRefundReason = Extract<EventOrderRefundReason, "user_cancel" | "admin">;
48
+ export type EventOrderAdminRow = {
49
+ orderId: string;
50
+ userId: string;
51
+ firstName: string;
52
+ email: string;
53
+ gender: Gender;
54
+ kind: EventOrderKind;
55
+ status: EventOrderStatus;
56
+ amountOre: number;
57
+ createdAt: string;
58
+ paidAt?: string;
59
+ refund?: EventOrderRefundView;
60
+ stripePaymentIntentId?: string;
61
+ checkedInAt?: string;
62
+ };
63
+ export type EventCancellationSummary = {
64
+ refunded: number;
65
+ released: number;
66
+ failed: number;
67
+ skipped: number;
68
+ };
69
+ export type TicketCheckIn = {
70
+ eventId: string;
71
+ userId: string;
72
+ checkedInAt?: string;
73
+ };
74
+ export type TicketingConfig = {
75
+ enabled: boolean;
76
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "heartraite",
3
- "version": "1.0.222",
3
+ "version": "1.0.223",
4
4
  "description": "Heartraite npm package for common functionality",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -81,3 +81,53 @@ export type EventOrderView = Pick<
81
81
  > & {
82
82
  refund?: EventOrderRefundView;
83
83
  };
84
+
85
+ export type TicketErrorReason =
86
+ | "sold_out"
87
+ | "checkout_expired"
88
+ | "already_ticketed"
89
+ | "sales_closed"
90
+ | "sales_not_open"
91
+ | "refund_on_record"
92
+ | "event_cancelled"
93
+ | "payment_incomplete"
94
+ | "payment_mismatch"
95
+ | "quota_exceeded";
96
+
97
+ export type AdminRefundReason = Extract<
98
+ EventOrderRefundReason,
99
+ "user_cancel" | "admin"
100
+ >;
101
+
102
+ export type EventOrderAdminRow = {
103
+ orderId: string;
104
+ userId: string;
105
+ firstName: string;
106
+ email: string;
107
+ gender: Gender;
108
+ kind: EventOrderKind;
109
+ status: EventOrderStatus;
110
+ amountOre: number;
111
+ createdAt: string;
112
+ paidAt?: string;
113
+ refund?: EventOrderRefundView;
114
+ stripePaymentIntentId?: string;
115
+ checkedInAt?: string;
116
+ };
117
+
118
+ export type EventCancellationSummary = {
119
+ refunded: number;
120
+ released: number;
121
+ failed: number;
122
+ skipped: number;
123
+ };
124
+
125
+ export type TicketCheckIn = {
126
+ eventId: string;
127
+ userId: string;
128
+ checkedInAt?: string;
129
+ };
130
+
131
+ export type TicketingConfig = {
132
+ enabled: boolean;
133
+ };