/**
 * List this user's mergeable PRs across registered project repos.
 *
 * The built-in `pr-merge-on-green` monitor used to run `gh pr list --author @me`
 * with no `--repo`. `gh` then infers the repository from the working directory,
 * and the daemon's cwd is not a git repo, so every poll returned empty.
 *
 * This helper:
 *   1. Collects GitHub slugs from `~/.agents/projects/*.yaml` (`repo` / `repos[].slug`).
 *   2. Canonicalizes each slug (`gh repo view` — `phnx-labs/agents-cli` lists
 *      nothing; the live name is `phnx-labs/agi-cli`).
 *   3. Runs `gh pr list --repo <slug> --author @me` (cwd-independent).
 *   4. Keeps CI-green PRs with a merge-guard verdict (formal APPROVED review
 *      OR an APPROVE comment on THIS PR).
 *
 * Stdout is a single line of `owner/repo#n` refs (or empty). Empty is a silent
 * observation under `condition.mode: every` — do not write to stderr on the
 * no-match path, or command.ts will treat stderr as the observation and fire.
 */
import { type ProjectDef } from '../projects.js';
import { type MergeablePrInput, type StatusCheck } from './pr-verdict.js';
export type GhExec = (args: string[]) => Promise<string>;
/** Default runner: `gh` with a 30s timeout. Non-zero exit throws. */
export declare function ghExec(args: string[]): Promise<string>;
/** Unique GitHub slugs declared on project definitions. */
export declare function projectRepoSlugs(defs: readonly ProjectDef[]): string[];
/**
 * Resolve a slug to GitHub's current `nameWithOwner`. A renamed repo
 * (`phnx-labs/agents-cli` → `phnx-labs/agi-cli`) lists zero PRs under the old
 * name; `gh repo view` returns the live one. On error, keep the input slug.
 */
export declare function canonicalizeRepo(slug: string, gh: GhExec): Promise<string>;
interface ListedPr {
    number: number;
    reviewDecision?: string | null;
    statusCheckRollup?: StatusCheck[] | null;
}
/**
 * Given PRs already listed for one repo, attach verdict payloads only for the
 * CI-green ones that lack a formal APPROVED reviewDecision, then select.
 */
export declare function selectListedMergeable(repo: string, listed: readonly ListedPr[], gh: GhExec): Promise<MergeablePrInput[]>;
/** List mergeable `owner/repo#n` refs, space-separated. Empty string if none. */
export declare function listMergeableRefs(opts?: {
    gh?: GhExec;
    defs?: ProjectDef[];
    repos?: string[];
}): Promise<string>;
export {};
