@pellux/goodvibes-sdk 0.25.10 → 0.25.11
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/_internal/contracts/artifacts/operator-contract.json +178 -6
- package/dist/_internal/contracts/generated/foundation-client-types.d.ts +16 -1
- package/dist/_internal/contracts/generated/foundation-client-types.d.ts.map +1 -1
- package/dist/_internal/contracts/generated/foundation-metadata.d.ts +2 -2
- package/dist/_internal/contracts/generated/foundation-metadata.js +2 -2
- package/dist/_internal/contracts/generated/operator-contract.d.ts.map +1 -1
- package/dist/_internal/contracts/generated/operator-contract.js +178 -6
- package/dist/_internal/contracts/generated/operator-method-ids.d.ts +1 -1
- package/dist/_internal/contracts/generated/operator-method-ids.d.ts.map +1 -1
- package/dist/_internal/contracts/generated/operator-method-ids.js +1 -0
- package/dist/_internal/daemon/context.d.ts +1 -0
- package/dist/_internal/daemon/context.d.ts.map +1 -1
- package/dist/_internal/daemon/integration-route-types.d.ts +1 -0
- package/dist/_internal/daemon/integration-route-types.d.ts.map +1 -1
- package/dist/_internal/daemon/integration-routes.d.ts +1 -1
- package/dist/_internal/daemon/integration-routes.d.ts.map +1 -1
- package/dist/_internal/daemon/integration-routes.js +3 -0
- package/dist/_internal/daemon/operator.d.ts +1 -1
- package/dist/_internal/daemon/operator.d.ts.map +1 -1
- package/dist/_internal/daemon/operator.js +2 -0
- package/dist/_internal/daemon/runtime-route-types.d.ts +1 -1
- package/dist/_internal/daemon/runtime-route-types.d.ts.map +1 -1
- package/dist/_internal/platform/adapters/discord/index.d.ts.map +1 -1
- package/dist/_internal/platform/adapters/discord/index.js +4 -5
- package/dist/_internal/platform/adapters/github/index.d.ts.map +1 -1
- package/dist/_internal/platform/adapters/github/index.js +4 -5
- package/dist/_internal/platform/adapters/google-chat/index.d.ts.map +1 -1
- package/dist/_internal/platform/adapters/google-chat/index.js +7 -5
- package/dist/_internal/platform/adapters/helpers.d.ts +2 -1
- package/dist/_internal/platform/adapters/helpers.d.ts.map +1 -1
- package/dist/_internal/platform/adapters/helpers.js +3 -34
- package/dist/_internal/platform/adapters/homeassistant/index.d.ts +3 -0
- package/dist/_internal/platform/adapters/homeassistant/index.d.ts.map +1 -0
- package/dist/_internal/platform/adapters/homeassistant/index.js +177 -0
- package/dist/_internal/platform/adapters/index.d.ts +1 -0
- package/dist/_internal/platform/adapters/index.d.ts.map +1 -1
- package/dist/_internal/platform/adapters/index.js +1 -0
- package/dist/_internal/platform/adapters/mattermost/index.d.ts.map +1 -1
- package/dist/_internal/platform/adapters/mattermost/index.js +6 -2
- package/dist/_internal/platform/adapters/slack/index.d.ts.map +1 -1
- package/dist/_internal/platform/adapters/slack/index.js +4 -5
- package/dist/_internal/platform/adapters/telegram/index.d.ts.map +1 -1
- package/dist/_internal/platform/adapters/telegram/index.js +7 -5
- package/dist/_internal/platform/adapters/types.d.ts +1 -1
- package/dist/_internal/platform/adapters/types.d.ts.map +1 -1
- package/dist/_internal/platform/adapters/webhook/index.d.ts.map +1 -1
- package/dist/_internal/platform/adapters/webhook/index.js +4 -1
- package/dist/_internal/platform/automation/types.d.ts +1 -1
- package/dist/_internal/platform/automation/types.d.ts.map +1 -1
- package/dist/_internal/platform/channels/builtin/accounts.d.ts.map +1 -1
- package/dist/_internal/platform/channels/builtin/accounts.js +22 -0
- package/dist/_internal/platform/channels/builtin/contracts.d.ts.map +1 -1
- package/dist/_internal/platform/channels/builtin/contracts.js +9 -0
- package/dist/_internal/platform/channels/builtin/descriptors.d.ts.map +1 -1
- package/dist/_internal/platform/channels/builtin/descriptors.js +9 -2
- package/dist/_internal/platform/channels/builtin/homeassistant.d.ts +64 -0
- package/dist/_internal/platform/channels/builtin/homeassistant.d.ts.map +1 -0
- package/dist/_internal/platform/channels/builtin/homeassistant.js +380 -0
- package/dist/_internal/platform/channels/builtin/plugins.d.ts.map +1 -1
- package/dist/_internal/platform/channels/builtin/plugins.js +2 -1
- package/dist/_internal/platform/channels/builtin/presentation.d.ts.map +1 -1
- package/dist/_internal/platform/channels/builtin/presentation.js +4 -0
- package/dist/_internal/platform/channels/builtin/setup-schema.d.ts.map +1 -1
- package/dist/_internal/platform/channels/builtin/setup-schema.js +46 -0
- package/dist/_internal/platform/channels/builtin/shared.d.ts +1 -1
- package/dist/_internal/platform/channels/builtin/shared.d.ts.map +1 -1
- package/dist/_internal/platform/channels/builtin/shared.js +2 -0
- package/dist/_internal/platform/channels/builtin/surfaces.d.ts.map +1 -1
- package/dist/_internal/platform/channels/builtin/surfaces.js +1 -0
- package/dist/_internal/platform/channels/builtin/targets.d.ts.map +1 -1
- package/dist/_internal/platform/channels/builtin/targets.js +24 -0
- package/dist/_internal/platform/channels/builtin-runtime.d.ts.map +1 -1
- package/dist/_internal/platform/channels/builtin-runtime.js +6 -0
- package/dist/_internal/platform/channels/delivery/strategies-core.d.ts +1 -0
- package/dist/_internal/platform/channels/delivery/strategies-core.d.ts.map +1 -1
- package/dist/_internal/platform/channels/delivery/strategies-core.js +41 -1
- package/dist/_internal/platform/channels/delivery-router.d.ts.map +1 -1
- package/dist/_internal/platform/channels/delivery-router.js +2 -1
- package/dist/_internal/platform/channels/reply-pipeline.d.ts.map +1 -1
- package/dist/_internal/platform/channels/reply-pipeline.js +9 -0
- package/dist/_internal/platform/channels/route-manager.d.ts.map +1 -1
- package/dist/_internal/platform/channels/route-manager.js +1 -0
- package/dist/_internal/platform/channels/surface-registry.d.ts.map +1 -1
- package/dist/_internal/platform/channels/surface-registry.js +4 -0
- package/dist/_internal/platform/channels/types.d.ts +1 -1
- package/dist/_internal/platform/channels/types.d.ts.map +1 -1
- package/dist/_internal/platform/cloudflare/manager.d.ts +1 -1
- package/dist/_internal/platform/cloudflare/manager.d.ts.map +1 -1
- package/dist/_internal/platform/cloudflare/manager.js +27 -24
- package/dist/_internal/platform/cloudflare/types.d.ts +5 -0
- package/dist/_internal/platform/cloudflare/types.d.ts.map +1 -1
- package/dist/_internal/platform/cloudflare/utils.d.ts.map +1 -1
- package/dist/_internal/platform/cloudflare/utils.js +4 -10
- package/dist/_internal/platform/companion/companion-chat-manager.d.ts +24 -4
- package/dist/_internal/platform/companion/companion-chat-manager.d.ts.map +1 -1
- package/dist/_internal/platform/companion/companion-chat-manager.js +128 -78
- package/dist/_internal/platform/config/schema-domain-surfaces.d.ts +11 -0
- package/dist/_internal/platform/config/schema-domain-surfaces.d.ts.map +1 -1
- package/dist/_internal/platform/config/schema-domain-surfaces.js +59 -0
- package/dist/_internal/platform/config/schema-types.d.ts +14 -2
- package/dist/_internal/platform/config/schema-types.d.ts.map +1 -1
- package/dist/_internal/platform/control-plane/gateway-utils.d.ts +37 -0
- package/dist/_internal/platform/control-plane/gateway-utils.d.ts.map +1 -0
- package/dist/_internal/platform/control-plane/gateway-utils.js +97 -0
- package/dist/_internal/platform/control-plane/gateway.d.ts +4 -9
- package/dist/_internal/platform/control-plane/gateway.d.ts.map +1 -1
- package/dist/_internal/platform/control-plane/gateway.js +26 -61
- package/dist/_internal/platform/control-plane/method-catalog-runtime.d.ts.map +1 -1
- package/dist/_internal/platform/control-plane/method-catalog-runtime.js +11 -1
- package/dist/_internal/platform/control-plane/operator-contract-schemas-admin.d.ts.map +1 -1
- package/dist/_internal/platform/control-plane/operator-contract-schemas-admin.js +3 -2
- package/dist/_internal/platform/control-plane/operator-contract-schemas-control.d.ts +1 -0
- package/dist/_internal/platform/control-plane/operator-contract-schemas-control.d.ts.map +1 -1
- package/dist/_internal/platform/control-plane/operator-contract-schemas-control.js +26 -0
- package/dist/_internal/platform/control-plane/routes/operator.d.ts +1 -1
- package/dist/_internal/platform/control-plane/routes/operator.d.ts.map +1 -1
- package/dist/_internal/platform/control-plane/routes/operator.js +2 -0
- package/dist/_internal/platform/control-plane/types.d.ts +1 -1
- package/dist/_internal/platform/control-plane/types.d.ts.map +1 -1
- package/dist/_internal/platform/daemon/control-plane.d.ts.map +1 -1
- package/dist/_internal/platform/daemon/control-plane.js +50 -6
- package/dist/_internal/platform/daemon/facade-composition.d.ts.map +1 -1
- package/dist/_internal/platform/daemon/facade-composition.js +30 -2
- package/dist/_internal/platform/daemon/facade-types.d.ts +1 -1
- package/dist/_internal/platform/daemon/facade-types.d.ts.map +1 -1
- package/dist/_internal/platform/daemon/http/router.d.ts +2 -2
- package/dist/_internal/platform/daemon/http/router.d.ts.map +1 -1
- package/dist/_internal/platform/daemon/http/router.js +7 -16
- package/dist/_internal/platform/daemon/http/runtime-route-types.d.ts +1 -1
- package/dist/_internal/platform/daemon/http/runtime-route-types.d.ts.map +1 -1
- package/dist/_internal/platform/daemon/http-listener.d.ts.map +1 -1
- package/dist/_internal/platform/daemon/http-listener.js +4 -8
- package/dist/_internal/platform/daemon/surface-actions.d.ts +1 -1
- package/dist/_internal/platform/daemon/surface-actions.d.ts.map +1 -1
- package/dist/_internal/platform/daemon/surface-delivery.d.ts +1 -1
- package/dist/_internal/platform/daemon/surface-delivery.d.ts.map +1 -1
- package/dist/_internal/platform/daemon/surface-delivery.js +1 -0
- package/dist/_internal/platform/daemon/surface-policy.d.ts +1 -1
- package/dist/_internal/platform/daemon/surface-policy.d.ts.map +1 -1
- package/dist/_internal/platform/daemon/surface-policy.js +8 -0
- package/dist/_internal/platform/daemon/types.d.ts +2 -2
- package/dist/_internal/platform/daemon/types.d.ts.map +1 -1
- package/dist/_internal/platform/integrations/homeassistant.d.ts +58 -0
- package/dist/_internal/platform/integrations/homeassistant.d.ts.map +1 -0
- package/dist/_internal/platform/integrations/homeassistant.js +174 -0
- package/dist/_internal/platform/integrations/index.d.ts +2 -0
- package/dist/_internal/platform/integrations/index.d.ts.map +1 -1
- package/dist/_internal/platform/integrations/index.js +1 -0
- package/dist/_internal/platform/runtime/events/control-plane.d.ts +1 -1
- package/dist/_internal/platform/runtime/events/control-plane.d.ts.map +1 -1
- package/dist/_internal/platform/runtime/events/control-plane.js +1 -0
- package/dist/_internal/platform/runtime/events/routes.d.ts +1 -1
- package/dist/_internal/platform/runtime/events/routes.d.ts.map +1 -1
- package/dist/_internal/platform/runtime/events/routes.js +1 -0
- package/dist/_internal/platform/runtime/feature-flags/flags.d.ts.map +1 -1
- package/dist/_internal/platform/runtime/feature-flags/flags.js +9 -0
- package/dist/_internal/platform/runtime/feature-flags/gates.d.ts.map +1 -1
- package/dist/_internal/platform/runtime/feature-flags/gates.js +2 -0
- package/dist/_internal/platform/runtime/index.d.ts +2 -0
- package/dist/_internal/platform/runtime/index.d.ts.map +1 -1
- package/dist/_internal/platform/runtime/index.js +1 -0
- package/dist/_internal/platform/runtime/integration/helpers.d.ts +4 -0
- package/dist/_internal/platform/runtime/integration/helpers.d.ts.map +1 -1
- package/dist/_internal/platform/runtime/integration/helpers.js +4 -0
- package/dist/_internal/platform/runtime/security-settings.d.ts +19 -0
- package/dist/_internal/platform/runtime/security-settings.d.ts.map +1 -0
- package/dist/_internal/platform/runtime/security-settings.js +187 -0
- package/dist/_internal/platform/runtime/services.d.ts.map +1 -1
- package/dist/_internal/platform/runtime/services.js +1 -0
- package/dist/_internal/platform/security/user-auth.d.ts +1 -1
- package/dist/_internal/platform/security/user-auth.d.ts.map +1 -1
- package/dist/_internal/platform/security/user-auth.js +18 -3
- package/dist/_internal/platform/tools/edit/core.d.ts.map +1 -1
- package/dist/_internal/platform/tools/edit/core.js +4 -47
- package/dist/_internal/platform/tools/exec/runtime.d.ts.map +1 -1
- package/dist/_internal/platform/tools/exec/runtime.js +7 -1
- package/dist/_internal/platform/tools/exec/schema.d.ts +1 -0
- package/dist/_internal/platform/tools/exec/schema.d.ts.map +1 -1
- package/dist/_internal/platform/tools/exec/schema.js +1 -0
- package/dist/_internal/platform/tools/fetch/runtime.d.ts.map +1 -1
- package/dist/_internal/platform/tools/fetch/runtime.js +140 -19
- package/dist/_internal/platform/tools/fetch/schema.d.ts +1 -0
- package/dist/_internal/platform/tools/fetch/schema.d.ts.map +1 -1
- package/dist/_internal/platform/tools/fetch/schema.js +1 -0
- package/dist/_internal/platform/tools/find/executor.d.ts.map +1 -1
- package/dist/_internal/platform/tools/find/executor.js +7 -1
- package/dist/_internal/platform/tools/find/schema.d.ts.map +1 -1
- package/dist/_internal/platform/tools/find/schema.js +2 -0
- package/dist/_internal/platform/tools/read/index.d.ts.map +1 -1
- package/dist/_internal/platform/tools/read/index.js +7 -1
- package/dist/_internal/platform/tools/read/schema.d.ts +1 -0
- package/dist/_internal/platform/tools/read/schema.d.ts.map +1 -1
- package/dist/_internal/platform/tools/read/schema.js +1 -0
- package/dist/_internal/platform/tools/shared/process-manager.d.ts +2 -0
- package/dist/_internal/platform/tools/shared/process-manager.d.ts.map +1 -1
- package/dist/_internal/platform/tools/shared/process-manager.js +67 -5
- package/dist/_internal/platform/tools/write/index.d.ts.map +1 -1
- package/dist/_internal/platform/tools/write/index.js +3 -36
- package/dist/_internal/platform/utils/concurrency.d.ts +3 -0
- package/dist/_internal/platform/utils/concurrency.d.ts.map +1 -0
- package/dist/_internal/platform/utils/concurrency.js +17 -0
- package/dist/_internal/platform/utils/logger.d.ts.map +1 -1
- package/dist/_internal/platform/utils/logger.js +19 -1
- package/dist/_internal/platform/utils/request-body.d.ts +4 -0
- package/dist/_internal/platform/utils/request-body.d.ts.map +1 -0
- package/dist/_internal/platform/utils/request-body.js +45 -0
- package/dist/_internal/platform/version.js +1 -1
- package/dist/workers.d.ts +6 -0
- package/dist/workers.d.ts.map +1 -1
- package/dist/workers.js +55 -3
- package/package.json +1 -1
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
export interface HomeAssistantStateRecord {
|
|
2
|
+
readonly entity_id: string;
|
|
3
|
+
readonly state: string;
|
|
4
|
+
readonly attributes?: Record<string, unknown>;
|
|
5
|
+
readonly last_changed?: string;
|
|
6
|
+
readonly last_updated?: string;
|
|
7
|
+
readonly context?: Record<string, unknown>;
|
|
8
|
+
}
|
|
9
|
+
export interface HomeAssistantServiceRecord {
|
|
10
|
+
readonly domain: string;
|
|
11
|
+
readonly services: Record<string, unknown> | readonly string[];
|
|
12
|
+
}
|
|
13
|
+
export interface HomeAssistantClientOptions {
|
|
14
|
+
readonly baseUrl: string;
|
|
15
|
+
readonly accessToken?: string;
|
|
16
|
+
readonly timeoutMs?: number;
|
|
17
|
+
readonly maxResponseBytes?: number;
|
|
18
|
+
}
|
|
19
|
+
export interface HomeAssistantGoodVibesEvent {
|
|
20
|
+
readonly type: string;
|
|
21
|
+
readonly title?: string;
|
|
22
|
+
readonly body: string;
|
|
23
|
+
readonly status?: string;
|
|
24
|
+
readonly jobId?: string;
|
|
25
|
+
readonly runId?: string;
|
|
26
|
+
readonly agentId?: string;
|
|
27
|
+
readonly sessionId?: string;
|
|
28
|
+
readonly routeId?: string;
|
|
29
|
+
readonly surfaceId?: string;
|
|
30
|
+
readonly externalId?: string;
|
|
31
|
+
readonly metadata?: Record<string, unknown>;
|
|
32
|
+
}
|
|
33
|
+
export declare class HomeAssistantIntegration {
|
|
34
|
+
private readonly baseUrl;
|
|
35
|
+
private readonly accessToken?;
|
|
36
|
+
private readonly timeoutMs;
|
|
37
|
+
private readonly maxResponseBytes;
|
|
38
|
+
constructor(options: HomeAssistantClientOptions);
|
|
39
|
+
getApiStatus(): Promise<unknown>;
|
|
40
|
+
getConfig(): Promise<unknown>;
|
|
41
|
+
listStates(): Promise<HomeAssistantStateRecord[]>;
|
|
42
|
+
getState(entityId: string): Promise<HomeAssistantStateRecord | null>;
|
|
43
|
+
listServices(): Promise<HomeAssistantServiceRecord[]>;
|
|
44
|
+
callService(input: {
|
|
45
|
+
readonly domain: string;
|
|
46
|
+
readonly service: string;
|
|
47
|
+
readonly serviceData?: Record<string, unknown>;
|
|
48
|
+
readonly returnResponse?: boolean;
|
|
49
|
+
}): Promise<unknown>;
|
|
50
|
+
fireEvent(eventType: string, eventData?: Record<string, unknown>): Promise<unknown>;
|
|
51
|
+
renderTemplate(template: string, variables?: Record<string, unknown>): Promise<string>;
|
|
52
|
+
publishGoodVibesEvent(eventType: string, event: HomeAssistantGoodVibesEvent): Promise<unknown>;
|
|
53
|
+
private requestJson;
|
|
54
|
+
private requestText;
|
|
55
|
+
private request;
|
|
56
|
+
}
|
|
57
|
+
export declare function normalizeHomeAssistantBaseUrl(value: string): string;
|
|
58
|
+
//# sourceMappingURL=homeassistant.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"homeassistant.d.ts","sourceRoot":"","sources":["../../../../src/_internal/platform/integrations/homeassistant.ts"],"names":[],"mappings":"AAKA,MAAM,WAAW,wBAAwB;IACvC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC9C,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;IAC/B,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;IAC/B,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAC5C;AAED,MAAM,WAAW,0BAA0B;IACzC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,MAAM,EAAE,CAAC;CAChE;AAED,MAAM,WAAW,0BAA0B;IACzC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,gBAAgB,CAAC,EAAE,MAAM,CAAC;CACpC;AAED,MAAM,WAAW,2BAA2B;IAC1C,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,MAAM,CAAC,EAAE,MA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CAAC;IAUd,SAAS,CAAC,SAAS,EAAE,MAAM,EAAE,SAAS,GAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAM,GAAG,OAAO,CAAC,OAAO,CAAC;IAQvF,cAAc,CAAC,QAAQ,EAAE,MAAM,EAAE,SAAS,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,OAAO,CAAC,MAAM,CAAC;IAYtF,qBAAqB,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,2BAA2B,GAAG,OAAO,CAAC,OAAO,CAAC;YAQtF,WAAW;YAuBX,WAAW;YAgBX,OAAO;CAuBtB;AAED,wBAAgB,6BAA6B,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAgBnE"}
|
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
import { instrumentedFetch } from '../utils/fetch-with-timeout.js';
|
|
2
|
+
const DEFAULT_HOME_ASSISTANT_TIMEOUT_MS = 15_000;
|
|
3
|
+
const DEFAULT_HOME_ASSISTANT_RESPONSE_BYTES = 2_000_000;
|
|
4
|
+
export class HomeAssistantIntegration {
|
|
5
|
+
baseUrl;
|
|
6
|
+
accessToken;
|
|
7
|
+
timeoutMs;
|
|
8
|
+
maxResponseBytes;
|
|
9
|
+
constructor(options) {
|
|
10
|
+
this.baseUrl = normalizeHomeAssistantBaseUrl(options.baseUrl);
|
|
11
|
+
this.accessToken = options.accessToken?.trim() || undefined;
|
|
12
|
+
this.timeoutMs = options.timeoutMs ?? DEFAULT_HOME_ASSISTANT_TIMEOUT_MS;
|
|
13
|
+
this.maxResponseBytes = options.maxResponseBytes ?? DEFAULT_HOME_ASSISTANT_RESPONSE_BYTES;
|
|
14
|
+
}
|
|
15
|
+
async getApiStatus() {
|
|
16
|
+
return this.requestJson('/api/', { auth: Boolean(this.accessToken) });
|
|
17
|
+
}
|
|
18
|
+
async getConfig() {
|
|
19
|
+
return this.requestJson('/api/config', { auth: true });
|
|
20
|
+
}
|
|
21
|
+
async listStates() {
|
|
22
|
+
const payload = await this.requestJson('/api/states', { auth: true });
|
|
23
|
+
return Array.isArray(payload) ? payload.filter(isHomeAssistantState) : [];
|
|
24
|
+
}
|
|
25
|
+
async getState(entityId) {
|
|
26
|
+
const payload = await this.requestJson(`/api/states/${encodeURIComponent(entityId)}`, {
|
|
27
|
+
auth: true,
|
|
28
|
+
notFoundAsNull: true,
|
|
29
|
+
});
|
|
30
|
+
return isHomeAssistantState(payload) ? payload : null;
|
|
31
|
+
}
|
|
32
|
+
async listServices() {
|
|
33
|
+
const payload = await this.requestJson('/api/services', { auth: true });
|
|
34
|
+
return Array.isArray(payload) ? payload.filter(isHomeAssistantService) : [];
|
|
35
|
+
}
|
|
36
|
+
async callService(input) {
|
|
37
|
+
const path = `/api/services/${encodeURIComponent(input.domain)}/${encodeURIComponent(input.service)}`
|
|
38
|
+
+ (input.returnResponse ? '?return_response' : '');
|
|
39
|
+
return this.requestJson(path, {
|
|
40
|
+
auth: true,
|
|
41
|
+
method: 'POST',
|
|
42
|
+
body: input.serviceData ?? {},
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
async fireEvent(eventType, eventData = {}) {
|
|
46
|
+
return this.requestJson(`/api/events/${encodeURIComponent(eventType)}`, {
|
|
47
|
+
auth: true,
|
|
48
|
+
method: 'POST',
|
|
49
|
+
body: eventData,
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
async renderTemplate(template, variables) {
|
|
53
|
+
const payload = await this.requestText('/api/template', {
|
|
54
|
+
auth: true,
|
|
55
|
+
method: 'POST',
|
|
56
|
+
body: {
|
|
57
|
+
template,
|
|
58
|
+
...(variables && Object.keys(variables).length > 0 ? { variables } : {}),
|
|
59
|
+
},
|
|
60
|
+
});
|
|
61
|
+
return payload;
|
|
62
|
+
}
|
|
63
|
+
async publishGoodVibesEvent(eventType, event) {
|
|
64
|
+
return this.fireEvent(eventType, {
|
|
65
|
+
...event,
|
|
66
|
+
source: 'goodvibes',
|
|
67
|
+
emittedAt: new Date().toISOString(),
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
async requestJson(path, options = {}) {
|
|
71
|
+
const response = await this.request(path, options);
|
|
72
|
+
if (options.notFoundAsNull && response.status === 404)
|
|
73
|
+
return null;
|
|
74
|
+
const text = await readResponseTextWithinLimit(response, this.maxResponseBytes);
|
|
75
|
+
if (!response.ok) {
|
|
76
|
+
throw new Error(`Home Assistant HTTP ${response.status}${text ? `: ${text.slice(0, 500)}` : ''}`);
|
|
77
|
+
}
|
|
78
|
+
if (!text.trim())
|
|
79
|
+
return null;
|
|
80
|
+
try {
|
|
81
|
+
return JSON.parse(text);
|
|
82
|
+
}
|
|
83
|
+
catch {
|
|
84
|
+
return text;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
async requestText(path, options = {}) {
|
|
88
|
+
const response = await this.request(path, options);
|
|
89
|
+
const text = await readResponseTextWithinLimit(response, this.maxResponseBytes);
|
|
90
|
+
if (!response.ok) {
|
|
91
|
+
throw new Error(`Home Assistant HTTP ${response.status}${text ? `: ${text.slice(0, 500)}` : ''}`);
|
|
92
|
+
}
|
|
93
|
+
return text;
|
|
94
|
+
}
|
|
95
|
+
async request(path, options) {
|
|
96
|
+
if (options.auth && !this.accessToken) {
|
|
97
|
+
throw new Error('Home Assistant access token is not configured.');
|
|
98
|
+
}
|
|
99
|
+
const headers = {
|
|
100
|
+
Accept: 'application/json',
|
|
101
|
+
...(options.body ? { 'Content-Type': 'application/json' } : {}),
|
|
102
|
+
...(options.auth && this.accessToken ? { Authorization: `Bearer ${this.accessToken}` } : {}),
|
|
103
|
+
};
|
|
104
|
+
return instrumentedFetch(new URL(path, `${this.baseUrl}/`).toString(), {
|
|
105
|
+
method: options.method ?? 'GET',
|
|
106
|
+
headers,
|
|
107
|
+
...(options.body ? { body: JSON.stringify(options.body) } : {}),
|
|
108
|
+
signal: AbortSignal.timeout(this.timeoutMs),
|
|
109
|
+
});
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
export function normalizeHomeAssistantBaseUrl(value) {
|
|
113
|
+
const trimmed = value.trim();
|
|
114
|
+
if (!trimmed)
|
|
115
|
+
throw new Error('Home Assistant base URL is required.');
|
|
116
|
+
let url;
|
|
117
|
+
try {
|
|
118
|
+
url = new URL(trimmed);
|
|
119
|
+
}
|
|
120
|
+
catch {
|
|
121
|
+
throw new Error(`Invalid Home Assistant base URL: ${trimmed}`);
|
|
122
|
+
}
|
|
123
|
+
if (url.protocol !== 'http:' && url.protocol !== 'https:') {
|
|
124
|
+
throw new Error('Home Assistant base URL must use http or https.');
|
|
125
|
+
}
|
|
126
|
+
url.pathname = url.pathname.replace(/\/+$/, '');
|
|
127
|
+
url.search = '';
|
|
128
|
+
url.hash = '';
|
|
129
|
+
return url.toString().replace(/\/+$/, '');
|
|
130
|
+
}
|
|
131
|
+
function isHomeAssistantState(value) {
|
|
132
|
+
if (!value || typeof value !== 'object')
|
|
133
|
+
return false;
|
|
134
|
+
const record = value;
|
|
135
|
+
return typeof record.entity_id === 'string' && typeof record.state === 'string';
|
|
136
|
+
}
|
|
137
|
+
function isHomeAssistantService(value) {
|
|
138
|
+
if (!value || typeof value !== 'object')
|
|
139
|
+
return false;
|
|
140
|
+
const record = value;
|
|
141
|
+
return typeof record.domain === 'string'
|
|
142
|
+
&& (Array.isArray(record.services) || (typeof record.services === 'object' && record.services !== null));
|
|
143
|
+
}
|
|
144
|
+
async function readResponseTextWithinLimit(response, maxBytes) {
|
|
145
|
+
const contentLength = Number.parseInt(response.headers.get('content-length') ?? '0', 10);
|
|
146
|
+
if (Number.isFinite(contentLength) && contentLength > maxBytes) {
|
|
147
|
+
await response.body?.cancel().catch(() => undefined);
|
|
148
|
+
throw new Error(`Home Assistant response too large: ${contentLength} bytes`);
|
|
149
|
+
}
|
|
150
|
+
if (!response.body)
|
|
151
|
+
return '';
|
|
152
|
+
const reader = response.body.getReader();
|
|
153
|
+
const decoder = new TextDecoder();
|
|
154
|
+
let total = 0;
|
|
155
|
+
let text = '';
|
|
156
|
+
try {
|
|
157
|
+
for (;;) {
|
|
158
|
+
const { done, value } = await reader.read();
|
|
159
|
+
if (done)
|
|
160
|
+
break;
|
|
161
|
+
total += value.byteLength;
|
|
162
|
+
if (total > maxBytes) {
|
|
163
|
+
await reader.cancel('Response too large').catch(() => undefined);
|
|
164
|
+
throw new Error(`Home Assistant response exceeded ${maxBytes} bytes`);
|
|
165
|
+
}
|
|
166
|
+
text += decoder.decode(value, { stream: true });
|
|
167
|
+
}
|
|
168
|
+
text += decoder.decode();
|
|
169
|
+
return text;
|
|
170
|
+
}
|
|
171
|
+
finally {
|
|
172
|
+
reader.releaseLock();
|
|
173
|
+
}
|
|
174
|
+
}
|
|
@@ -3,6 +3,8 @@ export type { SlackAuthTestResult, SlackConversationRecord, SlackCursorPage, Sla
|
|
|
3
3
|
export { DiscordGatewayClient, DiscordGatewayIntent, DiscordGatewayOpcode, DiscordIntegration } from './discord.js';
|
|
4
4
|
export type { DiscordApplicationCommand, DiscordApplicationCommandOption, DiscordGatewayBotResponse, DiscordGatewayClientOptions, DiscordGatewayDispatch, DiscordInteraction, DiscordOAuthAuthorizeOptions, } from './discord.js';
|
|
5
5
|
export { DiscordInteractionType, DiscordInteractionResponseType } from './discord.js';
|
|
6
|
+
export { HomeAssistantIntegration, normalizeHomeAssistantBaseUrl } from './homeassistant.js';
|
|
7
|
+
export type { HomeAssistantClientOptions, HomeAssistantGoodVibesEvent, HomeAssistantServiceRecord, HomeAssistantStateRecord, } from './homeassistant.js';
|
|
6
8
|
export { Notifier } from './notifier.js';
|
|
7
9
|
export { GitHubIntegration } from './github.js';
|
|
8
10
|
export type { GitHubWebhookEvent } from './github.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/_internal/platform/integrations/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,qBAAqB,EAAE,MAAM,YAAY,CAAC;AACrE,YAAY,E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AAW,CAAC;AACnB,YAAY,EACV,eAAe,EACf,oBAAoB,EACpB,eAAe,EACf,eAAe,EACf,mBAAmB,EACnB,sBAAsB,GACvB,MAAM,eAAe,CAAC;AACvB,YAAY,EACV,wBAAwB,EACxB,mBAAmB,EACnB,WAAW,EACX,kBAAkB,EAClB,oBAAoB,EACpB,oBAAoB,GACrB,MAAM,WAAW,CAAC"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export { SlackIntegration, SlackSocketModeClient } from './slack.js';
|
|
2
2
|
export { DiscordGatewayClient, DiscordGatewayIntent, DiscordGatewayOpcode, DiscordIntegration } from './discord.js';
|
|
3
3
|
export { DiscordInteractionType, DiscordInteractionResponseType } from './discord.js';
|
|
4
|
+
export { HomeAssistantIntegration, normalizeHomeAssistantBaseUrl } from './homeassistant.js';
|
|
4
5
|
export { Notifier } from './notifier.js';
|
|
5
6
|
export { GitHubIntegration } from './github.js';
|
|
6
7
|
export { DeliveryQueue, DeliveryError, classifyDeliveryError, snapshotQueueStatus } from './delivery.js';
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
/**
|
|
3
3
|
* ControlPlaneEvent — discriminated union covering gateway/control-plane client lifecycle events.
|
|
4
4
|
*/
|
|
5
|
-
export declare const CONTROL_PLANE_CLIENT_KINDS: readonly ["tui", "web", "slack", "discord", "ntfy", "daemon", "webhook", "service", "telegram", "google-chat", "signal", "whatsapp", "imessage", "msteams", "bluebubbles", "mattermost", "matrix"];
|
|
5
|
+
export declare const CONTROL_PLANE_CLIENT_KINDS: readonly ["tui", "web", "slack", "discord", "ntfy", "daemon", "webhook", "homeassistant", "service", "telegram", "google-chat", "signal", "whatsapp", "imessage", "msteams", "bluebubbles", "mattermost", "matrix"];
|
|
6
6
|
export declare const CONTROL_PLANE_TRANSPORT_KINDS: readonly ["local", "http", "sse", "ws", "websocket", "webhook"];
|
|
7
7
|
export declare const CONTROL_PLANE_PRINCIPAL_KINDS: readonly ["user", "bot", "service", "token"];
|
|
8
8
|
export type ControlPlaneClientKind = (typeof CONTROL_PLANE_CLIENT_KINDS)[number];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"control-plane.d.ts","sourceRoot":"","sources":["../../../../../src/_internal/platform/runtime/events/control-plane.ts"],"names":[],"mappings":"AAAA,qFAAqF;AAErF;;GAEG;AAEH,eAAO,MAAM,0BAA0B,
|
|
1
|
+
{"version":3,"file":"control-plane.d.ts","sourceRoot":"","sources":["../../../../../src/_internal/platform/runtime/events/control-plane.ts"],"names":[],"mappings":"AAAA,qFAAqF;AAErF;;GAEG;AAEH,eAAO,MAAM,0BAA0B,qNAmB7B,CAAC;AACX,eAAO,MAAM,6BAA6B,iEAAkE,CAAC;AAC7G,eAAO,MAAM,6BAA6B,8CAA+C,CAAC;AAE1F,MAAM,MAAM,sBAAsB,GAAG,CAAC,OAAO,0BAA0B,CAAC,CAAC,MAAM,CAAC,CAAC;AAEjF,MAAM,MAAM,yBAAyB,GAAG,CAAC,OAAO,6BAA6B,CAAC,CAAC,MAAM,CAAC,CAAC;AAEvF,MAAM,MAAM,yBAAyB,GAAG,CAAC,OAAO,6BAA6B,CAAC,CAAC,MAAM,CAAC,CAAC;AAEvF,MAAM,MAAM,iBAAiB,GACzB;IACE,IAAI,EAAE,gCAAgC,CAAC;IACvC,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,sBAAsB,CAAC;IACnC,SAAS,EAAE,yBAAyB,CAAC;CACtC,GACD;IACE,IAAI,EAAE,mCAAmC,CAAC;IAC1C,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;CAChB,GACD;IACE,IAAI,EAAE,oCAAoC,CAAC;IAC3C,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,EAAE,MAAM,CAAC;IACvB,MAAM,EAAE,MAAM,EAAE,CAAC;CAClB,GACD;IACE,IAAI,EAAE,oCAAoC,CAAC;IAC3C,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,EAAE,MAAM,CAAC;IACvB,MAAM,EAAE,MAAM,CAAC;CAChB,GACD;IACE,IAAI,EAAE,4BAA4B,CAAC;IACnC,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,aAAa,EAAE,yBAAyB,CAAC;IACzC,MAAM,EAAE,MAAM,EAAE,CAAC;CAClB,GACD;IACE,IAAI,EAAE,6BAA6B,CAAC;IACpC,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AAEN,MAAM,MAAM,qBAAqB,GAAG,iBAAiB,CAAC,MAAM,CAAC,CAAC"}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
/**
|
|
3
3
|
* RouteEvent — discriminated union covering external route binding lifecycle events.
|
|
4
4
|
*/
|
|
5
|
-
export declare const ROUTE_SURFACE_KINDS: readonly ["tui", "web", "slack", "discord", "ntfy", "webhook", "telegram", "google-chat", "signal", "whatsapp", "imessage", "msteams", "bluebubbles", "mattermost", "matrix", "service"];
|
|
5
|
+
export declare const ROUTE_SURFACE_KINDS: readonly ["tui", "web", "slack", "discord", "ntfy", "webhook", "homeassistant", "telegram", "google-chat", "signal", "whatsapp", "imessage", "msteams", "bluebubbles", "mattermost", "matrix", "service"];
|
|
6
6
|
export declare const ROUTE_TARGET_KINDS: readonly ["session", "run", "job", "task", "message"];
|
|
7
7
|
export type RouteSurfaceKind = (typeof ROUTE_SURFACE_KINDS)[number];
|
|
8
8
|
export type RouteTargetKind = (typeof ROUTE_TARGET_KINDS)[number];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"routes.d.ts","sourceRoot":"","sources":["../../../../../src/_internal/platform/runtime/events/routes.ts"],"names":[],"mappings":"AAAA,qFAAqF;AAErF;;GAEG;AAEH,eAAO,MAAM,mBAAmB,
|
|
1
|
+
{"version":3,"file":"routes.d.ts","sourceRoot":"","sources":["../../../../../src/_internal/plat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AAgB,CAAC;IAC9B,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEN,MAAM,MAAM,cAAc,GAAG,UAAU,CAAC,MAAM,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flags.d.ts","sourceRoot":"","sources":["../../../../../src/_internal/platform/runtime/feature-flags/flags.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAE9C;;;;GAIG;AACH,eAAO,MAAM,aAAa,EAAE,WAAW,
|
|
1
|
+
{"version":3,"file":"flags.d.ts","sourceRoot":"","sources":["../../../../../src/_internal/platform/runtime/feature-flags/flags.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAE9C;;;;GAIG;AACH,eAAO,MAAM,aAAa,EAAE,WAAW,EAohBtC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,gBAAgB,EAAE,WAAW,CAAC,MAAM,EAAE,WAAW,CAE7D,CAAC"}
|
|
@@ -434,6 +434,15 @@ export const FEATURE_FLAGS = [
|
|
|
434
434
|
tier: 10,
|
|
435
435
|
runtimeToggleable: true,
|
|
436
436
|
},
|
|
437
|
+
{
|
|
438
|
+
id: 'homeassistant-surface',
|
|
439
|
+
name: 'Home Assistant Surface',
|
|
440
|
+
description: 'Enables the Home Assistant surface for daemon/device integration, Home Assistant '
|
|
441
|
+
+ 'event delivery, service-call tools, and Home Assistant-originated prompts.',
|
|
442
|
+
defaultState: 'disabled',
|
|
443
|
+
tier: 10,
|
|
444
|
+
runtimeToggleable: true,
|
|
445
|
+
},
|
|
437
446
|
{
|
|
438
447
|
id: 'web-surface',
|
|
439
448
|
name: 'Web Surface',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gates.d.ts","sourceRoot":"","sources":["../../../../../src/_internal/platform/runtime/feature-flags/gates.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAEvD,MAAM,MAAM,iBAAiB,GAAG,IAAI,CAAC,kBAAkB,EAAE,WAAW,CAAC,GAAG,IAAI,GAAG,SAAS,CAAC;AAEzF,wBAAgB,oBAAoB,CAClC,YAAY,EAAE,iBAAiB,EAC/B,MAAM,EAAE,MAAM,EACd,OAAO,GAAE,SAAS,MAAM,EAAO,GAC9B,OAAO,CAGT;AAED,wBAAgB,kBAAkB,CAChC,YAAY,EAAE,iBAAiB,EAC/B,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,MAAM,EACjB,OAAO,GAAE,SAAS,MAAM,EAAO,GAC9B,IAAI,CAGN;AAED,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,
|
|
1
|
+
{"version":3,"file":"gates.d.ts","sourceRoot":"","sources":["../../../../../src/_internal/platform/runtime/feature-flags/gates.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAEvD,MAAM,MAAM,iBAAiB,GAAG,IAAI,CAAC,kBAAkB,EAAE,WAAW,CAAC,GAAG,IAAI,GAAG,SAAS,CAAC;AAEzF,wBAAgB,oBAAoB,CAClC,YAAY,EAAE,iBAAiB,EAC/B,MAAM,EAAE,MAAM,EACd,OAAO,GAAE,SAAS,MAAM,EAAO,GAC9B,OAAO,CAGT;AAED,wBAAgB,kBAAkB,CAChC,YAAY,EAAE,iBAAiB,EAC/B,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,MAAM,EACjB,OAAO,GAAE,SAAS,MAAM,EAAO,GAC9B,IAAI,CAGN;AAED,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAiBnE;AAED,wBAAgB,2BAA2B,CACzC,YAAY,EAAE,iBAAiB,EAC/B,OAAO,EAAE,MAAM,GACd,OAAO,CAOT"}
|
|
@@ -17,6 +17,8 @@ export { RUNTIME_EVENT_DOMAINS, isRuntimeEventDomain } from './events/domain-map
|
|
|
17
17
|
export type { AnyRuntimeEvent, RuntimeEventDomain, RuntimeEventRecord } from './events/domain-map.js';
|
|
18
18
|
export { createRuntimeEventFeed, createRuntimeEventFeeds } from './event-feeds.js';
|
|
19
19
|
export type { RuntimeEventFeed, RuntimeEventFeeds } from './event-feeds.js';
|
|
20
|
+
export { getSecuritySettingsReport } from './security-settings.js';
|
|
21
|
+
export type { SecuritySettingReport, SecuritySettingsReporter } from './security-settings.js';
|
|
20
22
|
export type { EmitterContext } from './emitters/index.js';
|
|
21
23
|
export { RuntimeHealthAggregator } from './health/aggregator.js';
|
|
22
24
|
export { CascadeEngine } from './health/cascade-engine.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/_internal/platform/runtime/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAC5E,YAAY,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AACrE,YAAY,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AACrD,cAAc,4BAA4B,CAAC;AAE3C,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAC1D,YAAY,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,qBAAqB,CAAC;AAC/E,YAAY,EAAE,oBAAoB,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAClF,OAAO,EAAE,qBAAqB,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AACrF,YAAY,EAAE,eAAe,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,C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,EAAE,yBAAyB,EAAE,MAAM,4BAA4B,CAAC;AACrF,YAAY,EAAE,uBAAuB,EAAE,sBAAsB,EAAE,MAAM,4BAA4B,CAAC;AAClG,OAAO,EAAE,0BAA0B,EAAE,MAAM,wCAAwC,CAAC;AACpF,YAAY,EACV,oBAAoB,EACpB,iCAAiC,EACjC,iCAAiC,GAClC,MAAM,wCAAwC,CAAC;AAChD,OAAO,EAAE,sBAAsB,EAAE,MAAM,oCAAoC,CAAC;AAC5E,YAAY,EACV,gBAAgB,EAChB,6BAA6B,GAC9B,MAAM,oCAAoC,CAAC;AAC5C,OAAO,EACL,mBAAmB,EACnB,iBAAiB,EACjB,0BAA0B,EAC1B,wBAAwB,EACxB,yBAAyB,EACzB,2BAA2B,EAC3B,wBAAwB,GACzB,MAAM,+BAA+B,CAAC;AACvC,YAAY,EACV,oBAAoB,EACpB,kBAAkB,EAClB,mBAAmB,EACnB,yBAAyB,GAC1B,MAAM,+BAA+B,CAAC;AAEvC,cAAc,oBAAoB,CAAC"}
|
|
@@ -11,6 +11,7 @@ export { RuntimeEventBus } from './events/index.js';
|
|
|
11
11
|
export { createEventEnvelope } from './event-envelope.js';
|
|
12
12
|
export { RUNTIME_EVENT_DOMAINS, isRuntimeEventDomain } from './events/domain-map.js';
|
|
13
13
|
export { createRuntimeEventFeed, createRuntimeEventFeeds } from './event-feeds.js';
|
|
14
|
+
export { getSecuritySettingsReport } from './security-settings.js';
|
|
14
15
|
export { RuntimeHealthAggregator } from './health/aggregator.js';
|
|
15
16
|
export { CascadeEngine } from './health/cascade-engine.js';
|
|
16
17
|
export { CASCADE_RULES } from './health/cascade-rules.js';
|
|
@@ -15,12 +15,15 @@ import type { UserAuthManager } from '../../security/user-auth.js';
|
|
|
15
15
|
import { type RecoveryFileInfo } from '../session-persistence.js';
|
|
16
16
|
import { type ManagedWorktreeMeta, type WorktreeOwnershipSummary } from '../worktree/registry.js';
|
|
17
17
|
import type { ManagedRollbackRecord, SettingsConflictRecord, StagedManagedBundle } from '../settings/control-plane-store.js';
|
|
18
|
+
import type { FeatureFlagManager } from '../feature-flags/index.js';
|
|
19
|
+
import { type SecuritySettingReport } from '../security-settings.js';
|
|
18
20
|
export interface IntegrationHelpersContext {
|
|
19
21
|
readonly workingDirectory: string;
|
|
20
22
|
readonly homeDirectory: string;
|
|
21
23
|
readonly runtimeStore: RuntimeStore;
|
|
22
24
|
readonly runtimeBus: RuntimeEventBus;
|
|
23
25
|
readonly configManager?: ConfigManager;
|
|
26
|
+
readonly featureFlags?: FeatureFlagManager;
|
|
24
27
|
readonly getConversationTitle?: () => string | undefined;
|
|
25
28
|
readonly automationManager: AutomationManager;
|
|
26
29
|
readonly approvalBroker: ApprovalBroker;
|
|
@@ -99,6 +102,7 @@ export declare class IntegrationHelperService {
|
|
|
99
102
|
getHealthSnapshot(): Record<string, unknown>;
|
|
100
103
|
getAccountsSnapshot(): Promise<Record<string, unknown>>;
|
|
101
104
|
getSettingsSnapshot(): SettingsSnapshot;
|
|
105
|
+
getSecuritySettingsReport(): readonly SecuritySettingReport[];
|
|
102
106
|
getLocalAuthSnapshot(): Record<string, unknown>;
|
|
103
107
|
getContinuitySnapshot(): ContinuitySnapshot;
|
|
104
108
|
getWorktreeSnapshot(): WorktreeSnapshot;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../../src/_internal/platform/runtime/integration/helpers.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACtD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAC;AACxE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AACzE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAC9D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM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ings/control-plane.js';
|
|
|
3
3
|
import { checkRecoveryFile, readLastSessionPointer } from '../session-persistence.js';
|
|
4
4
|
import { listPersistedWorktreeMeta, summarizeWorktreeOwnership } from '../worktree/registry.js';
|
|
5
5
|
import { inspectInboundTls, inspectOutboundTls } from '../network/index.js';
|
|
6
|
+
import { getSecuritySettingsReport } from '../security-settings.js';
|
|
6
7
|
const EVENT_DOMAINS = [
|
|
7
8
|
'session',
|
|
8
9
|
'turn',
|
|
@@ -426,6 +427,9 @@ export class IntegrationHelperService {
|
|
|
426
427
|
rollbackHistory: snapshot.rollbackHistory,
|
|
427
428
|
};
|
|
428
429
|
}
|
|
430
|
+
getSecuritySettingsReport() {
|
|
431
|
+
return getSecuritySettingsReport(this.context.featureFlags);
|
|
432
|
+
}
|
|
429
433
|
getLocalAuthSnapshot() {
|
|
430
434
|
const snapshot = this.context.localUserAuthManager.inspect();
|
|
431
435
|
return {
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { FlagState } from './feature-flags/types.js';
|
|
2
|
+
export interface SecuritySettingReport {
|
|
3
|
+
readonly key: string;
|
|
4
|
+
readonly type: 'feature-flag' | 'configuration';
|
|
5
|
+
readonly defaultState: FlagState | string;
|
|
6
|
+
readonly currentState: FlagState | string;
|
|
7
|
+
readonly securityRelevant: true;
|
|
8
|
+
readonly summary: string;
|
|
9
|
+
readonly insecureWhen: string;
|
|
10
|
+
readonly enablementEffect: string;
|
|
11
|
+
readonly enablementRequirements: readonly string[];
|
|
12
|
+
readonly compatibilityNotes: readonly string[];
|
|
13
|
+
}
|
|
14
|
+
export interface SecuritySettingsReporter {
|
|
15
|
+
getState?(flagId: string): FlagState;
|
|
16
|
+
isEnabled?(flagId: string): boolean;
|
|
17
|
+
}
|
|
18
|
+
export declare function getSecuritySettingsReport(reporter: SecuritySettingsReporter | null | undefined): SecuritySettingReport[];
|
|
19
|
+
//# sourceMappingURL=security-settings.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"security-settings.d.ts","sourceRoot":"","sources":["../../../../src/_internal/platform/runtime/security-settings.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,0BAA0B,CAAC;AAE1D,MAAM,WAAW,qBAAqB;IACpC,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,IAAI,EAAE,cAAc,GAAG,eAAe,CAAC;IAChD,QAAQ,CAAC,YAAY,EAAE,SAAS,GAAG,MAAM,CAAC;IAC1C,QAAQ,CAAC,YAAY,EAAE,SAAS,GAAG,MAAM,CAAC;IAC1C,QAAQ,CAAC,gBAAgB,EAAE,IAAI,CAAC;IAChC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,gBAAgB,EAAE,MAAM,CAAC;IAClC,QAAQ,CAAC,sBAAsB,EAAE,SAAS,MAAM,EAAE,CAAC;IACnD,QAAQ,CAAC,kBAAkB,EAAE,SAAS,MAAM,EAAE,CAAC;CAChD;AAED,MAAM,WAAW,wBAAwB;IACvC,QAAQ,CAAC,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC;IACrC,SAAS,CAAC,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC;CACrC;AA2LD,wBAAgB,yBAAyB,CACvC,QAAQ,EAAE,wBAAwB,GAAG,IAAI,GAAG,SAAS,GACpD,qBAAqB,EAAE,CAazB"}
|