feat(meal-planner): add get_meal_plan read-only tool (v0.10.0)

- Implement get_meal_plan() tool for accessing Family Wall meal planner
- Parameters: date_from, date_to (ISO 8601 format)
- Returns raw JSON for initial verification via FW_DEBUG=1
- Response structure to be verified in first deployment
- Add Meal Planner API section to SPEC.md documenting mplistinterval and other endpoints
- Update version to 0.10.0 in __init__.py and pyproject.toml
- Update README.md and CLAUDE.md with tool info and roadmap

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-04-17 11:03:48 +02:00
parent 935a159331
commit 500ad278a4
6 changed files with 75 additions and 6 deletions
+4 -3
View File
@@ -24,11 +24,11 @@ und wird in Claude Desktop eingebunden.
## Aktueller Stand
### Implementierte Tools (v0.9.1)
### Implementierte Tools (v0.10.0)
| Kategorie | Tools |
|---|---|
| Lesen | `get_circles`, `get_members`, `get_lists`, `get_tasks`, `get_categories`, `get_activities` |
| Lesen | `get_circles`, `get_members`, `get_lists`, `get_tasks`, `get_categories`, `get_activities`, `get_meal_plan` |
| Tasks | `create_task`, `update_task`, `toggle_task`, `delete_task` |
| Listen | `create_list`, `update_list`, `delete_list` |
| Kategorien | `create_category`, `delete_category` |
@@ -57,7 +57,8 @@ und wird in Claude Desktop eingebunden.
- v0.8.3: OTHER-Listentyp dokumentiert + create_list unterstützt ihn; FW_DEBUG=1 loggt unbekannte Task-Felder (Vorbereitung Wiederholungen) ✓
- v0.8.x: mpadditemtolist (gestrichen Family Wall kann das nativ)
- v0.9.0: get_tasks liefert recurrency, recurrency_interval, rrule, reminder (read-only) ✓
- v0.9.1: Bugfix reminder-Mapping (reminderUnit/reminderValue statt unit/value; value=0 ist gültig) ✓ ← aktuell
- v0.9.1: Bugfix reminder-Mapping (reminderUnit/reminderValue statt unit/value; value=0 ist gültig) ✓
- v0.10.0: get_meal_plan (read-only, raw JSON; Premium-Feature Essensplaner) ✓ ← aktuell
- v2.0: Schreibzugriff auf Wall-Posts (Erstellen, Kommentieren)
+2 -1
View File
@@ -2,7 +2,7 @@
MCP server for [Family Wall](https://www.familywall.com) -- read and manage your family's circles, lists, tasks, and recipes directly from Claude.
## Features (v0.9.1)
## Features (v0.10.0)
### Read
@@ -15,6 +15,7 @@ MCP server for [Family Wall](https://www.familywall.com) -- read and manage your
- `get_recipes` -- list all family recipes (compact summary: id, name, prep/cook time, serves)
- `get_recipe` -- get a single recipe in full detail (ingredients, instructions, ingredients_parsed, category_ids, etc.)
- `get_recipe_categories` -- list all available recipe categories (always returns all 5 standard categories: Bei Kindern beliebt, Wirklich einfach, Nachspeisen, Schmeckt toll, Gemüse; plus any additional categories found in existing recipes)
- `get_meal_plan` -- get meal plan entries for a date range (Premium feature; returns raw JSON for verification)
### Write (with confirmation prompt)
+42
View File
@@ -664,6 +664,48 @@ Löscht einen Kreis und alle zugehörigen Inhalte (Listen, Tasks, Rezepte, Wall-
**Verifiziert am:** 2026-04-16 via FW_DEBUG=1 (family/23447371 erfolgreich gelöscht)
## Meal Planner API
Premium-Feature. Endpoints extrahiert aus JS-Bundle `startupmodule.js?vfw=2026-04-03T140539`.
Browser-Analyse blockiert durch Service Worker. Response-Struktur wird nach erstem Deploy
mit `FW_DEBUG=1` verifiziert.
### `mplistinterval` Essensplan für Datumsbereich abrufen
POST https://api.familywall.com/api/mplistinterval
**Body-Parameter:**
| Parameter | Pflicht | Wert |
|---|---|---|
| `from` | ja | Start-Datum (ISO 8601, Format TBD: `"2026-04-13"` oder `"2026-04-13T00:00:00"`) |
| `to` | ja | End-Datum (ISO 8601, Format TBD) |
**Response-Struktur:** TBD — Tool liefert Raw JSON zur Verifizierung.
**Mahlzeiten-Typen:**
- `BREAKFAST` Frühstück
- `LUNCH` Mittagessen
- `SNACK` Snack
- `DINNER` Abendessen
**Mahlzeiten-Objekt:** MetaId-Format `dish/<id>` (Präfix "dish/").
**Verifiziert am:** 2026-04-17 (Endpoint-Name aus JS-Bundle, Response TBD)
### Weitere Meal Planner Endpoints (nicht implementiert)
| Endpoint | Parameter | Bedeutung |
|---|---|---|
| `mpcreate` | `name`, `date`, `type`, `clientOpId` | Mahlzeit mit freiem Text erstellen |
| `mpcreateByRecipeId` | `recipeId`, `date`, `type`, `clientOpId` | Mahlzeit aus Rezept erstellen |
| `mpmealput` | Mahlzeiten-Objekt (encoded) | Mahlzeit aktualisieren |
| `mpmove` | `metaId`, `date`, `type`, `clientOpId` | Mahlzeit zu anderem Datum/Typ verschieben |
| `mpdelete` | `metaId` | Mahlzeit löschen |
| `mpsettings` | | Einstellungen lesen |
**Quelle:** JS-Bundle-Analyse (startupmodule.js).
**Status:** Endpunkte bekannt, Response-Struktur unbekannt.
### Recipe Categories API Details
Recipe categories are managed via `mprecipeput` endpoint. Each recipe can have zero or more
+1 -1
View File
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
[project]
name = "mcp-familywall"
version = "0.9.1"
version = "0.10.0"
description = "MCP server for Family Wall — read your family's lists and tasks via Claude"
readme = "README.md"
requires-python = ">=3.12"
+1 -1
View File
@@ -1 +1 @@
__version__ = "0.9.1"
__version__ = "0.10.0"
+25
View File
@@ -2210,6 +2210,31 @@ def update_recipe(
return json.dumps(result, ensure_ascii=False, indent=2)
# ---------------------------------------------------------------------------
# Tool: get_meal_plan
# ---------------------------------------------------------------------------
@mcp.tool()
def get_meal_plan(date_from: str, date_to: str) -> str:
"""Return meal plan entries for a date range.
Args:
date_from: Start date in ISO format (e.g. ``"2026-04-13"``).
date_to: End date in ISO format (e.g. ``"2026-04-19"``).
Returns:
Raw JSON response from the API for initial verification.
"""
try:
data = _authenticated_call("mplistinterval", {"from": date_from, "to": date_to})
except RuntimeError as exc:
return f"Error: {exc}"
# Return raw JSON for verification — response structure not yet known
return json.dumps(data, ensure_ascii=False, indent=2)
# ---------------------------------------------------------------------------
# Factory
# ---------------------------------------------------------------------------