I am totally new to world of APIs, and trying to create an Issue/Ticket in Jira Service Desk using Jira API, but not able to achieve it even after multiple tries.
If someone has command/code how to create Issue/ticket in Jira Service Desk using bash shell/powershell/python, it will be of great help.
C:\Windows\system32>curl -D- -u user:password -X POST --data { "serviceDeskId": "10205", "requestTypeId": "10000", "requestFieldValues": { "summary": "Request JSD help via REST", "description": "Desc Request JSD help via REST" } -H "Content-Type: application/json" https://jjiraservicedeskurl/rest/api/2/issue/
curl: (6) Could not resolve host: serviceDeskId
curl: (6) Could not resolve host: 10205,
curl: (6) Could not resolve host: requestTypeId
curl: (6) Could not resolve host: 10000,
curl: (6) Could not resolve host: requestFieldValues
curl: (3) [globbing] unmatched brace in column 1
curl: (6) Could not resolve host: summary
curl: (6) Could not resolve host: Request JSD help via REST,
curl: (6) Could not resolve host: description
curl: (6) Could not resolve host: Desc Request JSD help via REST
curl: (3) [globbing] unmatched close brace/bracket in column 1
HTTP/1.1 400
X-AREQUESTID: 1037x7716x1
X-XSS-Protection: 1; mode=block
X-Content-Type-Options: nosniff
X-Frame-Options: SAMEORIGIN
Content-Security-Policy: frame-ancestors 'self'
X-ASEN: SEN-L15877282
Set-Cookie: JSESSIONID=9B5B3DA5D899E1897DC909CC57D94F78; Path=/; Secure; HttpOnly
X-Seraph-LoginReason: OK
Set-Cookie: atlassian.xsrf.token=BK2L-I3HA-D24Q-1X7S_ba3e1671ccd8a2bafa38871b994d5387159243b6_lin; Path=/; Secure
X-ASESSIONID: 16z1cmb
X-AUSERNAME: mill_adv_user_test
Cache-Control: no-cache, no-store, no-transform
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Mon, 07 Sep 2020 17:17:14 GMT
Connection: close
{"errorMessages":["Unexpected end-of-input: expected close marker for OBJECT (from [Source: org.apache.catalina.connector.CoyoteInputStream@17a62b93; line: 1, column: 0])\n at [Source: org.apache.catalina.connector.CoyoteInputStream@17a62b93; line: 1, column: 3]"]}
C:\Windows\system32>
Have you checked old answers to this topic?
https://community.atlassian.com/t5/Jira-questions/Create-Jira-issue-via-rest-api-python/qaq-p/455623
At the American Academy of Family Physicians, siloed marketing teams faced delays and duplicate work. Kerrie Gottschalk shook things up by moving the department to Jira, streamlining processes, boosting visibility, and sparking stronger collaboration.
Read the story
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.