@hexclave/shared 1.0.33 → 1.0.34

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.
@@ -6,13 +6,10 @@ declare const customerProductReadSchema: yup$1.ObjectSchema<{
6
6
  id: string | null;
7
7
  quantity: number;
8
8
  product: {
9
- free_trial?: ______utils_dates0.DayInterval | undefined;
10
9
  client_metadata?: {} | null | undefined;
11
10
  client_read_only_metadata?: {} | null | undefined;
12
11
  server_metadata?: {} | null | undefined;
13
- display_name: string;
14
- server_only: boolean;
15
- customer_type: "team" | "user" | "custom";
12
+ free_trial?: ______utils_dates0.DayInterval | undefined;
16
13
  stackable: boolean;
17
14
  prices: Record<string, {
18
15
  interval?: ______utils_dates0.DayInterval | undefined;
@@ -25,9 +22,12 @@ declare const customerProductReadSchema: yup$1.ObjectSchema<{
25
22
  CAD?: string | undefined;
26
23
  free_trial?: ______utils_dates0.DayInterval | undefined;
27
24
  }>;
25
+ display_name: string;
26
+ server_only: boolean;
27
+ customer_type: "user" | "team" | "custom";
28
28
  included_items: Record<string, {
29
- quantity?: number | undefined;
30
29
  repeat?: "never" | ______utils_dates0.DayInterval | undefined;
30
+ quantity?: number | undefined;
31
31
  expires?: "never" | "when-purchase-expires" | "when-repeated" | undefined;
32
32
  }>;
33
33
  };
@@ -39,15 +39,11 @@ declare const customerProductReadSchema: yup$1.ObjectSchema<{
39
39
  is_cancelable: boolean;
40
40
  } | null | undefined;
41
41
  switch_options: {
42
- product_id: string;
43
42
  product: {
44
- free_trial?: ______utils_dates0.DayInterval | undefined;
45
43
  client_metadata?: {} | null | undefined;
46
44
  client_read_only_metadata?: {} | null | undefined;
47
45
  server_metadata?: {} | null | undefined;
48
- display_name: string;
49
- server_only: boolean;
50
- customer_type: "team" | "user" | "custom";
46
+ free_trial?: ______utils_dates0.DayInterval | undefined;
51
47
  stackable: boolean;
52
48
  prices: Record<string, {
53
49
  interval?: ______utils_dates0.DayInterval | undefined;
@@ -60,12 +56,16 @@ declare const customerProductReadSchema: yup$1.ObjectSchema<{
60
56
  CAD?: string | undefined;
61
57
  free_trial?: ______utils_dates0.DayInterval | undefined;
62
58
  }>;
59
+ display_name: string;
60
+ server_only: boolean;
61
+ customer_type: "user" | "team" | "custom";
63
62
  included_items: Record<string, {
64
- quantity?: number | undefined;
65
63
  repeat?: "never" | ______utils_dates0.DayInterval | undefined;
64
+ quantity?: number | undefined;
66
65
  expires?: "never" | "when-purchase-expires" | "when-repeated" | undefined;
67
66
  }>;
68
67
  };
68
+ product_id: string;
69
69
  }[] | undefined;
70
70
  }, yup$1.AnyObject, {
71
71
  id: undefined;
@@ -102,15 +102,11 @@ declare const customerProductsListResponseSchema: yup$1.ObjectSchema<{
102
102
  is_cancelable: boolean;
103
103
  } | null | undefined;
104
104
  switch_options?: {
105
- product_id: string;
106
105
  product: {
107
- free_trial?: ______utils_dates0.DayInterval | undefined;
108
106
  client_metadata?: {} | null | undefined;
109
107
  client_read_only_metadata?: {} | null | undefined;
110
108
  server_metadata?: {} | null | undefined;
111
- display_name: string;
112
- server_only: boolean;
113
- customer_type: "team" | "user" | "custom";
109
+ free_trial?: ______utils_dates0.DayInterval | undefined;
114
110
  stackable: boolean;
115
111
  prices: Record<string, {
116
112
  interval?: ______utils_dates0.DayInterval | undefined;
@@ -123,23 +119,22 @@ declare const customerProductsListResponseSchema: yup$1.ObjectSchema<{
123
119
  CAD?: string | undefined;
124
120
  free_trial?: ______utils_dates0.DayInterval | undefined;
125
121
  }>;
122
+ display_name: string;
123
+ server_only: boolean;
124
+ customer_type: "user" | "team" | "custom";
126
125
  included_items: Record<string, {
127
- quantity?: number | undefined;
128
126
  repeat?: "never" | ______utils_dates0.DayInterval | undefined;
127
+ quantity?: number | undefined;
129
128
  expires?: "never" | "when-purchase-expires" | "when-repeated" | undefined;
130
129
  }>;
131
130
  };
131
+ product_id: string;
132
132
  }[] | undefined;
133
- id: string | null;
134
- quantity: number;
135
133
  product: {
136
- free_trial?: ______utils_dates0.DayInterval | undefined;
137
134
  client_metadata?: {} | null | undefined;
138
135
  client_read_only_metadata?: {} | null | undefined;
139
136
  server_metadata?: {} | null | undefined;
140
- display_name: string;
141
- server_only: boolean;
142
- customer_type: "team" | "user" | "custom";
137
+ free_trial?: ______utils_dates0.DayInterval | undefined;
143
138
  stackable: boolean;
144
139
  prices: Record<string, {
145
140
  interval?: ______utils_dates0.DayInterval | undefined;
@@ -152,12 +147,17 @@ declare const customerProductsListResponseSchema: yup$1.ObjectSchema<{
152
147
  CAD?: string | undefined;
153
148
  free_trial?: ______utils_dates0.DayInterval | undefined;
154
149
  }>;
150
+ display_name: string;
151
+ server_only: boolean;
152
+ customer_type: "user" | "team" | "custom";
155
153
  included_items: Record<string, {
156
- quantity?: number | undefined;
157
154
  repeat?: "never" | ______utils_dates0.DayInterval | undefined;
155
+ quantity?: number | undefined;
158
156
  expires?: "never" | "when-purchase-expires" | "when-repeated" | undefined;
159
157
  }>;
160
158
  };
159
+ quantity: number;
160
+ id: string | null;
161
161
  }[];
162
162
  is_paginated: boolean;
163
163
  pagination: {
@@ -1 +1 @@
1
- {"version":3,"file":"products.d.ts","names":[],"sources":["../../../../src/interface/crud/products.ts"],"mappings":";;;;cAQa,yBAAA,EAAyB,KAAA,CAAA,YAAA;;;;iBAc1B,kBAAA,CAAA,WAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAEA,mBAAA,GAAsB,KAAA,CAAI,SAAA,QAAiB,yBAAA;AAAA,cAE1C,kCAAA,EAAkC,KAAA,CAAA,YAAA;;;;;;;;;;;;qBAMnC,kBAAA,CAAA,WAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAEA,4BAAA,GAA+B,KAAA,CAAI,SAAA,QAAiB,kCAAA;AAAA,KAEpD,2BAAA;EACV,aAAA;EACA,WAAA;EACA,MAAA;EACA,KAAA;AAAA"}
1
+ {"version":3,"file":"products.d.ts","names":[],"sources":["../../../../src/interface/crud/products.ts"],"mappings":";;;;cAQa,yBAAA,EAAyB,KAAA,CAAA,YAAA;;;;;;;iBAc1B,kBAAA,CAAA,WAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAEA,mBAAA,GAAsB,KAAA,CAAI,SAAA,QAAiB,yBAAA;AAAA,cAE1C,kCAAA,EAAkC,KAAA,CAAA,YAAA;;;;;;;;;;;;;;qBAMnC,kBAAA,CAAA,WAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAEA,4BAAA,GAA+B,KAAA,CAAI,SAAA,QAAiB,kCAAA;AAAA,KAEpD,2BAAA;EACV,aAAA;EACA,WAAA;EACA,MAAA;EACA,KAAA;AAAA"}
@@ -80,11 +80,11 @@ declare const userApiKeysCrud: ______crud0.CrudSchemaFromOptions<{
80
80
  user_id: undefined;
81
81
  }, "">, userApiKeysCreateOutputSchema: yup$1.ObjectSchema<{
82
82
  type: "user";
83
+ description: string;
83
84
  id: string;
84
85
  created_at_millis: number;
85
86
  expires_at_millis: number | undefined;
86
87
  user_id: string;
87
- description: string;
88
88
  manually_revoked_at_millis: number | undefined;
89
89
  is_public: boolean;
90
90
  } & {
@@ -178,11 +178,11 @@ declare const teamApiKeysCrud: ______crud0.CrudSchemaFromOptions<{
178
178
  team_id: undefined;
179
179
  }, "">, teamApiKeysCreateOutputSchema: yup$1.ObjectSchema<{
180
180
  type: "team";
181
+ description: string;
181
182
  id: string;
182
183
  created_at_millis: number;
183
184
  expires_at_millis: number | undefined;
184
185
  team_id: string;
185
- description: string;
186
186
  manually_revoked_at_millis: number | undefined;
187
187
  is_public: boolean;
188
188
  } & {
@@ -6,7 +6,7 @@ import * as ______utils_dates0 from "../../utils/dates";
6
6
  declare const transactionEntrySchema: yup$1.MixedSchema<{
7
7
  type: "money_transfer";
8
8
  customer_id: string;
9
- customer_type: "team" | "user" | "custom";
9
+ customer_type: "user" | "team" | "custom";
10
10
  charged_amount: {
11
11
  USD?: string | undefined;
12
12
  EUR?: string | undefined;
@@ -23,28 +23,21 @@ declare const transactionEntrySchema: yup$1.MixedSchema<{
23
23
  adjusted_entry_index: number | null;
24
24
  } | {
25
25
  type: "item_quantity_change";
26
+ quantity: number;
26
27
  item_id: string;
27
28
  customer_id: string;
28
- quantity: number;
29
- customer_type: "team" | "user" | "custom";
29
+ customer_type: "user" | "team" | "custom";
30
30
  adjusted_transaction_id: string | null;
31
31
  adjusted_entry_index: number | null;
32
32
  } | {
33
33
  one_time_purchase_id?: string | undefined;
34
34
  subscription_id?: string | undefined;
35
35
  type: "product_grant";
36
- customer_id: string;
37
- product_id: string | null;
38
- quantity: number;
39
- customer_type: "team" | "user" | "custom";
40
36
  product: {
41
- free_trial?: ______utils_dates0.DayInterval | undefined;
42
37
  client_metadata?: {} | null | undefined;
43
38
  client_read_only_metadata?: {} | null | undefined;
44
39
  server_metadata?: {} | null | undefined;
45
- display_name: string;
46
- server_only: boolean;
47
- customer_type: "team" | "user" | "custom";
40
+ free_trial?: ______utils_dates0.DayInterval | undefined;
48
41
  stackable: boolean;
49
42
  prices: Record<string, {
50
43
  interval?: ______utils_dates0.DayInterval | undefined;
@@ -57,12 +50,19 @@ declare const transactionEntrySchema: yup$1.MixedSchema<{
57
50
  CAD?: string | undefined;
58
51
  free_trial?: ______utils_dates0.DayInterval | undefined;
59
52
  }>;
53
+ display_name: string;
54
+ server_only: boolean;
55
+ customer_type: "user" | "team" | "custom";
60
56
  included_items: Record<string, {
61
- quantity?: number | undefined;
62
57
  repeat?: "never" | ______utils_dates0.DayInterval | undefined;
58
+ quantity?: number | undefined;
63
59
  expires?: "never" | "when-purchase-expires" | "when-repeated" | undefined;
64
60
  }>;
65
61
  };
62
+ quantity: number;
63
+ customer_id: string;
64
+ product_id: string | null;
65
+ customer_type: "user" | "team" | "custom";
66
66
  adjusted_transaction_id: string | null;
67
67
  adjusted_entry_index: number | null;
68
68
  price_id: string | null;
@@ -85,12 +85,12 @@ declare const transactionSchema: yup$1.ObjectSchema<{
85
85
  created_at_millis: number;
86
86
  effective_at_millis: number;
87
87
  type: "purchase" | "subscription-cancellation" | "subscription-renewal" | "manual-item-quantity-change" | "refund" | "chargeback" | "product-change" | null;
88
- customer_type: "team" | "user" | "custom";
88
+ customer_type: "user" | "team" | "custom";
89
89
  customer_id: string;
90
90
  entries: ({
91
91
  type: "money_transfer";
92
92
  customer_id: string;
93
- customer_type: "team" | "user" | "custom";
93
+ customer_type: "user" | "team" | "custom";
94
94
  charged_amount: {
95
95
  USD?: string | undefined;
96
96
  EUR?: string | undefined;
@@ -107,28 +107,21 @@ declare const transactionSchema: yup$1.ObjectSchema<{
107
107
  adjusted_entry_index: number | null;
108
108
  } | {
109
109
  type: "item_quantity_change";
110
+ quantity: number;
110
111
  item_id: string;
111
112
  customer_id: string;
112
- quantity: number;
113
- customer_type: "team" | "user" | "custom";
113
+ customer_type: "user" | "team" | "custom";
114
114
  adjusted_transaction_id: string | null;
115
115
  adjusted_entry_index: number | null;
116
116
  } | {
117
117
  one_time_purchase_id?: string | undefined;
118
118
  subscription_id?: string | undefined;
119
119
  type: "product_grant";
120
- customer_id: string;
121
- product_id: string | null;
122
- quantity: number;
123
- customer_type: "team" | "user" | "custom";
124
120
  product: {
125
- free_trial?: ______utils_dates0.DayInterval | undefined;
126
121
  client_metadata?: {} | null | undefined;
127
122
  client_read_only_metadata?: {} | null | undefined;
128
123
  server_metadata?: {} | null | undefined;
129
- display_name: string;
130
- server_only: boolean;
131
- customer_type: "team" | "user" | "custom";
124
+ free_trial?: ______utils_dates0.DayInterval | undefined;
132
125
  stackable: boolean;
133
126
  prices: Record<string, {
134
127
  interval?: ______utils_dates0.DayInterval | undefined;
@@ -141,12 +134,19 @@ declare const transactionSchema: yup$1.ObjectSchema<{
141
134
  CAD?: string | undefined;
142
135
  free_trial?: ______utils_dates0.DayInterval | undefined;
143
136
  }>;
137
+ display_name: string;
138
+ server_only: boolean;
139
+ customer_type: "user" | "team" | "custom";
144
140
  included_items: Record<string, {
145
- quantity?: number | undefined;
146
141
  repeat?: "never" | ______utils_dates0.DayInterval | undefined;
142
+ quantity?: number | undefined;
147
143
  expires?: "never" | "when-purchase-expires" | "when-repeated" | undefined;
148
144
  }>;
149
145
  };
146
+ quantity: number;
147
+ customer_id: string;
148
+ product_id: string | null;
149
+ customer_type: "user" | "team" | "custom";
150
150
  adjusted_transaction_id: string | null;
151
151
  adjusted_entry_index: number | null;
152
152
  price_id: string | null;
@@ -1 +1 @@
1
- {"version":3,"file":"transactions.d.ts","names":[],"sources":["../../../../src/interface/crud/transactions.ts"],"mappings":";;;;;cAwFa,sBAAA,QAAsB,WAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAMxB,kBAAA,CAAA,WAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAEC,gBAAA,GAAmB,SAAA,QAAiB,sBAAA;AAAA,cAEnC,iBAAA;AAAA,KAUD,eAAA,WAA0B,iBAAA;AAAA,cAEzB,iBAAA,QAAiB,YAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;mBAkBlB,kBAAA,CAAA,WAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAEA,WAAA,GAAc,SAAA,QAAiB,iBAAA"}
1
+ {"version":3,"file":"transactions.d.ts","names":[],"sources":["../../../../src/interface/crud/transactions.ts"],"mappings":";;;;;cAwFa,sBAAA,QAAsB,WAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAMxB,kBAAA,CAAA,WAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAEC,gBAAA,GAAmB,SAAA,QAAiB,sBAAA;AAAA,cAEnC,iBAAA;AAAA,KAUD,eAAA,WAA0B,iBAAA;AAAA,cAEzB,iBAAA,QAAiB,YAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;mBAkBlB,kBAAA,CAAA,WAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAEA,WAAA,GAAc,SAAA,QAAiB,iBAAA"}
@@ -163,12 +163,12 @@ declare const usersCrudServerReadSchema: yup$1.ObjectSchema<{
163
163
  requires_totp_mfa: undefined;
164
164
  }, "">;
165
165
  declare const usersCrudServerCreateSchema: yup$1.ObjectSchema<{
166
+ password: string | null | undefined;
166
167
  country_code: string | null | undefined;
167
168
  display_name: string | null | undefined;
168
169
  primary_email: string | null | undefined;
169
170
  profile_image_url: string | null | undefined;
170
171
  is_anonymous: boolean | undefined;
171
- password: string | null | undefined;
172
172
  client_metadata: {} | null | undefined;
173
173
  client_read_only_metadata: {} | null | undefined;
174
174
  server_metadata: {} | null | undefined;
@@ -369,12 +369,12 @@ declare const usersCrud: ______crud0.CrudSchemaFromOptions<{
369
369
  };
370
370
  }, "">;
371
371
  serverCreateSchema: yup$1.ObjectSchema<{
372
+ password: string | null | undefined;
372
373
  country_code: string | null | undefined;
373
374
  display_name: string | null | undefined;
374
375
  primary_email: string | null | undefined;
375
376
  profile_image_url: string | null | undefined;
376
377
  is_anonymous: boolean | undefined;
377
- password: string | null | undefined;
378
378
  client_metadata: {} | null | undefined;
379
379
  client_read_only_metadata: {} | null | undefined;
380
380
  server_metadata: {} | null | undefined;
@@ -98,7 +98,7 @@ declare const KnownErrors: {
98
98
  };
99
99
  AccessTypeWithoutProjectId: KnownErrorConstructor<KnownError & KnownErrorBrand<"PROJECT_AUTHENTICATION_ERROR"> & {
100
100
  constructorArgs: [statusCode: number, humanReadableMessage: string, details?: Json | undefined];
101
- } & KnownErrorBrand<"INVALID_PROJECT_AUTHENTICATION"> & KnownErrorBrand<"ACCESS_TYPE_WITHOUT_PROJECT_ID">, [accessType: "client" | "server" | "admin"]> & {
101
+ } & KnownErrorBrand<"INVALID_PROJECT_AUTHENTICATION"> & KnownErrorBrand<"ACCESS_TYPE_WITHOUT_PROJECT_ID">, [accessType: "server" | "admin" | "client"]> & {
102
102
  errorCode: "ACCESS_TYPE_WITHOUT_PROJECT_ID";
103
103
  };
104
104
  AccessTypeRequired: KnownErrorConstructor<KnownError & KnownErrorBrand<"PROJECT_AUTHENTICATION_ERROR"> & {
@@ -111,7 +111,7 @@ declare const KnownErrors: {
111
111
  };
112
112
  InsufficientAccessType: KnownErrorConstructor<KnownError & KnownErrorBrand<"PROJECT_AUTHENTICATION_ERROR"> & {
113
113
  constructorArgs: [statusCode: number, humanReadableMessage: string, details?: Json | undefined];
114
- } & KnownErrorBrand<"INVALID_PROJECT_AUTHENTICATION"> & KnownErrorBrand<"INSUFFICIENT_ACCESS_TYPE">, [actualAccessType: "client" | "server" | "admin", allowedAccessTypes: ("client" | "server" | "admin")[]]> & {
114
+ } & KnownErrorBrand<"INVALID_PROJECT_AUTHENTICATION"> & KnownErrorBrand<"INSUFFICIENT_ACCESS_TYPE">, [actualAccessType: "server" | "admin" | "client", allowedAccessTypes: ("server" | "admin" | "client")[]]> & {
115
115
  errorCode: "INSUFFICIENT_ACCESS_TYPE";
116
116
  };
117
117
  InvalidPublishableClientKey: KnownErrorConstructor<KnownError & KnownErrorBrand<"PROJECT_AUTHENTICATION_ERROR"> & {
@@ -369,7 +369,7 @@ declare const KnownErrors: {
369
369
  PermissionNotFound: KnownErrorConstructor<KnownError & KnownErrorBrand<"PERMISSION_NOT_FOUND">, [permissionId: string]> & {
370
370
  errorCode: "PERMISSION_NOT_FOUND";
371
371
  };
372
- PermissionScopeMismatch: KnownErrorConstructor<KnownError & KnownErrorBrand<"WRONG_PERMISSION_SCOPE">, [permissionId: string, expectedScope: "team" | "project", actualScope: "team" | "project" | null]> & {
372
+ PermissionScopeMismatch: KnownErrorConstructor<KnownError & KnownErrorBrand<"WRONG_PERMISSION_SCOPE">, [permissionId: string, expectedScope: "project" | "team", actualScope: "project" | "team" | null]> & {
373
373
  errorCode: "WRONG_PERMISSION_SCOPE";
374
374
  };
375
375
  ContainedPermissionNotFound: KnownErrorConstructor<KnownError & KnownErrorBrand<"CONTAINED_PERMISSION_NOT_FOUND">, [permissionId: string]> & {
@@ -512,7 +512,7 @@ declare const KnownErrors: {
512
512
  ItemNotFound: KnownErrorConstructor<KnownError & KnownErrorBrand<"ITEM_NOT_FOUND">, [itemId: string]> & {
513
513
  errorCode: "ITEM_NOT_FOUND";
514
514
  };
515
- ItemCustomerTypeDoesNotMatch: KnownErrorConstructor<KnownError & KnownErrorBrand<"ITEM_CUSTOMER_TYPE_DOES_NOT_MATCH">, [itemId: string, customerId: string, itemCustomerType: "team" | "user" | "custom" | undefined, actualCustomerType: "team" | "user" | "custom"]> & {
515
+ ItemCustomerTypeDoesNotMatch: KnownErrorConstructor<KnownError & KnownErrorBrand<"ITEM_CUSTOMER_TYPE_DOES_NOT_MATCH">, [itemId: string, customerId: string, itemCustomerType: "user" | "team" | "custom" | undefined, actualCustomerType: "user" | "team" | "custom"]> & {
516
516
  errorCode: "ITEM_CUSTOMER_TYPE_DOES_NOT_MATCH";
517
517
  };
518
518
  CustomerDoesNotExist: KnownErrorConstructor<KnownError & KnownErrorBrand<"CUSTOMER_DOES_NOT_EXIST">, [customerId: string]> & {
@@ -521,7 +521,7 @@ declare const KnownErrors: {
521
521
  ProductDoesNotExist: KnownErrorConstructor<KnownError & KnownErrorBrand<"PRODUCT_DOES_NOT_EXIST">, [productId: string, context: "item_exists" | "server_only" | null]> & {
522
522
  errorCode: "PRODUCT_DOES_NOT_EXIST";
523
523
  };
524
- ProductCustomerTypeDoesNotMatch: KnownErrorConstructor<KnownError & KnownErrorBrand<"PRODUCT_CUSTOMER_TYPE_DOES_NOT_MATCH">, [productId: string | undefined, customerId: string, productCustomerType: "team" | "user" | "custom" | undefined, actualCustomerType: "team" | "user" | "custom"]> & {
524
+ ProductCustomerTypeDoesNotMatch: KnownErrorConstructor<KnownError & KnownErrorBrand<"PRODUCT_CUSTOMER_TYPE_DOES_NOT_MATCH">, [productId: string | undefined, customerId: string, productCustomerType: "user" | "team" | "custom" | undefined, actualCustomerType: "user" | "team" | "custom"]> & {
525
525
  errorCode: "PRODUCT_CUSTOMER_TYPE_DOES_NOT_MATCH";
526
526
  };
527
527
  ProductAlreadyGranted: KnownErrorConstructor<KnownError & KnownErrorBrand<"PRODUCT_ALREADY_GRANTED">, [productId: string, customerId: string]> & {
@@ -548,7 +548,7 @@ declare const KnownErrors: {
548
548
  StripeAccountInfoNotFound: KnownErrorConstructor<KnownError & KnownErrorBrand<"STRIPE_ACCOUNT_INFO_NOT_FOUND">, []> & {
549
549
  errorCode: "STRIPE_ACCOUNT_INFO_NOT_FOUND";
550
550
  };
551
- DefaultPaymentMethodRequired: KnownErrorConstructor<KnownError & KnownErrorBrand<"DEFAULT_PAYMENT_METHOD_REQUIRED">, [customerType: "team" | "user", customerId: string]> & {
551
+ DefaultPaymentMethodRequired: KnownErrorConstructor<KnownError & KnownErrorBrand<"DEFAULT_PAYMENT_METHOD_REQUIRED">, [customerType: "user" | "team", customerId: string]> & {
552
552
  errorCode: "DEFAULT_PAYMENT_METHOD_REQUIRED";
553
553
  };
554
554
  NewPurchasesBlocked: KnownErrorConstructor<KnownError & KnownErrorBrand<"NEW_PURCHASES_BLOCKED">, []> & {
@@ -113,7 +113,7 @@ declare const moneyAmountSchema: (currency: Currency) => yup$1.StringSchema<stri
113
113
  */
114
114
  declare const strictEmailSchema: (message: string | undefined) => yup$1.StringSchema<string | undefined, yup$1.AnyObject, undefined, "">;
115
115
  declare const emailSchema: yup$1.StringSchema<string | undefined, yup$1.AnyObject, undefined, "">;
116
- declare const clientOrHigherAuthTypeSchema: yup$1.StringSchema<"client" | "server" | "admin", yup$1.AnyObject, undefined, "">;
116
+ declare const clientOrHigherAuthTypeSchema: yup$1.StringSchema<"server" | "admin" | "client", yup$1.AnyObject, undefined, "">;
117
117
  declare const serverOrHigherAuthTypeSchema: yup$1.StringSchema<"server" | "admin", yup$1.AnyObject, undefined, "">;
118
118
  declare const adminAuthTypeSchema: yup$1.StringSchema<"admin", yup$1.AnyObject, undefined, "">;
119
119
  declare const projectIdSchema: yup$1.StringSchema<string | undefined, yup$1.AnyObject, undefined, "">;
@@ -174,7 +174,7 @@ declare const customDashboardsSchema: yup$1.MixedSchema<Record<string, {
174
174
  displayName: string;
175
175
  tsxSource: string;
176
176
  }>, yup$1.AnyObject, undefined, "">;
177
- declare const customerTypeSchema: yup$1.StringSchema<"team" | "user" | "custom" | undefined, yup$1.AnyObject, undefined, "">;
177
+ declare const customerTypeSchema: yup$1.StringSchema<"user" | "team" | "custom" | undefined, yup$1.AnyObject, undefined, "">;
178
178
  /**
179
179
  * Schema for a single product price. Each currency field (USD, EUR, etc.) is a decimal string
180
180
  * like `"9.99"` or `"1000"` — never cent integers. See `MoneyAmount` for the exact format.
@@ -218,7 +218,7 @@ declare const productSchema: yup$1.ObjectSchema<{
218
218
  displayName: string | undefined;
219
219
  productLineId: string | undefined;
220
220
  isAddOnTo: false | Record<string, true> | undefined;
221
- customerType: "team" | "user" | "custom";
221
+ customerType: "user" | "team" | "custom";
222
222
  freeTrial: DayInterval | undefined;
223
223
  serverOnly: boolean | undefined;
224
224
  stackable: boolean | undefined;
@@ -257,7 +257,7 @@ declare const productSchemaWithMetadata: yup$1.ObjectSchema<{
257
257
  displayName: string | undefined;
258
258
  productLineId: string | undefined;
259
259
  isAddOnTo: false | Record<string, true> | undefined;
260
- customerType: "team" | "user" | "custom";
260
+ customerType: "user" | "team" | "custom";
261
261
  freeTrial: DayInterval | undefined;
262
262
  serverOnly: boolean | undefined;
263
263
  stackable: boolean | undefined;
@@ -298,7 +298,7 @@ declare const productSchemaWithMetadata: yup$1.ObjectSchema<{
298
298
  }, "">;
299
299
  declare const inlineProductSchema: yup$1.ObjectSchema<{
300
300
  display_name: string;
301
- customer_type: "team" | "user" | "custom";
301
+ customer_type: "user" | "team" | "custom";
302
302
  free_trial: DayInterval | undefined;
303
303
  server_only: boolean;
304
304
  stackable: boolean;
@@ -314,8 +314,8 @@ declare const inlineProductSchema: yup$1.ObjectSchema<{
314
314
  free_trial?: DayInterval | undefined;
315
315
  }>;
316
316
  included_items: Record<string, {
317
- quantity?: number | undefined;
318
317
  repeat?: "never" | DayInterval | undefined;
318
+ quantity?: number | undefined;
319
319
  expires?: "never" | "when-purchase-expires" | "when-repeated" | undefined;
320
320
  }>;
321
321
  client_metadata: {} | null | undefined;
@@ -469,8 +469,8 @@ declare function yupDefinedWhen<S extends yup$1.AnyObject>(schema: S, triggers:
469
469
  declare function yupDefinedAndNonEmptyWhen<S extends yup$1.StringSchema>(schema: S, triggers: Record<string, any>): S;
470
470
  declare const branchConfigSourceSchema: yup$1.MixedSchema<{
471
471
  workflow_path?: string | undefined;
472
- type: "pushed-from-github";
473
472
  branch: string;
473
+ type: "pushed-from-github";
474
474
  owner: string;
475
475
  repo: string;
476
476
  commit_hash: string;
@@ -9,8 +9,8 @@ declare class AccessToken {
9
9
  private constructor();
10
10
  get payload(): {
11
11
  exp?: number | undefined;
12
- name: string | null;
13
12
  sub: string;
13
+ name: string | null;
14
14
  iat: number;
15
15
  iss: string;
16
16
  aud: string;
@@ -292,16 +292,16 @@ declare const MetricsAnalyticsOverviewSchema: yup.ObjectSchema<{
292
292
  activity: number;
293
293
  }[];
294
294
  top_browsers: {
295
- visitors: number;
296
295
  name: string;
296
+ visitors: number;
297
297
  }[];
298
298
  top_operating_systems: {
299
- visitors: number;
300
299
  name: string;
300
+ visitors: number;
301
301
  }[];
302
302
  top_devices: {
303
- visitors: number;
304
303
  name: string;
304
+ visitors: number;
305
305
  }[];
306
306
  conversion_rate: number | undefined;
307
307
  deltas: {} | undefined;
@@ -398,8 +398,8 @@ declare const AnalyticsClickmapResponseBodySchema: yup.ObjectSchema<{
398
398
  sampling: number;
399
399
  routes: {
400
400
  path: string;
401
- clicks: number;
402
401
  users: number;
402
+ clicks: number;
403
403
  replays: number;
404
404
  }[];
405
405
  users: {
@@ -652,16 +652,16 @@ declare const MetricsResponseBodySchema: yup.ObjectSchema<{
652
652
  activity: number;
653
653
  }[];
654
654
  top_browsers: {
655
- visitors: number;
656
655
  name: string;
656
+ visitors: number;
657
657
  }[];
658
658
  top_operating_systems: {
659
- visitors: number;
660
659
  name: string;
660
+ visitors: number;
661
661
  }[];
662
662
  top_devices: {
663
- visitors: number;
664
663
  name: string;
664
+ visitors: number;
665
665
  }[];
666
666
  };
667
667
  }, yup.AnyObject, {
@@ -56,9 +56,9 @@ declare const conversationSummarySchema: yup$1.ObjectSchema<{
56
56
  preview: string | null;
57
57
  lastActivityAt: string;
58
58
  metadata: {
59
- tags: string[];
60
59
  assignedToUserId: string | null;
61
60
  assignedToDisplayName: string | null;
61
+ tags: string[];
62
62
  firstResponseDueAt: string | null;
63
63
  firstResponseAt: string | null;
64
64
  nextResponseDueAt: string | null;
@@ -139,8 +139,8 @@ declare const conversationMessageSchema: yup$1.ObjectSchema<{
139
139
  createdAt: string;
140
140
  sender: {
141
141
  type: "user" | "agent" | "system";
142
- id: string | null;
143
142
  displayName: string | null;
143
+ id: string | null;
144
144
  primaryEmail: string | null;
145
145
  };
146
146
  }, yup$1.AnyObject, {
@@ -173,29 +173,29 @@ declare const conversationListResponseSchema: yup$1.ObjectSchema<{
173
173
  lastOutboundAt?: string | null | undefined;
174
174
  closedAt?: string | null | undefined;
175
175
  recordMetadata?: {} | null | undefined;
176
+ priority: "low" | "normal" | "high" | "urgent";
176
177
  status: "open" | "pending" | "closed";
177
178
  subject: string;
178
- priority: "low" | "normal" | "high" | "urgent";
179
- metadata: {
180
- tags: string[];
181
- assignedToUserId: string | null;
182
- assignedToDisplayName: string | null;
183
- firstResponseDueAt: string | null;
184
- firstResponseAt: string | null;
185
- nextResponseDueAt: string | null;
186
- lastCustomerReplyAt: string | null;
187
- lastAgentReplyAt: string | null;
188
- };
189
- source: "email" | "manual" | "chat" | "api";
190
179
  conversationId: string;
191
180
  userId: string | null;
192
181
  teamId: string | null;
193
182
  userDisplayName: string | null;
194
183
  userPrimaryEmail: string | null;
195
184
  userProfileImageUrl: string | null;
185
+ source: "email" | "manual" | "chat" | "api";
196
186
  lastMessageType: "message" | "internal-note" | "status-change";
197
187
  preview: string | null;
198
188
  lastActivityAt: string;
189
+ metadata: {
190
+ assignedToUserId: string | null;
191
+ assignedToDisplayName: string | null;
192
+ tags: string[];
193
+ firstResponseDueAt: string | null;
194
+ firstResponseAt: string | null;
195
+ nextResponseDueAt: string | null;
196
+ lastCustomerReplyAt: string | null;
197
+ lastAgentReplyAt: string | null;
198
+ };
199
199
  }[];
200
200
  hasMore: boolean;
201
201
  }, yup$1.AnyObject, {
@@ -211,48 +211,48 @@ declare const conversationDetailResponseSchema: yup$1.ObjectSchema<{
211
211
  lastOutboundAt?: string | null | undefined;
212
212
  closedAt?: string | null | undefined;
213
213
  recordMetadata?: {} | null | undefined;
214
+ priority: "low" | "normal" | "high" | "urgent";
214
215
  status: "open" | "pending" | "closed";
215
216
  subject: string;
216
- priority: "low" | "normal" | "high" | "urgent";
217
- metadata: {
218
- tags: string[];
219
- assignedToUserId: string | null;
220
- assignedToDisplayName: string | null;
221
- firstResponseDueAt: string | null;
222
- firstResponseAt: string | null;
223
- nextResponseDueAt: string | null;
224
- lastCustomerReplyAt: string | null;
225
- lastAgentReplyAt: string | null;
226
- };
227
- source: "email" | "manual" | "chat" | "api";
228
217
  conversationId: string;
229
218
  userId: string | null;
230
219
  teamId: string | null;
231
220
  userDisplayName: string | null;
232
221
  userPrimaryEmail: string | null;
233
222
  userProfileImageUrl: string | null;
223
+ source: "email" | "manual" | "chat" | "api";
234
224
  lastMessageType: "message" | "internal-note" | "status-change";
235
225
  preview: string | null;
236
226
  lastActivityAt: string;
227
+ metadata: {
228
+ assignedToUserId: string | null;
229
+ assignedToDisplayName: string | null;
230
+ tags: string[];
231
+ firstResponseDueAt: string | null;
232
+ firstResponseAt: string | null;
233
+ nextResponseDueAt: string | null;
234
+ lastCustomerReplyAt: string | null;
235
+ lastAgentReplyAt: string | null;
236
+ };
237
237
  };
238
238
  messages: {
239
+ priority: "low" | "normal" | "high" | "urgent";
239
240
  id: string;
240
241
  status: "open" | "pending" | "closed";
241
242
  subject: string;
242
- priority: "low" | "normal" | "high" | "urgent";
243
- metadata: {} | null;
244
- body: string | null;
245
- source: "email" | "manual" | "chat" | "api";
246
243
  conversationId: string;
247
244
  userId: string | null;
248
245
  teamId: string | null;
246
+ source: "email" | "manual" | "chat" | "api";
247
+ metadata: {} | null;
249
248
  createdAt: string;
250
249
  messageType: "message" | "internal-note" | "status-change";
250
+ body: string | null;
251
251
  attachments: {}[];
252
252
  sender: {
253
253
  type: "user" | "agent" | "system";
254
- id: string | null;
255
254
  displayName: string | null;
255
+ id: string | null;
256
256
  primaryEmail: string | null;
257
257
  };
258
258
  }[];