jira-node / node-jira-client

A Node.js wrapper for the Jira REST API
https://jira-node.github.io/
MIT License
449 stars 170 forks source link

Auth error when using admin user #314

Open dnuzzolillo opened 3 years ago

dnuzzolillo commented 3 years ago

For some reason, when i try to use the admin account of my Jira server, it throws: 401 Basic Authentication Failure - Reason : AUTHENTICATED_FAILED

i'm preetty sure i'm using the right credentials cuz i can login on the web client with any problem.

`const jira = new JiraClient({

protocol: 'http',
host: 'jira.my-company.es',
port: '8080',
username: 'admin',
password: '12345',
apiVersion: '2',

}); (async () => { console.log(await jira.searchJira('status = "In Progress"')) })() `

is there any parameter that i'm missing?

NamioL commented 2 years ago

Question is old but maybe for somebody it will be useful

Basic authentication with passwords is deprecated.

You need to use the token instead of the password.

for more information https://developer.atlassian.com/cloud/confluence/deprecation-notice-basic-auth/