In Google Cloud Console, enable the Google Calendar API, then create an API key (APIs & Services → Credentials). For production you can restrict it by HTTP referrer. The key is stored only in this browser's localStorage. Calendar:
localStorage