Update hivegrid-cloud reference to latest main

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
davidandClaude Fable 5 committed 2026-07-08 16:15:37 +02:00
1 parent e98d38e716
commit 7b21524c86
3781 files changed
+373484 -225607

No files matched your search

@@ -120,7 +120,7 @@ describe("loadApiConfig", () => {
expect(result.ok).toBe(false);
expect(result.config).toMatchObject({
appName: "ToolController",
appName: "HiveGrid",
nodeEnv: "development",
listen: {
port: 3001,
@@ -135,7 +135,6 @@ describe("loadApiConfig", () => {
origins: {},
analytics: {},
mailjet: {},
stripe: {},
storage: {},
});
});
@@ -204,8 +203,13 @@ describe("loadApiConfig", () => {
JWT_SECRET: " jwt-secret-value ",
ANALYTICS_TOKEN: " analytics-token-value ",
MAILJET_WEBHOOK_SECRET: " mailjet-webhook-secret-value ",
STRIPE_SK: " stripe-secret-value ",
STRIPE_WEBHOOK_SIGNING_SECRET: " stripe-webhook-secret-value ",
LAGO_API_URL: " http://lago.internal:3000 ",
LAGO_API_KEY: " lago-api-key-value ",
LAGO_WEBHOOK_SECRET: " lago-webhook-secret-value ",
LAGO_TIMEOUT_MS: " 5000 ",
MOLLIE_API_KEY: " mollie-api-key-value ",
MOLLIE_PROFILE_ID: " mollie-profile-id-value ",
MOLLIE_TIMEOUT_MS: " 6000 ",
STORAGE_ENDPOINT: " https://storage.example.com ",
STORAGE_REGION: " us-east-1 ",
STORAGE_BUCKET: " uploads ",
@@ -238,9 +242,16 @@ describe("loadApiConfig", () => {
mailjet: {
webhookSecret: "mailjet-webhook-secret-value",
},
stripe: {
secretKey: "stripe-secret-value",
webhookSigningSecret: "stripe-webhook-secret-value",
lago: {
apiUrl: "http://lago.internal:3000",
apiKey: "lago-api-key-value",
webhookSecret: "lago-webhook-secret-value",
timeoutMs: 5000,
},
mollie: {
apiKey: "mollie-api-key-value",
profileId: "mollie-profile-id-value",
timeoutMs: 6000,
},
storage: {
endpoint: "https://storage.example.com",
@@ -266,6 +277,43 @@ describe("loadApiConfig", () => {
expect(loadApiConfig({ API_KEY_LEGACY_PLAINTEXT_FALLBACK: "invalid" }).config.apiKeys.allowLegacyPlaintextFallback).toBe(false);
});
test("defaults invalid Lago timeout without leaking Lago secrets into diagnostics", () => {
const result = loadApiConfig({
API_PORT: "not-a-port",
LAGO_API_URL: " https://lago.example.test ",
LAGO_API_KEY: " lago-secret-value ",
LAGO_WEBHOOK_SECRET: " lago-webhook-secret-value ",
LAGO_TIMEOUT_MS: "invalid",
});
expect(result.config.lago).toEqual({
apiUrl: "https://lago.example.test",
apiKey: "lago-secret-value",
webhookSecret: "lago-webhook-secret-value",
timeoutMs: 10_000,
});
const diagnosticText = JSON.stringify(result.diagnostics);
expect(diagnosticText).not.toContain("lago-secret-value");
expect(diagnosticText).not.toContain("lago-webhook-secret-value");
});
test("defaults invalid Mollie timeout without leaking Mollie secrets into diagnostics", () => {
const result = loadApiConfig({
API_PORT: "not-a-port",
MOLLIE_API_KEY: " mollie-secret-value ",
MOLLIE_PROFILE_ID: " mollie-profile-value ",
MOLLIE_TIMEOUT_MS: "invalid",
});
expect(result.config.mollie).toEqual({
apiKey: "mollie-secret-value",
profileId: "mollie-profile-value",
timeoutMs: 10_000,
});
const diagnosticText = JSON.stringify(result.diagnostics);
expect(diagnosticText).not.toContain("mollie-secret-value");
});
test("normalizes empty storage strings to undefined and redacts storage secrets from diagnostics", () => {
const storageSecretValues = ["storage-access-key-id-value", "storage-secret-access-key-value", "storage-session-token-value"];
const result = loadApiConfig({