Hi all,
I want to update a custom field via curl API REST. It is a text field multiline type.
I can update the custom field (13630) but it always displays the last value.
curl -k -D- -u "user:pass" -X PUT --data '{"fields":{"customfield_13630": "'"\nMessage:: This is a test"'"}}' -H "Content-Type: application/json" https://jira.com/rest/api/2/issue/BUG-0000
Any way to do that appending the new values and not removing the old ones?
Thanks in advance!
Regards
Hey Alberto,
Unfortunately this is not possible, you need to know the previous value to append the new value to it.
It always updates the existing value by design.
No luck!!
Thanks
Chander Inguva
This is marked as solved but has no answer
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Alberto,
As mentioned by @Chander Inguva, not by default. I would advise you to retrieve te current value in a first curl and append your new value in a second step!
Good luck!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ok @Chander Inguva, @miikhy, thanks for the quick response.
So bearing in mind your answer I have to curl a get action and save the output before append the new value.
From that point, do you know any easy way to receive the text plain from the text field? Or do I have to do it formatting the json output?
Best Regards!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.