We want to implement a check for our external (non-marketplace) app to find out if the targetted instance has our Atlassian Marketplace Jira app installed or licensed.
The user is authenticated via OAuth, but we were not able to get the License API to work: https://developer.atlassian.com/platform/marketplace/license-api-for-cloud-apps/
Unfortunately the documentation is not very detailled about authorization (or anything else), and when we use the bearer token from our OAuth authentication we only get error messages:
The requested resource requires authentication as an add-on
How to solve this issue and authenticate as an add-on?
Is this the best way to find out if an app is installed / licensed?
We would like to not store and look up the installed client keys and do these checks ourselves as the app could get uninstalled without our knowledge.
Thank you.