Dashboard › cli › Distillation
d31a10a9-f3c7-4a26-a904-266916157329["lore_tm_v1_f80lY8tP4Z3nbTqSwTZBrm0wQnAfoo-hOwTSdrB19dM","lore_tm_v1_mZ94PbjJXruRjmuccocRYVsZ9QIbZT-ozg3T4ZDzX2Q","lore_tm_v1_xb_98F4xH35R40zBqsPtH8ITYUePUcHFUo5IJyKoIC0","lore_tm_v1_kw7Jgb2TV3c7zB6LXzMKkPW7-bZb_ARvhD43zhL4oDw","lore_tm_v1_dB0a4uksoEL1PNC2cT2sIEEXCQ8MRcz9MBh06qbR7qM","lore_tm_v1_0xP5JYjkQqOydSZpXxewuo8gP1xB6OtBC1YEQxdbALA","lore_tm_v1_qMoMaCBDrCfIDhBm4MVnz0R8C12lW7cGDZIgQirDWhU","lore_tm_v1_AxFjVpyeMTg5FJUZyok7Ibyvx2pI_b3lff46ZLP-y4I","lore_tm_v1_FZ6mdu-nAHZzQkQTj37-eGu267F3wAJ644FMjB_T6bg"]
Date: Sep 8, 2026
/; [<org>/]<conversation-id> therefore has at most one slash, with the prefix treated as the organization and the remainder as the conversation ID.packages/cli/src/commands/agent-conversation/view.ts found USAGE_HINT = "sentry agent-conversation view [<org>/]<conversation-id>"; parseConversationTarget(target) trims input, uses the whole value as conversationId when no slash exists, splits at the first slash otherwise, and throws new ContextError("Conversation ID", USAGE_HINT, []) if either split segment is empty.viewCommand uses buildCommand with customUsage: ["[<org>/]<conversation-id>"], positional placeholder "org/conversation-id", FRESH_FLAG/FRESH_ALIASES, and examples: sentry agent-conversation view conv-123, sentry agent-conversation view my-org/conv-123, and sentry agent-conversation view my-org/conv-123 --json.viewCommand calls applyFreshFlag(flags), rejects an empty or whitespace-only target, resolves the optional organization via resolveOrg({ org: orgArg, cwd }), and throws new ContextError("Organization", USAGE_HINT) when resolution fails.getConversationSpans(org, conversationId) inside withProgress() with message "Fetching conversation spans..." and json: flags.json; it builds the result via buildTranscriptResult(conversationId, org, spans, title), assigns result.truncated = truncated, and yields new CommandOutput<TranscriptResult>(result).packages/cli/src/commands/agent-conversation/index.ts defines conversationRoute via buildRouteMap; routes are list: listCommand and view: viewCommand, the default command is "list", and documentation describes listing and viewing agent conversations from Sentry Explore.CommandReturn and never on individual yields.packages/cli/src/lib/command.ts defines command execution modes: non-streaming commands yield one CommandOutput<T> and may return { hint }; streaming commands render each yield immediately, but --json commands must yield one aggregate value when callers need one parseable JSON document because chunks are pretty-printed rather than JSONL; void commands may return without yielding for early exits such as --web.buildCommand wrapper consumes originalFunc with repeated generator.next(), sends each yielded value to handleYieldedValue(), captures the final value as CommandReturn | undefined, applies appendCacheHint(returned.hint) only when a return value exists, and calls writeFinalization() inside the "render" tracing phase.packages/cli/src/lib/command.ts finalizes streaming state only in human mode to avoid corrupting JSON, attempts positional-help recovery through maybeRecoverWithHelp(), and otherwise calls handleOutputError(err).buildCommand preserves the first docs.customUsage line on the built command as __primaryUsage, exposes outputConfig.schema as __jsonSchema for introspection and SKILL generation, and exposes the original generator as __rawFunc for internal dispatchers that must bypass telemetry, auth, rc-trust, and output wrapping.packages/cli/script/generate-skill-markdown.ts uses COMMAND_HEADING_RE to extract literal command paths while excluding positional usage. matchExampleToCommand() checks command paths longest-first so sentry auth login wins over sentry auth, then falls back to the group path; bare-group examples map to defaultCommandPath when available.packages/cli/script/generate-skill.ts produces 3 artifact groups: 1. compact plugins/sentry-cli/skills/sentry-cli/SKILL.md, 2. full per-route files under plugins/sentry-cli/skills/sentry-cli/references/*.md, 3. discovery manifest docs/public/.well-known/skills/index.json.generate-skill.ts bootstraps missing src/generated/skill-content.ts by creating src/generated/ and writing export const SKILL_FILES: ReadonlyMap<string, string> = new Map();; this occurs before dynamically importing ../src/app.js.findDefaultCommandName(routeMap) identifies a route mapβs default command by identity among getAllEntries(); a hidden default named "default" maps to "login" so bare sentry auth examples document the login path.["help", "auth", "org", "project", "issue", "event", "api"], with unlisted routes placed afterward alphabetically. Globally injected flags omitted from the compact index include "json", "fields", "help", "helpAll", and "log-level".getting-started.mdx, strips YAML frontmatter and MDX/Astro components, extracts "Install Script" and "Authentication" sections, and gathers bash code blocks plus the npm command from <PackageManagerCode ... npm="...">.getDefaultPrerequisites() emits installation examples curl https://cli.sentry.dev/install -fsS | bash and npm install -g sentry, plus authentication examples sentry auth, sentry auth --token YOUR_SENTRY_API_TOKEN, and sentry auth status.marked, collects depth-3 headings matching ### `sentry ...` , initializes an examples array per command path, associates bash blocks by current heading when possible, and otherwise uses longest-path content matching with the default-command fallback.loadCommandExamples(commandGroup, defaultCommandName?) reads commands/${commandGroup}.md; when present, its default command path is sentry ${commandGroup} ${defaultCommandName}. It supports both generated command headings and hand-written example sections by combining heading context with code-content matching.