What field types are compatible with api/2/field/{fieldKey}/option endpoints?

JP Rowan November 29, 2016

I am trying to create a select field that I can update the options using the rest API.  There are a complete set of endpoints designed for this purpose, yet when I attempt a GET call on any of my select fields I am returned the following error:

{
  "errorMessages": [
    "The field with the given key does not exist or does not support options"
  ],
  "errors": {}
}

I have attempted creating a new field using the POST /rest/api/2/field method with the following definition:

{
    "name": "New Customer Field",
    "description": "Custom field for picking groups",
    "type": "com.atlassian.jira.plugin.system.customfieldtypes:select"
}

and still I am returned the same error above when I attempt to use any of the /option endpoints.  Can someone please explain what field type are the endpoints designed to work with?

11 answers

1 accepted

1 vote
Answer accepted
JP Rowan July 19, 2017

For clarification, this endpoint is only compatible with fields that are created with an Atlassian Connect Add-on.  Currently there is no support for editing select field values via API for Cloud instances.

0 votes
Jira Implementaton May 4, 2018

is it resolved? 

0 votes
Tien Hoang July 18, 2017

Do we have any update on this this issue, i also have the same problem with my Jira cloud ? 

0 votes
Eli Evans December 22, 2016

Thank you for the definitive answer, it has been difficult finding anything concrete for what can and cannot be done with so many versions of JIRA running around.

 

0 votes
Volodymyr Krupach
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.
December 21, 2016

Hi Eli,

You can not expose own REST for JIRA cloud. It's possible only for JIRA Server.

0 votes
Eli Evans December 21, 2016

From today's support ticket I was told to sit and wait and hope something gets done in that feature request.  I'm following up to see if I can expose those API points myself by writing a rest plugin, but that is a little beyond me and I hope it does not come to that.

0 votes
Eli Evans December 21, 2016

As far as I can tell, you can create an empty custom field, but there are no ways to add values to the custom field using REST.  My successful postman body for creating an empty select list was

{

    "name": "Whatever",

    "description": "Custom field for whatever",

    "type": "com.atlassian.jira.plugin.system.customfieldtypes:select"

}

I was not able to post/put any options, nor do anything effective with options at creation.  Hoping to get some resolution to this.  There has been at least one ticket open for this for over a year sad

 

https://jira.atlassian.com/browse/JRA-36112  Hopefully we can restart the campaign.

0 votes
Volodymyr Krupach
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.
December 17, 2016

Hi JP Rowan,

Thank you for sharing the status!

0 votes
JP Rowan December 16, 2016

I have a ticket in with the support team, but I was informed this is expected behavior due to the fact this endpoint was intended to only work for fields created by a Connect Add-on.  I was then pointed to this site: https://developer.atlassian.com/ to submit feedback, but when I submitted the form I got this error:

 Screen Shot 2016-12-14 at 8.21.40 AM.png

I am now waiting on support to create the feature request for me...

0 votes
Noah Van Loen December 16, 2016

+1 – Did a bug get logged for this error?

0 votes
Volodymyr Krupach
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 29, 2016

Checked this in my cloud instance and got the same error. Please report a bug: https://confluence.atlassian.com/support/atlassian-cloud-bug-fixing-policy-206865884.html

Suggest an answer

Log in or Sign up to answer