diff --git a/apps/sim/tools/agiloft/utils.ts b/apps/sim/tools/agiloft/utils.ts index 65c9deff49..c6e989054e 100644 --- a/apps/sim/tools/agiloft/utils.ts +++ b/apps/sim/tools/agiloft/utils.ts @@ -1,5 +1,4 @@ import { createLogger } from '@sim/logger' -import type { SecureFetchResponse } from '@/lib/core/security/input-validation.server' import type { AgiloftAttachmentInfoParams, AgiloftBaseParams, @@ -14,6 +13,21 @@ import type { } from '@/tools/agiloft/types' import type { HttpMethod, ToolResponse } from '@/tools/types' +/** + * Mirrors the shape of SecureFetchResponse from input-validation.server.ts. + * Defined locally to avoid importing the .server module into client bundles + * (it pulls in dns/promises which is Node-only). + */ +interface SecureFetchResponse { + ok: boolean + status: number + statusText: string + headers: { get(name: string): string | null } + text: () => Promise + json: () => Promise + arrayBuffer: () => Promise +} + const logger = createLogger('AgiloftAuth') /**