From e3b4e613adcab555906e2a4eb1f5346c63012268 Mon Sep 17 00:00:00 2001 From: Marcus van Elst Date: Wed, 15 Apr 2026 14:26:56 +0200 Subject: [PATCH] =?UTF-8?q?fix:=20reduce=20tools/list=20payload=20?= =?UTF-8?q?=E2=80=93=20remove=20return=20annotations=20and=20shorten=20doc?= =?UTF-8?q?strings=20(v0.3.1)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pyproject.toml | 2 +- src/mcp_familywall/__init__.py | 2 +- src/mcp_familywall/server.py | 56 +++++----------------------------- 3 files changed, 10 insertions(+), 50 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 81f3cb7..c6df00e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "hatchling.build" [project] name = "mcp-familywall" -version = "0.3.0" +version = "0.3.1" description = "MCP server for Family Wall — read your family's lists and tasks via Claude" readme = "README.md" requires-python = ">=3.12" diff --git a/src/mcp_familywall/__init__.py b/src/mcp_familywall/__init__.py index 493f741..260c070 100644 --- a/src/mcp_familywall/__init__.py +++ b/src/mcp_familywall/__init__.py @@ -1 +1 @@ -__version__ = "0.3.0" +__version__ = "0.3.1" diff --git a/src/mcp_familywall/server.py b/src/mcp_familywall/server.py index ac6524f..87916c0 100644 --- a/src/mcp_familywall/server.py +++ b/src/mcp_familywall/server.py @@ -118,15 +118,8 @@ def _extract_tasks(data: dict[str, Any]) -> list[dict[str, Any]]: @mcp.tool() -def get_circles() -> str: - """Return all Family Wall circles (Kreise) the account belongs to. - - Each circle has an id and a name. - Response structure verified: a00.r.r[] with metaId and name fields. - - Returns: - JSON string — list of {id, name} objects. - """ +def get_circles(): + """Return all Family Wall circles as JSON list of {id, name}.""" try: email, password = get_credentials() except RuntimeError as exc: @@ -163,19 +156,8 @@ def get_circles() -> str: @mcp.tool() -def get_lists(scope: str | None = None) -> str: - """Return all task lists, optionally filtered by circle name. - - Uses the taskgettasklists endpoint directly. - - Args: - scope: Optional circle name to filter by. When None, all lists from - all circles are returned. - - Returns: - JSON string — list of objects with keys: - id, name, type, open, total. - """ +def get_lists(scope: str | None = None): + """Return task lists as JSON, optionally filtered by circle name (scope).""" try: email, password = get_credentials() except RuntimeError as exc: @@ -232,17 +214,8 @@ def get_lists(scope: str | None = None) -> str: @mcp.tool() -def get_tasks(list_id: str, only_open: bool = True) -> str: - """Return tasks for a specific list. - - Args: - list_id: The metaId of the list (from get_lists). - only_open: When True (default), only incomplete tasks are returned. - - Returns: - JSON string — list of objects with keys: - id, text, description, completed. - """ +def get_tasks(list_id: str, only_open: bool = True): + """Return tasks for a list as JSON. list_id from get_lists. only_open=True filters completed.""" try: data = _accgetallfamily() except RuntimeError as exc: @@ -275,21 +248,8 @@ def get_tasks(list_id: str, only_open: bool = True) -> str: @mcp.tool() -def get_activities(limit: int = 20) -> str: - """Return recent Family Wall wall activities (posts, comments, photos, …). - - Uses the wallget endpoint. Response structure is not yet verified against - a live API call — the raw response is returned when no known pattern is - matched, so the structure can be inspected on the first real call. - - Args: - limit: Maximum number of activities to return (default 20). - - Returns: - JSON string — list of objects with keys: - id, type, text, date, author. - Falls back to raw API response when the structure is unrecognised. - """ +def get_activities(limit: int = 20): + """Return recent Family Wall wall activities as JSON. limit controls max number of results.""" try: email, password = get_credentials() except RuntimeError as exc: