Skip to main content
Glama

workflowy_list_nodes

Retrieve child nodes from a WorkFlowy outline to navigate hierarchical task structures. This tool helps organize and access nested information within your outlines.

Instructions

DEPRECATED: Use workflowy_glimpse (GLIMPSE) instead

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
parent_idNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Registration and deprecated handler stub for 'workflowy_list_nodes' tool. Raises ValueError with deprecation notice recommending workflowy_glimpse.
    @mcp.tool(name="workflowy_list_nodes", description="DEPRECATED: Use workflowy_glimpse (GLIMPSE) instead")
    async def list_nodes_base(parent_id: str | None = None) -> dict:
        """Deprecated - use GLIMPSE instead."""
        raise ValueError("""⚠️ FUNCTION RENAMED
    
    The function 'workflowy_list_nodes' has been renamed to 'workflowy_list_nodes__WARNING__prefer_glimpse'.
    
    BUT MORE IMPORTANTLY: Use workflowy_glimpse (GLIMPSE command) instead!
    
    ✅ RECOMMENDED:
      workflowy_glimpse(node_id="...")
      
    Returns: {"root": {...}, "children": [...]} with complete tree structure.
    
    GLIMPSE is better:
    - Gets full nested tree (not just direct children)
    - Gets root node metadata
    - More efficient
    
    📚 Build the GLIMPSE habit!
    """)
  • Full handler logic (under warning suffixed name). Validates secret_code, creates NodeListRequest, calls client.list_nodes, returns nodes list.
    @mcp.tool(name="workflowy_list_nodes__WARNING__prefer_glimpse", description="⚠️ WARNING: Prefer workflowy_glimpse (GLIMPSE) for reading trees. List WorkFlowy nodes (omit parent_id for root)")
    async def list_nodes(
        parent_id: str | None = None,
        secret_code: str | None = None,
    ) -> dict:
        """List WorkFlowy nodes.
    
        Args:
            parent_id: ID of parent node to list children for
                       (omit or pass None to list root nodes - parameter won't be sent to API)
            secret_code: Authorization code from Dan (required for WARNING functions)
    
        Returns:
            Dictionary with 'nodes' list and 'total' count
        """
        # 🔐 SECRET CODE VALIDATION
        is_valid, error = validate_secret_code(secret_code, "workflowy_list_nodes__WARNING__prefer_glimpse")
        if not is_valid:
            raise ValueError(error)
        
        client = get_client()
    
        request = NodeListRequest(  # type: ignore[call-arg]
            parentId=parent_id,
        )
    
        if _rate_limiter:
            await _rate_limiter.acquire()
    
        try:
            nodes, total = await client.list_nodes(request)
            if _rate_limiter:
                _rate_limiter.on_success()
            return {
                "nodes": [node.model_dump() for node in nodes],
                "total": total,
                "_warning": "⚠️ For reading multiple nodes or full trees, use workflowy_glimpse (GLIMPSE) instead for efficiency"
            }
        except Exception as e:
            if _rate_limiter and hasattr(e, "__class__") and e.__class__.__name__ == "RateLimitError":
                _rate_limiter.on_rate_limit(getattr(e, "retry_after", None))
            raise
  • Pydantic input schema model NodeListRequest used by list_nodes handlers.
    class NodeListRequest(BaseModel):
        """Request parameters for listing nodes."""
    
        parentId: str | None = Field(None, description="Parent node ID to list children for")
  • Core client-side implementation: HTTP GET /nodes with parent_id param, response parsing to WorkFlowyNode list, full retry/rate-limit handling.
    async def list_nodes(self, request: NodeListRequest, max_retries: int = 10) -> tuple[list[WorkFlowyNode], int]:
        """List nodes with optional filtering and exponential backoff retry.
        
        Args:
            request: Node list request
            max_retries: Maximum retry attempts (default 10)
        """
        import asyncio
    
        logger = _ClientLogger()
        retry_count = 0
        base_delay = 1.0
        
        while retry_count < max_retries:
            # Force delay at START of each iteration (rate limit protection)
            await asyncio.sleep(API_RATE_LIMIT_DELAY)
            
            try:
                # exclude_none=True ensures parent_id is omitted entirely for root nodes
                # (API requires absence of parameter, not null value)
                # Build params manually to ensure snake_case (API expects parent_id not parentId)
                params = {}
                if request.parentId is not None:
                    params['parent_id'] = request.parentId
                response = await self.client.get("/nodes", params=params)
                response_data: list[Any] | dict[str, Any] = await self._handle_response(response)
    
                # Assuming API returns an array of nodes directly
                # (Need to verify actual response structure)
                nodes: list[WorkFlowyNode] = []
                if isinstance(response_data, dict):
                    if "nodes" in response_data:
                        nodes = [WorkFlowyNode(**node_data) for node_data in response_data["nodes"]]
                elif isinstance(response_data, list):
                    nodes = [WorkFlowyNode(**node_data) for node_data in response_data]
    
                total = len(nodes)  # API doesn't provide a total count
                return nodes, total
                
            except RateLimitError as e:
                retry_count += 1
                retry_after = getattr(e, 'retry_after', None) or (base_delay * (2 ** retry_count))
                logger.warning(
                    f"Rate limited on list_nodes. Retry after {retry_after}s. "
                    f"Attempt {retry_count}/{max_retries}"
                )
                
                if retry_count < max_retries:
                    await asyncio.sleep(retry_after)
                else:
                    raise
                    
            except NetworkError as e:
                retry_count += 1
                logger.warning(
                    f"Network error on list_nodes: {e}. Retry {retry_count}/{max_retries}"
                )
                
                if retry_count < max_retries:
                    await asyncio.sleep(base_delay * (2 ** retry_count))
                else:
                    raise
                    
            except httpx.TimeoutException as err:
                retry_count += 1
                
                logger.warning(
                    f"Timeout error: {err}. Retry {retry_count}/{max_retries}"
                )
                
                if retry_count < max_retries:
                    await asyncio.sleep(base_delay * (2 ** retry_count))
                else:
                    raise TimeoutError("list_nodes") from err
        
        raise NetworkError("list_nodes failed after maximum retries")
Behavior2/5

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

No annotations are provided, so the description carries full burden. It only states the tool is deprecated, offering no behavioral details like what the tool originally did, its read/write nature, permissions needed, or output format. For a tool with 1 parameter and output schema, this is insufficient disclosure.

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 perfectly concise with zero wasted words—a single sentence front-loading the critical deprecation information. Every word earns its place by clearly communicating the tool's status and alternative.

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?

For a deprecated tool, the description adequately communicates its status and alternative, which is the primary need. However, given it has 1 parameter and an output schema, more context about its original function would help agents understand legacy usage or migration needs, though not strictly required for deprecation.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must compensate. It provides no information about the 'parent_id' parameter—not its purpose, format, or effect. The deprecation notice doesn't add any parameter semantics, leaving the parameter completely undocumented.

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

Purpose2/5

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

The description is a tautology that restates the tool name ('workflowy_list_nodes') without explaining what it does. It provides no specific verb or resource details, only indicating it's deprecated. This fails to clarify the tool's actual function beyond its name.

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

Usage Guidelines5/5

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

The description explicitly states 'DEPRECATED: Use workflowy_glimpse (GLIMPSE) instead', providing clear when-not-to-use guidance and naming the specific alternative. This is ideal for deprecated tools, leaving no ambiguity about usage.

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

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/daniel347x/workflowy-mcp-fixed'

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