Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Get Reference to the to be created issue

Steve Tedeschi
Contributor
October 26, 2023

I am using Jira automation to stub out "standard" Epics when a new Initiative is created. This is my first of two questions:

  1. Epics show all child tickets. I find it useful to include a link to open items; e.g., JQL 
    "Parent Link"=[insert issue key] AND statusCategory != Done ORDER BY Sprint, Rank
    Is there some way to get the key of the to be created issue?
    I've tried:
    1. {{createdIssue.key}}
    2. {{createdissues.get(0).key}}
      but am not getting anything returned, presumably, because the issue hasn't been created yet

Thanks in advance!

1 answer

1 accepted

1 vote
Answer accepted
Andy Heinzer
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Champions.
October 30, 2018

I think understand what you're trying to do here, but I don't believe there is a way to search only the displayName value on accounts at this time.  The current rest documentation doesn't make this explicitly clear though, however when searching for user accounts via rest, using either the query or username parameters, the following attributes always get searched in the search process:

  • username
  • displayname
  • email address

I can see why this would be potentially problematic when searching for a specific user.  But at the very least you should be able to change your URL to be

https://<our cloud instance>/rest/api/2/user/search?query=Bob

to get back all the accounts that any of those attributes that start with that string.

Kevin Chen
October 30, 2018

Thanks.  You might want to update the documentation with an example.  This was extremely confusing / frustrating.

Andy Heinzer
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Champions.
October 30, 2018

Fair point.  I will create a documentation update request to help make this more clear.  Thanks for reporting it.

Dario B
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
November 7, 2018

Hello @Kevin Chen and @André Mens

Just FYI, the documentation for the REST API endpoints needs indeed to be updated (especially the examples, some of them are missing the parameter/s) and some time ago I started creating the  below documentation requests:

I believe the first one is addressing what discussed in this thread.

 

Cheers,
Dario

Like Dip Pramanik likes this
Anand Elumalai
February 19, 2019

Hello @Andy Heinzer 

      Shall we use the get user API without username, query parameters. Shall we call the API just like https://<our cloud instance>/rest/api/2/user/search?query=startAt=1&maxResults=1000 . This will return the first 1000 users?

Dario B
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
February 21, 2019

Hi @Anand Elumalai 

Have you review the 3 documentation requests I liked above? I believe the answer to your  question is in there:

https://HOSTNAME/rest/api/latest/user/search?query=something@example.com

 

Otherwise, please provide a bit more context on what you are trying to achieve, I may have misunderstood the question :) 

Suggest an answer

Log in or Sign up to answer