Skip to main content
Glama

doc_disconnect

Remove documents from an AI agent's knowledge base to manage content access and update information sources.

Instructions

Disconnect/unlink a document from a Pickaxe agent, removing it from the agent's knowledge base.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
studioNoStudio name to use. Available: STAGING, MAIN, DEV, PRODUCTION. Default: PRODUCTION
documentIdYesThe document ID to disconnect
pickaxeIdYesThe Pickaxe agent ID to disconnect the document from

Implementation Reference

  • Handler implementation for the 'doc_disconnect' tool. It makes a POST request to the Pickaxe API endpoint '/studio/document/disconnect' with the documentId and pickaxeId parameters to unlink the document from the agent.
    case "doc_disconnect": { const result = await pickaxeRequest("/studio/document/disconnect", "POST", { documentId: args.documentId, pickaxeId: args.pickaxeId, }, studio); return JSON.stringify(result, null, 2);
  • Input schema definition for the 'doc_disconnect' tool, specifying parameters: studio (optional), documentId (required), pickaxeId (required).
    { name: "doc_disconnect", description: "Disconnect/unlink a document from a Pickaxe agent, removing it from the agent's knowledge base.", inputSchema: { type: "object", properties: { studio: studioParam, documentId: { type: "string", description: "The document ID to disconnect", }, pickaxeId: { type: "string", description: "The Pickaxe agent ID to disconnect the document from", }, }, required: ["documentId", "pickaxeId"], }, },
  • src/index.ts:616-618 (registration)
    Registration of the tool list handler, which returns the array of tools including 'doc_disconnect'.
    server.setRequestHandler(ListToolsRequestSchema, async () => { return { tools }; });
  • src/index.ts:621-636 (registration)
    Registration of the call tool handler, which dispatches to executeTool based on tool name, handling 'doc_disconnect' via the switch case.
    server.setRequestHandler(CallToolRequestSchema, async (request) => { const { name, arguments: args } = request.params; try { const result = await executeTool(name, (args as Record<string, unknown>) ?? {}); return { content: [{ type: "text", text: result }], }; } catch (error) { const errorMessage = error instanceof Error ? error.message : String(error); return { content: [{ type: "text", text: `Error: ${errorMessage}` }], isError: true, }; } });

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/aplaceforallmystuff/mcp-pickaxe'

If you have feedback or need assistance with the MCP directory API, please join our Discord server