Skip to main content
Glama

delete_page

Remove a page and all its associated blocks from a Logseq graph permanently. Specify the page name to delete it irreversibly using this MCP server tool.

Instructions

Deletes a page from the Logseq graph.

⚠️ This removes the page and all its blocks. Cannot be undone.

Args:
    name: The name of the page to delete.
    
Returns:
    Result of the deletion operation.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes

Implementation Reference

  • The MCP tool handler for 'delete_page', decorated with @mcp.tool(), which delegates to the LogseqAPIClient.delete_page method.
    @mcp.tool()
    def delete_page(name: str) -> Dict:
        """
        Deletes a page from the Logseq graph.
        
        ⚠️ This removes the page and all its blocks. Cannot be undone.
        
        Args:
            name: The name of the page to delete.
            
        Returns:
            Result of the deletion operation.
        """
        return logseq_client.delete_page(name)
  • The LogseqAPIClient helper method that performs the actual API call to Logseq's Editor.deletePage endpoint to delete the specified page.
    def delete_page(self, page_name: str) -> Dict:
        """Delete a page from the graph"""
        response = self.call_api("logseq.Editor.deletePage", [page_name])
        if isinstance(response, dict) and "result" in response:
            return response.get("result")
        return response
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively communicates critical behavioral traits: that the operation is destructive ('removes the page and all its blocks'), irreversible ('Cannot be undone'), and returns a result. This covers the essential safety and outcome information needed for a destructive operation.

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 efficiently structured with a clear purpose statement, critical warning, and organized parameter/return sections. Every sentence serves a distinct purpose: establishing action, warning about consequences, explaining the parameter, and describing the return value. No wasted words.

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

Completeness4/5

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

For a destructive tool with no annotations and no output schema, the description provides strong coverage of purpose, behavior, and parameter meaning. The main gap is the lack of detail about what the 'Result of the deletion operation' actually contains, which would be helpful given the absence of an output schema.

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

Parameters4/5

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

With 0% schema description coverage for the single parameter, the description compensates by explaining that 'name' refers to 'The name of the page to delete.' This adds meaningful context beyond the bare schema, clarifying what the parameter represents in the tool's domain.

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 ('Deletes') and target resource ('a page from the Logseq graph'), distinguishing it from sibling tools like remove_block or create_page. It precisely communicates what the tool does without being vague or tautological.

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

Usage Guidelines4/5

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

The description provides clear context about when to use this tool (to delete a page and all its blocks) and includes a warning about irreversibility, which helps guide usage decisions. However, it doesn't explicitly mention when NOT to use it or name specific alternatives among the sibling tools for partial deletions.

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/apw124/logseq-mcp'

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