Skip to content

Open-source manufacturing ERP, MES and QMS. Quoting, MRP, inventory, shop floor, quality and lot/serial traceability on one Postgres schema, with a REST API and MCP server. Self-host or use Carbon Cloud.

fix(integrations): check the Mount API URL scheme without a refinement

Rauld025a733fa4d
diff --git a/packages/ee/src/mount/config.tsx b/packages/ee/src/mount/config.tsx
index f10fcb8f5f..45ce6442eb 100644
--- a/packages/ee/src/mount/config.tsx
+++ b/packages/ee/src/mount/config.tsx
@@ -1,16 +1,18 @@
import type { ComponentProps } from "react";
import { z } from "zod";
import { defineIntegration } from "../fns";
-import { isHttpsUrl, MOUNT_DEFAULT_BASE_URL } from "./lib/constants";
+import { MOUNT_DEFAULT_BASE_URL } from "./lib/constants";
const MountSettingsSchema = z.object({
clientId: z.string().min(1),
// Empty means "keep the existing vaulted secret"; presence enforced at install.
clientSecret: z.string(),
+ // A plain string check, not a refinement: zod v4 skips refinements for a
+ // `.default()` value (conformance: no-default-on-effects).
baseUrl: z
.string()
.url()
- .refine(isHttpsUrl, { message: "Must be an HTTPS URL" })
+ .startsWith("https://", { message: "Must be an HTTPS URL" })
.default(MOUNT_DEFAULT_BASE_URL),
tenant: z.string().min(1),
scope: z.string().optional(),