Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

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

Create Customer Request Using Java API

Hi,
I was trying to create a customer request using Java API using the code below 

serviceDeskCustomerRequestService.createCustomerRequest(applicationUser, serviceDeskCustomerRequestService.newCreateBuilder().raiseOnBehalfOf("username")           .serviceDesk(serviceDesk).requestType(requestType).fieldValue(FieldId.withId("summary"),     FieldInputValue.withValue("summary value")).fieldValue(FieldId.withId("description"),             FieldInputValue.withValue("description value")).customerRequestChannelSource("Customer Channel Value").build());

Using this code outside a thread is working fine the request is created SLA is started and everything is working as expected, but adding adding the same code inside a thread it throws this exception 

com.atlassian.servicedesk.api.BadRequestException: The issue type selected is invalid.  com.atlassian.servicedesk.api.BadRequestException: The issue type selected is invalid.    at com.atlassian.servicedesk.internal.api.util.EitherExceptionUtils.httpStatusCodeToException(EitherExceptionUtils.java:95)    at com.atlassian.servicedesk.internal.api.util.EitherExceptionUtils.lambda$anErrorEitherToException$0(EitherExceptionUtils.java:36)    at io.atlassian.fugue.Either$Left.fold(Either.java:586)    at com.atlassian.servicedesk.internal.api.util.EitherExceptionUtils.anErrorEitherToException(EitherExceptionUtils.java:32)    at com.atlassian.servicedesk.internal.feature.customer.request.ServiceDeskCustomerRequestServiceImpl.createCustomerRequest(ServiceDeskCustomerRequestServiceImpl.java:45)

Is there a way to create a customer request inside a thread without getting any exception.

Thanks in advance 

0 comments

Comment

Log in or Sign up to comment
TAGS

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