Hi,
I am following the instructions on https://developer.atlassian.com/server/jira/platform/webhooks/ for registering a webhook.
I am using the same http client I use for all my other functionality
let httpClient = addon.httpClient(request);
for the sake of it the scopes are
“scopes”: [
“read”,
“write”,
“delete”,
“project_admin”,
“admin”
],
The url is
let webhookurl = hostBaseUrl+ ‘/rest/webhooks/1.0/webhook’;
the json
let webhookjson= {
“name”: “Sprint Webhooks”,
“url”: “/jira-event”,
“events”: [
“sprint_updated”,
“sprint_deleted”
],
and the call:
httpClient.post({
headers: {
'Authorization': "JWT "+ request.context.token
},
url: webhookurl,
accept: 'application/json',
json: webhookjson,
},
The response is always 403 (with or without the Authorization header).
What am I doing wrong?
Thanks
Jerry