Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,464,809
Community Members
 
Community Events
176
Community Groups

Unable to create Issue Using JIRA API

Hello Team,

I am trying to create Issue using provided API in JIRA documentation but it doesn't seems to be working.

Though I have made minimum payload but used to get error as:

{
"errorMessages": [
"The issue no longer exists."
],
"errors": {}
}
Payload:
{
"update": {

},
"fields": {
"summary": "Main order flow broken",
"parent": {
"key": "RAL"
},
"issuetype": {
"id": "10102"
},
"project": {
"id": "10100"
},
"description": "Order entry fails when selecting supplier."
}
}
Let me know If I am doing something wrong

1 answer

1 accepted

0 votes
Answer accepted

Hi @Amit Saxena ,

welcome to the Atlassian community!

I think that you are passing wrong fields to the REST api. Take a llok to the following guide https://developer.atlassian.com/server/jira/platform/jira-rest-api-example-create-issue-7897248/

In particular, "parent" param should be used just if you need to create a subtask and parent should contain the parent issue key. 

The correct params should be the following:

{ "fields": { "project": { "key": "TEST" }, "summary": "REST ye merry gentlemen.", "description": "Creating of an issue using project keys and issue type names using the REST API", "issuetype": { "name": "Bug" } } }

Hope this helps,

Fabio

Thanks Fabio.

I was following https://developer.atlassian.com/cloud/jira/platform/rest/v2/api-group-issues/#api-rest-api-2-issue-post

Can see the key mismatch.

http://hostname.com/rest/api/2/field/customfield_10300/option where I was trying to add option items for custom single select field but getting 

 

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<status>
<status-code>404</status-code>
</status>
Is there a different developed doc I have to follow??

Hi @Amit Saxena ,

it seems that there are no Rest api for this https://jira.atlassian.com/browse/JRASERVER-36112

Suggest an answer

Log in or Sign up to answer
TAGS

Atlassian Community Events