Skip to main content
Glama
Qwinty
by Qwinty

delete_object

Permanently removes an object and all its content from an Anytype space. Verify object ID before deletion as this action is irreversible.

Instructions

Permanently removes an object from a specified Anytype space. This tool deletes the object and all its content. Use this tool with caution as deleted objects cannot be recovered. Always verify the object ID before deletion to avoid removing important content.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
space_idYesSpace ID containing the object
object_idYesObject ID to delete

Implementation Reference

  • The asynchronous handler function that executes the DELETE API request to permanently remove the specified object from the Anytype space.
    async ({ space_id, object_id }) => { try { const response = await this.makeRequest( "delete", `/spaces/${space_id}/objects/${object_id}` ); return { content: [ { type: "text" as const, text: JSON.stringify(response.data, null, 2), }, ], }; } catch (error) { return this.handleApiError(error); } }
  • Zod input schema defining the required parameters: space_id and object_id.
    { space_id: z.string().describe("Space ID containing the object"), object_id: z.string().describe("Object ID to delete"), },
  • src/index.ts:278-303 (registration)
    The registration of the 'delete_object' tool using this.server.tool(), including name, description, schema, and inline handler.
    this.server.tool( "delete_object", "Permanently removes an object from a specified Anytype space. This tool deletes the object and all its content. Use this tool with caution as deleted objects cannot be recovered. Always verify the object ID before deletion to avoid removing important content.", { space_id: z.string().describe("Space ID containing the object"), object_id: z.string().describe("Object ID to delete"), }, async ({ space_id, object_id }) => { try { const response = await this.makeRequest( "delete", `/spaces/${space_id}/objects/${object_id}` ); return { content: [ { type: "text" as const, text: JSON.stringify(response.data, null, 2), }, ], }; } catch (error) { return this.handleApiError(error); } } );

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/Qwinty/anytype-mcp'

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