Skip to main content
Glama

get_all_pages

Retrieve all pages from a Logseq graph, including journal pages identified by the 'journal?' attribute and 'journalDay' in YYYYMMDD format, for comprehensive graph management.

Instructions

Gets all pages from the Logseq graph. Journal pages can be identified by the "journal?" attribute set to true and will include a "journalDay" attribute in the format YYYYMMDD. Returns: List of all pages in the Logseq graph.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The MCP tool handler for 'get_all_pages', decorated with @mcp.tool(). It has no input parameters and returns a list of page dictionaries. Includes documentation on journal pages. Delegates execution to the LogseqAPIClient instance.
    @mcp.tool() def get_all_pages() -> List[Dict]: """ Gets all pages from the Logseq graph. Journal pages can be identified by the "journal?" attribute set to true and will include a "journalDay" attribute in the format YYYYMMDD. Returns: List of all pages in the Logseq graph. """ return logseq_client.get_all_pages()
  • Supporting helper method in LogseqAPIClient that calls the Logseq API endpoint 'logseq.Editor.getAllPages', handles the response format, and ensures a list of pages is returned.
    def get_all_pages(self) -> List[Dict]: """Get all pages in the graph""" response = self.call_api("logseq.Editor.getAllPages") if isinstance(response, list): return response return response.get("result", []) if isinstance(response, dict) else []
  • Import and exposure of the get_all_pages tool function in the tools package __init__ for registration and usage.
    from .pages import get_all_pages, get_page, create_page, delete_page, get_page_linked_references from .blocks import get_page_blocks, get_block, create_block, update_block, remove_block, insert_block, move_block, search_blocks __all__ = [ "get_all_pages",
  • Type signature and documentation defining the tool's no-input schema and output as List[Dict] with details on journal page structure.
    def get_all_pages() -> List[Dict]: """ Gets all pages from the Logseq graph. Journal pages can be identified by the "journal?" attribute set to true and will include a "journalDay" attribute in the format YYYYMMDD. Returns: List of all pages in the Logseq graph. """ return logseq_client.get_all_pages()

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