Skip to main content
Glama

update_event

Modify calendar event details such as summary, start time, end time, location, description, or attendees using the event ID.

Instructions

Update an existing calendar event

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
attendeesNo
descriptionNo
endNo
event_idYes
locationNo
startNo
summaryNo

Implementation Reference

  • server.py:514-517 (registration)
    Registers the 'update_event' tool using the @mcp.tool decorator with name and description.
    @mcp.tool(
        name="update_event",
        description="Update an existing calendar event",
    )
  • The handler function that implements the update_event tool logic: authenticates with Google, fetches the existing event, applies provided updates (summary, start, end, etc.), and updates the event via the Google Calendar API.
    async def update_event(event_id: str, summary: Optional[str] = None, start: Optional[str] = None, end: Optional[str] = None, location: Optional[str] = None, description: Optional[str] = None, attendees: Optional[List[EmailStr]] = None) -> str:
        """
        Update an existing calendar event
        
        Args:
            event_id (str): Event ID to update
            summary (str, optional): New event title
            start (str, optional): New start datetime in ISO format
            end (str, optional): New end datetime in ISO format
            location (str, optional): New event location
            description (str, optional): New event description
            attendees (array, optional): New list of attendee email addresses
            
        Returns:
            str: Success message
        """
        creds = get_google_credentials()
        if not creds:
            return "Google authentication failed."
    
        try:
            service = build('calendar', 'v3', credentials=creds)
            event_tz = 'Asia/Seoul'
    
            # 기존 이벤트 정보 가져오기
            event = service.events().get(calendarId='primary', eventId=event_id).execute()
    
            # 입력 파라미터 기반으로 업데이트할 필드 구성
            update_payload = {}
            if summary is not None: update_payload['summary'] = summary
            if location is not None: update_payload['location'] = location
            if description is not None: update_payload['description'] = description
            if start is not None: update_payload['start'] = {'dateTime': start, 'timeZone': event_tz}
            if end is not None: update_payload['end'] = {'dateTime': end, 'timeZone': event_tz}
            if attendees is not None: update_payload['attendees'] = [{'email': email} for email in attendees]
    
            # 가져온 이벤트 정보에 업데이트 내용 반영 후 API 호출
            event.update(update_payload)
            updated_event = service.events().update(calendarId='primary', eventId=event_id, body=event).execute()
    
            logger.info(f"이벤트 업데이트됨: {updated_event.get('htmlLink')}")
            return f"이벤트 업데이트 성공. 이벤트 ID: {updated_event['id']}"
    
        except HttpError as error:
            logger.error(f"API 오류 발생: {error}")
            if error.resp.status == 404:
                return f"ID '{event_id}'의 이벤트를 찾을 수 없습니다."
            return f"Calendar API 오류: {error.resp.status} - {error.content.decode()}"
        except Exception as e:
            logger.exception("이벤트 업데이트 중 오류:")
            return f"예상치 못한 오류 발생: {str(e)}"
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. 'Update' implies a mutation operation, but the description doesn't disclose whether this requires specific permissions, what happens to unspecified fields (partial vs. full updates), whether changes are reversible, or any rate limits. It mentions no behavioral traits beyond the basic action.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence with no wasted words. It's front-loaded with the core action ('Update an existing calendar event') and doesn't include unnecessary details. Every word earns its place, making it easy to parse quickly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the complexity (7 parameters, mutation tool), lack of annotations, and no output schema, the description is incomplete. It doesn't explain what the tool returns, error conditions, or behavioral context needed for safe invocation. For a tool that modifies calendar events, this leaves significant gaps in understanding how to use it effectively.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description adds zero meaning beyond what the input schema provides. With 7 parameters and 0% schema description coverage, the schema only provides titles like 'Attendees' and 'Description' without explaining what these parameters do, their formats, or constraints. The description doesn't compensate by explaining any parameters, leaving all semantics undocumented.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb ('Update') and resource ('an existing calendar event'), making the purpose immediately understandable. It distinguishes from sibling tools like 'create_event' and 'delete_event' by specifying it's for existing events. However, it doesn't specify what aspects can be updated beyond the generic term.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (like needing an event_id), when not to use it, or how it differs from similar tools like 'modify_email' or 'create_event' in the sibling list. The agent must infer usage from the tool name alone.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Related Tools

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/jikime/py-mcp-google-toolbox'

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