update_event
Modify event details in Microsoft Calendar via Microsoft MCP server. Input event ID, account ID, and desired updates to adjust properties such as time, location, or description.
Instructions
Update event properties
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| account_id | Yes | ||
| event_id | Yes | ||
| updates | Yes |
Implementation Reference
- src/microsoft_mcp/tools.py:553-581 (handler)The core handler function for the 'update_event' tool. It formats the updates dictionary according to Microsoft Graph API requirements and sends a PATCH request to update the specified event. Registered via the @mcp.tool decorator.@mcp.tool def update_event( event_id: str, updates: dict[str, Any], account_id: str ) -> dict[str, Any]: """Update event properties""" formatted_updates = {} if "subject" in updates: formatted_updates["subject"] = updates["subject"] if "start" in updates: formatted_updates["start"] = { "dateTime": updates["start"], "timeZone": updates.get("timezone", "UTC"), } if "end" in updates: formatted_updates["end"] = { "dateTime": updates["end"], "timeZone": updates.get("timezone", "UTC"), } if "location" in updates: formatted_updates["location"] = {"displayName": updates["location"]} if "body" in updates: formatted_updates["body"] = {"contentType": "Text", "content": updates["body"]} result = graph.request( "PATCH", f"/me/events/{event_id}", account_id, json=formatted_updates ) return result or {"status": "updated"}
- src/microsoft_mcp/tools.py:553-553 (registration)The @mcp.tool decorator registers the update_event function as an MCP tool with FastMCP instance 'mcp'.@mcp.tool