I'm working on an API connection from Jira servicedesk, where I try to create a request via API, whenever I try to do the test in Postaman (testing and developing API's), it presents the error below:
"message": "Client must be authenticated to access this resource.", "status-code": 401
I'm passing as basic authentication the name of the token and the password created, the link I'm following for the api to know is this:
https://developer.atlassian.com/cloud/jira/service-desk/rest/api-group-request / # api-rest-servicedeskapi-request-post
could you help me?
Hi Eduardo, welcome to the Community!
For basic auth, you'll want to use the email address as the username and an API token in the password field. Details about how to use these with Atlassian Cloud are listed here. In short, you generate a new token from id.atlassian.com and use that in place of a password. The advantage to this is that you can have multiple tokens on your account (one per application) and they can be easily revoked!
So to recap, when using Postman, you'll want to select the Basic Auth type in the Authorization tab, and enter these for the parameters:
Hope that helps!
Cheers,
Daniel
Hi @Daniel Eads , I created a user tru this https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-users/#api-rest-api-3-user-post. If username and password is deprecated in favor of api tokens, whats the point of creating a user with password? Previously when our users login in a customer portal, we used their supplied username and pass to authenticate in Jira and get their profiles. But it no longer works in our new Jira cloud instance, I already tried authentication using encoded user email and api token, not working.My question is, how can I authenticate my user if this login no longer works ?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Daniel Eads I created a user by following this link https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-users/#api-rest-api-3-user-post. My question is, if username and password is deprecated in favor of email:apitoken, whats the point of creating user with password(random password is generated when not supplied by the user). Also, when creating new user, whats the correct api for them to login? Previously, we can fetch the user info by using the user supplied username and password when they loggin in our customer facing portal, but now it will not work.Kindly see my screenshot. I also tried encoding email and token and pass as Authorization header(Authorization: Basic longencode64base) but no luck.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.