From 0f24280943e6c5625dd16175a725cb9f5a8857e6 Mon Sep 17 00:00:00 2001 From: shreyas-lyzr Date: Sun, 24 May 2026 13:07:57 -0400 Subject: [PATCH] fix: add financial_governance to ComplianceConfig type MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit PR #79 added financial_governance usage in src/adapters/shared.ts and src/commands/validate.ts and the JSON schema, but never added the field to the ComplianceConfig TypeScript interface — breaking the build with TS2339 and blocking the npm release. Adds the financial_governance shape (enabled, firewall, spending, approval) matching all field accesses. spending.max_per_transaction_cents is required (number) so validate.ts's '<= 0' check compiles under strict. --- src/utils/loader.ts | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/utils/loader.ts b/src/utils/loader.ts index fda3c09..30e851f 100644 --- a/src/utils/loader.ts +++ b/src/utils/loader.ts @@ -141,6 +141,22 @@ export interface ComplianceConfig { }>; enforcement?: string; }; + financial_governance?: { + enabled?: boolean; + firewall?: string; + spending?: { + max_per_transaction_cents: number; + max_monthly_cents?: number; + currency?: string; + allowed_categories?: string[]; + blocked_categories?: string[]; + }; + approval?: { + require_above_cents?: number; + timeout_minutes?: number; + auto_deny_on_timeout?: boolean; + }; + }; } export function loadAgentManifest(dir: string): AgentManifest {