google-apps-scriptgoogle-calendar-apigoogle-cloud-console

Google Apps Script deployment not working


sorry if this question doesn't have all the necessary information (I'll edit it as I go if I'm missing something critical) but my Google Workspace Add-on isn't showing up after I click on 'Test Deployment' in Google Apps Script.

I have my appsscript.json and Code.gs file and also linked my project to a Google Cloud Console project with my Google Calendar API enabled (this is the app that I'm creating the add-on for). It didn't even ask me for authorization to my Google Calendar so already I know something is wrong.

I've been stuck at this for days. Would really appreciate the help!!

Tried playing around with the different deployment options. Ensured my code is working as intended.

Nothing seems to make that add-on show up in my Google Calendar or the Google Workspace Marketplace.


Solution

  • There may be a lot going on but I hope this checklist helps:

    The deployment should be a "Google Workspace Add on" and it should give you the option to install the addon in the same screen if:

    if in your manifest you don't have this on your manifest you won't be able to install the addon on calendar

    "calendar": {
          "eventOpenTrigger": {
            "runFunction": "onCalendarEventOpen"
          }
    

    The authorization part depends on the scope section in the manifest

    "oauthScopes": [
        "https://www.googleapis.com/auth/calendar.addons.execute",
        "https://www.googleapis.com/auth/calendar.readonly"
      ],
    

    Also take a look on that

    You can check the link for a useful example

    https://developers.google.com/workspace/add-ons/quickstart/cats-quickstart#set_up_the_script

    I Hope this helps you