get_goal_progress
Check reading goal progress by retrieving current status and completion metrics for a specific goal ID.
Instructions
Get books list progress toward a goal.
Args: goal_id: The ID of the reading goal
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| goal_id | Yes |
Implementation Reference
- dxt-extension/server/index.js:582-593 (handler)MCP server dispatch handler for the get_goal_progress tool. Extracts goal_id from arguments and calls the client method to fetch progress from Micro.blog API, then formats as JSON text response.case "get_goal_progress": { const { goal_id } = args; const result = await client.getGoalProgress(goal_id); return { content: [ { type: "text", text: JSON.stringify(result, null, 2), }, ], }; }
- micro_mcp_server/server.py:304-316 (handler)FastMCP tool handler for get_goal_progress. Calls the client method and returns JSON string of the goal progress.async def get_goal_progress(goal_id: int) -> str: """Get books list progress toward a goal. Args: goal_id: The ID of the reading goal """ try: result = await client.get_goal_progress(goal_id) return json.dumps(result, indent=2) except Exception: logger.exception("Failed to get goal progress") raise
- Input schema definition for the get_goal_progress tool, specifying goal_id as required positive integer.name: "get_goal_progress", description: "Get progress toward a specific reading goal", inputSchema: { type: "object", properties: { goal_id: { type: "integer", description: "The ID of the reading goal", minimum: 1, }, }, required: ["goal_id"], }, },
- MicroBooksClient helper method that performs HTTP GET to Micro.blog /books/goals/{goalId} endpoint to retrieve goal progress.async getGoalProgress(goalId) { if (!Number.isInteger(goalId) || goalId <= 0) { throw new Error("Goal ID must be a positive integer"); } return await this.makeRequest(`/books/goals/${goalId}`); }
- micro_mcp_server/server.py:139-148 (helper)MicroBooksClient helper method that performs HTTP GET request to Micro.blog API endpoint /books/goals/{goal_id} to fetch the goal progress data.async def get_goal_progress(self, goal_id: int) -> dict: """Get books list progress toward a goal.""" async with httpx.AsyncClient() as client: response = await client.get( urljoin(BASE_URL, f"/books/goals/{goal_id}"), headers=self.headers, ) response.raise_for_status() return response.json()