Hi everyone, i got two issues with the descriptor file in my connect add-on.
(1) About webhook:
I want update our database when user changed an issue status, so i use webhook "jira:issue_updated" to do this as the code below in descriptor file:
....
"webhooks": [
{
"event": "jira:issue_updated",
"url": "/issue-updated"
}
....
However i just got the request with "user_key", what i need is at least i can get the "issue_key", then i can use REST API to query the last status of issue. If i can get immediately what's changed about issue is so great.
I also tried with this:
....
"webhooks": [
{
"event": "jira:issue_updated",
"url": "/issue-updated/?issue_key={issue.key}"
}
....
and
....
"webhooks": [
{
"event": "jira:issue_updated",
"url": "/issue-updated/?issue_key=${issue.key}"
}
....
However, i can't install the add-on with the url contain the context parameter, it says: "An error occurred while installing the add-on. Refer to the logs for more information."
(I follow this instruction: https://developer.atlassian.com/static/connect/docs/latest/modules/common/webhook.html to do the webhook)
(2) About the Lifecycle callback to our server whenever user installed the add-on:
The callback works fine, however i also only received the parameter "user_key", and no anything more. How can i receive other parameters like this?
{
"key": "installed-addon-key",
"clientKey": "unique-client-identifier",
"publicKey": "MIGf....ZRWzwIDAQAB",
"sharedSecret": "a-secret-key-not-to-be-lost",
"serverVersion": "server-version",
"pluginsVersion": "version-of-connect",
"baseUrl": "http://example.atlassian.net",
"productType": "jira",
"description": "Atlassian JIRA at https://example.atlassian.net",
"serviceEntitlementNumber": "SEN-number",
"eventType": "installed"
}(I follow this instruction: https://developer.atlassian.com/static/connect/docs/latest/modules/lifecycle.html to do the the callback of lifecycle)
Thanks so much for viewing my issues.