Skip to main content
Glama
7robots

Micro.blog Books MCP Server

by 7robots

get_reading_goals

Retrieve reading goals from Micro.blog to track progress and manage your book collection effectively.

Instructions

Get reading goals.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • FastMCP tool handler for 'get_reading_goals'. Calls MicroBooksClient.get_reading_goals() and returns formatted JSON string response.
    @mcp.tool() async def get_reading_goals() -> str: """Get reading goals.""" try: result = await client.get_reading_goals() return json.dumps(result, indent=2) except Exception: logger.exception("Failed to get reading goals") raise
  • MicroBooksClient helper method implementing the core HTTP GET request to Micro.blog /books/goals API endpoint.
    async def get_reading_goals(self) -> dict: """Get reading goals.""" async with httpx.AsyncClient() as client: response = await client.get( urljoin(BASE_URL, "/books/goals"), headers=self.headers, ) response.raise_for_status() return response.json()
  • FastMCP tool handler for 'get_reading_goals' in the Python DXT extension server.
    @mcp.tool() async def get_reading_goals() -> str: """Get reading goals.""" try: result = await client.get_reading_goals() return json.dumps(result, indent=2) except Exception: logger.exception("Failed to get reading goals") raise
  • MicroBooksClient helper method for the HTTP API call in Python DXT extension.
    async def get_reading_goals(self) -> dict: """Get reading goals.""" async with httpx.AsyncClient() as client: response = await client.get( urljoin(BASE_URL, "/books/goals"), headers=self.headers, ) response.raise_for_status() return response.json()
  • MCP CallToolRequestSchema handler dispatch case for 'get_reading_goals'. Calls client.getReadingGoals() and returns text content with JSON.
    case "get_reading_goals": { const result = await client.getReadingGoals(); return { content: [ { type: "text", text: JSON.stringify(result, null, 2), }, ], };
  • MicroBooksClient getReadingGoals method performing the core fetch request to /books/goals.
    async getReadingGoals() { return await this.makeRequest("/books/goals"); }
  • Tool schema definition and registration in the tools list for ListToolsRequest, with empty input schema.
    { name: "get_reading_goals", description: "Get all reading goals", inputSchema: { type: "object", properties: {}, }, },

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/7robots/micro-mcp-server'

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