@aitne/shared 0.1.0
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/LICENSE +21 -0
- package/dist/advisor-models.d.ts +34 -0
- package/dist/advisor-models.d.ts.map +1 -0
- package/dist/advisor-models.js +39 -0
- package/dist/advisor-models.js.map +1 -0
- package/dist/agent-identity.d.ts +11 -0
- package/dist/agent-identity.d.ts.map +1 -0
- package/dist/agent-identity.js +29 -0
- package/dist/agent-identity.js.map +1 -0
- package/dist/alerts.d.ts +44 -0
- package/dist/alerts.d.ts.map +1 -0
- package/dist/alerts.js +12 -0
- package/dist/alerts.js.map +1 -0
- package/dist/backend-api-key-config.d.ts +337 -0
- package/dist/backend-api-key-config.d.ts.map +1 -0
- package/dist/backend-api-key-config.js +682 -0
- package/dist/backend-api-key-config.js.map +1 -0
- package/dist/backend.d.ts +93 -0
- package/dist/backend.d.ts.map +1 -0
- package/dist/backend.js +22 -0
- package/dist/backend.js.map +1 -0
- package/dist/branding.d.ts +96 -0
- package/dist/branding.d.ts.map +1 -0
- package/dist/branding.js +102 -0
- package/dist/branding.js.map +1 -0
- package/dist/chat-session-scope.d.ts +14 -0
- package/dist/chat-session-scope.d.ts.map +1 -0
- package/dist/chat-session-scope.js +18 -0
- package/dist/chat-session-scope.js.map +1 -0
- package/dist/date-utils.d.ts +80 -0
- package/dist/date-utils.d.ts.map +1 -0
- package/dist/date-utils.js +187 -0
- package/dist/date-utils.js.map +1 -0
- package/dist/docs-frontmatter.d.ts +51 -0
- package/dist/docs-frontmatter.d.ts.map +1 -0
- package/dist/docs-frontmatter.js +184 -0
- package/dist/docs-frontmatter.js.map +1 -0
- package/dist/docs-schema.d.ts +79 -0
- package/dist/docs-schema.d.ts.map +1 -0
- package/dist/docs-schema.js +135 -0
- package/dist/docs-schema.js.map +1 -0
- package/dist/editable-config-keys.d.ts +14 -0
- package/dist/editable-config-keys.d.ts.map +1 -0
- package/dist/editable-config-keys.js +157 -0
- package/dist/editable-config-keys.js.map +1 -0
- package/dist/exec-with-stdin.d.ts +14 -0
- package/dist/exec-with-stdin.d.ts.map +1 -0
- package/dist/exec-with-stdin.js +35 -0
- package/dist/exec-with-stdin.js.map +1 -0
- package/dist/index.d.ts +37 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +49 -0
- package/dist/index.js.map +1 -0
- package/dist/integrations-snapshot.d.ts +183 -0
- package/dist/integrations-snapshot.d.ts.map +1 -0
- package/dist/integrations-snapshot.js +757 -0
- package/dist/integrations-snapshot.js.map +1 -0
- package/dist/integrations.d.ts +675 -0
- package/dist/integrations.d.ts.map +1 -0
- package/dist/integrations.js +1656 -0
- package/dist/integrations.js.map +1 -0
- package/dist/keychain-helper-client.d.ts +31 -0
- package/dist/keychain-helper-client.d.ts.map +1 -0
- package/dist/keychain-helper-client.js +105 -0
- package/dist/keychain-helper-client.js.map +1 -0
- package/dist/log-entry.d.ts +14 -0
- package/dist/log-entry.d.ts.map +1 -0
- package/dist/log-entry.js +2 -0
- package/dist/log-entry.js.map +1 -0
- package/dist/management-domains.d.ts +369 -0
- package/dist/management-domains.d.ts.map +1 -0
- package/dist/management-domains.js +499 -0
- package/dist/management-domains.js.map +1 -0
- package/dist/process-key.d.ts +67 -0
- package/dist/process-key.d.ts.map +1 -0
- package/dist/process-key.js +366 -0
- package/dist/process-key.js.map +1 -0
- package/dist/schemas.d.ts +267 -0
- package/dist/schemas.d.ts.map +1 -0
- package/dist/schemas.js +271 -0
- package/dist/schemas.js.map +1 -0
- package/dist/secret-client-factory.d.ts +16 -0
- package/dist/secret-client-factory.d.ts.map +1 -0
- package/dist/secret-client-factory.js +111 -0
- package/dist/secret-client-factory.js.map +1 -0
- package/dist/secret-client-file.d.ts +51 -0
- package/dist/secret-client-file.d.ts.map +1 -0
- package/dist/secret-client-file.js +160 -0
- package/dist/secret-client-file.js.map +1 -0
- package/dist/secret-client-linux.d.ts +26 -0
- package/dist/secret-client-linux.d.ts.map +1 -0
- package/dist/secret-client-linux.js +63 -0
- package/dist/secret-client-linux.js.map +1 -0
- package/dist/secret-client-windows.d.ts +37 -0
- package/dist/secret-client-windows.d.ts.map +1 -0
- package/dist/secret-client-windows.js +82 -0
- package/dist/secret-client-windows.js.map +1 -0
- package/dist/secret-redaction.d.ts +3 -0
- package/dist/secret-redaction.d.ts.map +1 -0
- package/dist/secret-redaction.js +31 -0
- package/dist/secret-redaction.js.map +1 -0
- package/dist/skill-curation/decision-language.d.ts +6 -0
- package/dist/skill-curation/decision-language.d.ts.map +1 -0
- package/dist/skill-curation/decision-language.js +38 -0
- package/dist/skill-curation/decision-language.js.map +1 -0
- package/dist/skill-curation/schemas.d.ts +461 -0
- package/dist/skill-curation/schemas.d.ts.map +1 -0
- package/dist/skill-curation/schemas.js +211 -0
- package/dist/skill-curation/schemas.js.map +1 -0
- package/dist/types.d.ts +204 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +54 -0
- package/dist/types.js.map +1 -0
- package/package.json +50 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"docs-schema.js","sourceRoot":"","sources":["../src/docs-schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;;GASG;AAEH,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAU,CAAC;AAE9C,MAAM,cAAc,GAAG;IACrB,iBAAiB;IACjB,UAAU;IACV,UAAU;IACV,QAAQ;IACR,iBAAiB;IACjB,WAAW;IACX,UAAU;CACF,CAAC;AAGX,MAAM,UAAU,GAAG,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,YAAY,CAAU,CAAC;AAGtE;;;;;;;;GAQG;AACH,MAAM,UAAU,GAAG,CAAC;KACjB,MAAM,EAAE;KACR,GAAG,CAAC,CAAC,CAAC;KACN,GAAG,CAAC,GAAG,CAAC;KACR,KAAK,CACJ,iEAAiE,EACjE,kEAAkE,CACnE,CAAC;AAEJ;;;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EAAE,EAAE,CAAC;SAC5B,IAAI,EAAE;SACN,OAAO,CAAC,MAAM,EAAE,GAAG,CAAC;SACpB,OAAO,CAAC,KAAK,EAAE,GAAG,CAAC,CAAC;AACzB,CAAC;AAED,qEAAqE;AACrE,MAAM,WAAW,GAAG,4DAA4D,CAAC;AAYjF,sDAAsD;AACtD,MAAM,UAAU,mBAAmB,CAAC,IAAY;IAC9C,MAAM,GAAG,GAA0B,EAAE,CAAC;IACtC,WAAW,CAAC,SAAS,GAAG,CAAC,CAAC;IAC1B,IAAI,CAAyB,CAAC;IAC9B,OAAO,CAAC,CAAC,GAAG,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,KAAK,IAAI,EAAE,CAAC;QAC7C,GAAG,CAAC,IAAI,CAAC;YACP,KAAK,EAAE,CAAC,CAAC,KAAK;YACd,GAAG,EAAE,CAAC,CAAC,KAAK,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM;YAC1B,IAAI,EAAE,CAAC,CAAC,CAAC,CAAE;YACX,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC,IAAI,IAAI;YACpB,GAAG,EAAE,CAAC,CAAC,CAAC,CAAC;SACV,CAAC,CAAC;IACL,CAAC;IACD,OAAO,GAAG,CAAC;AACb,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Canonical list of config keys editable via the dashboard PATCH /config endpoint.
|
|
3
|
+
*
|
|
4
|
+
* Both the daemon (env-writer.ts) and the dashboard (useSaveConfig) import from here
|
|
5
|
+
* so the set of accepted keys is enforced at compile time in both packages.
|
|
6
|
+
*/
|
|
7
|
+
export declare const EDITABLE_RUNTIME_KEY_TUPLE: readonly ["advisorEnabled", "advisorModel", "maxConcurrentSessions", "maxReactiveSessions", "delegatedProxyMaxConcurrent", "executeTimeoutMinutes", "delegatedTaskModeEnabled", "delegatedTaskMaxPerDay", "delegatedTaskDefaultMaxToolCalls", "delegatedTaskDefaultMaxBudgetUsd", "delegatedTaskDefaultTimeoutMs", "delegatedTaskHeavyEnabled", "delegatedTaskStructuredOutputEnabled", "delegatedTaskSubprocessPoolEnabled", "delegatedTaskSubprocessPoolTtlSeconds", "delegatedTaskCacheEnabled", "delegatedTaskCacheTtlSeconds", "delegatedTaskCacheMaxEntries", "agentDisplayName", "character", "sessionTimeoutDmMinutes", "sessionTimeoutChannelMinutes", "sessionTimeoutDashboardMinutes", "historyInjectionMaxMessages", "historyInjectionMaxTokens", "historyOtherSurfaceWindowMinutes", "dmStalenessStrict", "proactiveForwardChannelTimelineEnabled", "proactiveForwardForceFreshSession", "timezone", "dayBoundaryHour", "hourlyCheckEnabled", "hourlyCheckIntervalMinutes", "hourlyCheckActiveStartHour", "hourlyCheckActiveEndHour", "hourlyCheckMinObservations", "hourlyCheckGateMode", "hourlyCheckStage2Enabled", "hourlyCheckHeartbeatHours", "hourlyCheckLowSignalPendingCeiling", "authProbeDisabled", "authPreflightFreshnessMs", "maxNotificationsPerHour", "maxNotificationsPerDay", "quietHoursStart", "quietHoursEnd", "batchIntervalMinutes", "primaryPlatform", "defaultNotificationPlatforms", "slackOwnerUserId", "telegramOwnerChatId", "discordOwnerUserId", "whatsappEnabled", "whatsappOwnerPhone", "whatsappAuthDir", "disallowedTools", "allowedToolsOverride", "claudeExecutionPermissionMode", "codexExecutionPermissionMode", "geminiExecutionPermissionMode", "externalObsidianVaultPath", "externalObsidianVaultName", "externalObsidianWatch", "obsidianDebounceSeconds", "primaryVaultPath", "primaryVaultName", "gitAccounts", "googleCalendarId", "notionDatabaseIds", "schedulePollIntervalSeconds", "maxBriefingDelayMinutes", "gitPollIntervalSeconds", "gitPushOverdueMinutes", "gitProjectUpdateDebounceMinutes", "notionPollIntervalSeconds", "calendarPollIntervalSeconds", "gmailPollIntervalSeconds", "githubPollIntervalSeconds", "mcpAutoProbeIntervalMinutes", "delegatedProbeIntervalMinutes", "enabledMailProviders", "mailPollIntervalSeconds", "mailIdleEnabled", "mailIdleInstabilityThreshold", "mailIdleFallbackRecoveryMinutes", "mailMaxMessagesPerPoll", "mailAuthFailureRetryHours", "hourlyObservationCharBudget", "observationSummarizerEnabled", "observationSummarizerConcurrency", "observationSummarizerMaxCallsPerMinute", "observationSummarizerQueueLimit", "observationSummarizerTimeoutMs", "vipMailSenders", "outlookDeltaPageSize", "outlookGraphConcurrency", "imapReconnectBaseMs", "imapReconnectMaxMs", "autonomousDailyCostCapUsd", "autonomousMonthlyCostCapUsd", "primaryLanguage", "vaultMode", "voiceTranscriptionEnabled"];
|
|
8
|
+
export declare const EDITABLE_BOOTSTRAP_KEY_TUPLE: readonly ["apiPort"];
|
|
9
|
+
export declare const RESTART_REQUIRED_KEY_TUPLE: readonly ["apiPort", "externalObsidianVaultName", "externalObsidianVaultPath", "externalObsidianWatch", "primaryVaultPath", "primaryVaultName", "slackOwnerUserId", "telegramOwnerChatId", "discordOwnerUserId", "whatsappEnabled", "whatsappOwnerPhone", "whatsappAuthDir", "notionDatabaseIds", "gmailPollIntervalSeconds", "delegatedProbeIntervalMinutes", "gitPollIntervalSeconds", "githubPollIntervalSeconds", "voiceTranscriptionEnabled", "observationSummarizerEnabled", "observationSummarizerConcurrency", "observationSummarizerMaxCallsPerMinute", "observationSummarizerQueueLimit", "observationSummarizerTimeoutMs"];
|
|
10
|
+
export type EditableRuntimeKey = (typeof EDITABLE_RUNTIME_KEY_TUPLE)[number];
|
|
11
|
+
export type EditableBootstrapKey = (typeof EDITABLE_BOOTSTRAP_KEY_TUPLE)[number];
|
|
12
|
+
export type EditableConfigKey = EditableRuntimeKey | EditableBootstrapKey;
|
|
13
|
+
export type RestartRequiredKey = (typeof RESTART_REQUIRED_KEY_TUPLE)[number];
|
|
14
|
+
//# sourceMappingURL=editable-config-keys.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"editable-config-keys.d.ts","sourceRoot":"","sources":["../src/editable-config-keys.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,eAAO,MAAM,0BAA0B,uvFAkG7B,CAAC;AAEX,eAAO,MAAM,4BAA4B,sBAE/B,CAAC;AAEX,eAAO,MAAM,0BAA0B,umBA+C7B,CAAC;AAEX,MAAM,MAAM,kBAAkB,GAAG,CAAC,OAAO,0BAA0B,CAAC,CAAC,MAAM,CAAC,CAAC;AAC7E,MAAM,MAAM,oBAAoB,GAAG,CAAC,OAAO,4BAA4B,CAAC,CAAC,MAAM,CAAC,CAAC;AACjF,MAAM,MAAM,iBAAiB,GAAG,kBAAkB,GAAG,oBAAoB,CAAC;AAC1E,MAAM,MAAM,kBAAkB,GAAG,CAAC,OAAO,0BAA0B,CAAC,CAAC,MAAM,CAAC,CAAC"}
|
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Canonical list of config keys editable via the dashboard PATCH /config endpoint.
|
|
3
|
+
*
|
|
4
|
+
* Both the daemon (env-writer.ts) and the dashboard (useSaveConfig) import from here
|
|
5
|
+
* so the set of accepted keys is enforced at compile time in both packages.
|
|
6
|
+
*/
|
|
7
|
+
export const EDITABLE_RUNTIME_KEY_TUPLE = [
|
|
8
|
+
"advisorEnabled", "advisorModel",
|
|
9
|
+
"maxConcurrentSessions", "maxReactiveSessions", "delegatedProxyMaxConcurrent", "executeTimeoutMinutes",
|
|
10
|
+
// DELEGATED-TASK-MODE-DESIGN.md §17 — task-mode kill switch / quotas /
|
|
11
|
+
// defaults. The heavy enable flag is Approve-tier semantically, but is
|
|
12
|
+
// editable here too so the user can flip it from the dashboard once
|
|
13
|
+
// they confirm the cost class.
|
|
14
|
+
"delegatedTaskModeEnabled", "delegatedTaskMaxPerDay",
|
|
15
|
+
"delegatedTaskDefaultMaxToolCalls", "delegatedTaskDefaultMaxBudgetUsd",
|
|
16
|
+
"delegatedTaskDefaultTimeoutMs", "delegatedTaskHeavyEnabled",
|
|
17
|
+
// DELEGATED-TASK-MODE-DESIGN.md §13 Phase 3 — three independent
|
|
18
|
+
// optimization kill switches. Each defaults off (cache, pool) or on
|
|
19
|
+
// (structured output) per the design doc; flipping any one does not
|
|
20
|
+
// affect the others. See runtime-settings.ts for the per-field rationale.
|
|
21
|
+
"delegatedTaskStructuredOutputEnabled",
|
|
22
|
+
"delegatedTaskSubprocessPoolEnabled", "delegatedTaskSubprocessPoolTtlSeconds",
|
|
23
|
+
"delegatedTaskCacheEnabled", "delegatedTaskCacheTtlSeconds",
|
|
24
|
+
"delegatedTaskCacheMaxEntries",
|
|
25
|
+
"agentDisplayName",
|
|
26
|
+
"character",
|
|
27
|
+
"sessionTimeoutDmMinutes", "sessionTimeoutChannelMinutes", "sessionTimeoutDashboardMinutes",
|
|
28
|
+
"historyInjectionMaxMessages", "historyInjectionMaxTokens",
|
|
29
|
+
"historyOtherSurfaceWindowMinutes",
|
|
30
|
+
"dmStalenessStrict",
|
|
31
|
+
"proactiveForwardChannelTimelineEnabled",
|
|
32
|
+
"proactiveForwardForceFreshSession",
|
|
33
|
+
"timezone", "dayBoundaryHour", "hourlyCheckEnabled", "hourlyCheckIntervalMinutes",
|
|
34
|
+
"hourlyCheckActiveStartHour", "hourlyCheckActiveEndHour", "hourlyCheckMinObservations",
|
|
35
|
+
// cost-reduction-structural §B — three-stage gate knobs.
|
|
36
|
+
"hourlyCheckGateMode", "hourlyCheckStage2Enabled", "hourlyCheckHeartbeatHours",
|
|
37
|
+
"hourlyCheckLowSignalPendingCeiling",
|
|
38
|
+
"authProbeDisabled", "authPreflightFreshnessMs",
|
|
39
|
+
"maxNotificationsPerHour", "maxNotificationsPerDay",
|
|
40
|
+
"quietHoursStart", "quietHoursEnd", "batchIntervalMinutes", "primaryPlatform",
|
|
41
|
+
"defaultNotificationPlatforms",
|
|
42
|
+
"slackOwnerUserId", "telegramOwnerChatId", "discordOwnerUserId",
|
|
43
|
+
"whatsappEnabled", "whatsappOwnerPhone", "whatsappAuthDir",
|
|
44
|
+
"disallowedTools", "allowedToolsOverride",
|
|
45
|
+
"claudeExecutionPermissionMode",
|
|
46
|
+
"codexExecutionPermissionMode",
|
|
47
|
+
"geminiExecutionPermissionMode",
|
|
48
|
+
"externalObsidianVaultPath", "externalObsidianVaultName",
|
|
49
|
+
// SETUP-FLOW-REDESIGN-PLAN §6.3 — kill switch for the external-vault
|
|
50
|
+
// branch of `ObsidianWatcher`. Editable so the Notes step's "Watch for
|
|
51
|
+
// changes" checkbox round-trips through `PATCH /api/config`.
|
|
52
|
+
"externalObsidianWatch",
|
|
53
|
+
"obsidianDebounceSeconds",
|
|
54
|
+
// Management Mode — primary-vault fields introduced by the management-mode
|
|
55
|
+
// redesign. Editable via the settings dialog once Phase 2's migration API
|
|
56
|
+
// lands; Phase 1 persists values if set but enters degraded mode if unset
|
|
57
|
+
// while vaultMode === "obsidian".
|
|
58
|
+
"primaryVaultPath", "primaryVaultName",
|
|
59
|
+
// gitRepos / gitWatchedRepos / githubRepos removed at the unified-
|
|
60
|
+
// repositories cutover (docs/design/appendices/unified-repositories.md);
|
|
61
|
+
// their data lives in the `repositories` DB table now. `gitAccounts`
|
|
62
|
+
// stays — it is 1:N over rows.
|
|
63
|
+
"gitAccounts",
|
|
64
|
+
"googleCalendarId", "notionDatabaseIds",
|
|
65
|
+
"schedulePollIntervalSeconds",
|
|
66
|
+
// SCHEDULED-DM-IMPLEMENTATION-PLAN §3.6.1 / §6.6.1 — max delay budget
|
|
67
|
+
// for scheduled.dm gate-acquisition before the briefing is dropped.
|
|
68
|
+
"maxBriefingDelayMinutes",
|
|
69
|
+
"gitPollIntervalSeconds", "gitPushOverdueMinutes", "gitProjectUpdateDebounceMinutes",
|
|
70
|
+
"notionPollIntervalSeconds", "calendarPollIntervalSeconds",
|
|
71
|
+
"gmailPollIntervalSeconds",
|
|
72
|
+
"githubPollIntervalSeconds",
|
|
73
|
+
"mcpAutoProbeIntervalMinutes",
|
|
74
|
+
"delegatedProbeIntervalMinutes",
|
|
75
|
+
"enabledMailProviders",
|
|
76
|
+
"mailPollIntervalSeconds",
|
|
77
|
+
"mailIdleEnabled",
|
|
78
|
+
"mailIdleInstabilityThreshold",
|
|
79
|
+
"mailIdleFallbackRecoveryMinutes",
|
|
80
|
+
"mailMaxMessagesPerPoll",
|
|
81
|
+
"mailAuthFailureRetryHours",
|
|
82
|
+
"hourlyObservationCharBudget",
|
|
83
|
+
// cost-reduction-structural §A — observation summarizer knobs.
|
|
84
|
+
"observationSummarizerEnabled",
|
|
85
|
+
"observationSummarizerConcurrency",
|
|
86
|
+
"observationSummarizerMaxCallsPerMinute",
|
|
87
|
+
"observationSummarizerQueueLimit",
|
|
88
|
+
"observationSummarizerTimeoutMs",
|
|
89
|
+
"vipMailSenders",
|
|
90
|
+
"outlookDeltaPageSize",
|
|
91
|
+
"outlookGraphConcurrency",
|
|
92
|
+
"imapReconnectBaseMs",
|
|
93
|
+
"imapReconnectMaxMs",
|
|
94
|
+
"autonomousDailyCostCapUsd",
|
|
95
|
+
"autonomousMonthlyCostCapUsd",
|
|
96
|
+
// B-007 — primary language + vault mode selected at setup, editable later
|
|
97
|
+
"primaryLanguage",
|
|
98
|
+
"vaultMode",
|
|
99
|
+
// Voice transcription opt-in (docs/design/appendices/voice-transcription.md).
|
|
100
|
+
// Direct PATCH is rejected by the voice route — the dashboard goes through
|
|
101
|
+
// POST /api/voice/install so the model download + auto-restart happen
|
|
102
|
+
// atomically. Listed here so the env-writer / settings-merge plumbing
|
|
103
|
+
// accepts the key on read-back.
|
|
104
|
+
"voiceTranscriptionEnabled",
|
|
105
|
+
];
|
|
106
|
+
export const EDITABLE_BOOTSTRAP_KEY_TUPLE = [
|
|
107
|
+
"apiPort",
|
|
108
|
+
];
|
|
109
|
+
export const RESTART_REQUIRED_KEY_TUPLE = [
|
|
110
|
+
"apiPort",
|
|
111
|
+
"externalObsidianVaultName", "externalObsidianVaultPath",
|
|
112
|
+
// SETUP-FLOW-REDESIGN-PLAN §6.3 — the kill switch is read once at boot in
|
|
113
|
+
// index.ts when ObsidianWatcher is registered; flipping it at runtime
|
|
114
|
+
// updates the integrations.md Note Sources line (via applyConfigUpdates
|
|
115
|
+
// chokepoint) but does NOT start/stop the live chokidar watcher. Surface
|
|
116
|
+
// that honestly via the dashboard's restart-required badge — same posture
|
|
117
|
+
// as `externalObsidianVaultPath` above, which has the same constraint.
|
|
118
|
+
"externalObsidianWatch",
|
|
119
|
+
"primaryVaultPath", "primaryVaultName",
|
|
120
|
+
"slackOwnerUserId",
|
|
121
|
+
"telegramOwnerChatId",
|
|
122
|
+
"discordOwnerUserId",
|
|
123
|
+
"whatsappEnabled", "whatsappOwnerPhone", "whatsappAuthDir",
|
|
124
|
+
"notionDatabaseIds",
|
|
125
|
+
"gmailPollIntervalSeconds",
|
|
126
|
+
// DelegatedProbeObserver (DELEGATED-MODE-V2 §7.1) captures `intervalMs`
|
|
127
|
+
// at construction time and registers a single setInterval — a hot PATCH
|
|
128
|
+
// updates `config.delegatedProbeIntervalMinutes` but the timer keeps
|
|
129
|
+
// firing on the old cadence until restart. Surface that honestly via
|
|
130
|
+
// the dashboard's restart-required badge rather than silently ignoring
|
|
131
|
+
// the change.
|
|
132
|
+
"delegatedProbeIntervalMinutes",
|
|
133
|
+
// GitWatcher / delegated Git cron / GitHubPoller capture their cadence in
|
|
134
|
+
// constructors and bind it to timers. Runtime PATCH updates config storage,
|
|
135
|
+
// but the live timers keep the old cadence until restart; flag honestly.
|
|
136
|
+
"gitPollIntervalSeconds",
|
|
137
|
+
"githubPollIntervalSeconds",
|
|
138
|
+
// VoiceTranscriber binds `enabled` at construction time in index.ts;
|
|
139
|
+
// toggling the flag at runtime does not affect the live transcriber until
|
|
140
|
+
// the daemon restarts. The /api/voice/install path triggers the restart
|
|
141
|
+
// automatically, but flag a manual PATCH honestly via the dashboard badge.
|
|
142
|
+
"voiceTranscriptionEnabled",
|
|
143
|
+
// ObservationSummarizerWorker reads these constructor-time options once
|
|
144
|
+
// at startup (cost-reduction-structural §A): the worker is registered
|
|
145
|
+
// only when `observationSummarizerEnabled=true` at boot, and concurrency
|
|
146
|
+
// / per-call timeout / rate limit / queue cap are captured by the
|
|
147
|
+
// worker constructor and bound to the running drain loops. A runtime
|
|
148
|
+
// PATCH updates `settings`/`AgentConfig` storage but does not re-create
|
|
149
|
+
// the worker — flag honestly via the restart badge so an operator that
|
|
150
|
+
// bumped the rate limit knows the change isn't live yet.
|
|
151
|
+
"observationSummarizerEnabled",
|
|
152
|
+
"observationSummarizerConcurrency",
|
|
153
|
+
"observationSummarizerMaxCallsPerMinute",
|
|
154
|
+
"observationSummarizerQueueLimit",
|
|
155
|
+
"observationSummarizerTimeoutMs",
|
|
156
|
+
];
|
|
157
|
+
//# sourceMappingURL=editable-config-keys.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"editable-config-keys.js","sourceRoot":"","sources":["../src/editable-config-keys.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,CAAC,MAAM,0BAA0B,GAAG;IACxC,gBAAgB,EAAE,cAAc;IAChC,uBAAuB,EAAE,qBAAqB,EAAE,6BAA6B,EAAE,uBAAuB;IACtG,uEAAuE;IACvE,uEAAuE;IACvE,oEAAoE;IACpE,+BAA+B;IAC/B,0BAA0B,EAAE,wBAAwB;IACpD,kCAAkC,EAAE,kCAAkC;IACtE,+BAA+B,EAAE,2BAA2B;IAC5D,gEAAgE;IAChE,oEAAoE;IACpE,oEAAoE;IACpE,0EAA0E;IAC1E,sCAAsC;IACtC,oCAAoC,EAAE,uCAAuC;IAC7E,2BAA2B,EAAE,8BAA8B;IAC3D,8BAA8B;IAC9B,kBAAkB;IAClB,WAAW;IACX,yBAAyB,EAAE,8BAA8B,EAAE,gCAAgC;IAC3F,6BAA6B,EAAE,2BAA2B;IAC1D,kCAAkC;IAClC,mBAAmB;IACnB,wCAAwC;IACxC,mCAAmC;IACnC,UAAU,EAAE,iBAAiB,EAAE,oBAAoB,EAAE,4BAA4B;IACjF,4BAA4B,EAAE,0BAA0B,EAAE,4BAA4B;IACtF,yDAAyD;IACzD,qBAAqB,EAAE,0BAA0B,E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AAgC;IAChC,2BAA2B;CACnB,CAAC;AAEX,MAAM,CAAC,MAAM,4BAA4B,GAAG;IAC1C,SAAS;CACD,CAAC;AAEX,MAAM,CAAC,MAAM,0BAA0B,GAAG;IACxC,SAAS;IACT,2BAA2B,EAAE,2BAA2B;IACxD,0EAA0E;IAC1E,sEAAsE;IACtE,wEAAwE;IACxE,yEAAyE;IACzE,0EAA0E;IAC1E,uEAAuE;IACvE,uBAAuB;IACvB,kBAAkB,EAAE,kBAAkB;IACtC,kBAAkB;IAClB,qBAAqB;IACrB,oBAAoB;IACpB,iBAAiB,EAAE,oBAAoB,EAAE,iBAAiB;IAC1D,mBAAmB;IACnB,0BAA0B;IAC1B,wEAAwE;IACxE,wEAAwE;IACxE,qEAAqE;IACrE,qEAAqE;IACrE,uEAAuE;IACvE,cAAc;IACd,+BAA+B;IAC/B,0EAA0E;IAC1E,4EAA4E;IAC5E,yEAAyE;IACzE,wBAAwB;IACxB,2BAA2B;IAC3B,qEAAqE;IACrE,0EAA0E;IAC1E,wEAAwE;IACxE,2EAA2E;IAC3E,2BAA2B;IAC3B,wEAAwE;IACxE,sEAAsE;IACtE,yEAAyE;IACzE,kEAAkE;IAClE,qEAAqE;IACrE,wEAAwE;IACxE,uEAAuE;IACvE,yDAAyD;IACzD,8BAA8B;IAC9B,kCAAkC;IAClC,wCAAwC;IACxC,iCAAiC;IACjC,gCAAgC;CACxB,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Run a command with stdin input piped from a string.
|
|
3
|
+
*
|
|
4
|
+
* Unlike `promisify(execFile)`, this supports writing to the child's stdin,
|
|
5
|
+
* which is needed by `secret-tool store` (Linux) and PowerShell DPAPI
|
|
6
|
+
* (Windows) where values must be passed via stdin to avoid command injection.
|
|
7
|
+
*/
|
|
8
|
+
export declare function execWithStdin(command: string, args: string[], input: string, options?: {
|
|
9
|
+
timeout?: number;
|
|
10
|
+
}): Promise<{
|
|
11
|
+
stdout: string;
|
|
12
|
+
stderr: string;
|
|
13
|
+
}>;
|
|
14
|
+
//# sourceMappingURL=exec-with-stdin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exec-with-stdin.d.ts","sourceRoot":"","sources":["../src/exec-with-stdin.ts"],"names":[],"mappings":"AAEA;;;;;;GAMG;AACH,wBAAgB,aAAa,CAC3B,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,MAAM,EAAE,EACd,KAAK,EAAE,MAAM,EACb,OAAO,CAAC,EAAE;IAAE,OAAO,CAAC,EAAE,MAAM,CAAA;CAAE,GAC7B,OAAO,CAAC;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAAC,CA4B7C"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { spawn } from "node:child_process";
|
|
2
|
+
/**
|
|
3
|
+
* Run a command with stdin input piped from a string.
|
|
4
|
+
*
|
|
5
|
+
* Unlike `promisify(execFile)`, this supports writing to the child's stdin,
|
|
6
|
+
* which is needed by `secret-tool store` (Linux) and PowerShell DPAPI
|
|
7
|
+
* (Windows) where values must be passed via stdin to avoid command injection.
|
|
8
|
+
*/
|
|
9
|
+
export function execWithStdin(command, args, input, options) {
|
|
10
|
+
return new Promise((resolve, reject) => {
|
|
11
|
+
const child = spawn(command, args, {
|
|
12
|
+
stdio: ["pipe", "pipe", "pipe"],
|
|
13
|
+
timeout: options?.timeout,
|
|
14
|
+
});
|
|
15
|
+
let stdout = "";
|
|
16
|
+
let stderr = "";
|
|
17
|
+
child.stdout.on("data", (data) => {
|
|
18
|
+
stdout += data;
|
|
19
|
+
});
|
|
20
|
+
child.stderr.on("data", (data) => {
|
|
21
|
+
stderr += data;
|
|
22
|
+
});
|
|
23
|
+
// Handle spawn errors (e.g., command not found) before writing to stdin
|
|
24
|
+
child.on("error", reject);
|
|
25
|
+
child.on("close", (code) => {
|
|
26
|
+
if (code === 0)
|
|
27
|
+
resolve({ stdout, stderr });
|
|
28
|
+
else
|
|
29
|
+
reject(new Error(`Exit ${code}: ${stderr}`));
|
|
30
|
+
});
|
|
31
|
+
child.stdin.write(input);
|
|
32
|
+
child.stdin.end();
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
//# sourceMappingURL=exec-with-stdin.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exec-with-stdin.js","sourceRoot":"","sources":["../src/exec-with-stdin.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAE3C;;;;;;GAMG;AACH,MAAM,UAAU,aAAa,CAC3B,OAAe,EACf,IAAc,EACd,KAAa,EACb,OAA8B;IAE9B,OAAO,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;QACrC,MAAM,KAAK,GAAG,KAAK,CAAC,OAAO,EAAE,IAAI,EAAE;YACjC,KAAK,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC;YAC/B,OAAO,EAAE,OAAO,EAAE,OAAO;SAC1B,CAAC,CAAC;QAEH,IAAI,MAAM,GAAG,EAAE,CAAC;QAChB,IAAI,MAAM,GAAG,EAAE,CAAC;QAEhB,KAAK,CAAC,MAAM,CAAC,EAAE,CAAC,MAAM,EAAE,CAAC,IAAY,EAAE,EAAE;YACvC,MAAM,IAAI,IAAI,CAAC;QACjB,CAAC,CAAC,CAAC;QACH,KAAK,CAAC,MAAM,CAAC,EAAE,CAAC,MAAM,EAAE,CAAC,IAAY,EAAE,EAAE;YACvC,MAAM,IAAI,IAAI,CAAC;QACjB,CAAC,CAAC,CAAC;QAEH,wEAAwE;QACxE,KAAK,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC;QAE1B,KAAK,CAAC,EAAE,CAAC,OAAO,EAAE,CAAC,IAAI,EAAE,EAAE;YACzB,IAAI,IAAI,KAAK,CAAC;gBAAE,OAAO,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;;gBACvC,MAAM,CAAC,IAAI,KAAK,CAAC,QAAQ,IAAI,KAAK,MAAM,EAAE,CAAC,CAAC,CAAC;QACpD,CAAC,CAAC,CAAC;QAEH,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;QACzB,KAAK,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC;IACpB,CAAC,CAAC,CAAC;AACL,CAAC"}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
export { localDateStr, nowInTimezone, getAgentDayBoundsUtc, getAgentDayDateStr, getAgentDayProgressMinutes, nextActiveHoursStart, formatSqliteDatetime, parseSqliteUtcMs, } from "./date-utils.js";
|
|
2
|
+
export { EventPriority, createEvent, isMessageEvent, isDocsQAMessage, isCalendarChangeEvent, isRoutineEvent, isAgentTaskEvent, isScheduledDmEvent, isScheduledEvent, isKnowledgeImportEvent, } from "./types.js";
|
|
3
|
+
export type { Event, MessageEvent, AttachmentRef, CalendarChangeEvent, RoutineEvent, AgentTaskEvent, ScheduledDmEvent, KnowledgeImportEvent, AgentResult, } from "./types.js";
|
|
4
|
+
export type { Alert, AlertSeverity, AlertSource } from "./alerts.js";
|
|
5
|
+
export { APP_NAME, AGENT_ROLE_DESCRIPTOR, APP_TAGLINE, APP_NAME_WITH_TAGLINE, joinTaglineWithSentence, substituteBrandTokens, } from "./branding.js";
|
|
6
|
+
export { BACKEND_IDS, EXECUTION_PERMISSION_MODES, WEB_SEARCH_CAPABLE_BACKENDS, getBackendIds, isBackendId, } from "./backend.js";
|
|
7
|
+
export type { BackendId, BackendCostSource, BackendModel, BackendModelTier, BackendUsage, ExecutionPermissionMode, } from "./backend.js";
|
|
8
|
+
export { CLAUDE_API_KEY_PROVIDERS, CODEX_API_KEY_PROVIDERS, GEMINI_API_KEY_PROVIDERS, API_KEY_PROVIDERS_BY_BACKEND, RECOMMENDED_PINNED_MODELS_BY_PROVIDER, DEFAULT_AZURE_OPENAI_API_VERSION, defaultApiKeyProvider, isApiKeyProviderForBackend, backendApiKeyConfigSchema, anthropicApiKeyConfigSchema, bedrockApiKeyConfigSchema, vertexApiKeyConfigSchema, foundryApiKeyConfigSchema, openaiApiKeyConfigSchema, azureOpenAiApiKeyConfigSchema, googleApiKeyConfigSchema, buildCodexAzureConfigToml, getManagedApiKeyEnvVars, getApiKeyEnvAssignments, parseBackendApiKeyConfig, serializeBackendApiKeyConfig, validateBackendApiKeyConfigFormat, isPlausibleAnthropicApiKey, isPlausibleOpenAiApiKey, isPlausibleGeminiApiKey, } from "./backend-api-key-config.js";
|
|
9
|
+
export type { ApiKeyProvider, ClaudeApiKeyProvider, CodexApiKeyProvider, GeminiApiKeyProvider, AnthropicApiKeyConfig, BedrockApiKeyConfig, VertexApiKeyConfig, FoundryApiKeyConfig, OpenAiApiKeyConfig, AzureOpenAiApiKeyConfig, GoogleApiKeyConfig, PinnedModelDefaults, BackendApiKeyConfig, } from "./backend-api-key-config.js";
|
|
10
|
+
export { CONFIGURABLE_PROCESS_KEYS, DELEGATED_TASK_HARD_CAPS, TIER_LOCKED_PROCESS_KEYS, customRoutineKey, customRoutineSlugFromKey, getDefaultTierForProcessKey, isAutonomousProcessKey, isConfigurableProcessKey, isCustomRoutineKey, isProcessKey, resolveProcessKey, } from "./process-key.js";
|
|
11
|
+
export type { ProcessKey, ProcessModelTier, } from "./process-key.js";
|
|
12
|
+
export { contextPutSchema, contextPatchSchema, notifyRequestSchema, scheduleRequestSchema, scheduleUpdateRequestSchema, scheduleDmRequestSchema, actionLogRequestSchema, skillNameSchema, skillCreateSchema, skillUpdateSchema, calendarCreateEventSchema, calendarUpdateEventSchema, calendarFreeBusySchema, recurrenceRuleSchema, recurringScheduleCreateSchema, recurringScheduleUpdateSchema, triggerCreateSchema, triggerUpdateSchema, } from "./schemas.js";
|
|
13
|
+
export type { NotifyRequest, ScheduleRequest, ScheduleUpdateRequest, ScheduleDmRequest, ActionLogRequest, SkillCreateRequest, SkillUpdateRequest, SkillSummary, SkillDetail, RecurrenceRule, TriggerCreateRequest, TriggerUpdateRequest, } from "./schemas.js";
|
|
14
|
+
export { DEFAULT_AGENT_DISPLAY_NAME, normalizeAgentDisplayName, validateAgentDisplayName, formatAgentOutboundLabel, } from "./agent-identity.js";
|
|
15
|
+
export type { LogEntry, SystemLogsResponse } from "./log-entry.js";
|
|
16
|
+
export { redactSensitiveString, SENSITIVE_KEY_PATTERN, } from "./secret-redaction.js";
|
|
17
|
+
export { CHAT_SIDEBAR_SCOPES, CHAT_SIDEBAR_SCOPE_PARAM, isChatSidebarScope, } from "./chat-session-scope.js";
|
|
18
|
+
export type { ChatSidebarScope } from "./chat-session-scope.js";
|
|
19
|
+
export { EDITABLE_RUNTIME_KEY_TUPLE, EDITABLE_BOOTSTRAP_KEY_TUPLE, RESTART_REQUIRED_KEY_TUPLE, } from "./editable-config-keys.js";
|
|
20
|
+
export type { EditableRuntimeKey, EditableBootstrapKey, EditableConfigKey, RestartRequiredKey, } from "./editable-config-keys.js";
|
|
21
|
+
export { INTEGRATION_KEYS, INTEGRATION_MODES, INTEGRATION_DESCRIPTORS, defaultIntegrationsMap, getIntegrationDescriptor, integrationPatchSchema, integrationStateSchema, integrationsMapSchema, isIntegrationKey, isIntegrationMode, listIntegrationDescriptors, selectSkillVariantFile, selectTaskFlowVariantSuffix, delegatedIntegrationsForProcessKey, backendHasIntegrationConnector, validateDeniedTools, filterDeniedToolsForBackend, matchToolPattern, collectSessionDeniedTools, recommendedStarterDeniedTools, destructiveTaskTools, destructiveTaskToolsBare, applyIntegrationModeFilter, INTEGRATION_MODE_PREDICATES, MCP_PATTERN_REGEX, matchRunAllowedToolPattern, validateRunAllowedTool, validateRunAllowedTools, } from "./integrations.js";
|
|
22
|
+
export type { ValidateRunAllowedToolsResult } from "./integrations.js";
|
|
23
|
+
export type { IntegrationBackendConnector, IntegrationDescriptor, IntegrationDirectSetup, IntegrationKey, IntegrationMode, IntegrationModePredicate, IntegrationPatch, IntegrationState, IntegrationsMap, ValidateDeniedToolsResult, } from "./integrations.js";
|
|
24
|
+
export { INTEGRATION_WRITE_TTL_MS, SNAPSHOT_NORMALIZERS, getSnapshotNormalizer, hasSnapshotNormalizer, listSnapshotNormalizers, stableStringify, } from "./integrations-snapshot.js";
|
|
25
|
+
export type { CalendarSnapshotPayload, IntegrationNormalizer, SnapshotActorHint, } from "./integrations-snapshot.js";
|
|
26
|
+
export { DOCS_SCHEMA_VERSION, docsFrontmatterSchema, slugifyAnchor, parseCitationTokens, } from "./docs-schema.js";
|
|
27
|
+
export type { DocCategory, DocStatus, DocsFrontmatter, ParsedCitationToken, } from "./docs-schema.js";
|
|
28
|
+
export { FrontmatterParseError, parseFrontmatter, } from "./docs-frontmatter.js";
|
|
29
|
+
export type { ParsedFrontmatter } from "./docs-frontmatter.js";
|
|
30
|
+
export { ADVISOR_ALLOWED_MODELS, DEFAULT_ADVISOR_MODEL, isAdvisorModel, } from "./advisor-models.js";
|
|
31
|
+
export type { AdvisorModel } from "./advisor-models.js";
|
|
32
|
+
export { APP_MAX_LENGTH, DOMAINS, ENTITY_TYPES, INTENT_MAX_LENGTH, LAST_RESULT_MAX_LENGTH, MANAGEMENT_ACTIVE_TASKS_SOFT_WARNING, MANAGEMENT_FAILURE_NOTIFY_THRESHOLD_DEFAULT, MANAGEMENT_MAX_ACTIVE_TASKS_DEFAULT, MANAGEMENT_MIN_CADENCE_MINUTES_DEFAULT, TYPE_PLURALS, buildEntityPath, entitySchema, entitySourceEntrySchema, formatManagedTaskId, isDomain, isEntityType, isValidManagedTaskId, isValidOutputPath, isValidSlug, managedTaskCreateSchema, managedTaskPatchSchema, managedTaskRunResultSchema, managedTaskSchema, normalizeAppLabel, parseEntityPath, pluralToType, sotBindingSchema, sotBindingsSchema, typeToPlural, validateAppLabel, validateIntent, } from "./management-domains.js";
|
|
33
|
+
export type { Domain, Entity, EntityPathParts, EntitySourceEntry, EntityType, ManagedTask, ManagedTaskCreate, ManagedTaskPatch, ManagedTaskRunResult, SotBinding, SotBindings, } from "./management-domains.js";
|
|
34
|
+
export { BYTE_BUDGET as SKILL_CURATION_BYTE_BUDGET, ConventionNote, ConventionNotesPayload, CrossReference, CrossReferencesPayload, CurationDeclaration, CurationDeclarationSection, CurationPayload, DEFAULT_SKILL_CURATION_CONFIG, FrontmatterConventionalField, FrontmatterFileType, FrontmatterRequiredField, FrontmatterSchemaPayload, KnowledgeLayoutFile, KnowledgeLayoutPayload, KnowledgeLayoutSection, OverlayEnvelope, RoutingTablePayload, RoutingTableRule, SECTION_KINDS, SKILL_CURATION_SCHEMA_VERSION, SearchRecipe, SearchRecipesPayload, SkillCurationConfig, SubmitProposalRequest, ManualRunRequest, DiscardOrphanRequest, } from "./skill-curation/schemas.js";
|
|
35
|
+
export type { ConventionNotesValue, CrossReferencesValue, CurationDeclarationSectionValue, CurationDeclarationValue, CurationPayloadValue, FrontmatterSchemaValue, KnowledgeLayoutValue, OverlayEnvelopeValue, RoutingTableValue, SearchRecipesValue, SectionKind, SkillCurationConfigValue, SubmitProposalRequestValue, ManualRunRequestValue, DiscardOrphanRequestValue, } from "./skill-curation/schemas.js";
|
|
36
|
+
export { containsDecisionLanguage, noDecisionLanguage, noEmbeddedMarkers, DECISION_LANGUAGE_MESSAGE, EMBEDDED_MARKER_MESSAGE, } from "./skill-curation/decision-language.js";
|
|
37
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EACL,YAAY,EACZ,aAAa,EACb,oBAAoB,EACpB,kBAAkB,EAClB,0BAA0B,EAC1B,oBAAoB,EACpB,oBAAoB,EACpB,gBAAgB,GACjB,MAAM,iBAAiB,CAAC;AAGzB,OAAO,EACL,aAAa,EACb,WAAW,EACX,cAAc,EACd,eAAe,EACf,qBAAqB,EACrB,cAAc,EACd,gBAAgB,EAChB,kBAAk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pB,+BAA+B,EAC/B,wBAAwB,EACxB,oBAAoB,EACpB,sBAAsB,EACtB,oBAAoB,EACpB,oBAAoB,EACpB,iBAAiB,EACjB,kBAAkB,EAClB,WAAW,EACX,wBAAwB,EACxB,0BAA0B,EAC1B,qBAAqB,EACrB,yBAAyB,GAC1B,MAAM,6BAA6B,CAAC;AACrC,OAAO,EACL,wBAAwB,EACxB,kBAAkB,EAClB,iBAAiB,EACjB,yBAAyB,EACzB,uBAAuB,GACxB,MAAM,uCAAuC,CAAC"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
// Date utilities
|
|
2
|
+
export { localDateStr, nowInTimezone, getAgentDayBoundsUtc, getAgentDayDateStr, getAgentDayProgressMinutes, nextActiveHoursStart, formatSqliteDatetime, parseSqliteUtcMs, } from "./date-utils.js";
|
|
3
|
+
// Types
|
|
4
|
+
export { EventPriority, createEvent, isMessageEvent, isDocsQAMessage, isCalendarChangeEvent, isRoutineEvent, isAgentTaskEvent, isScheduledDmEvent, isScheduledEvent, isKnowledgeImportEvent, } from "./types.js";
|
|
5
|
+
// Brand identity (single source of truth for product name / role anchor /
|
|
6
|
+
// tagline — substituted into agent-asset markdown and consumed directly
|
|
7
|
+
// by TS imports across daemon + dashboard). See `branding.ts`.
|
|
8
|
+
export { APP_NAME, AGENT_ROLE_DESCRIPTOR, APP_TAGLINE, APP_NAME_WITH_TAGLINE, joinTaglineWithSentence, substituteBrandTokens, } from "./branding.js";
|
|
9
|
+
// Multi-backend shared types
|
|
10
|
+
export { BACKEND_IDS, EXECUTION_PERMISSION_MODES, WEB_SEARCH_CAPABLE_BACKENDS, getBackendIds, isBackendId, } from "./backend.js";
|
|
11
|
+
// Per-backend provider auth config (direct API key / Bedrock / Vertex /
|
|
12
|
+
// Foundry / Codex Azure / Gemini Vertex). See `backend-api-key-config.ts`.
|
|
13
|
+
export { CLAUDE_API_KEY_PROVIDERS, CODEX_API_KEY_PROVIDERS, GEMINI_API_KEY_PROVIDERS, API_KEY_PROVIDERS_BY_BACKEND, RECOMMENDED_PINNED_MODELS_BY_PROVIDER, DEFAULT_AZURE_OPENAI_API_VERSION, defaultApiKeyProvider, isApiKeyProviderForBackend, backendApiKeyConfigSchema, anthropicApiKeyConfigSchema, bedrockApiKeyConfigSchema, vertexApiKeyConfigSchema, foundryApiKeyConfigSchema, openaiApiKeyConfigSchema, azureOpenAiApiKeyConfigSchema, googleApiKeyConfigSchema, buildCodexAzureConfigToml, getManagedApiKeyEnvVars, getApiKeyEnvAssignments, parseBackendApiKeyConfig, serializeBackendApiKeyConfig, validateBackendApiKeyConfigFormat, isPlausibleAnthropicApiKey, isPlausibleOpenAiApiKey, isPlausibleGeminiApiKey, } from "./backend-api-key-config.js";
|
|
14
|
+
// Process-key helpers
|
|
15
|
+
export { CONFIGURABLE_PROCESS_KEYS, DELEGATED_TASK_HARD_CAPS, TIER_LOCKED_PROCESS_KEYS, customRoutineKey, customRoutineSlugFromKey, getDefaultTierForProcessKey, isAutonomousProcessKey, isConfigurableProcessKey, isCustomRoutineKey, isProcessKey, resolveProcessKey, } from "./process-key.js";
|
|
16
|
+
// Schemas
|
|
17
|
+
export { contextPutSchema, contextPatchSchema, notifyRequestSchema, scheduleRequestSchema, scheduleUpdateRequestSchema, scheduleDmRequestSchema, actionLogRequestSchema, skillNameSchema, skillCreateSchema, skillUpdateSchema, calendarCreateEventSchema, calendarUpdateEventSchema, calendarFreeBusySchema, recurrenceRuleSchema, recurringScheduleCreateSchema, recurringScheduleUpdateSchema, triggerCreateSchema, triggerUpdateSchema, } from "./schemas.js";
|
|
18
|
+
// Agent identity helpers
|
|
19
|
+
export { DEFAULT_AGENT_DISPLAY_NAME, normalizeAgentDisplayName, validateAgentDisplayName, formatAgentOutboundLabel, } from "./agent-identity.js";
|
|
20
|
+
// Secret redaction helpers
|
|
21
|
+
export { redactSensitiveString, SENSITIVE_KEY_PATTERN, } from "./secret-redaction.js";
|
|
22
|
+
// Chat sidebar scope list (shared between daemon delete helper and
|
|
23
|
+
// dashboard useConversations filter — must never drift)
|
|
24
|
+
export { CHAT_SIDEBAR_SCOPES, CHAT_SIDEBAR_SCOPE_PARAM, isChatSidebarScope, } from "./chat-session-scope.js";
|
|
25
|
+
// Editable config key definitions (shared between daemon and dashboard)
|
|
26
|
+
export { EDITABLE_RUNTIME_KEY_TUPLE, EDITABLE_BOOTSTRAP_KEY_TUPLE, RESTART_REQUIRED_KEY_TUPLE, } from "./editable-config-keys.js";
|
|
27
|
+
// Integration delegation framework (shared between daemon registry +
|
|
28
|
+
// dashboard cards — single source of truth for mode vocabulary)
|
|
29
|
+
export { INTEGRATION_KEYS, INTEGRATION_MODES, INTEGRATION_DESCRIPTORS, defaultIntegrationsMap, getIntegrationDescriptor, integrationPatchSchema, integrationStateSchema, integrationsMapSchema, isIntegrationKey, isIntegrationMode, listIntegrationDescriptors, selectSkillVariantFile, selectTaskFlowVariantSuffix, delegatedIntegrationsForProcessKey, backendHasIntegrationConnector, validateDeniedTools, filterDeniedToolsForBackend, matchToolPattern, collectSessionDeniedTools, recommendedStarterDeniedTools, destructiveTaskTools, destructiveTaskToolsBare, applyIntegrationModeFilter, INTEGRATION_MODE_PREDICATES, MCP_PATTERN_REGEX, matchRunAllowedToolPattern, validateRunAllowedTool, validateRunAllowedTools, } from "./integrations.js";
|
|
30
|
+
// Integration drift-detection snapshot normalizers
|
|
31
|
+
// (INTEGRATION-DRIFT-DETECTION-PLAN.md §5.2)
|
|
32
|
+
export { INTEGRATION_WRITE_TTL_MS, SNAPSHOT_NORMALIZERS, getSnapshotNormalizer, hasSnapshotNormalizer, listSnapshotNormalizers, stableStringify, } from "./integrations-snapshot.js";
|
|
33
|
+
// Docs & QA frontmatter schema (shared between daemon indexer + dashboard
|
|
34
|
+
// renderer/page-doc-map drift guard — single source of truth)
|
|
35
|
+
export { DOCS_SCHEMA_VERSION, docsFrontmatterSchema, slugifyAnchor, parseCitationTokens, } from "./docs-schema.js";
|
|
36
|
+
export { FrontmatterParseError, parseFrontmatter, } from "./docs-frontmatter.js";
|
|
37
|
+
// Advisor model allowlist (Claude Agent SDK constraint, shared between
|
|
38
|
+
// daemon validators + dashboard dropdown)
|
|
39
|
+
export { ADVISOR_ALLOWED_MODELS, DEFAULT_ADVISOR_MODEL, isAdvisorModel, } from "./advisor-models.js";
|
|
40
|
+
// Management Registry — domain enum, entity-type map, path validators,
|
|
41
|
+
// and Zod schemas. Shared between daemon (api/routes/managed-tasks,
|
|
42
|
+
// core/management-registry, core/entity-mirror), dashboard (Settings →
|
|
43
|
+
// Management page, entity browser), and skill prompts. See
|
|
44
|
+
// `docs/design/21-management-registry-and-entities.md`.
|
|
45
|
+
export { APP_MAX_LENGTH, DOMAINS, ENTITY_TYPES, INTENT_MAX_LENGTH, LAST_RESULT_MAX_LENGTH, MANAGEMENT_ACTIVE_TASKS_SOFT_WARNING, MANAGEMENT_FAILURE_NOTIFY_THRESHOLD_DEFAULT, MANAGEMENT_MAX_ACTIVE_TASKS_DEFAULT, MANAGEMENT_MIN_CADENCE_MINUTES_DEFAULT, TYPE_PLURALS, buildEntityPath, entitySchema, entitySourceEntrySchema, formatManagedTaskId, isDomain, isEntityType, isValidManagedTaskId, isValidOutputPath, isValidSlug, managedTaskCreateSchema, managedTaskPatchSchema, managedTaskRunResultSchema, managedTaskSchema, normalizeAppLabel, parseEntityPath, pluralToType, sotBindingSchema, sotBindingsSchema, typeToPlural, validateAppLabel, validateIntent, } from "./management-domains.js";
|
|
46
|
+
// Skill-curation typed payloads (P22 §1.4) — appendix p22-skill-self-optimization.md.
|
|
47
|
+
export { BYTE_BUDGET as SKILL_CURATION_BYTE_BUDGET, ConventionNote, ConventionNotesPayload, CrossReference, CrossReferencesPayload, CurationDeclaration, CurationDeclarationSection, CurationPayload, DEFAULT_SKILL_CURATION_CONFIG, FrontmatterConventionalField, FrontmatterFileType, FrontmatterRequiredField, FrontmatterSchemaPayload, KnowledgeLayoutFile, KnowledgeLayoutPayload, KnowledgeLayoutSection, OverlayEnvelope, RoutingTablePayload, RoutingTableRule, SECTION_KINDS, SKILL_CURATION_SCHEMA_VERSION, SearchRecipe, SearchRecipesPayload, SkillCurationConfig, SubmitProposalRequest, ManualRunRequest, DiscardOrphanRequest, } from "./skill-curation/schemas.js";
|
|
48
|
+
export { containsDecisionLanguage, noDecisionLanguage, noEmbeddedMarkers, DECISION_LANGUAGE_MESSAGE, EMBEDDED_MARKER_MESSAGE, } from "./skill-curation/decision-language.js";
|
|
49
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,iBAAiB;AACjB,OAAO,EACL,YAAY,EACZ,aAAa,EACb,oBAAoB,EACpB,kBAAkB,EAClB,0BAA0B,EAC1B,oBAAoB,EACpB,oBAAoB,EACpB,gBAAgB,GACjB,MAAM,iBAAiB,CAAC;AAEzB,QAAQ;AACR,OAAO,EACL,aAAa,EACb,WAAW,EACX,cAAc,EACd,eAAe,EACf,qBAAqB,EACrB,cAAc,EACd,gBAAgB,EAChB,kBAAkB,EAClB,gBAAgB,EAChB,sBAAsB,GACvB,MAAM,YAAY,CAAC;AAgBpB,0EAA0E;AAC1E,wEAAwE;AACxE,+DAA+D;AAC/D,OAAO,EACL,QAAQ,EACR,qBAAqB,EACrB,WAAW,EACX,qBAAqB,EACrB,uBAAuB,EACvB,qBAAqB,GACtB,MAAM,eAAe,CAAC;AAEvB,6BAA6B;AAC7B,OAAO,EACL,WAAW,EACX,0BAA0B,EAC1B,2BAA2B,EAC3B,aAAa,EACb,WAAW,GACZ,MAAM,cAAc,CAAC;AAUtB,wEAAwE;AACxE,2EAA2E;AAC3E,OAAO,EACL,wBAAwB,EACxB,uBAAuB,EACvB,wBAAwB,EACxB,4BAA4B,EAC5B,qCAAqC,EACrC,gCAAgC,EAChC,qBAAqB,EACrB,0BAA0B,EAC1B,yBAAyB,EACzB,2BAA2B,EAC3B,yBAAyB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AA0B,EAC1B,iBAAiB,EACjB,iBAAiB,EACjB,eAAe,EACf,YAAY,EACZ,gBAAgB,EAChB,iBAAiB,EACjB,YAAY,EACZ,gBAAgB,EAChB,cAAc,GACf,MAAM,yBAAyB,CAAC;AAejC,sFAAsF;AACtF,OAAO,EACL,WAAW,IAAI,0BAA0B,EACzC,cAAc,EACd,sBAAsB,EACtB,cAAc,EACd,sBAAsB,EACtB,mBAAmB,EACnB,0BAA0B,EAC1B,eAAe,EACf,6BAA6B,EAC7B,4BAA4B,EAC5B,mBAAmB,EACnB,wBAAwB,EACxB,wBAAwB,EACxB,mBAAmB,EACnB,sBAAsB,EACtB,sBAAsB,EACtB,eAAe,EACf,mBAAmB,EACnB,gBAAgB,EAChB,aAAa,EACb,6BAA6B,EAC7B,YAAY,EACZ,oBAAoB,EACpB,mBAAmB,EACnB,qBAAqB,EACrB,gBAAgB,EAChB,oBAAoB,GACrB,MAAM,6BAA6B,CAAC;AAkBrC,OAAO,EACL,wBAAwB,EACxB,kBAAkB,EAClB,iBAAiB,EACjB,yBAAyB,EACzB,uBAAuB,GACxB,MAAM,uCAAuC,CAAC"}
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
import { type IntegrationKey } from "./integrations.js";
|
|
2
|
+
/**
|
|
3
|
+
* Snapshot normalizers for `integration_snapshots` reconcile pipeline.
|
|
4
|
+
*
|
|
5
|
+
* Per INTEGRATION-DRIFT-DETECTION-PLAN.md §5.2: each integration ships a
|
|
6
|
+
* pure normalizer that turns a raw upstream payload into the canonical
|
|
7
|
+
* shape stored in `integration_snapshots.payload_json`, plus a stable
|
|
8
|
+
* sha256 over a sorted JSON encoding of that shape used for diff
|
|
9
|
+
* comparison. The normalizer is shared between the daemon (CalendarPoller,
|
|
10
|
+
* DelegatedSyncWorker, reconcile route) and the LLM-driven hourly check
|
|
11
|
+
* path so behaviour is identical regardless of who writes the snapshot.
|
|
12
|
+
*
|
|
13
|
+
* Phase 1 shipped the calendar normalizer; Phase 5 adds Gmail thread and
|
|
14
|
+
* Notion page normalizers. The registry stays `Partial` so a future
|
|
15
|
+
* integration can land its connector wiring before its normalizer (route
|
|
16
|
+
* handlers continue returning a structured 400 in that gap).
|
|
17
|
+
*/
|
|
18
|
+
/**
|
|
19
|
+
* Actor pre-mark a reconcile caller can attach per-item. Mirrors the
|
|
20
|
+
* `observations.actor` column / `integration_snapshots.actor_hint` CHECK
|
|
21
|
+
* constraint vocabulary so a hint flows straight through to either column
|
|
22
|
+
* without translation. Reconcile still consults `integration_writes` as the
|
|
23
|
+
* authoritative source — this is only the fallback.
|
|
24
|
+
*/
|
|
25
|
+
export type SnapshotActorHint = "user" | "agent" | "system" | "unknown";
|
|
26
|
+
/**
|
|
27
|
+
* Default TTL for `integration_writes` entries, per integration.
|
|
28
|
+
*
|
|
29
|
+
* INTEGRATION-DRIFT-DETECTION-PLAN.md §17.11 requires `TTL ≥ slowest_cadence
|
|
30
|
+
* × 1.5` so an agent-originated write at T0 cannot have its attribution
|
|
31
|
+
* mark expire before the next reconcile sees it as a user write. Phase 7
|
|
32
|
+
* (c) tightens these constants to cover the §8.3 default cadences with
|
|
33
|
+
* margin:
|
|
34
|
+
*
|
|
35
|
+
* - google_calendar: slowest cadence is the 24h-window default (60 min)
|
|
36
|
+
* → 60 × 1.5 = 90 min. The 10-min imminent cadence is irrelevant for
|
|
37
|
+
* TTL because an agent-originated event always lands inside the 24h
|
|
38
|
+
* window first; the slowest cadence governs the contract.
|
|
39
|
+
* - gmail: 30 min default → 45 min. The 15-min soft floor gives the
|
|
40
|
+
* same TTL margin if the operator presses cadence to its minimum.
|
|
41
|
+
* - notion: 60 min default → 90 min. Pre-Phase-7 this was 30 min, which
|
|
42
|
+
* left the agent's own page edits at risk of mis-attribution on the
|
|
43
|
+
* very next worker tick.
|
|
44
|
+
*
|
|
45
|
+
* Operators who push a cadence past the corresponding TTL via
|
|
46
|
+
* `runtime_state.delegatedSync.intervals` opt into the pre-fix regime.
|
|
47
|
+
* The DelegatedSyncWorker logs warn at start and surfaces the violation
|
|
48
|
+
* via `getStatus().ttlContractViolations` so the breach is observable
|
|
49
|
+
* rather than silent.
|
|
50
|
+
*/
|
|
51
|
+
export declare const INTEGRATION_WRITE_TTL_MS: Readonly<Record<IntegrationKey, number>>;
|
|
52
|
+
export interface IntegrationNormalizer<TRaw = unknown, TPayload = unknown> {
|
|
53
|
+
/** Stable identifier within `(integration, window_key)`. */
|
|
54
|
+
itemId(raw: TRaw): string;
|
|
55
|
+
/** Canonical, fully-sorted payload stored in `payload_json`. */
|
|
56
|
+
payload(raw: TRaw): TPayload;
|
|
57
|
+
/** sha256 hex digest of a stable JSON encoding of the canonical payload. */
|
|
58
|
+
hash(payload: TPayload): string;
|
|
59
|
+
/** ISO-8601 start time, or `null` when the integration has no scheduled
|
|
60
|
+
* start (Gmail/Notion). Calendar uses this to feed the imminent-event
|
|
61
|
+
* scheduler index. */
|
|
62
|
+
itemStart(raw: TRaw): string | null;
|
|
63
|
+
/**
|
|
64
|
+
* §5.1 sliding-window predicate. Returns true if the (already-normalized)
|
|
65
|
+
* payload's time field falls within `[windowMin, windowMax)`. Reconcile
|
|
66
|
+
* uses this to distinguish a prior row that simply slid out of the
|
|
67
|
+
* window (silent prune, no observation emitted) from one that was truly
|
|
68
|
+
* deleted upstream (observation emitted). The predicate is per-integration
|
|
69
|
+
* because each integration's "time field" lives at a different path
|
|
70
|
+
* (calendar.start, gmail.internalDate, notion.lastEditedTime).
|
|
71
|
+
*/
|
|
72
|
+
inWindow(payload: TPayload, windowMin: string, windowMax: string): boolean;
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Canonical calendar snapshot payload. Field order in the type does not
|
|
76
|
+
* affect the hash — `stableStringify` sorts keys at every level — but the
|
|
77
|
+
* order documents the intent: identity-shaping fields first, then mutable
|
|
78
|
+
* detail. `htmlLink` is included because it lets the agent render a deep
|
|
79
|
+
* link without re-fetching, but it is excluded from the hash (it is purely
|
|
80
|
+
* derivable from the event id).
|
|
81
|
+
*/
|
|
82
|
+
export interface CalendarSnapshotPayload {
|
|
83
|
+
summary: string | null;
|
|
84
|
+
start: string | null;
|
|
85
|
+
end: string | null;
|
|
86
|
+
location: string | null;
|
|
87
|
+
description: string | null;
|
|
88
|
+
status: string | null;
|
|
89
|
+
/** Sorted by email so attendee-order jitter does not flap the hash. */
|
|
90
|
+
attendees: Array<{
|
|
91
|
+
email: string;
|
|
92
|
+
responseStatus: string;
|
|
93
|
+
}>;
|
|
94
|
+
/** Display-only, excluded from hash. */
|
|
95
|
+
htmlLink: string | null;
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* Lexicographic-key JSON encoder. Drop-in replacement for JSON.stringify
|
|
99
|
+
* that walks objects with a sorted key list at every level so two
|
|
100
|
+
* structurally-equal payloads always serialize identically. Arrays
|
|
101
|
+
* preserve order — the calendar normalizer pre-sorts attendees so
|
|
102
|
+
* `[{email:"a"}, {email:"b"}]` and `[{email:"b"}, {email:"a"}]` are
|
|
103
|
+
* distinct payloads pre-normalize but identical post-normalize.
|
|
104
|
+
*/
|
|
105
|
+
export declare function stableStringify(value: unknown): string;
|
|
106
|
+
/**
|
|
107
|
+
* Canonical Gmail thread snapshot payload. The shape is granularity-thread
|
|
108
|
+
* (per §15.4): `messageIds` lets reconcile detect a new message landing in an
|
|
109
|
+
* already-seen thread (length growth → hash differs → `modified` diff).
|
|
110
|
+
*
|
|
111
|
+
* `snippet` is intentionally display-only (excluded from the hash) — Gmail
|
|
112
|
+
* regenerates snippets server-side and an unrelated rewrite would otherwise
|
|
113
|
+
* flap the hash on every poll (§17.10). `from` is canonicalised to a
|
|
114
|
+
* lowercase email-only string so the hash is stable across `"Name <email>"`
|
|
115
|
+
* vs. `{ name, email }` connector representations and across capitalisation
|
|
116
|
+
* jitter.
|
|
117
|
+
*/
|
|
118
|
+
export interface GmailSnapshotPayload {
|
|
119
|
+
threadId: string;
|
|
120
|
+
subject: string | null;
|
|
121
|
+
/** Canonical lowercase email of the most recent sender. */
|
|
122
|
+
from: string | null;
|
|
123
|
+
/** Sorted ascending. */
|
|
124
|
+
labelIds: string[];
|
|
125
|
+
/** Sorted ascending. */
|
|
126
|
+
messageIds: string[];
|
|
127
|
+
/** ISO-8601 of the latest message's `internalDate`, when known. */
|
|
128
|
+
lastMessageInternalDate: string | null;
|
|
129
|
+
/** Display-only, excluded from the hash. */
|
|
130
|
+
snippet: string | null;
|
|
131
|
+
}
|
|
132
|
+
/**
|
|
133
|
+
* Canonical Notion page snapshot payload. Hash discipline (§17.9):
|
|
134
|
+
*
|
|
135
|
+
* - `title`, `lastEditedTime`, `parentDatabase` — page identity.
|
|
136
|
+
* - `propertiesSummaryHash` — sha256 over a canonical projection of the
|
|
137
|
+
* page's properties. Property types Notion knows about have stable
|
|
138
|
+
* value-shape extractors below; unknown types fall through to a
|
|
139
|
+
* conservative "type-tag only" projection so a new property shape does
|
|
140
|
+
* not silently flap the hash forever — the `propertiesSummary` display
|
|
141
|
+
* string still reflects the values, just not the hash.
|
|
142
|
+
* - `relationsHash` — sha256 over sorted relation-target ids per relation
|
|
143
|
+
* property. Separated so a future framework upgrade can promote
|
|
144
|
+
* relation changes to a first-class diff cause without re-versioning
|
|
145
|
+
* the page hash.
|
|
146
|
+
*
|
|
147
|
+
* Notion bumps `last_edited_time` whenever any property or block changes,
|
|
148
|
+
* so the conservative path (just `lastEditedTime` + `parentDatabase` +
|
|
149
|
+
* `title`) catches every meaningful diff. The properties hash is what
|
|
150
|
+
* lets the agent reason "what specifically changed" from the diff entry.
|
|
151
|
+
*/
|
|
152
|
+
export interface NotionSnapshotPayload {
|
|
153
|
+
pageId: string;
|
|
154
|
+
title: string | null;
|
|
155
|
+
lastEditedTime: string | null;
|
|
156
|
+
parentDatabase: string | null;
|
|
157
|
+
url: string | null;
|
|
158
|
+
inTrash: boolean;
|
|
159
|
+
/** Display-only summary string (status / select / date highlights), excluded from the hash. */
|
|
160
|
+
propertiesSummary: string | null;
|
|
161
|
+
/** sha256 hex of `{ [propName]: canonical-value-shape }` (sorted keys). */
|
|
162
|
+
propertiesSummaryHash: string;
|
|
163
|
+
/** sha256 hex of `{ [propName]: sorted-relation-id-array }` (sorted keys). */
|
|
164
|
+
relationsHash: string;
|
|
165
|
+
}
|
|
166
|
+
/**
|
|
167
|
+
* Normalizer registry. Phase 5 ships gmail and notion alongside calendar.
|
|
168
|
+
* Adding a future integration is one Record entry — the route handler
|
|
169
|
+
* reads via `getSnapshotNormalizer(key)` and stays integration-key-driven.
|
|
170
|
+
*/
|
|
171
|
+
export declare const SNAPSHOT_NORMALIZERS: Readonly<Partial<Record<IntegrationKey, IntegrationNormalizer>>>;
|
|
172
|
+
/** True if the integration has a Phase-1 normalizer registered. Used by
|
|
173
|
+
* the reconcile route to fail fast with a precise error message before
|
|
174
|
+
* parsing items. */
|
|
175
|
+
export declare function hasSnapshotNormalizer(key: IntegrationKey): boolean;
|
|
176
|
+
/** List the integrations currently registered with a normalizer. Drives
|
|
177
|
+
* the `supportedIntegrations` field in error responses so a caller sees
|
|
178
|
+
* the contract without grepping the source. */
|
|
179
|
+
export declare function listSnapshotNormalizers(): IntegrationKey[];
|
|
180
|
+
/** Fetch the normalizer for an integration. Returns `undefined` for
|
|
181
|
+
* unsupported integrations so the caller can return a structured 400. */
|
|
182
|
+
export declare function getSnapshotNormalizer(key: IntegrationKey): IntegrationNormalizer | undefined;
|
|
183
|
+
//# sourceMappingURL=integrations-snapshot.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"integrations-snapshot.d.ts","sourceRoot":"","sources":["../src/integrations-snapshot.ts"],"names":[],"mappings":"AACA,OAAO,EAAoB,KAAK,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAE1E;;;;;;;;;;;;;;;GAeG;AAEH;;;;;;GAMG;AACH,MAAM,MAAM,iBAAiB,GAAG,MAAM,GAAG,OAAO,GAAG,QAAQ,GAAG,SAAS,CAAC;AAExE;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAC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