Skip to main content
Glama
awkoy

notion-mcp-server

delete_block

Remove or archive a specific block in Notion by providing its block ID using the Notion MCP Server integration.

Instructions

Delete (move to trash) a block in Notion

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
blockIdYesThe ID of the block to delete/archive

Implementation Reference

  • The core handler function for the 'delete_block' tool. It deletes the specified Notion block using the Notion API and returns a success message with the response or handles errors.
    export const deleteBlock = async (
      params: DeleteBlockParams
    ): Promise<CallToolResult> => {
      try {
        const response = await notion.blocks.delete({
          block_id: params.blockId,
        });
    
        return {
          content: [
            {
              type: "text",
              text: `Block ${params.blockId} deleted (moved to trash) successfully`,
            },
            {
              type: "text",
              text: JSON.stringify(response, null, 2),
            },
          ],
        };
      } catch (error) {
        return handleNotionError(error);
      }
    };
  • Registration/dispatch logic within the 'notion_blocks' tool handler that routes 'delete_block' action to the deleteBlock function.
    case "delete_block":
      return deleteBlock(params.payload.params);
  • Zod schema defining the input parameters for the 'delete_block' tool (blockId). Used in the BLOCKS_OPERATION_SCHEMA.
    export const DELETE_BLOCK_SCHEMA = {
      blockId: z.string().describe("The ID of the block to delete/archive"),
    };
  • Integration of 'delete_block' action and its schema into the overarching BLOCKS_OPERATION_SCHEMA for the 'notion_blocks' tool.
        .literal("delete_block")
        .describe("Use this action to delete/archive a block."),
      params: z.object(DELETE_BLOCK_SCHEMA),
    }),
  • Top-level registration of the 'notion_blocks' MCP tool, which includes the 'delete_block' action among others.
      "notion_blocks",
      "Perform various block operations (retrieve, update, delete, append children, batch operations)",
      BLOCKS_OPERATION_SCHEMA,
      registerBlocksOperationTool
    );
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the action is a deletion that moves to trash, implying reversibility, but doesn't clarify if this requires specific permissions, the effect on child blocks, or response behavior. For a mutation tool with zero annotation coverage, this leaves significant gaps in understanding its operational traits.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that front-loads the core action and resource. It uses minimal words to convey essential information without redundancy, making it highly concise and well-structured for quick comprehension.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (a mutation operation with no annotations and no output schema), the description is minimally adequate. It covers the basic purpose but lacks details on behavioral aspects, usage context, and output expectations. For a deletion tool, more information on reversibility or effects would improve completeness, but it meets the minimum viable threshold.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, with the single parameter 'blockId' documented in the schema. The description adds no additional meaning beyond what the schema provides, such as format examples or constraints. With high schema coverage, the baseline score of 3 is appropriate as the description doesn't enhance parameter understanding.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the specific action ('Delete (move to trash)') and resource ('a block in Notion'), distinguishing it from siblings like 'archive_page' (which targets pages) and 'batch_delete_blocks' (which handles multiple blocks). It precisely communicates the tool's function without ambiguity.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., block existence, permissions), exclusions (e.g., irreversible deletion), or comparisons to siblings like 'archive_page' (for pages) or 'batch_delete_blocks' (for efficiency with multiple blocks). Usage context is implied but not explicit.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Related Tools

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/awkoy/notion-mcp-server'

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