@pellux/goodvibes-sdk 0.33.38 → 0.34.1
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/contracts/artifacts/operator-contract.json +1383 -4
- package/dist/events/workflows.d.ts +4 -0
- package/dist/events/workflows.d.ts.map +1 -1
- package/dist/platform/agents/message-bus-core.d.ts +11 -0
- package/dist/platform/agents/message-bus-core.d.ts.map +1 -1
- package/dist/platform/agents/message-bus-core.js +28 -21
- package/dist/platform/agents/orchestrator-runner.d.ts.map +1 -1
- package/dist/platform/agents/orchestrator-runner.js +6 -4
- package/dist/platform/agents/wrfc-config.d.ts.map +1 -1
- package/dist/platform/agents/wrfc-config.js +16 -10
- package/dist/platform/agents/wrfc-controller.d.ts +26 -0
- package/dist/platform/agents/wrfc-controller.d.ts.map +1 -1
- package/dist/platform/agents/wrfc-controller.js +134 -138
- package/dist/platform/agents/wrfc-runtime-events.d.ts +1 -0
- package/dist/platform/agents/wrfc-runtime-events.d.ts.map +1 -1
- package/dist/platform/agents/wrfc-runtime-events.js +4 -1
- package/dist/platform/automation/delivery-manager.d.ts.map +1 -1
- package/dist/platform/automation/delivery-manager.js +1 -6
- package/dist/platform/batch/manager.d.ts.map +1 -1
- package/dist/platform/batch/manager.js +1 -3
- package/dist/platform/channels/policy-manager.d.ts.map +1 -1
- package/dist/platform/channels/policy-manager.js +1 -3
- package/dist/platform/channels/reply-pipeline.d.ts.map +1 -1
- package/dist/platform/channels/reply-pipeline.js +4 -0
- package/dist/platform/config/schema-domain-core.d.ts +1 -1
- package/dist/platform/config/schema-domain-core.d.ts.map +1 -1
- package/dist/platform/config/schema-domain-core.js +12 -12
- package/dist/platform/config/schema-domain-runtime.d.ts +1 -1
- package/dist/platform/config/schema-domain-runtime.d.ts.map +1 -1
- package/dist/platform/config/schema-domain-runtime.js +19 -18
- package/dist/platform/config/schema-domain-surfaces.d.ts +1 -1
- package/dist/platform/config/schema-domain-surfaces.d.ts.map +1 -1
- package/dist/platform/config/schema-domain-surfaces.js +4 -3
- package/dist/platform/config/schema-shared.d.ts +6 -0
- package/dist/platform/config/schema-shared.d.ts.map +1 -1
- package/dist/platform/config/schema-shared.js +21 -1
- package/dist/platform/control-plane/approval-broker.d.ts.map +1 -1
- package/dist/platform/control-plane/approval-broker.js +1 -3
- package/dist/platform/control-plane/method-catalog-calendar.d.ts +9 -0
- package/dist/platform/control-plane/method-catalog-calendar.d.ts.map +1 -0
- package/dist/platform/control-plane/method-catalog-calendar.js +117 -0
- package/dist/platform/control-plane/method-catalog-channels.d.ts.map +1 -1
- package/dist/platform/control-plane/method-catalog-channels.js +174 -0
- package/dist/platform/control-plane/method-catalog-email.d.ts +9 -0
- package/dist/platform/control-plane/method-catalog-email.d.ts.map +1 -0
- package/dist/platform/control-plane/method-catalog-email.js +101 -0
- package/dist/platform/control-plane/method-catalog.d.ts.map +1 -1
- package/dist/platform/control-plane/method-catalog.js +4 -0
- package/dist/platform/control-plane/session-broker-state.d.ts.map +1 -1
- package/dist/platform/control-plane/session-broker-state.js +1 -3
- package/dist/platform/core/compaction-sections.d.ts +5 -1
- package/dist/platform/core/compaction-sections.d.ts.map +1 -1
- package/dist/platform/core/compaction-sections.js +73 -66
- package/dist/platform/core/context-compaction.d.ts.map +1 -1
- package/dist/platform/core/context-compaction.js +9 -16
- package/dist/platform/core/orchestrator-context-runtime.d.ts +2 -2
- package/dist/platform/core/orchestrator-context-runtime.d.ts.map +1 -1
- package/dist/platform/core/orchestrator-context-runtime.js +24 -21
- package/dist/platform/core/orchestrator-tool-runtime.d.ts.map +1 -1
- package/dist/platform/core/orchestrator-tool-runtime.js +2 -1
- package/dist/platform/core/session-lineage.d.ts +2 -5
- package/dist/platform/core/session-lineage.d.ts.map +1 -1
- package/dist/platform/core/session-lineage.js +4 -16
- package/dist/platform/core/wrfc-routing.d.ts.map +1 -1
- package/dist/platform/core/wrfc-routing.js +1 -3
- package/dist/platform/daemon/http/mcp-routes.d.ts.map +1 -1
- package/dist/platform/daemon/http/mcp-routes.js +1 -3
- package/dist/platform/daemon/http/openai-compatible-routes.d.ts.map +1 -1
- package/dist/platform/daemon/http/openai-compatible-routes.js +1 -3
- package/dist/platform/daemon/http/runtime-routes.d.ts.map +1 -1
- package/dist/platform/daemon/http/runtime-routes.js +1 -3
- package/dist/platform/hooks/runners/http.d.ts.map +1 -1
- package/dist/platform/hooks/runners/http.js +9 -19
- package/dist/platform/integrations/webhooks.js +2 -11
- package/dist/platform/knowledge/semantic/self-improvement.d.ts.map +1 -1
- package/dist/platform/knowledge/semantic/self-improvement.js +2 -21
- package/dist/platform/mcp/client.d.ts.map +1 -1
- package/dist/platform/mcp/client.js +1 -3
- package/dist/platform/mcp/config.d.ts.map +1 -1
- package/dist/platform/mcp/config.js +1 -3
- package/dist/platform/media/builtin-generation-providers.d.ts.map +1 -1
- package/dist/platform/media/builtin-generation-providers.js +1 -6
- package/dist/platform/providers/anthropic-compat.d.ts.map +1 -1
- package/dist/platform/providers/anthropic-compat.js +11 -131
- package/dist/platform/providers/anthropic-sdk-provider.d.ts.map +1 -1
- package/dist/platform/providers/anthropic-sdk-provider.js +8 -42
- package/dist/platform/providers/anthropic-sse-assembler.d.ts +80 -0
- package/dist/platform/providers/anthropic-sse-assembler.d.ts.map +1 -0
- package/dist/platform/providers/anthropic-sse-assembler.js +146 -0
- package/dist/platform/providers/anthropic-stream.d.ts +30 -0
- package/dist/platform/providers/anthropic-stream.d.ts.map +1 -0
- package/dist/platform/providers/anthropic-stream.js +44 -0
- package/dist/platform/providers/anthropic-vertex.d.ts.map +1 -1
- package/dist/platform/providers/anthropic-vertex.js +1 -3
- package/dist/platform/providers/anthropic.d.ts.map +1 -1
- package/dist/platform/providers/anthropic.js +15 -151
- package/dist/platform/providers/capabilities.d.ts.map +1 -1
- package/dist/platform/providers/capabilities.js +11 -7
- package/dist/platform/providers/context-discovery.d.ts.map +1 -1
- package/dist/platform/providers/context-discovery.js +9 -16
- package/dist/platform/providers/context-window-fallback.d.ts +24 -0
- package/dist/platform/providers/context-window-fallback.d.ts.map +1 -0
- package/dist/platform/providers/context-window-fallback.js +48 -0
- package/dist/platform/providers/gemini.d.ts.map +1 -1
- package/dist/platform/providers/gemini.js +3 -6
- package/dist/platform/providers/json-ttl-cache.d.ts +35 -0
- package/dist/platform/providers/json-ttl-cache.d.ts.map +1 -0
- package/dist/platform/providers/json-ttl-cache.js +52 -0
- package/dist/platform/providers/llama-cpp.d.ts.map +1 -1
- package/dist/platform/providers/llama-cpp.js +2 -23
- package/dist/platform/providers/lm-studio-helpers.d.ts +1 -1
- package/dist/platform/providers/lm-studio-helpers.d.ts.map +1 -1
- package/dist/platform/providers/lm-studio-helpers.js +5 -25
- package/dist/platform/providers/model-benchmarks.d.ts.map +1 -1
- package/dist/platform/providers/model-benchmarks.js +11 -34
- package/dist/platform/providers/model-catalog-cache.d.ts.map +1 -1
- package/dist/platform/providers/model-catalog-cache.js +15 -38
- package/dist/platform/providers/model-catalog-synthetic.d.ts.map +1 -1
- package/dist/platform/providers/model-catalog-synthetic.js +3 -2
- package/dist/platform/providers/model-catalog.d.ts.map +1 -1
- package/dist/platform/providers/model-catalog.js +3 -2
- package/dist/platform/providers/model-limits.d.ts.map +1 -1
- package/dist/platform/providers/model-limits.js +18 -42
- package/dist/platform/providers/ollama.d.ts.map +1 -1
- package/dist/platform/providers/ollama.js +3 -24
- package/dist/platform/providers/openai-codex.d.ts.map +1 -1
- package/dist/platform/providers/openai-codex.js +8 -9
- package/dist/platform/providers/openai-compat.d.ts.map +1 -1
- package/dist/platform/providers/openai-compat.js +13 -40
- package/dist/platform/providers/openai-stream-helpers.d.ts +62 -0
- package/dist/platform/providers/openai-stream-helpers.d.ts.map +1 -0
- package/dist/platform/providers/openai-stream-helpers.js +73 -0
- package/dist/platform/providers/openai.d.ts.map +1 -1
- package/dist/platform/providers/openai.js +13 -41
- package/dist/platform/providers/provider-error.d.ts +17 -0
- package/dist/platform/providers/provider-error.d.ts.map +1 -0
- package/dist/platform/providers/provider-error.js +33 -0
- package/dist/platform/providers/provider-stop-reason.d.ts +15 -0
- package/dist/platform/providers/provider-stop-reason.d.ts.map +1 -0
- package/dist/platform/providers/provider-stop-reason.js +15 -0
- package/dist/platform/providers/sse-line-buffer.d.ts +13 -0
- package/dist/platform/providers/sse-line-buffer.d.ts.map +1 -0
- package/dist/platform/providers/sse-line-buffer.js +23 -0
- package/dist/platform/providers/tool-formats.d.ts +5 -0
- package/dist/platform/providers/tool-formats.d.ts.map +1 -1
- package/dist/platform/providers/tool-formats.js +14 -0
- package/dist/platform/runtime/bootstrap-runtime-events.d.ts.map +1 -1
- package/dist/platform/runtime/bootstrap-runtime-events.js +6 -0
- package/dist/platform/runtime/bootstrap-services.d.ts.map +1 -1
- package/dist/platform/runtime/bootstrap-services.js +4 -5
- package/dist/platform/runtime/emitters/workflows.d.ts +4 -0
- package/dist/platform/runtime/emitters/workflows.d.ts.map +1 -1
- package/dist/platform/runtime/emitters/workflows.js +3 -0
- package/dist/platform/runtime/remote/distributed-runtime-store.d.ts.map +1 -1
- package/dist/platform/runtime/remote/distributed-runtime-store.js +1 -3
- package/dist/platform/runtime/retention/pruner.js +2 -5
- package/dist/platform/runtime/store/helpers/reducers/lifecycle.d.ts.map +1 -1
- package/dist/platform/runtime/store/helpers/reducers/lifecycle.js +15 -14
- package/dist/platform/runtime/store/helpers/reducers/shared.d.ts +6 -0
- package/dist/platform/runtime/store/helpers/reducers/shared.d.ts.map +1 -1
- package/dist/platform/runtime/store/helpers/reducers/shared.js +8 -1
- package/dist/platform/runtime/telemetry/exporters/queue.d.ts.map +1 -1
- package/dist/platform/runtime/telemetry/exporters/queue.js +1 -7
- package/dist/platform/runtime/transports/http-helpers.d.ts +0 -1
- package/dist/platform/runtime/transports/http-helpers.d.ts.map +1 -1
- package/dist/platform/runtime/transports/http-helpers.js +1 -3
- package/dist/platform/runtime/ui-read-model-helpers.d.ts +2 -0
- package/dist/platform/runtime/ui-read-model-helpers.d.ts.map +1 -1
- package/dist/platform/runtime/ui-read-model-helpers.js +8 -0
- package/dist/platform/runtime/ui-read-models-core.d.ts.map +1 -1
- package/dist/platform/runtime/ui-read-models-core.js +3 -5
- package/dist/platform/runtime/ui-read-models-observability-remote.d.ts.map +1 -1
- package/dist/platform/runtime/ui-read-models-observability-remote.js +2 -4
- package/dist/platform/runtime/ui-read-models-operations.d.ts.map +1 -1
- package/dist/platform/runtime/ui-read-models-operations.js +8 -26
- package/dist/platform/scheduler/scheduler.d.ts.map +1 -1
- package/dist/platform/scheduler/scheduler.js +1 -3
- package/dist/platform/tools/exec/runtime.d.ts.map +1 -1
- package/dist/platform/tools/exec/runtime.js +1 -7
- package/dist/platform/tools/fetch/runtime.d.ts.map +1 -1
- package/dist/platform/tools/fetch/runtime.js +9 -20
- package/dist/platform/tools/shared/process-manager.d.ts.map +1 -1
- package/dist/platform/tools/shared/process-manager.js +1 -6
- package/dist/platform/utils/concurrency.d.ts +1 -0
- package/dist/platform/utils/concurrency.d.ts.map +1 -1
- package/dist/platform/utils/concurrency.js +1 -0
- package/dist/platform/utils/error-display.d.ts +9 -0
- package/dist/platform/utils/error-display.d.ts.map +1 -1
- package/dist/platform/utils/error-display.js +11 -0
- package/dist/platform/utils/fetch-with-timeout.d.ts +22 -2
- package/dist/platform/utils/fetch-with-timeout.d.ts.map +1 -1
- package/dist/platform/utils/fetch-with-timeout.js +33 -15
- package/dist/platform/utils/record-coerce.d.ts +5 -0
- package/dist/platform/utils/record-coerce.d.ts.map +1 -1
- package/dist/platform/utils/record-coerce.js +7 -0
- package/dist/platform/utils/retry.d.ts.map +1 -1
- package/dist/platform/utils/retry.js +2 -4
- package/dist/platform/version.js +1 -1
- package/package.json +9 -9
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { randomUUID } from 'node:crypto';
|
|
2
2
|
import { PersistentStore } from '../state/persistent-store.js';
|
|
3
|
+
import { isRecord } from '../utils/record-coerce.js';
|
|
3
4
|
const MAX_AUDIT_RECORDS = 500;
|
|
4
5
|
function defaultPolicy(surface) {
|
|
5
6
|
return {
|
|
@@ -52,9 +53,6 @@ function commandAllowed(command, allowedCommands) {
|
|
|
52
53
|
}
|
|
53
54
|
const CONVERSATION_POLICIES = new Set(['allow', 'deny', 'inherit']);
|
|
54
55
|
const CONVERSATION_KINDS = new Set(['direct', 'group', 'channel', 'thread', 'service']);
|
|
55
|
-
function isRecord(value) {
|
|
56
|
-
return typeof value === 'object' && value !== null && !Array.isArray(value);
|
|
57
|
-
}
|
|
58
56
|
function isFiniteNumber(value) {
|
|
59
57
|
return typeof value === 'number' && Number.isFinite(value);
|
|
60
58
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reply-pipeline.d.ts","sourceRoot":"","sources":["../../../src/platform/channels/reply-pipeline.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,oBAAoB,EAAE,eAAe,EAAiB,MAAM,4BAA4B,CAAC;AACxH,OAAO,KAAK,EACV,kBAAkB,EAIlB,mBAAmB,EAEnB,cAAc,EACf,MAAM,YAAY,CAAC;AACpB,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,sBAAsB,CAAC;AAClE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AAO9D,MAAM,WAAW,mBAAmB;IAClC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,WAAW,EAAE,cAAc,CAAC;IACrC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACxC,QAAQ,CAAC,eAAe,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC9C,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACxC,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,SAAS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GAAG,OAAO,CAAC,mBAAmB,GAAG,IAAI,CAAC;IAe3G,YAAY,CAChB,OAAO,EAAE,MAAM,EACf,YAAY,EAAE,MAAM,EACpB,OAAO,GAAE;QAAE,QAAQ,CAAC,YAAY,CAAC,EAAE,OAAO,CAAA;KAAO,GAChD,OAAO,CAAC,mBAAmB,GAAG,IAAI,CAAC;YA0BxB,cAAc;YAiDd,sBAAsB;IAsCpC,OAAO,CAAC,sBAAsB;IAmB9B,OAAO,CAAC,0BAA0B;IAgBlC,OAAO,CAAC,sBAAsB;YAahB,aAAa;YAIb,QAAQ;IA0CtB,OAAO,CAAC,oBAAoB;CAK7B"}
|
|
@@ -358,6 +358,10 @@ export function normalizeChannelRenderEventFromRuntime(envelope) {
|
|
|
358
358
|
return [renderEvent('status', 'progress', envelope, {
|
|
359
359
|
text: `WRFC changes committed${payload.commitHash ? `: ${payload.commitHash}` : ''}`,
|
|
360
360
|
})];
|
|
361
|
+
case 'WORKFLOW_SCORE_REGRESSION':
|
|
362
|
+
return [renderEvent('status', 'progress', envelope, {
|
|
363
|
+
text: `WRFC score regression warning: ${payload.reason}`,
|
|
364
|
+
})];
|
|
361
365
|
case 'WORKFLOW_CASCADE_ABORTED':
|
|
362
366
|
return [renderEvent('error', 'progress', envelope, {
|
|
363
367
|
text: `WRFC cascade warning: ${payload.reason}`,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema-domain-core.d.ts","sourceRoot":"","sources":["../../../src/platform/config/schema-domain-core.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"schema-domain-core.d.ts","sourceRoot":"","sources":["../../../src/platform/config/schema-domain-core.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,uBAAuB,EAA4B,MAAM,oBAAoB,CAAC;AAE5F,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+H9B,CAAC;AAEF,eAAO,MAAM,sBAAsB,EAAE,uBAAuB,EA8Z3D,CAAC;AAEF,eAAO,MAAM,sBAAsB,EAAE,uBAAuB,EAsI3D,CAAC"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { intRange, numRange, port } from './schema-shared.js';
|
|
1
2
|
export const coreConfigDefaults = {
|
|
2
3
|
display: {
|
|
3
4
|
stream: true,
|
|
@@ -145,7 +146,7 @@ export const coreHeadConfigSettings = [
|
|
|
145
146
|
type: 'number',
|
|
146
147
|
default: 30,
|
|
147
148
|
description: 'Line count threshold for collapsing tool output',
|
|
148
|
-
|
|
149
|
+
...numRange(1, 1000),
|
|
149
150
|
},
|
|
150
151
|
{
|
|
151
152
|
key: 'display.theme',
|
|
@@ -219,7 +220,7 @@ export const coreHeadConfigSettings = [
|
|
|
219
220
|
type: 'number',
|
|
220
221
|
default: 80,
|
|
221
222
|
description: 'Compact conversation when context usage exceeds this percentage',
|
|
222
|
-
|
|
223
|
+
...numRange(10, 100),
|
|
223
224
|
},
|
|
224
225
|
{
|
|
225
226
|
key: 'behavior.staleContextWarnings',
|
|
@@ -265,7 +266,7 @@ export const coreHeadConfigSettings = [
|
|
|
265
266
|
type: 'number',
|
|
266
267
|
default: 512 * 1024 * 1024,
|
|
267
268
|
description: 'Maximum stored artifact size for file, URL, multipart, and raw upload ingest in bytes',
|
|
268
|
-
|
|
269
|
+
...intRange(1 * 1024 * 1024, 10 * 1024 * 1024 * 1024),
|
|
269
270
|
},
|
|
270
271
|
{
|
|
271
272
|
key: 'permissions.mode',
|
|
@@ -383,14 +384,14 @@ export const coreHeadConfigSettings = [
|
|
|
383
384
|
type: 'number',
|
|
384
385
|
default: 8,
|
|
385
386
|
description: 'Total active agents allowed across the orchestration tree',
|
|
386
|
-
|
|
387
|
+
...numRange(1, 20),
|
|
387
388
|
},
|
|
388
389
|
{
|
|
389
390
|
key: 'orchestration.maxDepth',
|
|
390
391
|
type: 'number',
|
|
391
392
|
default: 0,
|
|
392
393
|
description: 'Maximum recursive orchestration depth: 0=disabled, higher values allow deeper bounded recursion',
|
|
393
|
-
|
|
394
|
+
...numRange(0, 5),
|
|
394
395
|
},
|
|
395
396
|
{
|
|
396
397
|
key: 'sandbox.replIsolation',
|
|
@@ -449,7 +450,7 @@ export const coreHeadConfigSettings = [
|
|
|
449
450
|
type: 'number',
|
|
450
451
|
default: 2222,
|
|
451
452
|
description: 'Optional guest SSH port used by the QEMU wrapper for real guest command transport',
|
|
452
|
-
|
|
453
|
+
...port(),
|
|
453
454
|
},
|
|
454
455
|
{
|
|
455
456
|
key: 'sandbox.qemuGuestUser',
|
|
@@ -518,8 +519,7 @@ export const coreHeadConfigSettings = [
|
|
|
518
519
|
type: 'number',
|
|
519
520
|
default: 1.0,
|
|
520
521
|
description: 'Playback speed multiplier for TTS synthesis (0.25–4.0); 1.0 is normal speed',
|
|
521
|
-
|
|
522
|
-
validationHint: 'finite number in [0.25, 4.0]',
|
|
522
|
+
...numRange(0.25, 4.0),
|
|
523
523
|
},
|
|
524
524
|
{
|
|
525
525
|
key: 'ui.operationalMessages',
|
|
@@ -585,7 +585,7 @@ export const coreTailConfigSettings = [
|
|
|
585
585
|
type: 'number',
|
|
586
586
|
default: 5000,
|
|
587
587
|
description: 'Default token budget for precision read operations',
|
|
588
|
-
|
|
588
|
+
...numRange(100, 100000),
|
|
589
589
|
},
|
|
590
590
|
{
|
|
591
591
|
key: 'tools.hooksFile',
|
|
@@ -598,14 +598,14 @@ export const coreTailConfigSettings = [
|
|
|
598
598
|
type: 'number',
|
|
599
599
|
default: 9.9,
|
|
600
600
|
description: 'Minimum review score to pass WRFC (0-10)',
|
|
601
|
-
|
|
601
|
+
...numRange(0, 10),
|
|
602
602
|
},
|
|
603
603
|
{
|
|
604
604
|
key: 'wrfc.maxFixAttempts',
|
|
605
605
|
type: 'number',
|
|
606
606
|
default: 5,
|
|
607
607
|
description: 'Maximum gate retry depth before aborting WRFC chain',
|
|
608
|
-
|
|
608
|
+
...numRange(1, 20),
|
|
609
609
|
},
|
|
610
610
|
{
|
|
611
611
|
key: 'wrfc.autoCommit',
|
|
@@ -644,7 +644,7 @@ export const coreTailConfigSettings = [
|
|
|
644
644
|
type: 'number',
|
|
645
645
|
default: 0.3,
|
|
646
646
|
description: 'Warn when cache hit rate falls below this fraction (0.0–1.0)',
|
|
647
|
-
|
|
647
|
+
...numRange(0, 1),
|
|
648
648
|
},
|
|
649
649
|
{
|
|
650
650
|
key: 'helper.enabled',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema-domain-runtime.d.ts","sourceRoot":"","sources":["../../../src/platform/config/schema-domain-runtime.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"schema-domain-runtime.d.ts","sourceRoot":"","sources":["../../../src/platform/config/schema-domain-runtime.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,uBAAuB,EAAkB,MAAM,oBAAoB,CAAC;AAElF,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+HjC,CAAC;AAEF,eAAO,MAAM,4BAA4B,EAAE,uBAAuB,EAsNjE,CAAC;AAEF,eAAO,MAAM,8BAA8B,EAAE,uBAAuB,EA+WnE,CAAC"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { intRange, port } from './schema-shared.js';
|
|
1
2
|
export const runtimeConfigDefaults = {
|
|
2
3
|
runtime: {
|
|
3
4
|
companionChatLimiter: {
|
|
@@ -138,35 +139,35 @@ export const runtimePrimaryConfigSettings = [
|
|
|
138
139
|
type: 'number',
|
|
139
140
|
default: 4,
|
|
140
141
|
description: 'Maximum automation runs that may execute concurrently',
|
|
141
|
-
|
|
142
|
+
...intRange(1, 64),
|
|
142
143
|
},
|
|
143
144
|
{
|
|
144
145
|
key: 'automation.runHistoryLimit',
|
|
145
146
|
type: 'number',
|
|
146
147
|
default: 100,
|
|
147
148
|
description: 'Maximum run history entries retained per automation job',
|
|
148
|
-
|
|
149
|
+
...intRange(1, 5000),
|
|
149
150
|
},
|
|
150
151
|
{
|
|
151
152
|
key: 'automation.defaultTimeoutMs',
|
|
152
153
|
type: 'number',
|
|
153
154
|
default: 15 * 60 * 1000,
|
|
154
155
|
description: 'Default execution timeout for automation runs in milliseconds',
|
|
155
|
-
|
|
156
|
+
...intRange(1_000, 24 * 60 * 60 * 1000),
|
|
156
157
|
},
|
|
157
158
|
{
|
|
158
159
|
key: 'automation.catchUpWindowMinutes',
|
|
159
160
|
type: 'number',
|
|
160
161
|
default: 30,
|
|
161
162
|
description: 'How long after startup the engine should catch up missed runs',
|
|
162
|
-
|
|
163
|
+
...intRange(0, 24 * 60),
|
|
163
164
|
},
|
|
164
165
|
{
|
|
165
166
|
key: 'automation.failureCooldownMs',
|
|
166
167
|
type: 'number',
|
|
167
168
|
default: 5 * 60 * 1000,
|
|
168
169
|
description: 'Cooldown applied after a failed automation run before retrying',
|
|
169
|
-
|
|
170
|
+
...intRange(0, 24 * 60 * 60 * 1000),
|
|
170
171
|
},
|
|
171
172
|
{
|
|
172
173
|
key: 'automation.deleteAfterRun',
|
|
@@ -198,7 +199,7 @@ export const runtimePrimaryConfigSettings = [
|
|
|
198
199
|
type: 'number',
|
|
199
200
|
default: 3421,
|
|
200
201
|
description: 'Bind port for the control-plane HTTP server',
|
|
201
|
-
|
|
202
|
+
...port(),
|
|
202
203
|
},
|
|
203
204
|
{
|
|
204
205
|
key: 'controlPlane.baseUrl',
|
|
@@ -275,7 +276,7 @@ export const runtimePrimaryConfigSettings = [
|
|
|
275
276
|
type: 'number',
|
|
276
277
|
default: 3422,
|
|
277
278
|
description: 'Bind port for the webhook HTTP listener',
|
|
278
|
-
|
|
279
|
+
...port(),
|
|
279
280
|
},
|
|
280
281
|
{
|
|
281
282
|
key: 'httpListener.trustProxy',
|
|
@@ -326,7 +327,7 @@ export const runtimePrimaryConfigSettings = [
|
|
|
326
327
|
type: 'number',
|
|
327
328
|
default: 3423,
|
|
328
329
|
description: 'Bind port for the web surface',
|
|
329
|
-
|
|
330
|
+
...port(),
|
|
330
331
|
},
|
|
331
332
|
{
|
|
332
333
|
key: 'web.publicBaseUrl',
|
|
@@ -353,21 +354,21 @@ export const runtimeSecondaryConfigSettings = [
|
|
|
353
354
|
type: 'number',
|
|
354
355
|
default: 60_000,
|
|
355
356
|
description: 'Polling interval for watcher sources in milliseconds',
|
|
356
|
-
|
|
357
|
+
...intRange(1_000, 24 * 60 * 60 * 1000),
|
|
357
358
|
},
|
|
358
359
|
{
|
|
359
360
|
key: 'watchers.heartbeatIntervalMs',
|
|
360
361
|
type: 'number',
|
|
361
362
|
default: 15_000,
|
|
362
363
|
description: 'Heartbeat interval for watcher services in milliseconds',
|
|
363
|
-
|
|
364
|
+
...intRange(1_000, 60 * 60 * 1000),
|
|
364
365
|
},
|
|
365
366
|
{
|
|
366
367
|
key: 'watchers.recoveryWindowMinutes',
|
|
367
368
|
type: 'number',
|
|
368
369
|
default: 10,
|
|
369
370
|
description: 'Recovery window for watcher restart and missed-event catch-up',
|
|
370
|
-
|
|
371
|
+
...intRange(0, 24 * 60),
|
|
371
372
|
},
|
|
372
373
|
{
|
|
373
374
|
key: 'service.enabled',
|
|
@@ -451,7 +452,7 @@ export const runtimeSecondaryConfigSettings = [
|
|
|
451
452
|
default: 100,
|
|
452
453
|
description: 'Maximum number of listeners per event channel (per-type and per-domain) before a warning is emitted in production ' +
|
|
453
454
|
'or a RangeError is thrown in development mode. Raise this only if you have verified there is no subscriber leak.',
|
|
454
|
-
|
|
455
|
+
...intRange(1, 100_000),
|
|
455
456
|
},
|
|
456
457
|
{
|
|
457
458
|
key: 'telemetry.includeRawPrompts',
|
|
@@ -487,35 +488,35 @@ export const runtimeSecondaryConfigSettings = [
|
|
|
487
488
|
type: 'number',
|
|
488
489
|
default: 60_000,
|
|
489
490
|
description: 'Daemon-local batch scheduler tick interval in milliseconds',
|
|
490
|
-
|
|
491
|
+
...intRange(5_000, 60 * 60 * 1000),
|
|
491
492
|
},
|
|
492
493
|
{
|
|
493
494
|
key: 'batch.maxDelayMs',
|
|
494
495
|
type: 'number',
|
|
495
496
|
default: 5 * 60 * 1000,
|
|
496
497
|
description: 'Maximum time a queued local batch job should wait before the daemon submits its provider batch',
|
|
497
|
-
|
|
498
|
+
...intRange(0, 24 * 60 * 60 * 1000),
|
|
498
499
|
},
|
|
499
500
|
{
|
|
500
501
|
key: 'batch.maxJobsPerProviderBatch',
|
|
501
502
|
type: 'number',
|
|
502
503
|
default: 100,
|
|
503
504
|
description: 'Maximum SDK jobs grouped into a single upstream provider batch submission',
|
|
504
|
-
|
|
505
|
+
...intRange(1, 100_000),
|
|
505
506
|
},
|
|
506
507
|
{
|
|
507
508
|
key: 'batch.maxQueuePayloadBytes',
|
|
508
509
|
type: 'number',
|
|
509
510
|
default: 16 * 1024,
|
|
510
511
|
description: 'Recommended maximum Cloudflare queue message payload size; queue messages should be signals, not full prompt archives',
|
|
511
|
-
|
|
512
|
+
...intRange(1024, 128 * 1024),
|
|
512
513
|
},
|
|
513
514
|
{
|
|
514
515
|
key: 'batch.maxQueueMessagesPerDay',
|
|
515
516
|
type: 'number',
|
|
516
517
|
default: 1_000,
|
|
517
518
|
description: 'SDK-side free-tier guardrail for Cloudflare queue message volume',
|
|
518
|
-
|
|
519
|
+
...intRange(0, 10_000_000),
|
|
519
520
|
},
|
|
520
521
|
{
|
|
521
522
|
key: 'cloudflare.enabled',
|
|
@@ -703,6 +704,6 @@ export const runtimeSecondaryConfigSettings = [
|
|
|
703
704
|
type: 'number',
|
|
704
705
|
default: 10_000,
|
|
705
706
|
description: 'Free-tier queue operation budget used by clients to warn before Cloudflare queue usage exceeds the intended budget',
|
|
706
|
-
|
|
707
|
+
...intRange(0, 10_000_000),
|
|
707
708
|
},
|
|
708
709
|
];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema-domain-surfaces.d.ts","sourceRoot":"","sources":["../../../src/platform/config/schema-domain-surfaces.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"schema-domain-surfaces.d.ts","sourceRoot":"","sources":["../../../src/platform/config/schema-domain-surfaces.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,uBAAuB,EAAY,MAAM,oBAAoB,CAAC;AAE5E,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8IjC,CAAC;AAEF,eAAO,MAAM,qBAAqB,EAAE,uBAAuB,EA8b1D,CAAC"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { intRange } from './schema-shared.js';
|
|
1
2
|
export const surfaceConfigDefaults = {
|
|
2
3
|
slack: {
|
|
3
4
|
enabled: false,
|
|
@@ -261,7 +262,7 @@ export const surfaceConfigSettings = [
|
|
|
261
262
|
type: 'number',
|
|
262
263
|
default: 3,
|
|
263
264
|
description: 'Default ntfy priority (1-5)',
|
|
264
|
-
|
|
265
|
+
...intRange(1, 5),
|
|
265
266
|
},
|
|
266
267
|
{
|
|
267
268
|
key: 'surfaces.webhook.enabled',
|
|
@@ -280,7 +281,7 @@ export const surfaceConfigSettings = [
|
|
|
280
281
|
type: 'number',
|
|
281
282
|
default: 10_000,
|
|
282
283
|
description: 'Outbound webhook timeout in milliseconds',
|
|
283
|
-
|
|
284
|
+
...intRange(1_000, 60_000),
|
|
284
285
|
},
|
|
285
286
|
{
|
|
286
287
|
key: 'surfaces.webhook.secret',
|
|
@@ -341,7 +342,7 @@ export const surfaceConfigSettings = [
|
|
|
341
342
|
type: 'number',
|
|
342
343
|
default: 20 * 60_000,
|
|
343
344
|
description: 'Idle TTL for Home Assistant remote conversation sessions before the daemon closes them',
|
|
344
|
-
|
|
345
|
+
...intRange(60_000, 24 * 60 * 60_000),
|
|
345
346
|
},
|
|
346
347
|
{
|
|
347
348
|
key: 'surfaces.telegram.enabled',
|
|
@@ -13,4 +13,10 @@ export interface ConfigSettingDefinition {
|
|
|
13
13
|
*/
|
|
14
14
|
validationHint?: string | undefined;
|
|
15
15
|
}
|
|
16
|
+
/** Returns validate + validationHint for an integer in [min, max]. */
|
|
17
|
+
export declare function intRange(min: number, max: number): Pick<ConfigSettingDefinition, 'validate' | 'validationHint'>;
|
|
18
|
+
/** Returns validate + validationHint for a float in [min, max]. */
|
|
19
|
+
export declare function numRange(min: number, max: number): Pick<ConfigSettingDefinition, 'validate' | 'validationHint'>;
|
|
20
|
+
/** Returns validate + validationHint for a TCP port (integer in [1, 65535]). */
|
|
21
|
+
export declare function port(): Pick<ConfigSettingDefinition, 'validate' | 'validationHint'>;
|
|
16
22
|
//# sourceMappingURL=schema-shared.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema-shared.d.ts","sourceRoot":"","sources":["../../../src/platform/config/schema-shared.ts"],"names":[],"mappings":"AAAA,qFAAqF;AAErF,MAAM,WAAW,uBAAuB;IACtC,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,SAAS,GAAG,QAAQ,GAAG,QAAQ,GAAG,MAAM,CAAC;IAC/C,OAAO,EAAE,OAAO,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,EAAE,GAAG,SAAS,CAAC;IAClC,QAAQ,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,OAAO,KAAK,OAAO,CAAC,GAAG,SAAS,CAAC;IACrD;;;;OAIG;IACH,cAAc,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACrC"}
|
|
1
|
+
{"version":3,"file":"schema-shared.d.ts","sourceRoot":"","sources":["../../../src/platform/config/schema-shared.ts"],"names":[],"mappings":"AAAA,qFAAqF;AAErF,MAAM,WAAW,uBAAuB;IACtC,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,SAAS,GAAG,QAAQ,GAAG,QAAQ,GAAG,MAAM,CAAC;IAC/C,OAAO,EAAE,OAAO,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,EAAE,GAAG,SAAS,CAAC;IAClC,QAAQ,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,OAAO,KAAK,OAAO,CAAC,GAAG,SAAS,CAAC;IACrD;;;;OAIG;IACH,cAAc,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACrC;AAED,sEAAsE;AACtE,wBAAgB,QAAQ,CACtB,GAAG,EAAE,MAAM,EACX,GAAG,EAAE,MAAM,GACV,IAAI,CAAC,uBAAuB,EAAE,UAAU,GAAG,gBAAgB,CAAC,CAK9D;AAED,mEAAmE;AACnE,wBAAgB,QAAQ,CACtB,GAAG,EAAE,MAAM,EACX,GAAG,EAAE,MAAM,GACV,IAAI,CAAC,uBAAuB,EAAE,UAAU,GAAG,gBAAgB,CAAC,CAK9D;AAED,gFAAgF;AAChF,wBAAgB,IAAI,IAAI,IAAI,CAAC,uBAAuB,EAAE,UAAU,GAAG,gBAAgB,CAAC,CAKnF"}
|
|
@@ -1,2 +1,22 @@
|
|
|
1
1
|
/** SDK-owned platform module. This implementation is maintained in goodvibes-sdk. */
|
|
2
|
-
|
|
2
|
+
/** Returns validate + validationHint for an integer in [min, max]. */
|
|
3
|
+
export function intRange(min, max) {
|
|
4
|
+
return {
|
|
5
|
+
validate: (v) => typeof v === 'number' && Number.isInteger(v) && v >= min && v <= max,
|
|
6
|
+
validationHint: `integer in [${min}, ${max}]`,
|
|
7
|
+
};
|
|
8
|
+
}
|
|
9
|
+
/** Returns validate + validationHint for a float in [min, max]. */
|
|
10
|
+
export function numRange(min, max) {
|
|
11
|
+
return {
|
|
12
|
+
validate: (v) => typeof v === 'number' && v >= min && v <= max,
|
|
13
|
+
validationHint: `number in [${min}, ${max}]`,
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
/** Returns validate + validationHint for a TCP port (integer in [1, 65535]). */
|
|
17
|
+
export function port() {
|
|
18
|
+
return {
|
|
19
|
+
validate: (v) => typeof v === 'number' && Number.isInteger(v) && v >= 1 && v <= 65535,
|
|
20
|
+
validationHint: 'integer port in [1, 65535]',
|
|
21
|
+
};
|
|
22
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"approval-broker.d.ts","sourceRoot":"","sources":["../../../src/platform/control-plane/approval-broker.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,KAAK,EAAE,wBAAwB,EAAE,uBAAuB,EAAE,wBAAwB,EAAE,MAAM,0BAA0B,CAAC;AAC5H,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"approval-broker.d.ts","sourceRoot":"","sources":["../../../src/platform/control-plane/approval-broker.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,KAAK,EAAE,wBAAwB,EAAE,uBAAuB,EAAE,wBAAwB,EAAE,MAAM,0BAA0B,CAAC;AAC5H,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,YAAY,CAAC;AAI7D,MAAM,MAAM,oBAAoB,GAAG,SAAS,GAAG,SAAS,GAAG,UAAU,GAAG,QAAQ,GAAG,WAAW,GAAG,SAAS,CAAC;AAE3G,MAAM,WAAW,yBAAyB;IACxC,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,MAAM,EAAE,SAAS,GAAG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AC,UAAU,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,YAAY,SAAQ,EAAE,IAAI,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,oBAAoB,GAAG,IAAI,CAAC;YA4BpH,cAAc;YAwBd,OAAO;IAMrB,OAAO,CAAC,OAAO;CA8BhB"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { randomUUID } from 'node:crypto';
|
|
2
2
|
import { PersistentStore } from '../state/persistent-store.js';
|
|
3
3
|
import { logger } from '../utils/logger.js';
|
|
4
|
+
import { isRecord } from '../utils/record-coerce.js';
|
|
4
5
|
function sortApprovals(records) {
|
|
5
6
|
return [...records].sort((a, b) => b.updatedAt - a.updatedAt || a.id.localeCompare(b.id));
|
|
6
7
|
}
|
|
@@ -16,9 +17,6 @@ const APPROVAL_AUDIT_ACTIONS = new Set([
|
|
|
16
17
|
]);
|
|
17
18
|
const PERMISSION_CATEGORIES = new Set(['read', 'write', 'execute', 'delegate']);
|
|
18
19
|
const PERMISSION_RISK_LEVELS = new Set(['low', 'medium', 'high', 'critical']);
|
|
19
|
-
function isRecord(value) {
|
|
20
|
-
return typeof value === 'object' && value !== null && !Array.isArray(value);
|
|
21
|
-
}
|
|
22
20
|
function isFiniteNumber(value) {
|
|
23
21
|
return typeof value === 'number' && Number.isFinite(value);
|
|
24
22
|
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { GatewayMethodDescriptor } from './method-catalog-shared.js';
|
|
2
|
+
/**
|
|
3
|
+
* Calendar operator methods — CalDAV-backed event read/write and iCalendar
|
|
4
|
+
* import/export through the standard operator method protocol. Daemon-backed;
|
|
5
|
+
* the SDK publishes the typed contract surface (no internal handler). Local .ics
|
|
6
|
+
* parsing is handled agent-side and does not depend on these contracts.
|
|
7
|
+
*/
|
|
8
|
+
export declare const builtinGatewayCalendarMethodDescriptors: readonly GatewayMethodDescriptor[];
|
|
9
|
+
//# sourceMappingURL=method-catalog-calendar.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"method-catalog-calendar.d.ts","sourceRoot":"","sources":["../../../src/platform/control-plane/method-catalog-calendar.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,4BAA4B,CAAC;AAiC1E;;;;;GAKG;AACH,eAAO,MAAM,uCAAuC,EAAE,SAAS,uBAAuB,EAyFrF,CAAC"}
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
import { STRING_SCHEMA, NUMBER_SCHEMA, arraySchema, objectSchema, listOutputSchema, bodyEnvelopeSchema, methodDescriptor, } from './method-catalog-shared.js';
|
|
2
|
+
const CALENDAR_EVENT_SUMMARY_SCHEMA = objectSchema({
|
|
3
|
+
id: STRING_SCHEMA,
|
|
4
|
+
title: STRING_SCHEMA,
|
|
5
|
+
start: STRING_SCHEMA,
|
|
6
|
+
end: STRING_SCHEMA,
|
|
7
|
+
location: STRING_SCHEMA,
|
|
8
|
+
description: STRING_SCHEMA,
|
|
9
|
+
attendees: arraySchema(STRING_SCHEMA),
|
|
10
|
+
}, ['id', 'title', 'start', 'end']);
|
|
11
|
+
const CALENDAR_EVENT_DETAIL_SCHEMA = objectSchema({
|
|
12
|
+
id: STRING_SCHEMA,
|
|
13
|
+
uid: STRING_SCHEMA,
|
|
14
|
+
title: STRING_SCHEMA,
|
|
15
|
+
start: STRING_SCHEMA,
|
|
16
|
+
end: STRING_SCHEMA,
|
|
17
|
+
location: STRING_SCHEMA,
|
|
18
|
+
description: STRING_SCHEMA,
|
|
19
|
+
attendees: arraySchema(STRING_SCHEMA),
|
|
20
|
+
recurrence: STRING_SCHEMA,
|
|
21
|
+
}, ['id', 'title', 'start', 'end']);
|
|
22
|
+
/**
|
|
23
|
+
* Calendar operator methods — CalDAV-backed event read/write and iCalendar
|
|
24
|
+
* import/export through the standard operator method protocol. Daemon-backed;
|
|
25
|
+
* the SDK publishes the typed contract surface (no internal handler). Local .ics
|
|
26
|
+
* parsing is handled agent-side and does not depend on these contracts.
|
|
27
|
+
*/
|
|
28
|
+
export const builtinGatewayCalendarMethodDescriptors = [
|
|
29
|
+
methodDescriptor({
|
|
30
|
+
id: 'calendar.events.list',
|
|
31
|
+
title: 'List Calendar Events',
|
|
32
|
+
description: 'Return calendar event summaries from the configured CalDAV calendar within an optional time window.',
|
|
33
|
+
category: 'calendar',
|
|
34
|
+
scopes: ['read:calendar'],
|
|
35
|
+
http: { method: 'GET', path: '/api/calendar/events' },
|
|
36
|
+
inputSchema: objectSchema({
|
|
37
|
+
calendarId: STRING_SCHEMA,
|
|
38
|
+
from: STRING_SCHEMA,
|
|
39
|
+
to: STRING_SCHEMA,
|
|
40
|
+
limit: NUMBER_SCHEMA,
|
|
41
|
+
}),
|
|
42
|
+
outputSchema: listOutputSchema('events', CALENDAR_EVENT_SUMMARY_SCHEMA),
|
|
43
|
+
}),
|
|
44
|
+
methodDescriptor({
|
|
45
|
+
id: 'calendar.events.get',
|
|
46
|
+
title: 'Get Calendar Event',
|
|
47
|
+
description: 'Return the full event object including attendees, recurrence, and raw iCalendar UID.',
|
|
48
|
+
category: 'calendar',
|
|
49
|
+
scopes: ['read:calendar'],
|
|
50
|
+
http: { method: 'GET', path: '/api/calendar/events/{eventId}' },
|
|
51
|
+
inputSchema: objectSchema({
|
|
52
|
+
eventId: STRING_SCHEMA,
|
|
53
|
+
calendarId: STRING_SCHEMA,
|
|
54
|
+
}, ['eventId']),
|
|
55
|
+
outputSchema: CALENDAR_EVENT_DETAIL_SCHEMA,
|
|
56
|
+
}),
|
|
57
|
+
methodDescriptor({
|
|
58
|
+
id: 'calendar.events.create',
|
|
59
|
+
title: 'Create Calendar Event',
|
|
60
|
+
description: 'Create an event on the configured CalDAV calendar. Requires explicit confirmation.',
|
|
61
|
+
category: 'calendar',
|
|
62
|
+
scopes: ['write:calendar'],
|
|
63
|
+
access: 'admin',
|
|
64
|
+
http: { method: 'POST', path: '/api/calendar/events' },
|
|
65
|
+
inputSchema: bodyEnvelopeSchema({
|
|
66
|
+
title: STRING_SCHEMA,
|
|
67
|
+
start: STRING_SCHEMA,
|
|
68
|
+
end: STRING_SCHEMA,
|
|
69
|
+
description: STRING_SCHEMA,
|
|
70
|
+
attendees: arraySchema(STRING_SCHEMA),
|
|
71
|
+
location: STRING_SCHEMA,
|
|
72
|
+
calendarId: STRING_SCHEMA,
|
|
73
|
+
confirm: { type: 'boolean' },
|
|
74
|
+
}, ['title', 'start', 'end', 'confirm']),
|
|
75
|
+
outputSchema: objectSchema({
|
|
76
|
+
eventId: STRING_SCHEMA,
|
|
77
|
+
uid: STRING_SCHEMA,
|
|
78
|
+
createdAt: STRING_SCHEMA,
|
|
79
|
+
}, ['eventId', 'uid', 'createdAt']),
|
|
80
|
+
}),
|
|
81
|
+
methodDescriptor({
|
|
82
|
+
id: 'calendar.ics.import',
|
|
83
|
+
title: 'Import iCalendar',
|
|
84
|
+
description: 'Import raw .ics content into the configured CalDAV calendar. Requires explicit confirmation.',
|
|
85
|
+
category: 'calendar',
|
|
86
|
+
scopes: ['write:calendar'],
|
|
87
|
+
access: 'admin',
|
|
88
|
+
http: { method: 'POST', path: '/api/calendar/ics/import' },
|
|
89
|
+
inputSchema: bodyEnvelopeSchema({
|
|
90
|
+
icsContent: STRING_SCHEMA,
|
|
91
|
+
calendarId: STRING_SCHEMA,
|
|
92
|
+
confirm: { type: 'boolean' },
|
|
93
|
+
}, ['icsContent', 'confirm']),
|
|
94
|
+
outputSchema: objectSchema({
|
|
95
|
+
imported: NUMBER_SCHEMA,
|
|
96
|
+
eventIds: arraySchema(STRING_SCHEMA),
|
|
97
|
+
errors: arraySchema(STRING_SCHEMA),
|
|
98
|
+
}, ['imported', 'eventIds', 'errors']),
|
|
99
|
+
}),
|
|
100
|
+
methodDescriptor({
|
|
101
|
+
id: 'calendar.ics.export',
|
|
102
|
+
title: 'Export iCalendar',
|
|
103
|
+
description: 'Export events from the configured CalDAV calendar as raw .ics content within an optional time window.',
|
|
104
|
+
category: 'calendar',
|
|
105
|
+
scopes: ['read:calendar'],
|
|
106
|
+
http: { method: 'GET', path: '/api/calendar/ics/export' },
|
|
107
|
+
inputSchema: objectSchema({
|
|
108
|
+
calendarId: STRING_SCHEMA,
|
|
109
|
+
from: STRING_SCHEMA,
|
|
110
|
+
to: STRING_SCHEMA,
|
|
111
|
+
}),
|
|
112
|
+
outputSchema: objectSchema({
|
|
113
|
+
icsContent: STRING_SCHEMA,
|
|
114
|
+
eventCount: NUMBER_SCHEMA,
|
|
115
|
+
}, ['icsContent', 'eventCount']),
|
|
116
|
+
}),
|
|
117
|
+
];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"method-catalog-channels.d.ts","sourceRoot":"","sources":["../../../src/platform/control-plane/method-catalog-channels.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,4BAA4B,CAAC;
|
|
1
|
+
{"version":3,"file":"method-catalog-channels.d.ts","sourceRoot":"","sources":["../../../src/platform/control-plane/method-catalog-channels.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,4BAA4B,CAAC;AAuF1E,eAAO,MAAM,sCAAsC,EAAE,SAAS,uBAAuB,EAkqBpF,CAAC"}
|