get_areas
Retrieve all areas from the Things app, optionally including projects and tasks, to organize and analyze your workspace efficiently.
Instructions
Get all areas from Things
Args: include_items: Include projects and tasks within areas
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| include_items | No |
Implementation Reference
- things_server.py:121-133 (handler)The main handler function for the 'get_areas' MCP tool, decorated with @mcp.tool for registration. It retrieves all areas from the Things database using things.areas(), optionally includes sub-items, formats them using format_area, and returns a formatted string.@mcp.tool async def get_areas(include_items: bool = False) -> str: """Get all areas from Things Args: include_items: Include projects and tasks within areas """ areas = things.areas() if not areas: return "No areas found" formatted_areas = [format_area(area, include_items) for area in areas] return "\n\n---\n\n".join(formatted_areas)
- things_server.py:121-121 (registration)The @mcp.tool decorator registers the get_areas function as an MCP tool.@mcp.tool
- things_server.py:122-127 (schema)Input schema defined by function signature (include_items: bool = False) and docstring, output str.async def get_areas(include_items: bool = False) -> str: """Get all areas from Things Args: include_items: Include projects and tasks within areas """