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

Is there a way to add customers with their first and last name in bulk?

Benjamin Peikes Dec 20, 2017

We can't create tickets with our customers as request participants until they have created Service Desk accounts. We would like to create the accounts on their behalf, with first and last names. The way we do it now, requires us to add the customer via the "Customers" item in the Service Desk project, then to hover on the user, and click on "Administer User", then click on Edit.

When we bring on a new client, we'd like to "precreate" all of their customer accounts, with first and last names. Is there anyway to do this?

1 answer

0 votes
Rian Spivak Dec 20, 2017

This sounds like something that can be handled by the REST api for service desk. There are two ways to do this through REST. You can add a generic customer that isn't attached to a particular ServiceDesk Project or add a customer to a specific ServiceDesk Project.

The documentation for Server is:

https://docs.atlassian.com/jira-servicedesk/REST/3.6.2/#servicedeskapi/customer-createCustomer

And for Cloud is:

https://developer.atlassian.com/cloud/jira/service-desk/rest/#api-customer-post

Benjamin Peikes Dec 20, 2017

We were hoping there was a way of doing this through the UI, we're really not interested in developing for Jira. We have our own development tasks to work on.

Additionally, The API is a doesn't make sense. The createCustomer takes a single "displayName" and "email", while the add customer to a service desk endpoint takes a list of usernames.

A couple more questions:
1) What's a username? 
2) In the Service Desk UI, you can decide on whether or not they get an email when created/added. It's not clear via the API if a customer is emailed when created.

Rian Spivak Dec 20, 2017

Looks like to do this you need to create the "customer" in Service Desk as a whole which is the first REST API (servicedeskapi/customer) you looked at that requires the displayName and Email. It will return the username for the person during this creation. You can use this username or list of usernames for the second REST API (servicedeskapi/servicedesk/{serviceDeskId}/customer) so that these customer accounts will be associated with that particular service desk.

The username is the account username that is tied to the customer's account in JIRA service desk.

As far as emails go, the first operation (servicedeskapi/customer) doesn't email the customer during the account creation. However, the documentation doesn't mention whether the second operation (servicedeskapi/servicedesk/{serviceDeskId}/customer) emails in the same that the UI does when adding a customer to a service desk project. That would probably need to be tested to see what the behavior is.

Benjamin Peikes Jan 10, 2018

Thanks! I think we're going to pass on writing anything ourselves. That would mean having to host the page to perform the action on another server. 

Suggest an answer

Log in or Sign up to answer
This widget could not be displayed.
This widget could not be displayed.
Community showcase
Published in Jira Service Desk

4 changes to queues and issues you don’t want to miss

Hello Atlassian Community! I'm Tania, a Senior Product Marketing Manager for Jira Service Desk Cloud! I'm excited to announce some exciting improvements coming up for those who work with queues and...

862 views 9 14
Read article

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