remove_hook
Remove a registered hook by ID to manage quantum-inspired secret manager connections and prevent API key leaks.
Instructions
Remove a registered hook by ID.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Hook ID to remove |
Implementation Reference
- src/core/hooks.ts:96-105 (handler)Implementation of the logic to remove a hook by its ID from the registry.
export function removeHook(id: string): boolean { const registry = loadRegistry(); const before = registry.hooks.length; registry.hooks = registry.hooks.filter((h) => h.id !== id); if (registry.hooks.length < before) { saveRegistry(registry); return true; } return false; } - src/mcp/server.ts:969-981 (handler)MCP tool definition and handler for "remove_hook".
"remove_hook", "Remove a registered hook by ID.", { id: z.string().describe("Hook ID to remove"), }, async (params) => { const removed = removeHook(params.id); return text( removed ? `Removed hook ${params.id}` : `Hook "${params.id}" not found`, !removed, ); }, );