Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Jira API end point for adding Story Points in a Issue

Deleted user October 21, 2021

Jira API end point for adding Story Points in a Issue

1 answer

1 vote
Mikael Sandberg
Community Champion
October 21, 2021

Hi @[deleted],

Welcome to Atlassian Community!

Story Points is just a custom field so the end point you are looking for is Edit issue.

Deleted user October 21, 2021

Thanks @Mikael Sandberg for the quick response, could you please share me body schema that I need to pass for updating the story points for a particular issue? 

Like xiangzhongwu likes this
Mikael Sandberg
Community Champion
October 21, 2021
{ 
"fields": {
"Story Points" : <Number>
}
}

This is all you need to send in the body.

Deleted user October 22, 2021

Hi @Mikael Sandberg ,

Getting below error when i tried Edit Issue endpoint, could you please help? Did i anything?

Error

 "errors": {
        "Story Points""Field 'Story Points' cannot be set. It is not on the appropriate screen, or unknown."
    }
End Point URL : PUT {{JiraURL}}/rest/api/3/issue/{issueIdOrKey}
Body
{ 
"fields": {
"Story Points" : 10
}
}
Mikael Sandberg
Community Champion
October 22, 2021

The clue is in the error message. You have to make sure Story Points is on the edit screen.

Deleted user October 22, 2021

Hi @Mikael Sandberg -  Could you elaborate more on below point please? You have to make sure Story Points is on the edit screen.

 

In my Jira Issue i can see the Story Points field available and manually i am able to update as well.

Like G H Mahimaanvita likes this
Mikael Sandberg
Community Champion
October 22, 2021

You have to make sure Story Points is on both your create screen and edit screen. Go to project settings and check you screen scheme.

Mikael Sandberg
Community Champion
October 22, 2021
Deleted user October 22, 2021

Hi @Mikael Sandberg Just checked its there.

Mikael Sandberg
Community Champion
October 22, 2021

Instead of using "Story Points" have you tried using the ID for the field instead? It is something like this: customfield_123456. You can get the ID by going to Issues > Custom fields, search for Story Points and then click the three dot menu and hover over Details. The URL will show you the ID, it is the last part of the URL.

Deleted user October 23, 2021

Hi @Mikael Sandberg 

Tried with the above suggestion but still no luck. PFB Error

{
    "errorMessages": [
        "Issue does not exist or you do not have permission to see it."
    ],
    "errors": {}
}
Alistair Quinn
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 16, 2022

As suggested above, the clue is in the error message.

Configure your Screen to include Story Points.

To update, you must use the custom field id. To find this, just do a Get on the request and see which custom field related to Story Points and then you should be good to go!

Justin Meyer
Contributor
November 4, 2023

I am using the correct custom id, and my screen shows the field, but this doesn't seem to work. 

 

Has anyone been able to make story points work?  I'm able to set every other field. 

 

UPDATE! 

 

I made this work by using the REST "update" property instead of the "fields" property.

Like jérôme Legoff likes this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events