Bugfix: Why were Vitto Command Hub components showing incorrect/empt...

Documentation for Sessions

🐛 Bugfix: Why were Vitto Command Hub components showing incorrect/empt...

Date: 2026-02-17
Time: 18:21:55 UTC
Session: gspace1-111.4
Agent: angular
Confidence: 100%
Status: ✅ Documented


📋 Decision Context

Question:

Why were Vitto Command Hub components showing incorrect/empty data?

Task: Fix Vitto Command Hub data display issues across all components


🎯 Decision Made

Chosen:

Fixed 7 confirmed bugs: field mapping mismatches between backend response shapes and frontend parsing. Memory used 'content' but backend returns 'summary'; stats used 'total' but backend returns 'totalMemories'; IDs used '_id' but backend returns 'memoryId'; Observatory components parsed .data but backends return .approvals/.entries; Cost Dashboard called non-existent /agents/metrics endpoint; added getMcpStatus() for real data from McpStatusController.

Options Considered:


💭 Reasoning

Root cause was systematic: frontend components were written assuming a generic { data: [...] } wrapper, but each backend endpoint uses its own named response shape (approvals, entries, memories, etc.). The Cost Dashboard called a non-existent endpoint (/agents/metrics) when the real data lives at /ai/mcp/status. The memory field mapping bugs (summary vs content, memoryId vs _id, totalMemories vs total) were invisible — cards rendered with empty text, stats showed 0, and edit/delete operations would fail silently.


📁 Files Involved


🔗 Related


Auto-generated by MCP Smart Consolidation