Cannot get authorization dialog to show with Google Apps Script

心不动则不痛 提交于 2019-12-02 11:16:13

问题


I've got a Google Apps Script that I have been working on to manage an event's resources - it's working fine I'm hitting an API and updating the sheet with my Python code.

I then added functionality to notify users via email that a video is ready to be approved. I've already seen the authorisation dialog and allowed the script to use my Gmail account etc.

But when running my script with the installable trigger added it's showing this:

The script doesn't have permission to perform that action. Required permission: (https://www.googleapis.com/auth/gmail.send || https://www.googleapis.com/auth/gmail.compose || https://www.googleapis.com/auth/gmail.modify || https://mail.google.com/ || https://www.googleapis.com/auth/gmail.addons.current.action.compose) at onCellEdit(Code:60)

In my StackDriver Error logs.

I cannot get the Google Apps script to re-authorise the Gmail app I wrote to save my life. Does anyone have experience with this and know how to force the script reauthorization?


回答1:


You can try invalidating your authorization with ScriptApp.invalidateAuth().



来源:https://stackoverflow.com/questions/52274478/cannot-get-authorization-dialog-to-show-with-google-apps-script

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!