Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Deleted user
0 / 0 points
badges earned

Your Points Tracker
  • Global
  • Feed

Badge for your thoughts?

You're enrolled in our new beta rewards program. Join our group to get the inside scoop and share your feedback.

Join group
Give the gift of kudos
You have 0 kudos available to give
Who do you want to recognize?
Why do you want to recognize them?
Great job appreciating your peers!
Check back soon to give more kudos.

Past Kudos Given
No kudos given
You haven't given any kudos yet. Share the love above and you'll see it here.

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Setting the Requst Type of a newly created Issue via remote API Edited

I have been able to successfully create an issue using the REST api (rails gem) on my JIRA Service Desk instance (cloud).  I have also been successful in setting the reporter, but I have noticed that although the customer has been set, the issue does not show up on the customer's request list.  I readily figured out that the problem is that the request type was not being set.


The project that I am using has the issue type mapped to a specific request type.  Furthermore, the Request Type field has been added to the create issue screen.  In addition, I have manually set another issue to include the appropriate request type, and determined the request type field to be 'customfield_10047'.  


With all this said, I have been very unsuccessful in setting the Request Type during creation.  The first semi-sucessful attempt resulted in the following error:



    customfield_10047: Operation value must be a string



This occurred when I was passing more complex information about the request type (so as to mirror an existing issue).

After this, the closest I managed to getting a semi-valid response is when the server was when using a pure string.  In this case, the server responded with:



    customfield_10047: Invalid customer request value



I've tried setting the string value to the id of the request type "97", and I've also tried setting it to the exact string value of the Request Type, namely "Purchase Request", but no matter what I enter, I get an error.


Any ideas on how this value can be set appropriately?


3 answers

1 accepted

6 votes
Answer accepted
Dario B Atlassian Team Jul 02, 2019

Hi @Peter Androutsos ,

It  took a bit of research and testing but I am happy to say I managed to make this work in Jira Cloud as well. Also, I am adding this as a new answer so that if you like it you can accept it as the solution for this question.

The way to achieve what you are asking for is actually explained in below KB for Jira Server:


However, since in Cloud you do not have access to the Database, you cannot get the request type KEY from the  AO_54307E_VIEWPORTFORM table as explained in above KB, but you will have to use the following REST API endpoint instead:

  • https://YOUR_HOSTNAME/rest/servicedesk/SERVICE_DESK/servicedesk/request/ISSUE/request-types

Calling to the above endpoint (or pasting it in the browser) with a correct issue ID and the correct service desk ID for the associated issue will result in JIRA returning a JSON response containing all customer request types within the service desk, including the Key.


Please notice that this is an internal endpoint not officially documented that can change without prior notice. Indeed we have the below Feature request opened in our system to have the official REST API endpoint to include the request-type key to which I have just added the workaround:


You may want to vote and watch the above feature request so that you will get notified in case of any update. The  feature will be addressed according to the Implementation of New Features Policy.


Let me know if this helps.



This is helpful.  I will explore these options and endpoints.

Like Dario B likes this

Agreed - helpful.

Like Dario B likes this
Dario B Atlassian Team Aug 20, 2019

Thanks for letting me know @Linwood Ma ! :) 

Also, just FYI, I have summarized everything in the below KB article:



I didn't have any luck using the API to get the keys so instead, I exported my cloud instance and found the /backup/data[@tablename='AO_54307E_VIEWPORTFORM'] node in the activeobjects.xml file.

This node contains all the rows from the AO_54307E_VIEWPORTFORM table, where you should find the KEY column. The column should be the 7th entry in the row node and will be either a string like "getithelp" or a GUID.

Hello @Dario B ,
Thank you for this link:

There is one thing I would need to explain bit more:
"You'll just have to identify the custom field id and valid values and you should use for it to work."

Long story short, I am working on Integration from OpsGenie to Jira where I need to create tickets in Jira based on Alerts from OpsGenie. The problem is that "Customer request type" is set to "Service Request" and we need "Incident"

my custom field for this setting is "customfield_13040" but what I don't know is valid values. When I put there "fixit/alerts" it works but it's creating Service Requests, not Incidents as desired. I don't know where and how to look it up.
Can you please advice?

Jira version if needed: Jira v8.5.5

I was able to solve this problem. Please ignore

Like Dario B likes this
0 votes
Dario B Atlassian Team Jun 28, 2019

Hi @Peter Androutsos ,

In order to create a valid customer request in Jira Service Desk Cloud you may want to use the Jira Service Desk REST API endpoint /rest/servicedeskapi/request instead of the Jira Core Rest API endpoint /rest/api/2/issue (or /rest/api/3/issue).


For further details please see:

I hope this helps.


Have a nice weekend.



Thanks.  I've since added some automation in the project which provides a workaround to this, but I will investigate trying to do this the other way around regardless.  With that said, I am curious as to why the option to set the request type exists on the regular issue-generating api, but won't accept any value.  Are there specifics to what values can be set for this parameter?

Dario B Atlassian Team Jul 03, 2019

@Peter Androutsos ,

The actual problem is not that it does not accept any value, but that the value you are supposed to enter in there is not documented and not exposed by public APIs. For this I have added an howto/workaround yesterday.

However, can you kindly let us know the use case for which you need to call the Jira Core REST API endpoint to create the issue and you cannot use the Servicedesk ones, so that I can forward this feedback to the Jira Service Desk team?  



Hi @Dario B ,

I tried to follow your guide but i am still unable to get the Customer Request Type field's allowed value list.

I am working on Jira Cloud and i am trying to create a ticket using Google Scripting and trying to Populate the Customer Request Type field with an existing category 'Testing & Management' and my script returns "customfield_10800":"Invalid customer request value" error.


My project key is "Test" and i tried using the endpoint "rest/servicedesk/SERVICE_DESK/servicedesk/request/ISSUE/request-types" but it doesn't display anything on the screen.


Any help is highly appreciated.

@Dario B , i get a 404 when trying to access the below endpoint.

Service-Desk ID: 2

Issue-Id: 10201


Is there any other way to view the Key?

@harsh kanukuntla ,

The endpoint seem to have changed and now it is: 

  • https://YOUR_HOSTNAME/rest/servicedesk/1/servicedesk/request/ISSUE_ID/request-types


Also, the below KB has been updated in order to reflect the change:


However, please once again notice that you should be using the Jira Service Desk Cloud REST API /rest/servicedeskapi/request instead of the Jira Core Cloud REST API endpoint  /rest/api/2/issue:

Suggest an answer

Log in or Sign up to answer

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you