jira|November 10, 2017|1 min read

Jira Rest APIs common usages

TL;DR

Use JIRA REST APIs like createmeta to fetch custom field values, create issues programmatically, and automate JIRA workflows with basic authentication.

Jira Rest APIs common usages

This article shows some of common usages of JIRA rest apis.

Note: This article assumes you have a username and password for calling rest api of JIRA.

Get values of a custom field for a project

You know about a custom field, and want to get its possible values like a drop down having alot of options.

There is an API: createmeta, which gives you every possible field require to create JIRA issues.

Note: This API is pretty expensive in terms of data. It can give you complete data for all the projects. But, you might be interested in one or two projects.

curl -u "username:password" "https://jira_url/rest/api/2/issue/createmeta?projectKeys=XYZ"

Above api call will give you very limited result, which has only the issue types, and no expanded fields. But, we are interested in getting data of a custom field.

curl -u "username:password" "https://jira_url/rest/api/2/issue/createmeta?projectKeys=XYZ&expand=projects.issuetypes.fields"

Now, you are telling JIRA to return expanded fields, and now you will get values of all custom fields that appear while creating a JIRA issue in your project XYZ, and for each issuetype.

Related Posts

Drupal Helpful codes for database queries

Drupal Helpful codes for database queries

Being a drupal user from last around 5 years, I used to know small codes for…

Curl - Your friend for Rest APIs/Calls - Basic Commands

Curl - Your friend for Rest APIs/Calls - Basic Commands

Curl is a wonderful tool for initiate REST APIs or calls. Or, you can literally…

Docker image for Drupal 7, and Php extension MongoDB installed.

Docker image for Drupal 7, and Php extension MongoDB installed.

You have drupal 7 image from docker hub, and want to connect tomongo db via php…

Docker Push: How to push your docker image to your organization in hub.docker.com

Docker Push: How to push your docker image to your organization in hub.docker.com

Tag the image, by seeing its image id, from docker images command docker tag 04d…

How to get Youtube Video Thumbnail Images

How to get Youtube Video Thumbnail Images

If your youtube video looks like:https://www.youtube.com/watch?v=g0kFl7sBdDQ…

Claude Code Skills — Build a Better Engineering Workflow with AI-Powered Code Reviews, Security Scans, and More

Claude Code Skills — Build a Better Engineering Workflow with AI-Powered Code Reviews, Security Scans, and More

Most developers use Claude Code like a search engine — ask a question, get an…

Latest Posts

Claude Code Skills — Build a Better Engineering Workflow with AI-Powered Code Reviews, Security Scans, and More

Claude Code Skills — Build a Better Engineering Workflow with AI-Powered Code Reviews, Security Scans, and More

Most developers use Claude Code like a search engine — ask a question, get an…

Building an AI Voicebot for Visitor Check-In — A Practical Guide to Handling the Messy Parts

Building an AI Voicebot for Visitor Check-In — A Practical Guide to Handling the Messy Parts

Every office lobby has the same problem: a visitor walks in, nobody’s at the…

Server Security Best Practices — Complete Hardening Guide for Production Systems

Server Security Best Practices — Complete Hardening Guide for Production Systems

Every breach post-mortem tells the same story: an unpatched service, a…

Staff Engineer Study Plan for MAANG Interviews — The Complete 12-Week Roadmap

Staff Engineer Study Plan for MAANG Interviews — The Complete 12-Week Roadmap

If you’re a Senior Engineer (L5) preparing for Staff (L6+) roles at MAANG…

XSS and CSRF Explained — The Complete Guide with Real Attack Examples and Defenses

XSS and CSRF Explained — The Complete Guide with Real Attack Examples and Defenses

XSS and CSRF have been in the OWASP Top 10 for over a decade. They’re among the…

OWASP Top 10 (2021) — Every Vulnerability Explained with Code

OWASP Top 10 (2021) — Every Vulnerability Explained with Code

The OWASP Top 10 is the industry standard for web application security risks. If…