Populating Custom Field Drop-down With JSON Data

Hello Atlassian Community.

I would like to achieve the following, your help is needed and welcomed.

We use BuildBot for our build-system and management. One of the neat features of BuildBot is, that it offers an API printing (fairly human readable) text output. Sample output below:

{
  "dir": "TestBuild1", 
  "cachedBuilds": [
    0001, 
    0002, 
    0003, 
    0004, 
    0005, 
    0006, 
    0007, 
    0008
  ]
  }

That said, I would like to grab data from that respective output and auto-populate a JIRA drop-down during bug/issue creation.

Data represented is in a numbers-only format which never shows more that 10 new values.

Furthermore, I would like to achieve this without the use of paid plug-ins. The most notable is nFeed, which would break the budget for this venture.

Thanks in advance!

2 answers

You may create your own plugin which will contain customfield with ajax query to data you need.
Examples of customfield plugin you can find here or in Jira Development CookBook
Format of example output is JSON, ajax support this. Here I described how to do AJAX call. https://answers.atlassian.com/questions/157639/ajax-calls-to-jira-from-custom-field

Except this you need some javascript to show your data.

Is there a way to use script runner to accomplish this?

Hi Melissa,

I'm curious to know how you solved your problem. Did you use ScriptRunner?

Thanks

We ended up using a plugin of our own development. We were repeatedly running into issues with our tomcat accepting scriptrunner's requests.

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted 2 hours ago in Off-topic

Miscellaneous Monday - CreatatronV3

You may remember, not so long ago, that together we invented the most evil of machines: The Destructo5000!  The effects of missing Durian rippled over nations. Complete chaos as goat chee...

36 views 2 2
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you