Some of JIRA API are not working like Create User, adding a user to group etc

Mudit Nagpal
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
December 7, 2020

Hi Team, I was trying with JIRA API request through my linux Server i.e Ubuntu hosted on cloud.

Over this  some API's are not working like providing response as shown on JIRA Developer page.

1st

https://developer.atlassian.com/cloud/jira/platform/rest/v2/api-group-users/#api-rest-api-2-user-groups-get

I am getting 404 with 

{"message":"null for uri: https://test.xyz.com/rest/api/2/user/groups?username=800","status-code":404}

I'm passing username instead of accountID

2nd

https://developer.atlassian.com/cloud/jira/platform/rest/v2/api-group-users/#api-rest-api-2-user-post

below is the way i want to use

one of example is :- 

#cat create.sh
read -p "Enter User's Full Name : " fullname
read -p "Enter User's Email : " email
read -p "Enter User's username : " uname
curl --request POST \
--url "https://test.xyz.com/rest/api/2/user" \
--user "Username:Password" \
--header "Accept: application/json" \
--header "Content-Type: application/json" \
--data '{
"password": "User@12345",
"emailAddress": "'$email'",
"displayName": "'$fullname'",
"name": "'$name'"
}'

error:-

{"errorMessages":["Unexpected end-of-input in VALUE_STRING\n at [Source: org.apache.catalina.connector.CoyoteInputStream@da65b24; line: 4, column: 113]"]}curl: (3) [globbing] unmatched close brace/bracket in column 21

nOte :- this username password is password not an API token.

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events