Search code examples
jirajira-rest-apijira-plugin

Is it possible to develop a Jira plugin with RESTful capabilities for creating issues programatically?


I have developed a Django app which hosts a bunch of forms that collect information about issues and I want to use this data to create Jira issues programmatically.

I have a conceptual idea of how that can be achieved but my problem is that I am a complete software development newbie and also have never used Jira to this date, hence googling stuff is quite hard as I have an almost non-existent vocabulary in these regards and things get quite overwhelming really fast. I want to know if what I have in mind even makes sense before I delve deeper into documentations and figuring out how to implement stuff.

So I'm going to send POST requests from my Django app containing the issue information in JSON format. These POST requests would then be handled by some Java service which in turn uses the JRJC to create issues on Jira. In my head this implies that I have to develop a whole server (or use some kind of framework for that matter) for django to send its requests to and handle them. Would it be possible to write a plugin for JIRA that bypasses the need for such a server so I could just write the service for handling the requests and expose it on some URL based on the domain of my Jira instance?

I apologize if my question appears vague or ill-structured. Any attempts to shine light on my incompetence or pointing fingers in some direction will be greatly appreciated!


Solution

  • I assume that you're talking about Jira Server (hosted by you) rather than Jira Cloud (hosted by Atlassian).

    A Jira plugin can expose a REST endpoint, so yes, you can write such a plugin and POST to an endpoint you define, which then uses the Jira Java API to create issues.

    See https://developer.atlassian.com/server/framework/atlassian-sdk/rest-plugin-module/ for information on putting REST endpoints in your plugin.