/** * Writing Jira without the MCP channel. * * The companion to cli/jira-read.ts, for the same reason and with the same * shape. A session whose MCP registry came up in a failed state cannot be shown * the tools - Claude Code has no reload surface for a running session - so JAM, * its credentials and its Jira access can all be healthy while `jira_write_plan` * is simply unreachable. Reads were addressed to the shell first; this is the * other half. * * Nothing here is a second write path. `write-plan` and `write-apply` call the * same `planWrite` / `applyWritePlan` the tools call, with the same deps, the * same project binding, the same whitelist and the same plan store - so a plan * made through MCP can be applied here, which is the point when MCP is what * broke. * * The two-call contract is not relaxed for the shell: * * write-plan reads Jira, decides what is possible, writes nothing * write-apply takes a planId and nothing else, then reads the result back * * There is deliberately no `jam jira comment` or `jam jira close`. A shortcut * that skips planning is exactly what the write plane exists to prevent, and * being on a terminal does not change that. * * Contract, enforced by tests: * stdout - one JSON document and nothing else, no ANSI, no prompts * stderr - diagnostics only * * `write-apply` never asks for confirmation. What to write was settled when the * plan was made; a prompt here would be a second approval step, which is a * different feature and not this one. */ import { type BuildDepsOptions, type JamDeps } from "../deps.js"; export declare const JIRA_WRITE_USAGE: string; export type JiraWriteOptions = BuildDepsOptions & { /** Injected by tests so no test reaches a real Jira. */ deps?: JamDeps; /** Where the JSON document goes. Defaults to stdout. */ write?: (text: string) => void; /** Where diagnostics go. Defaults to stderr. */ warn?: (text: string) => void; }; export declare function runJiraWrite(argv: readonly string[], options?: JiraWriteOptions): Promise;