@hexclave/shared 1.0.22 → 1.0.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (85) hide show
  1. package/dist/ai/unified-prompts/reminders.js +2 -1
  2. package/dist/ai/unified-prompts/reminders.js.map +1 -1
  3. package/dist/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.d.ts.map +1 -1
  4. package/dist/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.js +15 -0
  5. package/dist/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.js.map +1 -1
  6. package/dist/ai/unified-prompts/skill-site-prompt-parts/docs-json.generated.d.ts +1 -46
  7. package/dist/ai/unified-prompts/skill-site-prompt-parts/docs-json.generated.js +1 -62
  8. package/dist/ai/unified-prompts/skill-site-prompt-parts/docs-json.generated.js.map +1 -1
  9. package/dist/config/schema.d.ts +80 -80
  10. package/dist/esm/ai/unified-prompts/reminders.js +2 -1
  11. package/dist/esm/ai/unified-prompts/reminders.js.map +1 -1
  12. package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.d.ts.map +1 -1
  13. package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.js +15 -0
  14. package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.js.map +1 -1
  15. package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/docs-json.generated.d.ts +1 -46
  16. package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/docs-json.generated.js +1 -62
  17. package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/docs-json.generated.js.map +1 -1
  18. package/dist/esm/config/schema.d.ts +80 -80
  19. package/dist/esm/interface/admin-interface.js +1 -1
  20. package/dist/esm/interface/admin-metrics.d.ts +13 -13
  21. package/dist/esm/interface/client-interface.js +1 -1
  22. package/dist/esm/interface/conversations.d.ts +35 -35
  23. package/dist/esm/interface/crud/current-user.d.ts +10 -10
  24. package/dist/esm/interface/crud/email-outbox.d.ts +116 -116
  25. package/dist/esm/interface/crud/invoices.d.ts +2 -2
  26. package/dist/esm/interface/crud/products.d.ts +15 -15
  27. package/dist/esm/interface/crud/products.d.ts.map +1 -1
  28. package/dist/esm/interface/crud/project-api-keys.d.ts +2 -2
  29. package/dist/esm/interface/crud/projects.d.ts +36 -36
  30. package/dist/esm/interface/crud/team-member-profiles.d.ts +36 -36
  31. package/dist/esm/interface/crud/transactions.d.ts +21 -21
  32. package/dist/esm/interface/crud/transactions.d.ts.map +1 -1
  33. package/dist/esm/interface/crud/users.d.ts +18 -18
  34. package/dist/esm/interface/server-interface.js +1 -1
  35. package/dist/esm/interface/webhooks.d.ts +2 -2
  36. package/dist/esm/known-errors.d.ts +5 -5
  37. package/dist/esm/schema-fields.d.ts +5 -5
  38. package/dist/esm/sessions.d.ts +7 -7
  39. package/dist/esm/utils/env.d.ts +2 -1
  40. package/dist/esm/utils/env.d.ts.map +1 -1
  41. package/dist/esm/utils/env.js +29 -17
  42. package/dist/esm/utils/env.js.map +1 -1
  43. package/dist/esm/utils/env.test.d.ts +1 -0
  44. package/dist/esm/utils/env.test.js +49 -0
  45. package/dist/esm/utils/env.test.js.map +1 -0
  46. package/dist/esm/utils/errors.d.ts.map +1 -1
  47. package/dist/esm/utils/errors.js +4 -1
  48. package/dist/esm/utils/errors.js.map +1 -1
  49. package/dist/interface/admin-interface.js +1 -1
  50. package/dist/interface/admin-metrics.d.ts +13 -13
  51. package/dist/interface/client-interface.js +1 -1
  52. package/dist/interface/conversations.d.ts +35 -35
  53. package/dist/interface/crud/current-user.d.ts +10 -10
  54. package/dist/interface/crud/email-outbox.d.ts +116 -116
  55. package/dist/interface/crud/invoices.d.ts +2 -2
  56. package/dist/interface/crud/products.d.ts +15 -15
  57. package/dist/interface/crud/products.d.ts.map +1 -1
  58. package/dist/interface/crud/project-api-keys.d.ts +2 -2
  59. package/dist/interface/crud/projects.d.ts +36 -36
  60. package/dist/interface/crud/team-member-profiles.d.ts +36 -36
  61. package/dist/interface/crud/transactions.d.ts +21 -21
  62. package/dist/interface/crud/transactions.d.ts.map +1 -1
  63. package/dist/interface/crud/users.d.ts +18 -18
  64. package/dist/interface/server-interface.js +1 -1
  65. package/dist/interface/webhooks.d.ts +2 -2
  66. package/dist/known-errors.d.ts +5 -5
  67. package/dist/schema-fields.d.ts +5 -5
  68. package/dist/sessions.d.ts +7 -7
  69. package/dist/utils/env.d.ts +2 -1
  70. package/dist/utils/env.d.ts.map +1 -1
  71. package/dist/utils/env.js +29 -16
  72. package/dist/utils/env.js.map +1 -1
  73. package/dist/utils/env.test.d.ts +1 -0
  74. package/dist/utils/env.test.js +49 -0
  75. package/dist/utils/env.test.js.map +1 -0
  76. package/dist/utils/errors.d.ts.map +1 -1
  77. package/dist/utils/errors.js +4 -1
  78. package/dist/utils/errors.js.map +1 -1
  79. package/package.json +1 -1
  80. package/src/ai/unified-prompts/reminders.ts +1 -0
  81. package/src/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.ts +15 -0
  82. package/src/ai/unified-prompts/skill-site-prompt-parts/docs-json.generated.ts +1 -62
  83. package/src/utils/env.test.tsx +58 -0
  84. package/src/utils/env.tsx +36 -20
  85. package/src/utils/errors.tsx +6 -1
@@ -36,7 +36,7 @@ declare const branchPaymentsSchema: yup$1.ObjectSchema<{
36
36
  } | undefined;
37
37
  productLines: Record<string, {
38
38
  displayName?: string | undefined;
39
- customerType?: "team" | "user" | "custom" | undefined;
39
+ customerType?: "user" | "team" | "custom" | undefined;
40
40
  }>;
41
41
  products: Record<string, {
42
42
  displayName?: string | undefined;
@@ -45,7 +45,7 @@ declare const branchPaymentsSchema: yup$1.ObjectSchema<{
45
45
  productLineId?: string | undefined;
46
46
  isAddOnTo?: false | Record<string, true> | undefined;
47
47
  stackable?: boolean | undefined;
48
- customerType: "team" | "user" | "custom";
48
+ customerType: "user" | "team" | "custom";
49
49
  prices: Record<string, {
50
50
  USD?: string | undefined;
51
51
  EUR?: string | undefined;
@@ -66,7 +66,7 @@ declare const branchPaymentsSchema: yup$1.ObjectSchema<{
66
66
  }>;
67
67
  items: Record<string, {
68
68
  displayName?: string | undefined;
69
- customerType?: "team" | "user" | "custom" | undefined;
69
+ customerType?: "user" | "team" | "custom" | undefined;
70
70
  }>;
71
71
  } | undefined, yup$1.AnyObject, {
72
72
  blockNewPurchases: undefined;
@@ -84,7 +84,7 @@ declare const branchConfigSchema: yup$1.Schema<Omit<Omit<{
84
84
  sourceOfTruth: {
85
85
  type: "hosted";
86
86
  };
87
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
87
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
88
88
  payments?: {
89
89
  blockNewPurchases?: boolean | undefined;
90
90
  autoPay?: {
@@ -92,11 +92,11 @@ declare const branchConfigSchema: yup$1.Schema<Omit<Omit<{
92
92
  } | undefined;
93
93
  items: Record<string, {
94
94
  displayName?: string | undefined;
95
- customerType?: "team" | "user" | "custom" | undefined;
95
+ customerType?: "user" | "team" | "custom" | undefined;
96
96
  }>;
97
97
  productLines: Record<string, {
98
98
  displayName?: string | undefined;
99
- customerType?: "team" | "user" | "custom" | undefined;
99
+ customerType?: "user" | "team" | "custom" | undefined;
100
100
  }>;
101
101
  products: Record<string, {
102
102
  displayName?: string | undefined;
@@ -105,7 +105,7 @@ declare const branchConfigSchema: yup$1.Schema<Omit<Omit<{
105
105
  productLineId?: string | undefined;
106
106
  isAddOnTo?: false | Record<string, true> | undefined;
107
107
  stackable?: boolean | undefined;
108
- customerType: "team" | "user" | "custom";
108
+ customerType: "user" | "team" | "custom";
109
109
  prices: Record<string, {
110
110
  USD?: string | undefined;
111
111
  EUR?: string | undefined;
@@ -134,9 +134,6 @@ declare const branchConfigSchema: yup$1.Schema<Omit<Omit<{
134
134
  otp: {
135
135
  allowSignIn?: boolean | undefined;
136
136
  };
137
- passkey: {
138
- allowSignIn?: boolean | undefined;
139
- };
140
137
  oauth: {
141
138
  accountMergeStrategy?: "link_method" | "raise_error" | "allow_duplicates" | undefined;
142
139
  providers: Record<string, {
@@ -145,10 +142,13 @@ declare const branchConfigSchema: yup$1.Schema<Omit<Omit<{
145
142
  allowConnectedAccounts?: boolean | undefined;
146
143
  }>;
147
144
  };
145
+ passkey: {
146
+ allowSignIn?: boolean | undefined;
147
+ };
148
148
  signUpRules: Record<string, {
149
149
  displayName?: string | undefined;
150
- priority?: number | undefined;
151
150
  enabled?: boolean | undefined;
151
+ priority?: number | undefined;
152
152
  condition?: string | undefined;
153
153
  action: {
154
154
  message?: string | undefined;
@@ -166,7 +166,7 @@ declare const branchConfigSchema: yup$1.Schema<Omit<Omit<{
166
166
  rbac: {
167
167
  permissions: Record<string, {
168
168
  description?: string | undefined;
169
- scope?: "team" | "project" | undefined;
169
+ scope?: "project" | "team" | undefined;
170
170
  containedPermissionIds?: Record<string, true | undefined> | undefined;
171
171
  } | undefined>;
172
172
  defaultPermissions: {
@@ -190,10 +190,11 @@ declare const branchConfigSchema: yup$1.Schema<Omit<Omit<{
190
190
  users: {
191
191
  allowClientUserDeletion?: boolean | undefined;
192
192
  };
193
+ domains: {};
193
194
  apiKeys: {
194
195
  enabled: {
195
- team?: boolean | undefined;
196
196
  user?: boolean | undefined;
197
+ team?: boolean | undefined;
197
198
  };
198
199
  };
199
200
  apps: {
@@ -201,7 +202,6 @@ declare const branchConfigSchema: yup$1.Schema<Omit<Omit<{
201
202
  enabled?: boolean | undefined;
202
203
  }>;
203
204
  };
204
- domains: {};
205
205
  dbSync: {
206
206
  externalDatabases: Record<string, {
207
207
  connectionString?: string | undefined;
@@ -218,7 +218,7 @@ declare const branchConfigSchema: yup$1.Schema<Omit<Omit<{
218
218
  project: {
219
219
  requirePublishableClientKey: undefined;
220
220
  };
221
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
221
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
222
222
  rbac: {
223
223
  permissions: undefined;
224
224
  defaultPermissions: {
@@ -293,7 +293,7 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
293
293
  sourceOfTruth: {
294
294
  type: "hosted";
295
295
  };
296
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
296
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
297
297
  payments?: {
298
298
  blockNewPurchases?: boolean | undefined;
299
299
  autoPay?: {
@@ -301,11 +301,11 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
301
301
  } | undefined;
302
302
  items: Record<string, {
303
303
  displayName?: string | undefined;
304
- customerType?: "team" | "user" | "custom" | undefined;
304
+ customerType?: "user" | "team" | "custom" | undefined;
305
305
  }>;
306
306
  productLines: Record<string, {
307
307
  displayName?: string | undefined;
308
- customerType?: "team" | "user" | "custom" | undefined;
308
+ customerType?: "user" | "team" | "custom" | undefined;
309
309
  }>;
310
310
  products: Record<string, {
311
311
  displayName?: string | undefined;
@@ -314,7 +314,7 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
314
314
  productLineId?: string | undefined;
315
315
  isAddOnTo?: false | Record<string, true> | undefined;
316
316
  stackable?: boolean | undefined;
317
- customerType: "team" | "user" | "custom";
317
+ customerType: "user" | "team" | "custom";
318
318
  prices: Record<string, {
319
319
  USD?: string | undefined;
320
320
  EUR?: string | undefined;
@@ -343,9 +343,6 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
343
343
  otp: {
344
344
  allowSignIn?: boolean | undefined;
345
345
  };
346
- passkey: {
347
- allowSignIn?: boolean | undefined;
348
- };
349
346
  oauth: {
350
347
  accountMergeStrategy?: "link_method" | "raise_error" | "allow_duplicates" | undefined;
351
348
  providers: Record<string, {
@@ -354,10 +351,13 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
354
351
  allowConnectedAccounts?: boolean | undefined;
355
352
  }>;
356
353
  };
354
+ passkey: {
355
+ allowSignIn?: boolean | undefined;
356
+ };
357
357
  signUpRules: Record<string, {
358
358
  displayName?: string | undefined;
359
- priority?: number | undefined;
360
359
  enabled?: boolean | undefined;
360
+ priority?: number | undefined;
361
361
  condition?: string | undefined;
362
362
  action: {
363
363
  message?: string | undefined;
@@ -375,7 +375,7 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
375
375
  rbac: {
376
376
  permissions: Record<string, {
377
377
  description?: string | undefined;
378
- scope?: "team" | "project" | undefined;
378
+ scope?: "project" | "team" | undefined;
379
379
  containedPermissionIds?: Record<string, true | undefined> | undefined;
380
380
  } | undefined>;
381
381
  defaultPermissions: {
@@ -399,10 +399,11 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
399
399
  users: {
400
400
  allowClientUserDeletion?: boolean | undefined;
401
401
  };
402
+ domains: {};
402
403
  apiKeys: {
403
404
  enabled: {
404
- team?: boolean | undefined;
405
405
  user?: boolean | undefined;
406
+ team?: boolean | undefined;
406
407
  };
407
408
  };
408
409
  apps: {
@@ -410,7 +411,6 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
410
411
  enabled?: boolean | undefined;
411
412
  }>;
412
413
  };
413
- domains: {};
414
414
  dbSync: {
415
415
  externalDatabases: Record<string, {
416
416
  connectionString?: string | undefined;
@@ -430,11 +430,11 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
430
430
  } | undefined;
431
431
  items: Record<string, {
432
432
  displayName?: string | undefined;
433
- customerType?: "team" | "user" | "custom" | undefined;
433
+ customerType?: "user" | "team" | "custom" | undefined;
434
434
  }>;
435
435
  productLines: Record<string, {
436
436
  displayName?: string | undefined;
437
- customerType?: "team" | "user" | "custom" | undefined;
437
+ customerType?: "user" | "team" | "custom" | undefined;
438
438
  }>;
439
439
  products: Record<string, {
440
440
  displayName?: string | undefined;
@@ -443,7 +443,7 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
443
443
  productLineId?: string | undefined;
444
444
  isAddOnTo?: false | Record<string, true> | undefined;
445
445
  stackable?: boolean | undefined;
446
- customerType: "team" | "user" | "custom";
446
+ customerType: "user" | "team" | "custom";
447
447
  prices: Record<string, {
448
448
  USD?: string | undefined;
449
449
  EUR?: string | undefined;
@@ -474,9 +474,6 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
474
474
  otp: {
475
475
  allowSignIn?: boolean | undefined;
476
476
  };
477
- passkey: {
478
- allowSignIn?: boolean | undefined;
479
- };
480
477
  oauth: {
481
478
  accountMergeStrategy?: "link_method" | "raise_error" | "allow_duplicates" | undefined;
482
479
  providers: Record<string, {
@@ -485,10 +482,13 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
485
482
  allowConnectedAccounts?: boolean | undefined;
486
483
  }>;
487
484
  };
485
+ passkey: {
486
+ allowSignIn?: boolean | undefined;
487
+ };
488
488
  signUpRules: Record<string, {
489
489
  displayName?: string | undefined;
490
- priority?: number | undefined;
491
490
  enabled?: boolean | undefined;
491
+ priority?: number | undefined;
492
492
  condition?: string | undefined;
493
493
  action: {
494
494
  message?: string | undefined;
@@ -549,10 +549,10 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
549
549
  server: {
550
550
  provider?: "resend" | "smtp" | "managed" | undefined;
551
551
  password?: string | undefined;
552
- isShared?: boolean | undefined;
553
552
  host?: string | undefined;
554
553
  port?: number | undefined;
555
554
  username?: string | undefined;
555
+ isShared?: boolean | undefined;
556
556
  senderName?: string | undefined;
557
557
  senderEmail?: string | undefined;
558
558
  managedSubdomain?: string | undefined;
@@ -575,7 +575,7 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
575
575
  project: {
576
576
  requirePublishableClientKey: undefined;
577
577
  };
578
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
578
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
579
579
  rbac: {
580
580
  permissions: undefined;
581
581
  defaultPermissions: {
@@ -648,7 +648,7 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
648
648
  project: {
649
649
  requirePublishableClientKey: undefined;
650
650
  };
651
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
651
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
652
652
  rbac: {
653
653
  permissions: undefined;
654
654
  defaultPermissions: {
@@ -721,7 +721,7 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
721
721
  project: {
722
722
  requirePublishableClientKey: undefined;
723
723
  };
724
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
724
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
725
725
  rbac: {
726
726
  permissions: undefined;
727
727
  defaultPermissions: {
@@ -797,7 +797,7 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
797
797
  project: {
798
798
  requirePublishableClientKey: undefined;
799
799
  };
800
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
800
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
801
801
  rbac: {
802
802
  permissions: undefined;
803
803
  defaultPermissions: {
@@ -883,7 +883,7 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
883
883
  project: {
884
884
  requirePublishableClientKey: undefined;
885
885
  };
886
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
886
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
887
887
  rbac: {
888
888
  permissions: undefined;
889
889
  defaultPermissions: {
@@ -959,7 +959,7 @@ declare const environmentConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<Omit<{
959
959
  project: {
960
960
  requirePublishableClientKey: undefined;
961
961
  };
962
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
962
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
963
963
  rbac: {
964
964
  permissions: undefined;
965
965
  defaultPermissions: {
@@ -1041,7 +1041,7 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1041
1041
  sourceOfTruth: {
1042
1042
  type: "hosted";
1043
1043
  };
1044
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
1044
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
1045
1045
  payments?: {
1046
1046
  blockNewPurchases?: boolean | undefined;
1047
1047
  autoPay?: {
@@ -1049,11 +1049,11 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1049
1049
  } | undefined;
1050
1050
  items: Record<string, {
1051
1051
  displayName?: string | undefined;
1052
- customerType?: "team" | "user" | "custom" | undefined;
1052
+ customerType?: "user" | "team" | "custom" | undefined;
1053
1053
  }>;
1054
1054
  productLines: Record<string, {
1055
1055
  displayName?: string | undefined;
1056
- customerType?: "team" | "user" | "custom" | undefined;
1056
+ customerType?: "user" | "team" | "custom" | undefined;
1057
1057
  }>;
1058
1058
  products: Record<string, {
1059
1059
  displayName?: string | undefined;
@@ -1062,7 +1062,7 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1062
1062
  productLineId?: string | undefined;
1063
1063
  isAddOnTo?: false | Record<string, true> | undefined;
1064
1064
  stackable?: boolean | undefined;
1065
- customerType: "team" | "user" | "custom";
1065
+ customerType: "user" | "team" | "custom";
1066
1066
  prices: Record<string, {
1067
1067
  USD?: string | undefined;
1068
1068
  EUR?: string | undefined;
@@ -1091,9 +1091,6 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1091
1091
  otp: {
1092
1092
  allowSignIn?: boolean | undefined;
1093
1093
  };
1094
- passkey: {
1095
- allowSignIn?: boolean | undefined;
1096
- };
1097
1094
  oauth: {
1098
1095
  accountMergeStrategy?: "link_method" | "raise_error" | "allow_duplicates" | undefined;
1099
1096
  providers: Record<string, {
@@ -1102,10 +1099,13 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1102
1099
  allowConnectedAccounts?: boolean | undefined;
1103
1100
  }>;
1104
1101
  };
1102
+ passkey: {
1103
+ allowSignIn?: boolean | undefined;
1104
+ };
1105
1105
  signUpRules: Record<string, {
1106
1106
  displayName?: string | undefined;
1107
- priority?: number | undefined;
1108
1107
  enabled?: boolean | undefined;
1108
+ priority?: number | undefined;
1109
1109
  condition?: string | undefined;
1110
1110
  action: {
1111
1111
  message?: string | undefined;
@@ -1123,7 +1123,7 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1123
1123
  rbac: {
1124
1124
  permissions: Record<string, {
1125
1125
  description?: string | undefined;
1126
- scope?: "team" | "project" | undefined;
1126
+ scope?: "project" | "team" | undefined;
1127
1127
  containedPermissionIds?: Record<string, true | undefined> | undefined;
1128
1128
  } | undefined>;
1129
1129
  defaultPermissions: {
@@ -1147,10 +1147,11 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1147
1147
  users: {
1148
1148
  allowClientUserDeletion?: boolean | undefined;
1149
1149
  };
1150
+ domains: {};
1150
1151
  apiKeys: {
1151
1152
  enabled: {
1152
- team?: boolean | undefined;
1153
1153
  user?: boolean | undefined;
1154
+ team?: boolean | undefined;
1154
1155
  };
1155
1156
  };
1156
1157
  apps: {
@@ -1158,7 +1159,6 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1158
1159
  enabled?: boolean | undefined;
1159
1160
  }>;
1160
1161
  };
1161
- domains: {};
1162
1162
  dbSync: {
1163
1163
  externalDatabases: Record<string, {
1164
1164
  connectionString?: string | undefined;
@@ -1178,11 +1178,11 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1178
1178
  } | undefined;
1179
1179
  items: Record<string, {
1180
1180
  displayName?: string | undefined;
1181
- customerType?: "team" | "user" | "custom" | undefined;
1181
+ customerType?: "user" | "team" | "custom" | undefined;
1182
1182
  }>;
1183
1183
  productLines: Record<string, {
1184
1184
  displayName?: string | undefined;
1185
- customerType?: "team" | "user" | "custom" | undefined;
1185
+ customerType?: "user" | "team" | "custom" | undefined;
1186
1186
  }>;
1187
1187
  products: Record<string, {
1188
1188
  displayName?: string | undefined;
@@ -1191,7 +1191,7 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1191
1191
  productLineId?: string | undefined;
1192
1192
  isAddOnTo?: false | Record<string, true> | undefined;
1193
1193
  stackable?: boolean | undefined;
1194
- customerType: "team" | "user" | "custom";
1194
+ customerType: "user" | "team" | "custom";
1195
1195
  prices: Record<string, {
1196
1196
  USD?: string | undefined;
1197
1197
  EUR?: string | undefined;
@@ -1222,9 +1222,6 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1222
1222
  otp: {
1223
1223
  allowSignIn?: boolean | undefined;
1224
1224
  };
1225
- passkey: {
1226
- allowSignIn?: boolean | undefined;
1227
- };
1228
1225
  oauth: {
1229
1226
  accountMergeStrategy?: "link_method" | "raise_error" | "allow_duplicates" | undefined;
1230
1227
  providers: Record<string, {
@@ -1233,10 +1230,13 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1233
1230
  allowConnectedAccounts?: boolean | undefined;
1234
1231
  }>;
1235
1232
  };
1233
+ passkey: {
1234
+ allowSignIn?: boolean | undefined;
1235
+ };
1236
1236
  signUpRules: Record<string, {
1237
1237
  displayName?: string | undefined;
1238
- priority?: number | undefined;
1239
1238
  enabled?: boolean | undefined;
1239
+ priority?: number | undefined;
1240
1240
  condition?: string | undefined;
1241
1241
  action: {
1242
1242
  message?: string | undefined;
@@ -1297,10 +1297,10 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1297
1297
  server: {
1298
1298
  provider?: "resend" | "smtp" | "managed" | undefined;
1299
1299
  password?: string | undefined;
1300
- isShared?: boolean | undefined;
1301
1300
  host?: string | undefined;
1302
1301
  port?: number | undefined;
1303
1302
  username?: string | undefined;
1303
+ isShared?: boolean | undefined;
1304
1304
  senderName?: string | undefined;
1305
1305
  senderEmail?: string | undefined;
1306
1306
  managedSubdomain?: string | undefined;
@@ -1323,7 +1323,7 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1323
1323
  project: {
1324
1324
  requirePublishableClientKey: undefined;
1325
1325
  };
1326
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
1326
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
1327
1327
  rbac: {
1328
1328
  permissions: undefined;
1329
1329
  defaultPermissions: {
@@ -1396,7 +1396,7 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1396
1396
  project: {
1397
1397
  requirePublishableClientKey: undefined;
1398
1398
  };
1399
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
1399
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
1400
1400
  rbac: {
1401
1401
  permissions: undefined;
1402
1402
  defaultPermissions: {
@@ -1469,7 +1469,7 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1469
1469
  project: {
1470
1470
  requirePublishableClientKey: undefined;
1471
1471
  };
1472
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
1472
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
1473
1473
  rbac: {
1474
1474
  permissions: undefined;
1475
1475
  defaultPermissions: {
@@ -1545,7 +1545,7 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1545
1545
  project: {
1546
1546
  requirePublishableClientKey: undefined;
1547
1547
  };
1548
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
1548
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
1549
1549
  rbac: {
1550
1550
  permissions: undefined;
1551
1551
  defaultPermissions: {
@@ -1631,7 +1631,7 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1631
1631
  project: {
1632
1632
  requirePublishableClientKey: undefined;
1633
1633
  };
1634
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
1634
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
1635
1635
  rbac: {
1636
1636
  permissions: undefined;
1637
1637
  defaultPermissions: {
@@ -1707,7 +1707,7 @@ declare const organizationConfigSchema: yup$1.Schema<Omit<NonNullable<Omit<NonNu
1707
1707
  project: {
1708
1708
  requirePublishableClientKey: undefined;
1709
1709
  };
1710
- }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "apiKeys" | "apps" | "domains" | "dbSync" | "dataVault"> & {
1710
+ }, string>, "auth" | "onboarding" | "teams" | "rbac" | "payments" | "emails" | "users" | "domains" | "apiKeys" | "apps" | "dbSync" | "dataVault"> & {
1711
1711
  rbac: {
1712
1712
  permissions: undefined;
1713
1713
  defaultPermissions: {
@@ -2073,15 +2073,14 @@ declare function sanitizeOrganizationConfig(config: OrganizationRenderedConfigBe
2073
2073
  };
2074
2074
  signUpRules: Record<string, {
2075
2075
  displayName: string | undefined;
2076
- priority: number;
2077
2076
  enabled: boolean;
2077
+ priority: number;
2078
2078
  condition: string | undefined;
2079
2079
  action: {
2080
- message: string | undefined;
2081
2080
  type: "allow" | "reject" | "restrict" | "log";
2081
+ message: string | undefined;
2082
2082
  };
2083
2083
  }>;
2084
- allowSignUp: boolean;
2085
2084
  password: {
2086
2085
  allowSignIn: boolean;
2087
2086
  };
@@ -2091,6 +2090,7 @@ declare function sanitizeOrganizationConfig(config: OrganizationRenderedConfigBe
2091
2090
  passkey: {
2092
2091
  allowSignIn: boolean;
2093
2092
  };
2093
+ allowSignUp: boolean;
2094
2094
  signUpRulesDefaultAction: string;
2095
2095
  };
2096
2096
  emails: {
@@ -2111,10 +2111,10 @@ declare function sanitizeOrganizationConfig(config: OrganizationRenderedConfigBe
2111
2111
  server: {
2112
2112
  provider: "resend" | "smtp" | "managed";
2113
2113
  password: string | undefined;
2114
- isShared: boolean;
2115
2114
  host: string | undefined;
2116
2115
  port: number | undefined;
2117
2116
  username: string | undefined;
2117
+ isShared: boolean;
2118
2118
  senderName: string | undefined;
2119
2119
  senderEmail: string | undefined;
2120
2120
  managedSubdomain: string | undefined;
@@ -2142,12 +2142,12 @@ declare function sanitizeOrganizationConfig(config: OrganizationRenderedConfigBe
2142
2142
  serverOnly: boolean;
2143
2143
  freeTrial: [number, "day" | "week" | "month" | "year"] | undefined;
2144
2144
  productLineId: string | undefined;
2145
- customerType: "team" | "user" | "custom";
2145
+ customerType: "user" | "team" | "custom";
2146
2146
  stackable: boolean | undefined;
2147
2147
  includedItems: {
2148
2148
  [x: string]: {
2149
- quantity: number;
2150
2149
  repeat: "never" | [number, "day" | "week" | "month" | "year"];
2150
+ quantity: number;
2151
2151
  expires: "never" | "when-purchase-expires" | "when-repeated";
2152
2152
  };
2153
2153
  };
@@ -2155,7 +2155,7 @@ declare function sanitizeOrganizationConfig(config: OrganizationRenderedConfigBe
2155
2155
  items: {
2156
2156
  [x: string]: {
2157
2157
  displayName: string;
2158
- customerType: "team" | "user" | "custom";
2158
+ customerType: "user" | "team" | "custom";
2159
2159
  };
2160
2160
  };
2161
2161
  blockNewPurchases: boolean;
@@ -2165,7 +2165,7 @@ declare function sanitizeOrganizationConfig(config: OrganizationRenderedConfigBe
2165
2165
  productLines: {
2166
2166
  [x: string]: {
2167
2167
  displayName: string | undefined;
2168
- customerType: "team" | "user" | "custom" | undefined;
2168
+ customerType: "user" | "team" | "custom" | undefined;
2169
2169
  };
2170
2170
  };
2171
2171
  testMode: boolean;
@@ -2209,7 +2209,7 @@ declare function sanitizeOrganizationConfig(config: OrganizationRenderedConfigBe
2209
2209
  permissions: {
2210
2210
  [x: string]: {
2211
2211
  description: string | undefined;
2212
- scope: "team" | "project" | undefined;
2212
+ scope: "project" | "team" | undefined;
2213
2213
  containedPermissionIds: {
2214
2214
  [x: string]: true | undefined;
2215
2215
  };
@@ -2230,12 +2230,6 @@ declare function sanitizeOrganizationConfig(config: OrganizationRenderedConfigBe
2230
2230
  users: {
2231
2231
  allowClientUserDeletion: boolean;
2232
2232
  };
2233
- apiKeys: {
2234
- enabled: {
2235
- team: boolean;
2236
- user: boolean;
2237
- };
2238
- };
2239
2233
  domains: {
2240
2234
  allowLocalhost: boolean;
2241
2235
  trustedDomains: {
@@ -2245,6 +2239,12 @@ declare function sanitizeOrganizationConfig(config: OrganizationRenderedConfigBe
2245
2239
  };
2246
2240
  };
2247
2241
  };
2242
+ apiKeys: {
2243
+ enabled: {
2244
+ user: boolean;
2245
+ team: boolean;
2246
+ };
2247
+ };
2248
2248
  dbSync: {
2249
2249
  externalDatabases: {
2250
2250
  [x: string]: {
@@ -1,5 +1,5 @@
1
- import { deindent } from "../../utils/strings.js";
2
1
  import { ALL_APPS } from "../../apps/apps-config.js";
2
+ import { deindent } from "../../utils/strings.js";
3
3
 
4
4
  //#region src/ai/unified-prompts/reminders.ts
5
5
  const remindersPrompt = deindent`
@@ -27,6 +27,7 @@ const remindersPrompt = deindent`
27
27
  - There is a \`useHexclaveApp()\` hook as a named export from the package itself that serves as a shortcut to get the current Hexclave App object from the React context. Similarly, the \`useUser(...args)\` named export is short for \`useHexclaveApp().useUser(...args)\`.
28
28
  - Other
29
29
  - Hexclave also has a REST API with near-full feature parity with the SDK. It can be used for both client and server-side code.
30
+ - If available, always prefer editing the \`hexclave.config.ts\` file directly over asking the user to make changes on the dashboard. When implementing new features, you can always update the config file, and then tell the user about the changes you've made.
30
31
  - Hexclave's config files allow dot notation for nested properties. For example, the config \`{ auth: { allowSignUp: true }, "auth.password": { allowSignIn: true } }\` is the same as \`{ auth: { allowSignUp: true, password: { allowSignIn: true } } }\`.
31
32
  - Hexclave was formerly known as Stack Auth. You may still see references to it as Stack Auth in some places.
32
33
  `;