Do we have any Rest API or JQL query to fetch all issues in Jira Server having issuelinks? - jira

Do we have any rest API or JQL query to execute which would fetch all the issues in a project having 0 or more issue links?
In Jira Cloud using "numberOfLinks" parameter we could fetch all the issues having issue links. But how do we fetch all the issues consisting of issue links in Jira Server/Datacenter?
Thanks & Regards,
Preethi H R

You can use the JQL query:
issuefunction in hasLinks() and project = XXX
That's show you all the issue in XXX project that has 1 link or more.
XXX = your project key
If you want to see all issues that doesn't have any links you can use:
issuefunction not in hasLinks() and project = XXX

Related

Jira Xray JQL - All test executions for a testplan

How would I construct a JQL query to find all text executions for a given testplan? I do have the testplan key.
I know this sounds strange since you can see it, when you open the testplan. But I am trying to automate the creation of executions and in the API the testplan issue has no link to it's executions, it's only the other way around. So I try to get them by query.
Use:
issue in testPlanTestExecutions("XXX")
XXX = test plan key

How can I get all issues from a specific unreleased version via jira rest api

I am not administrator of my project.I want to get list of all JIRAS from specific unreleased version so that I can close them after production release.How can I get such jira list via jira rest API??
Use this JQL:
project = PROJECTKEY and fixVersion = 3.5.2 AND resolution is EMPTY
And send it with the GET HTTP method to the api/2/search endpoint using the jql queryparam
Full example:
GET https://yourjiraserver.com/api/2/search?jql=project%20%3D%20PROJECTKEY%20and%20fixVersion%20%3D%203.5.2%20AND%20resolution%20is%20EMPTY

how can a Jira workflow validator read the status of bitbucket pull request?

I am trying to create a workflow validator that checks if there's an (open) pull request in the issue. The JQL for listing such issues is easy:
issue.property[development].prs = 1
But if I try in the Simple Scripted Validator
issue.property['Development'].prs == 1
I get the error that there's no property for the class com.atlassian.jira.issue.Issue
We're using Jira 7.x, and are testing the latest BitBucket version for managing branches. Crunched the APIs, but to no avail: I can't get past reading the prs (Pull Request Status).
Note that Development or prs are no custom fields in Jira, but fields on the right side of the screen, coming from the integration with BitBucket.
Perhaps it doesn't work because you spelled 'Development' with capital D. When I do this, I get zero results (but not the error that you mention about the property not being there).

Query all issues for the currently active project in Jira

I would like to create a general query that is active in the web interface that selects all issues for the currently selected project.
For example if I have two projects
PROJ1
PROJ2
to select all issues for PROJ1 I would create a query
Project = PROJ1
However, if I have a multitude of projects I need to create a query specific to that particular project.
What I would like to do is create a query such as
Project = CurrentProject
Is there a query syntax that allows me to do such a thing?
As far as I know, the Create JQL currentProject() function issue is still unresolved.
However there exists CurrentProjectFunction plugin on MarketPlace which gives you following ability in JQL:
project = currentProject()
This must be new because I cannot find anyone mentioning it, this works nicely for me
project = "{{ project.name }}"
https://support.atlassian.com/cloud-automation/docs/jira-smart-values-projects/

Worklog gadget for JIRA

Is there an ability to create JIRA gadget that shows my total month worklog for 2 projects?
Or you can create your own plugin with required gadgets using this book: "JIRA 5.x Development Cookbook" by Jobin Kuruvilla. It was useful for me
You can do this Tempo. First create a saved search for your two projects. Then view them in the Advanced Timesheet.

Resources