Hi everyone, I have more than 200 data to write down in field type "single choice" (Custom Field) . Is there any workaround to import it or get by API to make it faster? (In picture below there is only 1 button add to list the data)
Hello @MQZ-M. Iqbal Rizaldi ,
You can use the REST API:
https://your-domain.atlassian.net/rest/api/3/field/{fieldId}/context/{contextId}/option
which can be consulted in this article:
This will force a different value created in the list field for each issue it creates in this import.
I believe it is an easier option, as via API it is complicated to put all the values in a single call.
In the end, 200 issues will be created in the test project and 200 different options in the list field.
Please tell me if this solution helped you!
If you need details regarding the process of creating options in a list field via Import CSV, you can answer me here.
Oh nice thank you so much, both solution seems good.
But how do I know "fieldID" and "contextID" if I want to try API way
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
In the Browser itself, in the Issues - Custom fields option in the global menu.
When accessing the field, your ID will be with you in the URL:
The same happens with Context:
If you want, you can also use a GET to redeem the IDs
https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issue-custom-field-options/#api-rest-api-3-field-fieldid-context-contextid-option
https://your-domain.atlassian.net/rest/api/3/field/{fieldId}/context/{contextId}/option
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.