Dashboardsentry-api-schemagetsentry/cli detectAgent() returns str…

getsentry/cli detectAgent() returns string | undefined, not AgentInfo

Category: architecture
Confidence: 1.00
ID: 019de1e9-ce0c-7423-a68e-56eabc7ee584
Project ID: 6c9a871d-74f1-447a-a3e8-d61a6564a1a1
Cross-project: No
Recalled in other projects: 2
Source session: (none)
Created: 2026-08-06 12:05:45
Updated: 2026-08-06 12:05:45

Cross-Project Recalls

ProjectHitsLast recalled
cli 1 8d ago
opencode 1 8d ago

Content

After the detect-agent refactor (post-PR #896), detectAgent() returns a plain string | undefined (the agent name), not the former AgentInfo object ({ name, version?, role? }). The normalizeAgent, AGENT_ALIASES, and AgentInfo type were removed. Process-tree detection (detectAgentFromProcessTree()) also returns string | undefined. Use detectAgent() synchronously for banner/UI gating; use detectAgentFromProcessTree() for async telemetry.

Move to: