diff --git a/server/routers/org/getOrg.ts b/server/routers/org/getOrg.ts index 642efb5b9..bd8746e17 100644 --- a/server/routers/org/getOrg.ts +++ b/server/routers/org/getOrg.ts @@ -16,13 +16,12 @@ const getOrgSchema = z.strictObject({ }); export type GetOrgResponse = { - org: Org; + org: Omit; }; const GetOrgResponseDataSchema = z.object({ org: z.object({}).passthrough() }); - registry.registerPath({ method: "get", path: "/org/{orgId}", @@ -76,9 +75,12 @@ export async function getOrg( ); } + // sshCaPrivateKey is encrypted anyway but just to be safe + const { sshCaPrivateKey: _, ...orgWithoutPrivateKey } = org; + return response(res, { data: { - org + org: orgWithoutPrivateKey }, success: true, error: false,