Why is Google Calendar API (oauth2) responding with 'Insufficient Permission'?

后端 未结 8 1305
萌比男神i
萌比男神i 2020-12-01 17:42

I\'m doing a get request to the following URL (with {id} replaced with the id from the web interface):

https://www.googleapis.com/calendar/v3/calendars/{id}
         


        
相关标签:
8条回答
  • 2020-12-01 18:40

    I have had to delete permissions to my application and then back to give permissions in https://security.google.com/settings/security/permissions

    0 讨论(0)
  • 2020-12-01 18:42

    When I did the example in QuickStart, I could get the list of the events from my calendar.
    But I was using the SCOPE='https://www.googleapis.com/auth/calendar.readonly'.

    When I execute the code was generated a link, where I had to create a key for permission to list the events from Calendar. So, when I tried to insert an event I had this error INSUFICIENT PERMISSION.

    To solve this issue:
    1) I changed the SCOPE to https://www.googleapis.com/auth/calendar
    2) delete the file token.json
    3) execute the code again, and I had to create a new key for permission, now with the permission to insert a new event.

    0 讨论(0)
提交回复
热议问题