Delete Calendar Event
Definition
This action allows a user to remove a specific event from a Google Calendar. It is a critical component for automating calendar management, such as canceling appointments, processing leave cancellations, or removing placeholder events once a task is complete.
Key capabilities:
- Targeting: Deletes from a specific calendar or defaults to the user’s primary calendar.
- Precision: Identifies the exact event to be removed using its unique Event ID.
- Communication: Controls whether attendees receive a cancellation email or if the deletion happens silently.
Note: When this action runs, the event is moved to the Google Calendar Trash (Bin). It is not instantly erased; it can be restored manually via the Google Calendar web interface for up to 30 days.
Inputs
- Connection
- Purpose: Authorizes Zenphi to securely access and interact with your Google Calendar account.
- Practical Guidance: Select a pre-configured Google Calendar connection. This determines who is performing the deletion.
- Calendar
- Purpose: Specifies the exact calendar where the event lives.
- Practical Guidance:
- Specific Calendar: Select a calendar from the dropdown (e.g., “Team Leave”, “Conference Rooms”).
- Dynamic: Use the Token Picker to map a Calendar ID from a previous step.
- Default: Leave empty to target the Primary Calendar of the selected connection.
- Event
- Purpose: The unique identifier (ID) of the event you wish to delete.
- Practical Guidance: This is the most critical field. You almost never type this manually. You must use the Token Picker to map the
Event IDoutput from a preceding action, such as “List Events” or “Create Event”. - ⚠️ Recurring Events Warning: If you map the ID of a single instance of a recurring meeting, only that specific day will be deleted. If you map the ID of the “Series Master,” the entire recurring series will be removed.
- Send Notification
- Purpose: Determines who receives an email regarding the cancellation.
- Practical Guidance:
- Empty (Default): If you leave this field blank, the event is deleted silently. No emails are sent. This is best for administrative cleanup.
- All: Notifies every guest on the invite list (Internal and External). Use this for genuine meeting cancellations.
- External Only: Sends notifications only to guests outside your domain (e.g., clients), preventing internal team spam.
Outputs
This action does not return any dynamic output values.
Example Use Cases
- Automate Appointment Cancellations: Automatically delete a calendar event when a client cancels their booking via a web form.
- Sync Project Management: Remove deadline events from a shared calendar when a task is marked “Dropped” or “Completed” in your project management tool.
- Free Up Resources: Instantly delete a “Meeting Room” booking if the organizer declines the meeting invite.
- Silent Cleanup: Remove “Tentative” hold events once a final time is confirmed, without spamming the user with cancellation emails (by leaving the Notification field empty).
Example Scenario: The Leave Cancellation
Goal: Your organization allows employees to cancel approved leave. When they submit a cancellation form, the corresponding “Time Off” event must be removed from the Team Calendar.
Steps to Implement:
- Trigger: Google Forms - New Response (Form: “Cancel Leave Request”). Captures Employee Email and Date.
- Action: Google Calendar - List Events.
- Calendar: “Team Time Off”.
- Filter: Configure the query to search for events on the specific Date where the Title contains the Employee’s Name.
- Output: This action produces a list of matching events.
- Action: Foreach Item (Loop).
- Reason: “List Events” always returns a list/collection, even if it finds only one matching event. We must loop through the list to access the specific ID.
- Action (Inside Loop): Delete Calendar Event.
- Connection: HR Admin Account.
- Calendar: “Team Time Off”.
- Event: Map the
Event IDfrom the current loop item. - Send Notification: Select All (So the employee and manager get the cancellation confirmation).
Outcome: The specific leave entry is found and removed from the shared view, keeping resource planning accurate.
Best Practices
- Always “List” Before Deleting Never guess an Event ID. Always use a List Events action immediately before the delete step. This allows you to dynamically find the correct event based on criteria like Title, Date, or Attendees.
- Use Silent Delete for Admin Tasks If you are cleaning up technical placeholders or duplicate entries, leave the Send Notifications field empty. Flooding users’ inboxes with “Canceled Event” emails for things they didn’t know existed creates confusion.
- Handle “Not Found” Scenarios If your “List Events” action returns zero results (perhaps the user already deleted it manually), the Loop will simply not run, and the Delete action will be skipped. This is a safe way to prevent errors compared to trying to delete a hard-coded ID that might not exist.