Dashboard › cli › Distillation
d640953f-0ae9-4d39-a2b2-202e3b2b7aa8["lore_tm_v1_qRtCTKdo8sekUa_iIZ8ZVz3f7XIxz2je-yVXodOiOnk","lore_tm_v1_yE8SQ2Bl1ZYDbmo7SOP7PtgSN4wl36vOOa43LmOQ2iA","lore_tm_v1_gtCSs-ldJmRWK6ZCl3WYiD4KymgH5TWVuNnDqT4uUc0","lore_tm_v1_MCun8fJAcmCo167sN52rkj9ksfqDQ_rsZmVvcalJosE","lore_tm_v1_5ucpPC3OwhWwXZUeV8LLVoJYDZLSQsmFaDibnWNlQt0","lore_tm_v1_E1vuPC46BBsuK7bxFqvSDRgTdAGphyb7g-MMaklVVDo","lore_tm_v1_Gw5QQPbUvwufWzdqU-Z09WWoX2mQWTiMxiOz6P41F8Q","lore_tm_v1_302aaRrbCV0qm2N0xPxOjFI_QcKk6R9lZbLz84u7RV0"]
packages/cli/script/check-fragments.ts is a 316-line fragment validator supporting tsx script/check-fragments.ts and strict mode via tsx script/check-fragments.ts --strict; non-strict mode warns for missing subcommand coverage, while --strict treats those omissions as errors.packages/cli/script/check-fragments.ts ensures the generated stub src/generated/skill-content.ts exists before dynamically importing ../src/app.js; when absent, it creates src/generated/ recursively and writes export const SKILL_FILES: [string, string][] = [];\n.${DOCS_FRAGMENTS}/commands, skips the help route via SKIP_ROUTES, and expects one .md fragment per extracted route plus index.md.content.includes("---\ntitle:") or content.startsWith("---\n"), the generated marker <!-- GENERATED:END -->, and missing required top-level fragment ${DOCS_FRAGMENTS}/configuration.md.packages/cli/script/check-fragments.ts accepts: 1. the full CLI command path anywhere in content; 2. for a default command, a bare sentry <route> match; 3. a level 1–4 Markdown heading containing the leaf subcommand outside fenced code blocks. Commands already carrying examples are skipped.packages/cli/script/check-fragments.ts derives default subcommands by comparing the Stricli route map’s getDefaultCommand() object reference with targets returned by getAllEntries().Fragment missing subcommand coverage: <path>, followed by Not documented: ... and a hint to add a heading or command example; final success output reports the exact command-fragment count as <route count> routes + index and the required top-level-fragment count.target?: string: packages/cli/src/commands/trace/list.ts:261, replay/list.ts:325, explore.ts:741, project/list.ts:732, issue/list.ts:1524, feedback/list.ts:198, release/list.ts:700, agent-conversation/list.ts:168, alert/metrics/list.ts:555, and alert/issues/list.ts:561.packages/cli/src/commands/trace/list.ts defines an optional positional placeholder "org/project" with brief "<org>/<project> or <project> (search)"; its function resolves the target through resolveOrgProjectFromArg(target, cwd, COMMAND_NAME), resolves the slug to a numeric ID via resolveLogProjectId(org, project), and scopes pagination with buildPaginationContextKey("trace", \${org}/${project}`, { sort, q, period })`.packages/cli/src/commands/agent-conversation/list.ts defines optional positional "org" and computes USAGE_HINT as sentry ${COMMAND_NAME} ${getPositionalString(POSITIONAL)}; omitted organizations are resolved with resolveOrg({ org: target, cwd }), and failure throws new ContextError("Organization", USAGE_HINT).packages/cli/src/commands/agent-conversation/list.ts metadata contains 5 ordered examples: 1. sentry agent-conversation list; 2. sentry agent-conversation list my-org; 3. sentry agent-conversation list --limit 50 --period 24h; 4. sentry agent-conversation list -q "has:errors"; 5. sentry agent-conversation list my-org -c next.COMMAND_NAME = "agent-conversation list", PAGINATION_KEY = "agent-conversation-list", and DEFAULT_PERIOD = "7d"; JSON output is an envelope with data, hasMore, and boolean hasPrev, plus nextCursor when present.sentry agent-conversation list ${org} -c next${flagSuffix} and sentry agent-conversation list ${org} -c prev${flagSuffix}; the suffix preserves -q "<query>" and any non-default period.packages/cli/src/commands/trace/view.ts: sentry trace view [<org>/<project>/]<trace-id>, and in packages/cli/src/commands/trace/logs.ts: sentry trace logs [<org>/[<project>/]]<trace-id>.packages/cli/src/lib/list-command.ts was changed to import and use CommandDocumentation from ./command.js for buildListCommand documentation and for OrgListCommandDocs, replacing narrower local types that only permitted brief and optional fullDescription; this allows complete command documentation metadata such as examples to pass through.buildListCommand must always inject --fresh unless the command already defines it.buildListCommand injects --cursor unless options.noCursorFlag is set or the command already defines cursor; it injects alias -f unless options.noFreshAlias is set or alias key f already exists, and alias -c unless cursor injection is opted out or alias key c already exists.ListCommandOptions contains noCursorFlag?: boolean and noFreshAlias?: boolean; the former supports commands such as streaming log list, while the latter supports commands where -f means --follow.buildListCommand wraps command execution to call applyFreshFlag(flags) before invoking the original function.buildListCommand is always the target using the org/project pattern.buildListCommand passes its first positional argument through interceptSubcommand() when it is a string or undefined; this handles plural aliases by detecting singular-route subcommand names, writing Tip: "<name>" is a subcommand. Running: sentry <route> <name>, and replacing that target with undefined for auto-detection.interceptSubcommand(target, stderr, routeName) trims the target only for subcommand-name matching; if no match is found, it returns the original untrimmed target.buildListCommand: trace/list.ts:198, issue/list.ts:1450, issue/events.ts:68, feedback/list.ts:132, explore.ts:621, event/list.ts:78, dashboard/list.ts:366, span/list.ts:540, alert/metrics/list.ts:511, alert/issues/list.ts:517, agent-conversation/list.ts:111, project/list.ts:680, release/list.ts:631, and replay/list.ts:250.packages/cli/src/lib/mutate-command.ts was changed to import and use CommandDocumentation from ./command.js for buildDeleteCommand, replacing the narrower inline docs type containing only brief and optional fullDescription.buildDeleteCommand must always inject --yes unless the command already defines it.buildDeleteCommand injects --force unless options.noForceFlag is set or force already exists, and injects --dry-run unless options.noDryRunFlag is set or dry-run already exists.buildDeleteCommand injects alias -y when alias key y is free, alias -f when force is not opted out and key f is free, and alias -n when dry-run is not opted out and key n is free.DeleteCommandOptions contains noForceFlag?: boolean, noDryRunFlag?: boolean, and noNonInteractiveGuard?: boolean.noNonInteractiveGuard is enabled, buildDeleteCommand runs guardNonInteractive() before the original command function using the yes, force, and dry-run flag values; non-TTY destructive execution requires --yes or --force, while dry runs bypass the guard.