/**
 * GitHub Issue Writer Service
 *
 * Octokit-backed implementation of `IGitHubIssueWriter`. Reuses the
 * existing GitHub-integration token (resolved by `gh auth token` — same path
 * `IGitHubRepositoryService` uses) so no new auth flow or token storage is
 * introduced (NFR-10).
 *
 * Resilience: the production factory composes `@octokit/rest` with the
 * retry and throttling plugins. Retry handles transient 5xx and abuse-rate-
 * limit (Retry-After). Throttling pauses requests proactively when primary
 * or secondary rate-limit budgets are near exhaustion.
 */
import { type IGitHubIssueWriter, type IssueRef } from '../../../application/ports/output/services/github-issue-writer.interface.js';
/**
 * Minimal Octokit shape this adapter touches. Defined in terms of methods so
 * tests can substitute a hand-rolled double without pulling Octokit's full
 * generated types into the test surface.
 */
export interface OctokitLike {
    issues: {
        addLabels(params: {
            owner: string;
            repo: string;
            issue_number: number;
            labels: readonly string[];
        }): Promise<unknown>;
        removeLabel(params: {
            owner: string;
            repo: string;
            issue_number: number;
            name: string;
        }): Promise<unknown>;
        createComment(params: {
            owner: string;
            repo: string;
            issue_number: number;
            body: string;
        }): Promise<unknown>;
        addAssignees(params: {
            owner: string;
            repo: string;
            issue_number: number;
            assignees: readonly string[];
        }): Promise<unknown>;
    };
}
/**
 * Constructs an Octokit-shaped client given a resolved bearer token.
 * The default factory composes retry + throttling plugins.
 */
export type OctokitFactory = (options: {
    auth: string;
}) => OctokitLike;
/**
 * Resolves the bearer token from the existing GitHub-integration code path
 * (i.e. `gh auth token`). Returns the raw token string.
 */
export type TokenResolver = () => Promise<string>;
/**
 * Default production factory — composes retry + throttling. Tests inject a
 * stub factory instead so they never hit the network.
 */
export declare const defaultOctokitFactory: OctokitFactory;
/**
 * Default token resolver — shells out to `gh auth token` exactly like
 * `IGitHubRepositoryService.checkAuth` does. Reuses any token already
 * configured by the user (no new auth flow per NFR-10).
 */
export declare const defaultTokenResolver: TokenResolver;
export declare class GitHubIssueWriter implements IGitHubIssueWriter {
    private readonly tokenResolver;
    private readonly octokitFactory;
    private clientPromise;
    constructor(tokenResolver?: TokenResolver, octokitFactory?: OctokitFactory);
    addLabels(ref: IssueRef, labels: readonly string[]): Promise<void>;
    removeLabels(ref: IssueRef, labels: readonly string[]): Promise<void>;
    addComment(ref: IssueRef, body: string): Promise<void>;
    assignUsers(ref: IssueRef, logins: readonly string[]): Promise<void>;
    private client;
}
//# sourceMappingURL=github-issue-writer.service.d.ts.map