import type { CredentialStore } from "@earendil-works/pi-ai";
import type { ClaudeCliAccountCheck } from "./accounts.ts";
import { type ClaudeCliConnectionTestInput, type DefaultModelSelection } from "./claude-cli-connection-test.ts";
export type ProviderAccountTestErrorCode = "unsupported_provider" | "unknown_account" | "unsupported_account" | "needs_sign_in";
/** A refusal before any turn runs; `message` is the bare code the RPC error carries. */
export declare class ProviderAccountTestError extends Error {
    readonly code: ProviderAccountTestErrorCode;
    constructor(code: ProviderAccountTestErrorCode);
}
export declare function claudeCliDefaultModel(cwd: string): DefaultModelSelection;
export type ClaudeCliAccountTestInput = {
    readonly provider: string;
    /** Where `check` is read and written: the caller's own store, so its next listing shows the new check. */
    readonly store: CredentialStore;
    readonly name: string;
    readonly cwd: string;
    readonly signal?: AbortSignal;
    readonly connectionTest?: (input: ClaudeCliConnectionTestInput) => Promise<ClaudeCliAccountCheck>;
};
/**
 * Re-runs the sign-in connection test (one pinned "Reply with OK" turn, account fallback off) on one stored Claude
 * CLI account and stores its outcome as `check`. The turn is a probe (`queryWithAuthLane` `probe`): it runs on that
 * account even while it is blocked, recovers no other account, and stores or clears no block. It writes `check`,
 * applied to the slot as it is under the lock (blocks other sessions wrote meanwhile stay), plus the slot's `profile`
 * when the CLI reports a changed one (`claudeCliInitializationCheck` in auth-lane.ts, as on every turn). An account
 * that must sign in again is refused before any turn: no test can pass until it signs in.
 */
export declare function testClaudeCliAccount(input: ClaudeCliAccountTestInput): Promise<ClaudeCliAccountCheck>;
//# sourceMappingURL=claude-cli-account-test.d.ts.map