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

How to create a Service Desk Ticket using the Service Desk API?

I've been trying to create a ticket using the Service Desk API, but I can't get this done.

I'm currently using this with Python:


 I've been trying to use this URL, but have gotten no results:{}/requesttype

Pplease, a response would be appreciated, thanks in advance!

1 answer

1 accepted

5 votes
Answer accepted
Mikael Sandberg Community Leader Dec 02, 2021

Hi @gabriel_silfa,

Welcome to Atlassian Community!

You have to include the service desk ID and the request type ID as part of the body in your request, not in the header.  

This is what it looks like if you are using curl

curl --request POST \ 
'' \
'Authorization: Bearer <access_token>' \
'Accept: application/json' \
'Content-Type: application/json' \
"serviceDeskId": "10",
"requestTypeId": "25",
"requestFieldValues": {
"summary": "Request JSD help via REST",
"description": "I need a new *mouse* for my Mac"

Also note that using password as part or your authentication is being deprecated, instead you should create an API token.

Have a look at the REST API documentation for more information.

Hi, sorry for the long wait. Thanks for answering! We are going to change the way we connect to Jira, we didn't know it was going to be deprecated.

We are going to use the OAuth 2.0 Code Grant to authenticate with the Jira Service Desk API, but we are having issues with the authorization URL. We're trying to connect an external system with Jira Service API to create tickets and retrieve information from it.

What we don't understand is the state parameters, we're using this as a base URL: Changing the "your-domain" with ours of course, but we still can't connect, any ideas about what we are doing wrong?

Mikael Sandberg Community Leader Dec 06, 2021

It's hard to say what exactly is wrong without seeing the code or the response, but make sure that you are sending the right headers with your request. From the example I posted above you have to include your authentication in a header, and the data you want to add to your request in the data header. I would recommend that you check out the API documentation and it also has examples. I can also recommend that you check out the Developer Community as well.

Like # people like this

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Jira Service Management

JSM Jira Automation: How to Send SLA Breached Notifications

Hi Everyone, In   this tutorial,  we will show you how you can monitor an SLA, and send notifications before or after the SLA has been breached.   SLA Threshold Trigger The SLA t...

769 views 5 13
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