"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.register = register;
const zod_1 = require("zod");
function register(server, mgr) {
    server.registerTool('skills_delete', {
        description: 'Delete a skill and all its edges (relations, cross-graph links). ' +
            'Orphaned proxy nodes are cleaned up automatically. ' +
            'This action is irreversible.',
        inputSchema: {
            skillId: zod_1.z.string().min(1).max(500).describe('Skill ID to delete'),
        },
    }, async ({ skillId }) => {
        const deleted = mgr.deleteSkill(skillId);
        if (!deleted) {
            return { content: [{ type: 'text', text: 'Skill not found' }], isError: true };
        }
        return { content: [{ type: 'text', text: JSON.stringify({ skillId, deleted: true }, null, 2) }] };
    });
}
