/google-calendar-api-client-python

google-calendar-api-client-python is Google Calendar api client for python3.

Primary LanguagePythonMIT LicenseMIT

google-calendar-api-client-python

Travis CI COVERALLS Code Climate Issue Count LICENSE MIT

google-calendar-api-client-python is Google Calendar api client for python3.

Requirement

  • Python >= 3.5

Quick start

  1. Install by pip

    # install from github master branch
    pip install -U https://github.com/kacchan822/google-calendar-api-client-python/archive/master.tar.gz
    
  2. Usage

    import datetime
    
    from google_calendar_api.client import GoogleCalendarClient
    
    CALENDAR_ID = 'XXXXXXXXXXXXXXXXX@group.calendar.google.com'
    
    client = GoogleCalendarClient(calendar_id=CALENDAR_ID, client_secrete_file='/path/to/client_secret.json')
    
    events = client.get_events()
    
    for event in events:
        start = event['start'].get('dateTime', event['start'].get('date'))
        print(start, event['summary'])
    

Acknowledgements