Dear all,
I'm creating a ticket from a confluence form using confiforms and everything works as expected until I try to add watchers to the JIRA ticket.
My code looks like
{ "fields":
{ "project": {"key": "CBCF"},
"summary": "$summary",
"assignee": {"name":""},
"description": "Please go to www and $description",
"issuetype": {"name": "Task"},
"labels": ["CBCFBuckets","[entry.CBCFTeam.escapeJSON]"],
"watchers": ["watcher1","watcher2","watcher3" ],
}
}
the error I get when trying to create the ticket is:
com.atlassian.sal.api.net.ResponseException: Error communicating with Jira, {"errorMessages":[],"errors":{"watchers":"Field 'watchers' cannot be set. It is not on the appropriate screen, or unknown."}}
The only refence to adding watcher I've found is this in here where it says:
You can set additional watches to the issue what will be created, but in this tutorial we omit this step (see IFTTT macro parameter "watchers"). Could be set dynamically, referencing entry fields or record owner or modifier.
but when I try to do it in the ConfiForms IFTTT Integration Rules, under watchers, it does not add them in the JIRA ticket.
Could anyone help me, please?
Hi @Arnau Bria
Watchers could not be added as part of the issue creation. As technically those are added via a different API call
These are to be set in the macro parameters
Alex
Hi @Alex Medved _ConfiForms_ and thanks for your answer.
I already did it like this, this is what I meant by
but when I try to do it in the ConfiForms IFTTT Integration Rules, under watchers, it does not add them in the JIRA ticket.
the problem is that even adding them there like
["watcher1","watcher2","watcher3" ]
or
"watcher1","watcher2","watcher3"
they don't end up as watchers in the JIRA ticket.
I'm using user's email as those are jira user names.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
watcher1,watcher2,watcher3
Each must be a username that your Jira recognizes and accepts
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ok, then I guess (and hope) that this is the problem. I've been told that email is what JIRA users as usernames, but seems like it is not the case.
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can verify that yourself, checking through the APIs - https://docs.atlassian.com/ConfluenceServer/rest/8.6.0/#api/user-getUser
Alex
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks!
Did it and the username in both JIRA/Confluence are the email address... any other reason why the watchers are not added to the ticket?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hard to tell... impossible to debug something like this remotely
Try adding the watcher yourself, via API - https://docs.atlassian.com/software/jira/docs/api/REST/9.11.0/#api/2/issue-addWatcher
(postman or curl)
Does it work?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
API worked. I'm going to do the whole thing from API instead of confluence and confiforms.
thanks for your help.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
API can also be invoked from ConfiForms.
But are you saying that setting the watchers parameter to the correct value representing a user does not work when called from the ConfiForms IFTTT macro?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
yes, but as I realized I have access to the API I prefer to create the JIRA from my applications insetad of sending people to confluence.
But yes, adding watchers in ConfiForms IFTTT macrodoes not work as expected.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Could we take this via our support channel? I would love to understand what does not work for you in ConfiForms and how is that watchers parameter is configured
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I'm not the atlassian responsible here in my compnay. I'd have to consult.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have my conversation to get 4 years pectices to be help Google patner
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.