@hexclave/shared 1.0.53 → 1.0.54
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.
- package/dist/{admin-interface-D9wMduWc.d.ts → admin-interface-DuboQXpC.d.ts} +11 -11
- package/dist/{admin-interface-D9wMduWc.d.ts.map → admin-interface-DuboQXpC.d.ts.map} +1 -1
- package/dist/{admin-metrics-bsOkw4YQ.d.ts → admin-metrics-IxLyJ-cP.d.ts} +18 -18
- package/dist/{admin-metrics-bsOkw4YQ.d.ts.map → admin-metrics-IxLyJ-cP.d.ts.map} +1 -1
- package/dist/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.js +4 -4
- package/dist/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.js.map +1 -1
- package/dist/{client-interface-BQz4jNAC.d.ts → client-interface-Ca6UZywk.d.ts} +9 -9
- package/dist/{client-interface-BQz4jNAC.d.ts.map → client-interface-Ca6UZywk.d.ts.map} +1 -1
- package/dist/config/schema.d.ts +1 -1
- package/dist/config-authoring.d.ts +1 -1
- package/dist/config-rendering.d.ts +9 -1
- package/dist/config-rendering.d.ts.map +1 -1
- package/dist/config-rendering.js +2 -2
- package/dist/config-rendering.js.map +1 -1
- package/dist/{current-user-BBoN3hsn.d.ts → current-user-DNxac4sS.d.ts} +15 -15
- package/dist/{current-user-BBoN3hsn.d.ts.map → current-user-DNxac4sS.d.ts.map} +1 -1
- package/dist/dates-BRAvSk6L.d.ts.map +1 -1
- package/dist/{email-outbox-B1wmVPRG.d.ts → email-outbox-ILs0LlGd.d.ts} +185 -185
- package/dist/{email-outbox-B1wmVPRG.d.ts.map → email-outbox-ILs0LlGd.d.ts.map} +1 -1
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.js +4 -4
- package/dist/esm/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.js.map +1 -1
- package/dist/esm/config/schema.d.ts +99 -99
- package/dist/esm/config-rendering.d.ts +9 -1
- package/dist/esm/config-rendering.d.ts.map +1 -1
- package/dist/esm/config-rendering.js +2 -3
- package/dist/esm/config-rendering.js.map +1 -1
- package/dist/esm/interface/admin-metrics.d.ts +17 -17
- package/dist/esm/interface/conversations.d.ts +10 -10
- package/dist/esm/interface/crud/current-user.d.ts +14 -14
- package/dist/esm/interface/crud/email-outbox.d.ts +184 -184
- package/dist/esm/interface/crud/products.d.ts +17 -17
- package/dist/esm/interface/crud/project-api-keys.d.ts +4 -4
- package/dist/esm/interface/crud/projects.d.ts +28 -28
- package/dist/esm/interface/crud/team-member-profiles.d.ts +24 -24
- package/dist/esm/interface/crud/transactions.d.ts +15 -15
- package/dist/esm/interface/crud/transactions.d.ts.map +1 -1
- package/dist/esm/interface/crud/users.d.ts +16 -16
- package/dist/esm/interface/plan-usage.d.ts +1 -1
- package/dist/esm/interface/webhooks.d.ts +2 -2
- package/dist/esm/known-errors.d.ts +3 -3
- package/dist/esm/package.json +18 -0
- package/dist/esm/schema-fields.d.ts +5 -5
- package/dist/esm/sessions.d.ts +8 -8
- package/dist/esm/utils/dates.d.ts.map +1 -1
- package/dist/esm/utils/dates.js +2 -1
- package/dist/esm/utils/dates.js.map +1 -1
- package/dist/helpers/password.d.ts +1 -1
- package/dist/helpers/production-mode.d.ts +1 -1
- package/dist/index.d.ts +4 -4
- package/dist/interface/admin-interface.d.ts +2 -2
- package/dist/interface/admin-metrics.d.ts +1 -1
- package/dist/interface/client-interface.d.ts +1 -1
- package/dist/interface/conversations.d.ts +10 -10
- package/dist/interface/crud/current-user.d.ts +1 -1
- package/dist/interface/crud/email-outbox.d.ts +1 -1
- package/dist/interface/crud/products.d.ts +1 -1
- package/dist/interface/crud/project-api-keys.d.ts +1 -1
- package/dist/interface/crud/projects.d.ts +1 -1
- package/dist/interface/crud/team-member-profiles.d.ts +1 -1
- package/dist/interface/crud/transactions.d.ts +1 -1
- package/dist/interface/crud/users.d.ts +1 -1
- package/dist/interface/plan-usage.d.ts +1 -1
- package/dist/interface/server-interface.d.ts +1 -1
- package/dist/interface/webhooks.d.ts +1 -1
- package/dist/{known-errors-Bm4a61wL.d.ts → known-errors-g7JC8z58.d.ts} +4 -4
- package/dist/{known-errors-Bm4a61wL.d.ts.map → known-errors-g7JC8z58.d.ts.map} +1 -1
- package/dist/known-errors.d.ts +1 -1
- package/dist/{plan-usage-BaDxcLZ1.d.ts → plan-usage-D0kWw4HR.d.ts} +2 -2
- package/dist/{plan-usage-BaDxcLZ1.d.ts.map → plan-usage-D0kWw4HR.d.ts.map} +1 -1
- package/dist/{products-D4o8A2W0.d.ts → products-C98fCS-1.d.ts} +18 -18
- package/dist/{products-D4o8A2W0.d.ts.map → products-C98fCS-1.d.ts.map} +1 -1
- package/dist/{project-api-keys--7V5X_UW.d.ts → project-api-keys-P97ElZZe.d.ts} +5 -5
- package/dist/{project-api-keys--7V5X_UW.d.ts.map → project-api-keys-P97ElZZe.d.ts.map} +1 -1
- package/dist/{projects-CFTNXRfG.d.ts → projects-BM2a4sfO.d.ts} +29 -29
- package/dist/{projects-CFTNXRfG.d.ts.map → projects-BM2a4sfO.d.ts.map} +1 -1
- package/dist/{schema-DV0SQUbY.d.ts → schema-Bq1TSMFV.d.ts} +100 -100
- package/dist/{schema-DV0SQUbY.d.ts.map → schema-Bq1TSMFV.d.ts.map} +1 -1
- package/dist/{schema-fields-DZtDQEEO.d.ts → schema-fields-Cch3V5nd.d.ts} +6 -6
- package/dist/{schema-fields-DZtDQEEO.d.ts.map → schema-fields-Cch3V5nd.d.ts.map} +1 -1
- package/dist/schema-fields.d.ts +1 -1
- package/dist/{server-interface-BjY-eS4Q.d.ts → server-interface-yKuDPrQI.d.ts} +8 -8
- package/dist/{server-interface-BjY-eS4Q.d.ts.map → server-interface-yKuDPrQI.d.ts.map} +1 -1
- package/dist/{sessions-CI-0TBQb.d.ts → sessions-DCTyJhi3.d.ts} +10 -10
- package/dist/{sessions-CI-0TBQb.d.ts.map → sessions-DCTyJhi3.d.ts.map} +1 -1
- package/dist/sessions.d.ts +1 -1
- package/dist/{team-member-profiles-BoDEqx-0.d.ts → team-member-profiles-CaD1OJqt.d.ts} +25 -25
- package/dist/{team-member-profiles-BoDEqx-0.d.ts.map → team-member-profiles-CaD1OJqt.d.ts.map} +1 -1
- package/dist/{transactions-CHNUJ42J.d.ts → transactions-CrAZLdGo.d.ts} +16 -16
- package/dist/transactions-CrAZLdGo.d.ts.map +1 -0
- package/dist/{users-DHNRwoSz.d.ts → users-DSpJgn9Z.d.ts} +18 -18
- package/dist/{users-DHNRwoSz.d.ts.map → users-DSpJgn9Z.d.ts.map} +1 -1
- package/dist/utils/dates.js +2 -1
- package/dist/utils/dates.js.map +1 -1
- package/dist/{webhooks-8Ts1Clcb.d.ts → webhooks-_aXIgZBW.d.ts} +3 -3
- package/dist/{webhooks-8Ts1Clcb.d.ts.map → webhooks-_aXIgZBW.d.ts.map} +1 -1
- package/package.json +1 -1
- package/src/ai/unified-prompts/skill-site-prompt-parts/ai-setup-prompt.ts +4 -4
- package/src/config-rendering.ts +5 -6
- package/src/utils/dates.tsx +22 -1
- package/dist/transactions-CHNUJ42J.d.ts.map +0 -1
|
@@ -1,4 +1,12 @@
|
|
|
1
1
|
//#region src/config-rendering.d.ts
|
|
2
|
+
/**
|
|
3
|
+
* Packages that export the `HexclaveConfig` type, in priority order.
|
|
4
|
+
* The first match found in a project's dependencies wins. Hexclave-branded
|
|
5
|
+
* packages come first (canonical); the legacy `@stackframe/*` names remain
|
|
6
|
+
* so projects pinned to the last legacy release still render a config file
|
|
7
|
+
* that compiles against their installed SDK.
|
|
8
|
+
*/
|
|
9
|
+
declare const CONFIG_IMPORT_PACKAGES: readonly ["@hexclave/next", "@hexclave/react", "@hexclave/tanstack-start", "@hexclave/js", "@hexclave/template", "@stackframe/stack", "@stackframe/react", "@stackframe/js", "@stackframe/template"];
|
|
2
10
|
/**
|
|
3
11
|
* Given a list of dependency names (from package.json), returns the SDK
|
|
4
12
|
* package that should be used for the `HexclaveConfig` import, or `undefined`
|
|
@@ -10,5 +18,5 @@ declare function detectConfigImportPackage(dependencies: string[]): string | und
|
|
|
10
18
|
*/
|
|
11
19
|
declare function renderConfigFileContent(config: unknown, importPackage?: string): string;
|
|
12
20
|
//#endregion
|
|
13
|
-
export { detectConfigImportPackage, renderConfigFileContent };
|
|
21
|
+
export { CONFIG_IMPORT_PACKAGES, detectConfigImportPackage, renderConfigFileContent };
|
|
14
22
|
//# sourceMappingURL=config-rendering.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config-rendering.d.ts","names":[],"sources":["../../src/config-rendering.ts"],"mappings":";;
|
|
1
|
+
{"version":3,"file":"config-rendering.d.ts","names":[],"sources":["../../src/config-rendering.ts"],"mappings":";;AAWA;;;;AAUU;AAOV;cAjBa,sBAAA;;;AAiBmD;AAYhE;;iBAZgB,yBAAA,CAA0B,YAAsB;;AAYe;;iBAA/D,uBAAA,CAAwB,MAAA,WAAiB,aAAsB"}
|
|
@@ -39,10 +39,9 @@ function renderConfigFileContent(config, importPackage) {
|
|
|
39
39
|
droppedKeys
|
|
40
40
|
});
|
|
41
41
|
if (droppedKeys.length > 0) throw new Error(`Config has conflicting keys that would be dropped during normalization: ${droppedKeys.map((k) => JSON.stringify(k)).join(", ")}`);
|
|
42
|
-
|
|
43
|
-
return `${`import type { HexclaveConfig } from "${pkg.startsWith("@hexclave/") ? `${pkg}/config` : pkg}";`}\n\nexport const config: HexclaveConfig = ${JSON.stringify(normalizedConfig, null, 2)};\n`;
|
|
42
|
+
return `${`import type { HexclaveConfig } from "${importPackage ?? DEFAULT_CONFIG_IMPORT_PACKAGE}";`}\n\nexport const config: HexclaveConfig = ${JSON.stringify(normalizedConfig, null, 2)};\n`;
|
|
44
43
|
}
|
|
45
44
|
//#endregion
|
|
46
|
-
export { detectConfigImportPackage, renderConfigFileContent };
|
|
45
|
+
export { CONFIG_IMPORT_PACKAGES, detectConfigImportPackage, renderConfigFileContent };
|
|
47
46
|
|
|
48
47
|
//# sourceMappingURL=config-rendering.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config-rendering.js","names":[],"sources":["../../src/config-rendering.ts"],"sourcesContent":["import { isValidConfig, normalize } from \"./config/format\";\n\nconst DEFAULT_CONFIG_IMPORT_PACKAGE = \"@hexclave/js\";\n\n/**\n * Packages that export the `HexclaveConfig` type, in priority order.\n * The first match found in a project's dependencies wins. Hexclave-branded\n * packages come first (canonical); the legacy `@stackframe/*` names remain\n * so projects pinned to the last legacy release still render a config file\n * that compiles against their installed SDK.\n */\
|
|
1
|
+
{"version":3,"file":"config-rendering.js","names":[],"sources":["../../src/config-rendering.ts"],"sourcesContent":["import { isValidConfig, normalize } from \"./config/format\";\n\nconst DEFAULT_CONFIG_IMPORT_PACKAGE = \"@hexclave/js\";\n\n/**\n * Packages that export the `HexclaveConfig` type, in priority order.\n * The first match found in a project's dependencies wins. Hexclave-branded\n * packages come first (canonical); the legacy `@stackframe/*` names remain\n * so projects pinned to the last legacy release still render a config file\n * that compiles against their installed SDK.\n */\nexport const CONFIG_IMPORT_PACKAGES = [\n \"@hexclave/next\",\n \"@hexclave/react\",\n \"@hexclave/tanstack-start\",\n \"@hexclave/js\",\n \"@hexclave/template\",\n \"@stackframe/stack\",\n \"@stackframe/react\",\n \"@stackframe/js\",\n \"@stackframe/template\",\n] as const;\n\n/**\n * Given a list of dependency names (from package.json), returns the SDK\n * package that should be used for the `HexclaveConfig` import, or `undefined`\n * if none of the known packages are installed.\n */\nexport function detectConfigImportPackage(dependencies: string[]): string | undefined {\n for (const pkg of CONFIG_IMPORT_PACKAGES) {\n if (dependencies.includes(pkg)) {\n return pkg;\n }\n }\n return undefined;\n}\n\n/**\n * Renders a config object into the source text of a `stack.config.ts` file.\n */\nexport function renderConfigFileContent(config: unknown, importPackage?: string): string {\n if (!isValidConfig(config)) {\n throw new Error(\"Invalid config: expected a plain object.\");\n }\n\n const droppedKeys: string[] = [];\n const normalizedConfig = normalize(config, {\n onDotIntoNonObject: \"ignore\",\n onDotIntoNull: \"empty-object\",\n droppedKeys,\n });\n if (droppedKeys.length > 0) {\n throw new Error(`Config has conflicting keys that would be dropped during normalization: ${droppedKeys.map(k => JSON.stringify(k)).join(\", \")}`);\n }\n const pkg = importPackage ?? DEFAULT_CONFIG_IMPORT_PACKAGE;\n const importLine = `import type { HexclaveConfig } from \"${pkg}\";`;\n return `${importLine}\\n\\nexport const config: HexclaveConfig = ${JSON.stringify(normalizedConfig, null, 2)};\\n`;\n}\n\n// --- inline vitest tests ---\n\nimport.meta.vitest?.test(\"renderConfigFileContent normalizes config exports\", ({ expect }) => {\n expect(renderConfigFileContent({\n \"payments.items.todos.displayName\": \"Todo Slots\",\n \"payments.items.todos.customerType\": \"user\",\n })).toContain(`export const config: HexclaveConfig = {\n \"payments\": {\n \"items\": {\n \"todos\": {\n \"displayName\": \"Todo Slots\",\n \"customerType\": \"user\"\n }\n }\n }\n};`);\n});\n\nimport.meta.vitest?.test(\"renderConfigFileContent rejects conflicting dotted keys\", ({ expect }) => {\n expect(() => renderConfigFileContent({\n \"a.b\": 1,\n \"a.b.c\": 2,\n })).toThrowError(/conflicting keys.*\"a\\.b\\.c\"/);\n});\n\nimport.meta.vitest?.test(\"renderConfigFileContent rejects invalid config exports\", ({ expect }) => {\n expect(() => renderConfigFileContent(null)).toThrowErrorMatchingInlineSnapshot(\n `[Error: Invalid config: expected a plain object.]`,\n );\n});\n\nimport.meta.vitest?.test(\"renderConfigFileContent uses custom import package\", ({ expect }) => {\n const content = renderConfigFileContent({}, \"@hexclave/next\");\n expect(content).toContain('import type { HexclaveConfig } from \"@hexclave/next\";');\n});\n\nimport.meta.vitest?.test(\"renderConfigFileContent defaults to @hexclave/js\", ({ expect }) => {\n const content = renderConfigFileContent({});\n expect(content).toContain('import type { HexclaveConfig } from \"@hexclave/js\";');\n});\n\nimport.meta.vitest?.test(\"renderConfigFileContent imports from the SDK package root\", ({ expect }) => {\n const content = renderConfigFileContent({}, \"@stackframe/next\");\n expect(content).toContain('import type { HexclaveConfig } from \"@stackframe/next\";');\n});\n\nimport.meta.vitest?.test(\"detectConfigImportPackage picks first matching package by priority\", ({ expect }) => {\n expect(detectConfigImportPackage([\"@hexclave/next\", \"@hexclave/js\"])).toBe(\"@hexclave/next\");\n expect(detectConfigImportPackage([\"@hexclave/react\", \"@hexclave/js\"])).toBe(\"@hexclave/react\");\n expect(detectConfigImportPackage([\"@hexclave/js\"])).toBe(\"@hexclave/js\");\n expect(detectConfigImportPackage([\"@hexclave/tanstack-start\"])).toBe(\"@hexclave/tanstack-start\");\n expect(detectConfigImportPackage([\"@stackframe/stack\", \"@hexclave/next\"])).toBe(\"@hexclave/next\");\n expect(detectConfigImportPackage([\"@stackframe/stack\"])).toBe(\"@stackframe/stack\");\n expect(detectConfigImportPackage([\"@stackframe/template\"])).toBe(\"@stackframe/template\");\n expect(detectConfigImportPackage([\"lodash\", \"express\"])).toBeUndefined();\n expect(detectConfigImportPackage([])).toBeUndefined();\n});\n"],"mappings":";;AAEA,MAAM,gCAAgC;;;;;;;;AAStC,MAAa,yBAAyB;CACpC;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF;;;;;;AAOA,SAAgB,0BAA0B,cAA4C;CACpF,KAAK,MAAM,OAAO,wBAChB,IAAI,aAAa,SAAS,GAAG,GAC3B,OAAO;AAIb;;;;AAKA,SAAgB,wBAAwB,QAAiB,eAAgC;CACvF,IAAI,CAAC,cAAc,MAAM,GACvB,MAAM,IAAI,MAAM,0CAA0C;CAG5D,MAAM,cAAwB,CAAC;CAC/B,MAAM,mBAAmB,UAAU,QAAQ;EACzC,oBAAoB;EACpB,eAAe;EACf;CACF,CAAC;CACD,IAAI,YAAY,SAAS,GACvB,MAAM,IAAI,MAAM,2EAA2E,YAAY,KAAI,MAAK,KAAK,UAAU,CAAC,CAAC,CAAC,CAAC,KAAK,IAAI,GAAG;CAIjJ,OAAO,GAAG,wCAFE,iBAAiB,8BACkC,IAC1C,4CAA4C,KAAK,UAAU,kBAAkB,MAAM,CAAC,EAAE;AAC7G"}
|
|
@@ -150,15 +150,15 @@ declare const MetricsEmailOverviewSchema: yup.ObjectSchema<{
|
|
|
150
150
|
activity: number;
|
|
151
151
|
}[];
|
|
152
152
|
daily_emails_by_status: {
|
|
153
|
+
ok: number;
|
|
153
154
|
error: number;
|
|
154
155
|
date: string;
|
|
155
|
-
ok: number;
|
|
156
156
|
in_progress: number;
|
|
157
157
|
}[];
|
|
158
158
|
emails_sent: number;
|
|
159
159
|
recent_emails: {
|
|
160
|
-
status: string;
|
|
161
160
|
id: string;
|
|
161
|
+
status: string;
|
|
162
162
|
subject: string;
|
|
163
163
|
created_at_millis: number;
|
|
164
164
|
}[];
|
|
@@ -392,30 +392,30 @@ declare const AnalyticsClickmapResponseBodySchema: yup.ObjectSchema<{
|
|
|
392
392
|
kind: "team_user_hour_of_week" | "session_replay_clicks";
|
|
393
393
|
cells: {
|
|
394
394
|
value: number;
|
|
395
|
-
hour: number;
|
|
396
395
|
weekday: number;
|
|
396
|
+
hour: number;
|
|
397
397
|
}[];
|
|
398
398
|
sampling: number;
|
|
399
399
|
routes: {
|
|
400
400
|
path: string;
|
|
401
|
-
users: number;
|
|
402
401
|
clicks: number;
|
|
402
|
+
users: number;
|
|
403
403
|
replays: number;
|
|
404
404
|
}[];
|
|
405
405
|
users: {
|
|
406
|
-
primary_email: string | null;
|
|
407
|
-
display_name: string | null;
|
|
408
406
|
id: string;
|
|
407
|
+
display_name: string | null;
|
|
408
|
+
primary_email: string | null;
|
|
409
409
|
profile_image_url: string | null;
|
|
410
410
|
clicks: number;
|
|
411
411
|
replays: number;
|
|
412
412
|
last_event_at_millis: number;
|
|
413
413
|
}[];
|
|
414
414
|
replays: {
|
|
415
|
-
user_id: string | null;
|
|
416
415
|
id: string;
|
|
417
416
|
clicks: number;
|
|
418
417
|
last_event_at_millis: number;
|
|
418
|
+
user_id: string | null;
|
|
419
419
|
route_path: string | null;
|
|
420
420
|
viewport_width: number | null;
|
|
421
421
|
viewport_height: number | null;
|
|
@@ -443,9 +443,9 @@ declare const AnalyticsClickmapResponseBodySchema: yup.ObjectSchema<{
|
|
|
443
443
|
elements: never[];
|
|
444
444
|
}, "">;
|
|
445
445
|
declare const MetricsActiveUsersByCountrySchema: yup.MixedSchema<Record<string, {
|
|
446
|
-
primary_email: string | null;
|
|
447
|
-
display_name: string | null;
|
|
448
446
|
id: string;
|
|
447
|
+
display_name: string | null;
|
|
448
|
+
primary_email: string | null;
|
|
449
449
|
profile_image_url: string | null;
|
|
450
450
|
signed_up_at_millis: number;
|
|
451
451
|
last_active_at_millis: number | null;
|
|
@@ -471,25 +471,25 @@ declare const MetricsResponseBodySchema: yup.ObjectSchema<{
|
|
|
471
471
|
}[];
|
|
472
472
|
users_by_country: Record<string, number>;
|
|
473
473
|
active_users_by_country: Record<string, {
|
|
474
|
-
primary_email: string | null;
|
|
475
|
-
display_name: string | null;
|
|
476
474
|
id: string;
|
|
475
|
+
display_name: string | null;
|
|
476
|
+
primary_email: string | null;
|
|
477
477
|
profile_image_url: string | null;
|
|
478
478
|
signed_up_at_millis: number;
|
|
479
479
|
last_active_at_millis: number | null;
|
|
480
480
|
}[]>;
|
|
481
481
|
recently_registered: {
|
|
482
|
-
primary_email: string | null;
|
|
483
|
-
display_name: string | null;
|
|
484
482
|
id: string;
|
|
483
|
+
display_name: string | null;
|
|
484
|
+
primary_email: string | null;
|
|
485
485
|
profile_image_url: string | null;
|
|
486
486
|
signed_up_at_millis: number;
|
|
487
487
|
last_active_at_millis: number | null;
|
|
488
488
|
}[];
|
|
489
489
|
recently_active: {
|
|
490
|
-
primary_email: string | null;
|
|
491
|
-
display_name: string | null;
|
|
492
490
|
id: string;
|
|
491
|
+
display_name: string | null;
|
|
492
|
+
primary_email: string | null;
|
|
493
493
|
profile_image_url: string | null;
|
|
494
494
|
signed_up_at_millis: number;
|
|
495
495
|
last_active_at_millis: number | null;
|
|
@@ -563,15 +563,15 @@ declare const MetricsResponseBodySchema: yup.ObjectSchema<{
|
|
|
563
563
|
emails_by_status: Record<string, number>;
|
|
564
564
|
total_emails: number;
|
|
565
565
|
daily_emails_by_status: {
|
|
566
|
+
ok: number;
|
|
566
567
|
error: number;
|
|
567
568
|
date: string;
|
|
568
|
-
ok: number;
|
|
569
569
|
in_progress: number;
|
|
570
570
|
}[];
|
|
571
571
|
emails_sent: number;
|
|
572
572
|
recent_emails: {
|
|
573
|
-
status: string;
|
|
574
573
|
id: string;
|
|
574
|
+
status: string;
|
|
575
575
|
subject: string;
|
|
576
576
|
created_at_millis: number;
|
|
577
577
|
}[];
|
|
@@ -49,7 +49,7 @@ declare const conversationSummarySchema: yup$1.ObjectSchema<{
|
|
|
49
49
|
userPrimaryEmail: string | null;
|
|
50
50
|
userProfileImageUrl: string | null;
|
|
51
51
|
subject: string;
|
|
52
|
-
status: "
|
|
52
|
+
status: "pending" | "open" | "closed";
|
|
53
53
|
priority: "low" | "normal" | "high" | "urgent";
|
|
54
54
|
source: "email" | "manual" | "chat" | "api";
|
|
55
55
|
lastMessageType: "message" | "internal-note" | "status-change";
|
|
@@ -129,7 +129,7 @@ declare const conversationMessageSchema: yup$1.ObjectSchema<{
|
|
|
129
129
|
userId: string | null;
|
|
130
130
|
teamId: string | null;
|
|
131
131
|
subject: string;
|
|
132
|
-
status: "
|
|
132
|
+
status: "pending" | "open" | "closed";
|
|
133
133
|
priority: "low" | "normal" | "high" | "urgent";
|
|
134
134
|
source: "email" | "manual" | "chat" | "api";
|
|
135
135
|
messageType: "message" | "internal-note" | "status-change";
|
|
@@ -139,8 +139,8 @@ declare const conversationMessageSchema: yup$1.ObjectSchema<{
|
|
|
139
139
|
createdAt: string;
|
|
140
140
|
sender: {
|
|
141
141
|
type: "user" | "agent" | "system";
|
|
142
|
-
displayName: string | null;
|
|
143
142
|
id: string | null;
|
|
143
|
+
displayName: string | null;
|
|
144
144
|
primaryEmail: string | null;
|
|
145
145
|
};
|
|
146
146
|
}, yup$1.AnyObject, {
|
|
@@ -173,8 +173,7 @@ declare const conversationListResponseSchema: yup$1.ObjectSchema<{
|
|
|
173
173
|
lastOutboundAt?: string | null | undefined;
|
|
174
174
|
closedAt?: string | null | undefined;
|
|
175
175
|
recordMetadata?: {} | null | undefined;
|
|
176
|
-
status: "
|
|
177
|
-
priority: "low" | "normal" | "high" | "urgent";
|
|
176
|
+
status: "pending" | "open" | "closed";
|
|
178
177
|
subject: string;
|
|
179
178
|
conversationId: string;
|
|
180
179
|
userId: string | null;
|
|
@@ -182,6 +181,7 @@ declare const conversationListResponseSchema: yup$1.ObjectSchema<{
|
|
|
182
181
|
userDisplayName: string | null;
|
|
183
182
|
userPrimaryEmail: string | null;
|
|
184
183
|
userProfileImageUrl: string | null;
|
|
184
|
+
priority: "low" | "normal" | "high" | "urgent";
|
|
185
185
|
source: "email" | "manual" | "chat" | "api";
|
|
186
186
|
lastMessageType: "message" | "internal-note" | "status-change";
|
|
187
187
|
preview: string | null;
|
|
@@ -211,8 +211,7 @@ declare const conversationDetailResponseSchema: yup$1.ObjectSchema<{
|
|
|
211
211
|
lastOutboundAt?: string | null | undefined;
|
|
212
212
|
closedAt?: string | null | undefined;
|
|
213
213
|
recordMetadata?: {} | null | undefined;
|
|
214
|
-
status: "
|
|
215
|
-
priority: "low" | "normal" | "high" | "urgent";
|
|
214
|
+
status: "pending" | "open" | "closed";
|
|
216
215
|
subject: string;
|
|
217
216
|
conversationId: string;
|
|
218
217
|
userId: string | null;
|
|
@@ -220,6 +219,7 @@ declare const conversationDetailResponseSchema: yup$1.ObjectSchema<{
|
|
|
220
219
|
userDisplayName: string | null;
|
|
221
220
|
userPrimaryEmail: string | null;
|
|
222
221
|
userProfileImageUrl: string | null;
|
|
222
|
+
priority: "low" | "normal" | "high" | "urgent";
|
|
223
223
|
source: "email" | "manual" | "chat" | "api";
|
|
224
224
|
lastMessageType: "message" | "internal-note" | "status-change";
|
|
225
225
|
preview: string | null;
|
|
@@ -236,13 +236,13 @@ declare const conversationDetailResponseSchema: yup$1.ObjectSchema<{
|
|
|
236
236
|
};
|
|
237
237
|
};
|
|
238
238
|
messages: {
|
|
239
|
-
status: "open" | "pending" | "closed";
|
|
240
239
|
id: string;
|
|
241
|
-
|
|
240
|
+
status: "pending" | "open" | "closed";
|
|
242
241
|
subject: string;
|
|
243
242
|
conversationId: string;
|
|
244
243
|
userId: string | null;
|
|
245
244
|
teamId: string | null;
|
|
245
|
+
priority: "low" | "normal" | "high" | "urgent";
|
|
246
246
|
source: "email" | "manual" | "chat" | "api";
|
|
247
247
|
metadata: {} | null;
|
|
248
248
|
createdAt: string;
|
|
@@ -251,8 +251,8 @@ declare const conversationDetailResponseSchema: yup$1.ObjectSchema<{
|
|
|
251
251
|
attachments: {}[];
|
|
252
252
|
sender: {
|
|
253
253
|
type: "user" | "agent" | "system";
|
|
254
|
-
displayName: string | null;
|
|
255
254
|
id: string | null;
|
|
255
|
+
displayName: string | null;
|
|
256
256
|
primaryEmail: string | null;
|
|
257
257
|
};
|
|
258
258
|
}[];
|
|
@@ -3,20 +3,20 @@ import { CrudTypeOf } from "../../crud.js";
|
|
|
3
3
|
//#region src/interface/crud/current-user.d.ts
|
|
4
4
|
declare const currentUserCrud: import("../../crud").CrudSchemaFromOptions<{
|
|
5
5
|
clientReadSchema: import("yup").ObjectSchema<{
|
|
6
|
-
restricted_reason: {
|
|
7
|
-
type: "anonymous" | "email_not_verified" | "restricted_by_administrator";
|
|
8
|
-
} | null;
|
|
9
|
-
primary_email: string | null;
|
|
10
|
-
display_name: string | null;
|
|
11
|
-
client_metadata: {} | null;
|
|
12
|
-
client_read_only_metadata: {} | null;
|
|
13
6
|
id: string;
|
|
7
|
+
display_name: string | null;
|
|
8
|
+
primary_email: string | null;
|
|
9
|
+
profile_image_url: string | null;
|
|
10
|
+
signed_up_at_millis: number;
|
|
14
11
|
selected_team_id: string | null;
|
|
15
12
|
is_anonymous: boolean;
|
|
16
13
|
is_restricted: boolean;
|
|
14
|
+
restricted_reason: {
|
|
15
|
+
type: "anonymous" | "email_not_verified" | "restricted_by_administrator";
|
|
16
|
+
} | null;
|
|
17
17
|
requires_totp_mfa: boolean;
|
|
18
|
-
|
|
19
|
-
|
|
18
|
+
client_metadata: {} | null;
|
|
19
|
+
client_read_only_metadata: {} | null;
|
|
20
20
|
primary_email_verified: boolean;
|
|
21
21
|
has_password: boolean;
|
|
22
22
|
otp_auth_enabled: boolean;
|
|
@@ -33,8 +33,8 @@ declare const currentUserCrud: import("../../crud").CrudSchemaFromOptions<{
|
|
|
33
33
|
selected_team: {
|
|
34
34
|
client_metadata?: {} | null | undefined;
|
|
35
35
|
client_read_only_metadata?: {} | null | undefined;
|
|
36
|
-
display_name: string;
|
|
37
36
|
id: string;
|
|
37
|
+
display_name: string;
|
|
38
38
|
profile_image_url: string | null;
|
|
39
39
|
} | null;
|
|
40
40
|
}, import("yup").AnyObject, {
|
|
@@ -89,9 +89,9 @@ declare const currentUserCrud: import("../../crud").CrudSchemaFromOptions<{
|
|
|
89
89
|
client_metadata?: {} | null | undefined;
|
|
90
90
|
client_read_only_metadata?: {} | null | undefined;
|
|
91
91
|
server_metadata?: {} | null | undefined;
|
|
92
|
-
display_name: string;
|
|
93
92
|
id: string;
|
|
94
93
|
created_at_millis: number;
|
|
94
|
+
display_name: string;
|
|
95
95
|
profile_image_url: string | null;
|
|
96
96
|
} | null;
|
|
97
97
|
selected_team_id: string | null;
|
|
@@ -171,11 +171,11 @@ declare const currentUserCrud: import("../../crud").CrudSchemaFromOptions<{
|
|
|
171
171
|
requires_totp_mfa: undefined;
|
|
172
172
|
}, "">;
|
|
173
173
|
clientUpdateSchema: import("yup").ObjectSchema<{
|
|
174
|
-
primary_email: string | null | undefined;
|
|
175
174
|
display_name: string | null | undefined;
|
|
176
|
-
|
|
177
|
-
selected_team_id: string | null | undefined;
|
|
175
|
+
primary_email: string | null | undefined;
|
|
178
176
|
profile_image_url: string | null | undefined;
|
|
177
|
+
selected_team_id: string | null | undefined;
|
|
178
|
+
client_metadata: {} | null | undefined;
|
|
179
179
|
otp_auth_enabled: boolean | undefined;
|
|
180
180
|
passkey_auth_enabled: boolean | undefined;
|
|
181
181
|
totp_secret_base64: string | null | undefined;
|