list_recent_entries
Retrieve recent diary entry dates from your Obsidian journal to track writing progress and review past reflections.
Instructions
List recent diary entries.
Args: count: Number of recent entries to list (default: 10)
Returns: A list of recent entry dates
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| count | No |
Implementation Reference
- src/obsidian_diary_mcp/server.py:256-262 (registration)Registers the 'list_recent_entries' tool with the FastMCP server using the @mcp.tool decorator.@mcp.tool( annotations={ "title": "List Recent Memory Logs", "readOnlyHint": True, "openWorldHint": False } )
- src/obsidian_diary_mcp/server.py:263-278 (handler)Implements the core logic of the 'list_recent_entries' tool by fetching recent diary entries from entry_manager and formatting them into a readable list.def list_recent_entries( count: Annotated[int, Field(ge=1, le=100, description="Number of recent entries to list")] = 10 ) -> str: """List your most recent diary entries.""" entries = entry_manager.get_all_entries()[:count] if not entries: return "No memory logs found" result = [f"📅 Your {len(entries)} most recent memory logs:\n"] result.extend( f"- {date.strftime('%Y-%m-%d')} ({date.strftime('%A, %B %d, %Y')})" for date, path in entries ) return "\n".join(result)
- Defines the input schema for the tool using Pydantic's Annotated and Field for parameter validation and description.count: Annotated[int, Field(ge=1, le=100, description="Number of recent entries to list")] = 10