export declare const REPO_PATTERN: RegExp; /** Clone/push URL that carries the token. Never log it or store it in a repo's git config. */ export declare const authedUrl: (repo: string, token: string) => string; export declare const plainUrl: (repo: string) => string; /** * Strips personal data from text bound for GitHub, where a public repo makes it public. * URLs keep only origin and path (query strings and fragments carry emails and session ids), then emails, * IP addresses and long digit runs (phone and card numbers) are masked. * ponytail: pattern-based, so a name or street address written in free text still gets through. */ export declare function redactPersonalData(text: string): string; /** * The repo's README as raw Markdown, or undefined when it has none or GitHub can't be reached. Tried with the token * first, then without it: a public repo needs no token, and a private one needs a token with Contents: Read-only * (an Issues-only token can't read it). */ export declare function getReadme(repo: string, token: string | undefined, f?: typeof fetch): Promise; export interface Issue { number: number; title: string; body: string | null; html_url: string; state: 'open' | 'closed'; author_association: string; labels: string[]; } export declare function getIssue(token: string, repo: string, number: number, f?: typeof fetch): Promise; /** Open issues with a label (pull requests excluded), newest first. All pages, so duplicates are found past the first 100. */ export declare function listOpenIssues(token: string, repo: string, label: string, f?: typeof fetch): Promise; export declare function listComments(token: string, repo: string, number: number, f?: typeof fetch): Promise; export declare function commentOnIssue(token: string, repo: string, number: number, body: string, f?: typeof fetch): Promise; export declare function addLabels(token: string, repo: string, number: number, labels: string[], f?: typeof fetch): Promise; export interface PullRequestInput { token: string; repo: string; head: string; base: string; title: string; body: string; } export declare function openPullRequest(input: PullRequestInput, f?: typeof fetch): Promise<{ url: string; number: number; }>; /** Used when the fix engine can't produce a passing fix: the findings go to the developers instead. */ export declare function openIssue(input: { token: string; repo: string; title: string; body: string; labels?: string[]; }, f?: typeof fetch): Promise<{ url: string; number: number; }>; /** Pushes the workspace's HEAD to `branch` on the remote. Errors are scrubbed of the token. */ export declare function pushBranch(cwd: string, remoteUrl: string, branch: string, token: string): Promise; export { checkTokenHealth, type TokenHealthStatus } from './token-health.js'; //# sourceMappingURL=index.d.ts.map