JIRA Rest API and Ampersand

Michael Rivera April 13, 2020

When using the REST API, with a POST to /rest/api/2/search and using an ampersand in the search criteria of the JQL, i.e. "component = \"Research & Architecture\" "

I get the following error.

"The value 'Research %26 Architecture' does not exist for the field 'component'."

Is there a way to use the REST api without the values being encoded?

1 answer

1 accepted

0 votes
Answer accepted
David_Bakkers
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.
May 19, 2020

Nope. You have to convert the ampersand to the unicode value %26 first.

Depending on the scripting language you're using, you can probably declare the ampersand in the string literally using something like \& or && or similar and it will be converted for you.

Change the name of the Component to "Research and Architecture" and the problem's solved :)

Suggest an answer

Log in or Sign up to answer