Fix: Why was /core/templates returning 404 when accessing api.gog...

Documentation for Sessions

📝 Fix: Why was /core/templates returning 404 when accessing api.gog...

Date: 2026-01-28
Time: 16:10:39 UTC
Session: editor2-72.77
Agent: angular
Confidence: 100%
Status: ✅ Documented


📋 Decision Context

Question:

Why was /core/templates returning 404 when accessing api.gograb.space/core/templates instead of api.gograb.space/api/core/templates?

Task: Not specified


🎯 Decision Made

Chosen:

core-properties has its own API_BASE_URL token (to avoid circular deps with core-angular) that had wrong default value 'https://api.gograb.space' instead of 'https://api.gograb.space/api'. Fixed by: 1) Updating the factory default to include /api suffix, 2) Adding provider in app.config.ts to use environment.backendApiUrl for the core-properties token.

Options Considered:

  1. Backend endpoint misconfigured
  2. Frontend using wrong URL path
  3. core-properties has separate API_BASE_URL token with wrong default

💭 Reasoning

The core-properties library defines its own API_BASE_URL token to avoid circular dependency with core-angular. However, this token's factory default was missing the /api suffix. The app.config.ts was only providing the core-angular token, not the core-properties one. Fixed both: updated the default and added the provider.


📁 Files Involved


🔗 Related


Auto-generated by MCP Smart Consolidation