export type GitCloneRepositoryPermission = "git:read" | "filesystem:write";
export type GitCloneRepositoryRiskCategory = "remote-network" | "workspace-mutation";
export type GitCloneRepositoryGuard = {
    allowed?: boolean;
    accepted?: boolean;
    reason?: string;
};
export type GitCloneRepositoryContext = {
    runtimeId?: string;
    sessionId?: string;
    invocationId?: string;
    dryRun?: boolean;
    guard?: GitCloneRepositoryGuard;
    allowedRepositoryRoots?: readonly string[];
    grantedPermissions?: readonly GitCloneRepositoryPermission[];
    auditMetadata?: Readonly<Record<string, unknown>>;
};
export type GitCloneRepositoryTarget = {
    repositoryPath: string;
    remoteUrl: string;
    destinationPath: string;
    branch?: string;
    depth?: number;
    singleBranch: boolean;
    bare: boolean;
    mirror: boolean;
};
export type GitCloneRepositoryRequest = {
    target?: Partial<GitCloneRepositoryTarget>;
    context?: GitCloneRepositoryContext;
    provider?: GitCloneRepositoryProvider;
    timeoutMs?: number;
    metadata?: Readonly<Record<string, unknown>>;
    runtimeId?: string;
    invocationId?: string;
    repositoryPath?: string;
    cwd?: string;
    workspaceRoot?: string;
    remoteUrl?: string;
    destinationPath?: string;
    branch?: string;
    depth?: number;
    singleBranch?: boolean;
    bare?: boolean;
    mirror?: boolean;
    dryRun?: boolean;
};
export type GitCloneRepositoryRuntimeEntry = {
    owner: "runtime";
    port: "BaseToolExecutorPort.git.runGit";
    method: "runGit";
    binary: "git";
    argvMode: "fixed-clone-repository";
    allowedSubcommand: "clone";
};
export type GitCloneRepositoryRisk = {
    category: GitCloneRepositoryRiskCategory;
    riskLevel: "risky";
    mutatesRepository: true;
    mutatesWorkingTree: true;
    mayUseNetwork: true;
    createsRepositoryMetadata: true;
    spawnsProcess: true;
    requiresTapApproval: true;
    runtimeOwnsExecution: true;
};
export type GitCloneRepositoryEnvelope = {
    parser: "git-clone-output-v1";
    repositoryPath: string;
    remoteUrl: string;
    destinationPath: string;
    branch?: string;
    depth?: number;
    exitCode?: number;
    stdoutLineCount: number;
    stderrLineCount: number;
    operationHint?: string;
    cloned: boolean;
};
export type GitCloneRepositoryOutput = {
    kind: "agentCore.basicTool.git.cloneRepository";
    target: GitCloneRepositoryTarget;
    runtimeEntry: GitCloneRepositoryRuntimeEntry;
    risk: GitCloneRepositoryRisk;
    gitArgs: readonly string[];
    commandPreview: readonly string[];
    timeoutMs: number;
    dryRun: boolean;
    executionBlocked: boolean;
    providerCalled: boolean;
    exitCode?: number;
    stdout?: string;
    stderr?: string;
    permissionsRequired: readonly GitCloneRepositoryPermission[];
    unsafeSideEffects: true;
    mayUseNetwork: true;
    resultEnvelope: GitCloneRepositoryEnvelope;
};
export type GitCloneRepositoryPlan = {
    toolId: "git.cloneRepository";
    toolKind: "git.cloneRepository";
    capability: "clone-repository";
    runtimeId: string;
    invocationId: string;
    repositoryPath: string;
    remoteUrl: string;
    destinationPath: string;
    gitArgs: readonly string[];
    commandPreview: readonly string[];
    requiredPermissions: readonly GitCloneRepositoryPermission[];
    runtimeEntry: GitCloneRepositoryRuntimeEntry;
    risk: GitCloneRepositoryRisk;
    dispatch: "dry-run" | "runtime-git-executor";
    dryRun: boolean;
    wouldMutateRepository: true;
    unsafeSideEffects: true;
    outputEnvelope: {
        stdoutPreview: "";
        stderrPreview: "";
        parsed: false;
    };
    audit: {
        guard: "git-repository-network-runtime-guard";
        event: "basicTool.git.cloneRepository.planned";
        governanceRequired: true;
        tapCanWrap: true;
        metadata: Readonly<Record<string, unknown>>;
    };
};
export type GitCloneRepositoryErrorBoundary = "input" | "scope" | "permission" | "governance" | "provider";
export type GitCloneRepositoryErrorCode = "MISSING_REPOSITORY_PATH" | "MISSING_REQUIRED_FIELD" | "MISSING_TARGET_PATH" | "INVALID_ARGUMENT" | "INVALID_CONTEXT" | "INVALID_TIMEOUT" | "SCOPE_REJECTED" | "PERMISSION_DENIED" | "GOVERNANCE_REJECTED" | "PROVIDER_UNAVAILABLE" | "PROVIDER_REJECTED";
export type GitCloneRepositoryError = {
    code: GitCloneRepositoryErrorCode;
    message: string;
    boundary: GitCloneRepositoryErrorBoundary;
    publicSafe: true;
    safeForRuntimeInspection: true;
    internalDetailExposed: false;
};
export type GitCloneRepositoryAuditEvent = {
    type: string;
    toolId: "git.cloneRepository";
    invocationId: string;
    dryRun: boolean;
    repositoryPath?: string;
    metadata: Readonly<Record<string, unknown>>;
};
export type GitCloneRepositoryResult = {
    ok: true;
    toolId: "git.cloneRepository";
    output: GitCloneRepositoryOutput;
    plan: GitCloneRepositoryPlan;
    audit: readonly GitCloneRepositoryAuditEvent[];
    events: readonly string[];
} | {
    ok: false;
    toolId: "git.cloneRepository";
    error: GitCloneRepositoryError;
    audit: readonly GitCloneRepositoryAuditEvent[];
    events: readonly string[];
};
export type GitCloneRepositoryProviderRequest = {
    repositoryPath: string;
    args: readonly string[];
    timeoutMs?: number;
};
export type GitCloneRepositoryProviderResult = {
    exitCode: number;
    stdout: string;
    stderr: string;
};
export type GitCloneRepositoryProvider = (request: GitCloneRepositoryProviderRequest, context: GitCloneRepositoryContext) => GitCloneRepositoryProviderResult | Promise<GitCloneRepositoryProviderResult>;
export declare const gitCloneRepositoryDescriptor: {
    readonly toolId: "git.cloneRepository";
    readonly toolKind: "git.cloneRepository";
    readonly capability: "clone-repository";
    readonly route: "agent_executionEngine.basic_toolLayer.baseTools.gitBase.repository";
    readonly defaultDryRun: true;
    readonly defaultDispatch: "dry-run";
    readonly tapOwnsApproval: true;
    readonly requiresTapApproval: true;
    readonly runtimeEntryPort: "BaseToolExecutorPort.git.runGit";
    readonly operationRisk: "remote-network-workspace-mutation";
    readonly permissionsRequired: readonly ["git:read", "filesystem:write"];
    readonly defaultTimeoutMs: 120000;
    readonly maxTimeoutMs: 900000;
    readonly unsafeSideEffects: true;
};
export declare function parseGitCloneRepositoryResult(providerResult: GitCloneRepositoryProviderResult | undefined, target: GitCloneRepositoryTarget): GitCloneRepositoryEnvelope;
export declare function planGitRepositoryClone(request?: GitCloneRepositoryRequest): GitCloneRepositoryResult;
export declare const planGitCloneRepository: typeof planGitRepositoryClone;
export declare function executeGitCloneRepository(request?: GitCloneRepositoryRequest): Promise<GitCloneRepositoryResult>;
