deleteTool()
This method manages AI tool definitions or agent-to-tool bindings.
Usage
The following example shows a basic usage of the backend client from @wacht/nextjs/server.
import { wachtClient } from '@wacht/nextjs/server';export async function example() { const client = await wachtClient(); const toolId: string = 'toolid-123'; return client.ai.deleteTool(toolId);}Signature
function deleteTool( toolId: string, client?: WachtClient,): Promise<void>Parameters
›toolId: string;
toolId: string;Target tool id.
Examples
AI usage pattern
import { wachtClient } from '@wacht/nextjs/server';export async function attachTool(agentId: string) { const client = await wachtClient(); const tool = await client.ai.createTool({ name: 'fetch-user-profile', kind: 'api', configuration: {}, }); await client.ai.attachAgentTool(agentId, tool.id); return tool;}