Recently, I had to create one status dashboard for a JIRA project. Tableau does not connect to JIRA out of the box and you need to purchase a connector to get this functionality. Since JIRA has a REST API, my initial instinct was to build a web data connector. But it turns out that you can get the JIRA data to Tableau in two lines of python code.I ended up with writing a python script that runs every hour and dump the JIRA data to a json file. Tableau can consume json file easily and it works for both JIRA cloud and server. Here is the essence of my script.from jira import JIRA import json import sys jira = JIRA(server="yourserver", auth=('uid','pwd')) # Get all issues in project issues = jira.search_issues('project=yourproject',maxResults=sys.maxsize) # Keep only raw data cleaned_list = [issue.raw for issue in issues] # Dump cleaned list as a json file with open('result.json','w')as fp: json.dump(cleaned_list,fp) I know what you are thinking; this is not two lines! Well, it can be written in two lines if you dont care about code styling or PEP-8 compliance.import jira,json,sys with open('result.json','w')as fp:json.dump([issue.raw for issue in jira.JIRA(server="yourserver",auth=('uid','pwd')).search_issues('project=yourproject',maxResults=sys.maxsize)],fp) Remember to select all schema levels when making the connection in Tableau..Here is a preview of the available fields after creating the connection. Post navigationTableau Tip: Aligning Text and Shape inside a single cell (KPI Indicators) Predicting Dam Water Levels Using Tableau
Hi, this is awesome!! Many thanks for sharing 🙂Btw, I know this post’s from a while ago but, any chance you could explain how to implement the code (as in, where – never used Python in combo with other software)?Regards,MarionaReply
You can copy the code in to a .py file and run it as a standalone script. (You need to update your JIRA url and credentials).Reply
Very helpful article, thanks for sharing! For those who don’t know Python or just looking for an easier way, I recommend taking a look at this Tableau Connector for Jira add-on https://marketplace.atlassian.com/apps/1221376/tableau-connector-for-jira?hosting=server&tab=overview This plugin allows you to import data from Jira to Tableau and create informative dashboards and reports in minutes. You can export jira tables and fields, including Custom fields, History, Jira Service Desk, Tempo Timesheets, Tempo Planner, Agile, etc. Hope this helps someone too))Reply
Hello,Thanks for providing this! I tried running the script and updated the jira to my server and Auth credentials. It appeared to run with Python closing out automatically. Where is the result.json supposed to be located?Reply
Thanks for this helpful article! It was previously written that there is an easier way for those who don’t know Python. I also know the convenient way to connect Jira and Tableau — the Skyvia Connector: https://skyvia.com/blog/how-to-connect-tableu-and-jira. This article details how to connect JIRA to Tableau in 4 steps without coding or installation in your browser. I think it might be helpful.Reply