Picking the right fieldKey in /rest/api/2/field/{fieldKey}/option

Hi @igor,

I am a product manager on the Jira Cloud team and I worked on this feature. @alexter_pr is correct – this API is only for managing the options for Issue Fields defined by Atlassian Connect apps. The field must be defined in your apps Atlassian Connect app descriptor, and the key must be the key of the app. You can see the app key and definition of the issue field in the descriptor of the demo project that Alexey linked. The key is teams-add-on and the relevant section of the descriptor is

"jiraIssueFields": [
            {
                "key" : "team-issue-field",
                "name" : {
                    "value" : "Team"
                },
                "description" : {
                    "value" : "Team tied to issue"
                },
                "type": "single_select",
                "extractions": [{
                    "path": "category",
                    "type": "string",
                    "name": "category"
                }]
            }
        ]

There is no public API for managing the options of a regular custom field, only for Issue Fields defined by apps that have been installed in the site. Apologies for the confusion.

2 Likes