Issue: MCP Agent Handoff System Disconnected

Agent handoff system queues offline when backend connection drops

Issue: MCP Agent Handoff System Disconnected

Summary

The MCP multi-agent handoff system fails to deliver handoffs when the agent connection to the backend is in a disconnected state. Handoffs are queued locally as "offline" entries but never sync to the backend, meaning the cowork agent and GoGrab AI extension never see them.

Symptoms

Root Cause (Investigation Needed)

The agent system's authentication token has expired (hasToken: false, tokenExpiring: true). The backends are running (backend-api on 3000, backend-ai on 3001) but the MCP agent cannot authenticate to establish a WebSocket or HTTP connection.

Potential causes:

  1. Token expiration -- JWT token used by the MCP agent has expired and auto-refresh is failing
  2. Backend endpoint unreachable -- The agent registration/auth endpoint may not be accessible from the MCP server process
  3. MCP server restart needed -- The MCP server process may need to be restarted to re-authenticate

Impact

Workaround

Create handoffs directly from the GoGrab AI Chrome extension panel, which has its own authenticated connection (as confirmed by the popup showing "AUTH: Paco Guijarro, NETWORK: Online").

Environment

Next Steps

  1. Investigate the MCP agent token refresh mechanism
  2. Check if restarting the MCP server resolves the connection
  3. Add a reconnect/re-auth command to the agent MCP tools
  4. Consider adding a health check that warns when the agent is disconnected before attempting handoff creation