import { type SkillBaseContext, type SkillBasePermission, type SkillFilesystemProvider, type SkillResourceIndex } from "../_shared/skillCore.js";
import type { SkillToolResult } from "../_shared/baseToolAdapter.js";
export type SkillManagementAction = "list" | "inspect" | "activate" | "load" | "enable" | "disable" | "install" | "link" | "reload";
export type SkillManagementTarget = {
    action: SkillManagementAction;
    skillId?: string;
    registryRoot?: string;
    sourcePath?: string;
    metadataPatch?: Readonly<Record<string, unknown>>;
};
export type SkillManagementRequest = {
    target?: unknown;
    context?: SkillBaseContext;
    provider?: SkillFilesystemProvider;
};
export type SkillManagementErrorCode = "MISSING_ACTION" | "INVALID_ACTION" | "MISSING_SKILL_ID" | "INVALID_SKILL_ID" | "MISSING_REGISTRY_ROOT" | "SCOPE_REJECTED" | "PERMISSION_DENIED" | "GOVERNANCE_REJECTED" | "PROVIDER_UNAVAILABLE" | "PROVIDER_REJECTED";
export type SkillManagementOutput = {
    kind: "agentCore.basicTool.skill.management.output";
    target: SkillManagementTarget;
    runtimeEntry: {
        port: "BaseToolExecutorPort.filesystem.readText/list/writeText";
        runtimeOwnsFilesystem: true;
    };
    managementEnvelope: {
        action: SkillManagementAction;
        affectedSkillIds: readonly string[];
        registryRoot?: string;
        skillRoot?: string;
        metadataKeys: readonly string[];
        skill?: {
            name: string;
            description: string;
            skillPath: string;
            body?: string;
            resourceIndex?: SkillResourceIndex;
            modelInstructionEnvelope?: string;
        };
        registryEntries?: readonly string[];
    };
    dryRun: boolean;
    executionBlocked: boolean;
    permissionsRequired: readonly SkillBasePermission[];
    unsafeSideEffects: boolean;
};
export type SkillManagementResult = SkillToolResult<SkillManagementOutput, SkillManagementErrorCode>;
export declare const skillManagementDescriptor: {
    readonly toolId: "skill.management";
    readonly capability: "manage-skill";
    readonly defaultDryRun: true;
    readonly permissionsByAction: {
        list: ("filesystem:read" | "skill:read")[];
        inspect: ("filesystem:read" | "skill:read")[];
        activate: ("filesystem:read" | "skill:read")[];
        load: ("filesystem:read" | "skill:read")[];
        enable: ("filesystem:write" | "skill:read" | "skill:write")[];
        disable: ("filesystem:write" | "skill:read" | "skill:write")[];
        install: ("filesystem:write" | "skill:read" | "skill:write")[];
        link: ("filesystem:write" | "skill:read" | "skill:write")[];
        reload: ("filesystem:read" | "skill:read")[];
    };
};
export declare function executeSkillManagement(request?: SkillManagementRequest): Promise<SkillManagementResult>;
export declare const planSkillManagement: typeof executeSkillManagement;
