<jupyter_start><jupyter_text>Create Event<jupyter_code>from datetime import datetime, timedelta


d = datetime.now().date()
tomorrow = datetime(d.year, d.month, d.day, 10) + timedelta(days=1)
start = tomorrow.isoformat()
end = (tomorrow + timedelta(hours=1)).isoformat()

body = {
            "summary": "Automating calendar",
            "description": "This is a tutorial example of automating google calendar with python",
            "start": {"dateTime": start, "timeZone": "Asia/Kolkata"},
            "end": {"dateTime": end, "timeZone": "Asia/Kolkata"},
        }
event_result = CC.create_event(calendarId="primary", body = body)<jupyter_output>created event
id:  n8su45n9n3cenniemrs7rffsck
summary:  Automating calendar<jupyter_text>Get Event<jupyter_code>event = CC.get_event(calendarId="primary",iCaiUID=event_result["iCalUID"])
event[0]["summary"]<jupyter_output>2022-02-13T13:30:00+09:00 Automating calendar<jupyter_text>Update Event<jupyter_code>event_id = event_result["id"]
d = datetime.now().date()
tomorrow = datetime(d.year, d.month, d.day, 9)+timedelta(days=1)
start = tomorrow.isoformat()
end = (tomorrow + timedelta(hours=2)).isoformat()

body={ 
    "summary": 'Updated Automating calendar 222',
    "description": 'This is a tutorial example of automating google calendar with python, updated time.',
    "start": {"dateTime": start, "timeZone": 'Asia/Kolkata'}, 
    "end": {"dateTime": end, "timeZone": 'Asia/Kolkata'},
}

event_result = CC.update_event(calendarId="primary",eventId= event_id, body = body)
event = CC.get_event(calendarId="primary",iCaiUID=event_result["iCalUID"])
event[0]["summary"]<jupyter_output>2022-02-13T12:30:00+09:00 Updated Automating calendar 222<jupyter_text>Delete Event<jupyter_code>CC.delete_event(calendarId="primary",eventId = event_result["id"])
CC.get_event(calendarId="primary",iCaiUID=event_result["iCalUID"])<jupyter_output>No upcoming events found.
{'fraction_non_alphanumeric': 0.15308254963427378, 'fraction_numerical': 0.029780564263322883, 'mean_word_length': 6.48046875, 'pattern_counts': {'":': 16, '<': 13, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '4', 'dir': 'jupyter-structured-clean-dedup', 'id': '392068', 'license': 'Apache-2.0', 'n_tokens_mistral': 697, 'n_tokens_neox': 654, 'n_words': 122, 'path': '00. check_google_calendar.ipynb', 'repo_name': 'sungreong/PyKorAnniversary', 'size': '1914'}