From 57c49096de53e49f5fa8f1d344678077fe70d4ea Mon Sep 17 00:00:00 2001 From: Jeff Emmett Date: Fri, 26 Dec 2025 10:49:03 -0500 Subject: [PATCH] fix: use WORKER_URL for networking API to fix connections loading MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The connectionService was using a relative path '/api/networking' which caused requests to go to the Pages frontend URL instead of the Worker API. This resulted in HTML being returned instead of JSON. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- src/lib/networking/connectionService.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/lib/networking/connectionService.ts b/src/lib/networking/connectionService.ts index bca7568..7ee8658 100644 --- a/src/lib/networking/connectionService.ts +++ b/src/lib/networking/connectionService.ts @@ -19,12 +19,13 @@ import type { GraphEdge, TrustLevel, } from './types'; +import { WORKER_URL } from '../../constants/workerUrl'; // ============================================================================= // Configuration // ============================================================================= -const API_BASE = '/api/networking'; +const API_BASE = `${WORKER_URL}/api/networking`; // ============================================================================= // Helper Functions