Domaina whitelist problem when app is published

Greetings everyone!

I’m having a problem with domain whitelisting. Whitelisting worked on my local setup but after updating my companies custom app I got errors about a domain not being whitelisted.

Here is the manifest.json:

    "platform-version": "2.0",
    "product": {
      "freshdesk": {
        "location": {
          "ticket_sidebar": {
            "url": "index.html",
            "icon": "img/icon.png"
          }
        }
      }
    },
    "whitelisted-domains": [
      "https://<%= iparam.domainURL.freshdeskManifest %>",
      "https://<%= iparam.domainURL.teamworksManifest %>",
      "https://s3.eu-central-1.amazonaws.com",
      "https://tw-eu-bucket.s3.eu-west-1.amazonaws.com"
    ]
  }

saved iparams:

   {
        "freshp_101_101_freshdesk": {
            "freshp_101_101_custom_iparams": {
                "__meta": {
                    "secure": [
                        "apiKeys"
                    ]
                },
                "domainURL": {
                    "freshdesk": "https://example.freshdesk.com/",
                    "freshdeskManifest": "example.freshdesk.com",
                    "teamwork": "https://example.eu.teamwork.com/",
                    "teamworkManifest": "example.eu.teamwork.com"
                }
            }
        }
    }

Description of the problem:
In app settings user must provide freshdesk and teamwork URLs, so these two systems can be connected. So we need our whitelisted-domains to be dynamic. This was working, but with the latest changes it is broken.

Maybe you could point me to and example that uses dynami whitelisted-domains set from app settings?

Hi Peteris,

Welcome to community! :slight_smile:

Domains can be whitelisted dynamically as you u have done.
I can see one typo mistake and maybe that’s the reason it isn’t working correctly. In saved iparams, the key is “teamworkManifest” while when whitelisting, you have written “teamworksManifest” with an additional s.

Let me know if you are unable to solve this.

3 Likes

Omg, haha, classic, thanks. I wonder why it still worked from fdk, will try the fix now :slight_smile:

1 Like

This topic was automatically closed 6 days after the last reply. New replies are no longer allowed.