Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

close JIRA ticket on status OK #59

Open
verboEse opened this issue Jan 27, 2021 · 3 comments
Open

close JIRA ticket on status OK #59

verboEse opened this issue Jan 27, 2021 · 3 comments
Labels
enhancement New feature or request

Comments

@verboEse
Copy link

Hi.

Is it possible to automatically close the created ticket when the status changes back to "OK"?

@theFeu theFeu added the enhancement New feature or request label Mar 29, 2022
@yoshi314
Copy link

i did it by hand, using a wrapper script.

first, you have to find transition id for closing the issue, and then do a POST with that transition id.

@yoshi314
Copy link

curl -u icinga2:icinga2sekrit https://jira.server.com/rest/api/2/issue/${issue_key}/transitions -X POST --data '{"transition": {"id":"701"}}' -H "Content-Type: application/json"

where 701 would be transition id for close issue. That might vary on your installation.

do :

curl -s -u icinga2:icinga2sekrit https://jira.server.com/rest/api/2/issue/PROJ-12345/transitions

to find out available transitions.

Should not be too hard to figure out how to implement it in php code.

@moreamazingnick
Copy link

moreamazingnick commented Jun 18, 2024

you can do that using jira automation rules

onchange on icingaStatus -> close

but it must be a valid transition in your workflow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants