Search code examples
google-calendar-apigoogle-api-client

Google api auth client token for server api calls


I want to integrate users google calendar with my web app. I have been looking through the google docs but at this stage it is not clear whether i can use the simple drop in java-script library Auth the user and use that Auth token on my server for simple API calls to the calendar API?


Solution

  • You may want to check this Google Calendar API Quickstart for reference.

    Every request your application sends to the Google Calendar API must include an authorization token. The token also identifies your application to Google. Your application must use OAuth 2.0 to authorize requests. No other authorization protocols are supported. If your application uses Google Sign-In, some aspects of authorization are handled for you.

    After the initial user authorization, calls to gapi.auth.authorize that use immediate:true mode will obtain an auth token without user interaction.

    Hope this helps!