Unable to get the issue metadata using jira on premise

Saurabh Bhandari July 14, 2022

I am using jira on premise and trying to get metadata for creating an issue as per this atlassian doc :
https://developer.atlassian.com/server/jira/platform/jira-rest-api-examples/

Url used : http://localhost:8080/rest/api/2/issue/createmeta?projectKeys=DEMO&expand=projects.issuetypes.fields

Response : 

{
    "errorMessages": [
        "Issue Does Not Exist"
    ],
    "errors": {}
}
So I am figuring out an API for jira on premise which will provide metadata for creating an issue.


Also, When i am using that endpoint for the jira cloud , It is working fine 
Url used: https://{host}/rest/api/3/issue/createmeta

Response :
 image (1).png

2 answers

1 vote
Jannik Arndt July 26, 2022

Hey Saurabh!

Thanks to your post I looked at the docs at https://developer.atlassian.com/server/jira/platform/jira-rest-api-examples/ and found the following:

Note that the createmeta resource has been reported to cause issues especially on larger instances. These issues have involved the size of the response or Jira running out of memory. That is why we decided to remove this endpoint in Jira 9.0.

The page is now split into "before 8.4" and "after 8.4".

Here they propose three new endpoints as replacement:

Note that these seem to NOT work with Jira Cloud.

Tom Penrose August 22, 2022

I am running on prem Jira DC 9.1.0 and these endpoints do not seem to work.  I am able to get projects but the second URL when requested with my project key or project id return "400 - Bad Request".  Any thoughts?

Like # people like this
Christoph Roll _Communardo_ April 12, 2023

Same problem as @Tom Penrose - different error on DC v9.4.3 though:

Via Browser:

SyntaxError: JSON.parse: unexpected end of data at line 1 column 1 of the JSON data
Via CURL: Nothing at all
ghanshyam July 12, 2023

Same problem for on prem 9.4

0 votes
Jared Kells
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 Leaders.
November 1, 2022

Hey Tom,

I've seen 400 responses with no error messages from those endpoints when the requesting user doesn't have permission to create issues in the project.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events