Hi,
I am trying to hit the service desk API Create Customer API(https://[domainname].atlassian.net/rest/servicedeskapi/request) through POSTMAN, getting 400(bad request) response.
Request Parameters are as such-
URL - https://[domainname].atlassian.net/rest/servicedeskapi/request
Method - POST
Authorization
Basic Auth(username, Password[API Token])
ContentType : Application/json
Request Body:
{
“serviceDeskId”: “1”,
“requestTypeId”: “10009”,
“requestFieldValues”: {
“summary”: “Request JSD help via REST”,
“description”: “sdfasdfdsfsadfdfasdf”
}
}
Response :
Status: 400 Bad Request
{
“errorMessage”: “Your request could not be created. Please check the fields have been correctly filled in. Please provide a value for required field ‘Change type’”,
“i18nErrorMessage”: {
“i18nKey”: “sd.validation.request.creation.failure.required.field”,
“parameters”: [
“Please provide a value for required field ‘Change type’”
]
}
}
Please provide your view on this, may be somewhere I’m doing mistake.
API reference - https://developer.atlassian.com/cloud/jira/service-desk/rest/#api-rest-servicedeskapi-request-post
Other method like GET is working fine, I’m able to fetch all the details.
HI @Rahul_Ray
It seems that you have a field called "Change Type" that is required and you don't fill it in your code.
Hi Mohamed_Benziane,
Thanks for the response.
I tried to add the Change Type in request body but it is not working.
And also referred the API document, not getting anything like Change Type request parameter.
https://developer.atlassian.com/cloud/jira/service-desk/rest/#api-rest-servicedeskapi-request-post
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Can you create a issue using the UI. It pretty sure that you have a change type field in your create screen.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You need to put this field in your body. I think you need to put it after the description field.
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.