/** * Signposts for scaffolded subcommands. * * A stub that refuses with nothing but "not implemented; see --help" — where * `--help` lists the same unimplemented command — is a closed circuit, and an * agent's way out of a closed circuit is to leave gws-axi entirely and drive * the Google APIs with the raw token, discarding write-protection and error * translation with it. So every stub declares the working commands that do * some or all of its job, and the same list feeds all three surfaces a caller * can hit: the NOT_IMPLEMENTED error, the stub's own --help, and the service * help screen. * * See specs/principles.md#no-dead-end-surfaces and specs/api/conventions.md * ("Unimplemented and unsupported surfaces"). */ import { AxiError } from "axi-sdk-js"; export interface StubbableSubcommand { name: string; handler?: unknown; /** * Runnable gws-axi commands that accomplish some or all of this subcommand's * job. Each line names the command AND where it falls short — these are * mostly wholesale-replace substitutes for a granular edit, and a signpost * that oversells is worse than none. Omit when nothing comes close. */ instead?: string[]; } /** * The refusal for a scaffolded subcommand. Alternatives lead; the account * diagnostic and the pointer to the planned surface follow, because they are * context rather than a next step. */ export declare function notImplemented(service: string, sub: string, account: string, instead?: string[]): AxiError; /** Append the `instead[N]:` block to a stubbed subcommand's own --help. */ export declare function withInstead(help: string, instead?: string[]): string; /** * The service-level `alternatives[N]:` block, deduped across every stub. * Returns "" when the service has no stubs, so fully-implemented services * (calendar) gain nothing. */ export declare function renderAlternatives(subs: StubbableSubcommand[]): string;