get_active_session
Retrieve the currently active Pomodoro session to monitor ongoing work intervals and manage productivity workflows.
Instructions
Get the currently active pomodoro session
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/index.ts:529-553 (handler)The handler logic for the 'get_active_session' tool. It searches the sessions array for the first incomplete session (!s.completed) and returns it or null with a message if none found.case "get_active_session": { const activeSession = data.sessions.find((s) => !s.completed); if (!activeSession) { return { content: [ { type: "text", text: JSON.stringify({ success: true, activeSession: null, message: "No active session", }), }, ], }; } return { content: [ { type: "text", text: JSON.stringify({ success: true, activeSession }, null, 2), }, ], }; }
- src/index.ts:234-242 (schema)The schema definition for the 'get_active_session' tool in the TOOLS array, specifying name, description, and an empty input schema (no arguments required). This is used for tool listing and validation.{ name: "get_active_session", description: "Get the currently active pomodoro session", inputSchema: { type: "object", properties: {}, }, }, ];