Hi there,
We create an app for Jira.
We use a Jira Cloud instance to test it.
Recently we’ve stopped being able to install it on the above account successfully. As part of our app installation process, we add a webhook to the installing account.
We first check to see if our webhook is already installed. If so we delete it.
Unfortunately this has stopped working. When we check to see if the webhook is already installed the API doesn’t return any webhooks.
When we go to add the webhook to the account we get an error saying we can’t because there is already a webhook created.
Here’s what we are seeing…
# Here's the api url
>>> client._jira.url
'https://api.atlassian.com/ex/jira/<some_id>/'
# No webhooks exist
>>> client._jira.get("rest/api/2/webhook")
{'maxResults': 100, 'startAt': 0, 'total': 0, 'isLast': True, 'values': []}
# Great no webhook so lets make one!
>>> data
{'webhooks': [{'jqlFilter': 'project != "non-existing-project"', 'fieldIdsFilter': ['status', 'summary', 'issuetype', 'project'], 'events': ['jira:issue_updated']}], 'url': '<some_new_webhook_id>'}
>>> res = client._jira.post("rest/api/2/webhook", data=data)
# Error, a webhook already exists for our app!? That doesn't seem right!
>>> res
{'webhookRegistrationResult': [{'errors': ['Only a single URL per app is allowed to be registered via REST API. Currently used URL: <some_old_webhook_id>']}]}
I wonder if maybe this has something to do with this account being recently downgraded (automatically?) to a free account?
Any guidance greatly appreciated!