from typing import Any from ..utils.confluence import update_page async def confluence_update_page( page_id: str, title: str | None = None, body: str | None = None, ) -> dict[str, Any]: """Update an existing Confluence page. Use this tool to keep architecture/documentation pages in sync with code changes. Confluence versions every edit, so this reads the current page first and bumps the version number automatically. Args: page_id: The Confluence page id to update. title: Optional new title (existing title is reused if not provided). body: Optional new plain-text page body (replaces the existing body). Returns: Dictionary with 'success' (bool) and 'page' (id, title, url), or 'error'. """ return await update_page(page_id, title=title, body=body)