createIssueFieldOption method

Future<IssueFieldOption> createIssueFieldOption({
  1. required String fieldKey,
  2. required IssueFieldOptionCreateBean body,
})

Creates an option for a select list issue field.

Note that this operation only works for issue field select list options added by Connect apps, it cannot be used with issue field select list options created in Jira or using operations from the Issue custom field options resource.

Permissions required: Administer Jira global permission. Jira permissions are not required for the app providing the field.

Implementation

Future<IssueFieldOption> createIssueFieldOption(
    {required String fieldKey,
    required IssueFieldOptionCreateBean body}) async {
  return IssueFieldOption.fromJson(await _client.send(
    'post',
    'rest/api/3/field/{fieldKey}/option',
    pathParameters: {
      'fieldKey': fieldKey,
    },
    body: body.toJson(),
  ));
}