Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Authentication error: 401 when trying a JIRA REST API call.

Dani Rubin April 29, 2021

Hi I am new to this community. I am looking to call the JIRA REST API. The problem is when I try make a connection it gives me an authentication error: 401. I am using basic authentication via Python (Requests module). There is no additional security, so I am suspecting a firewall between my laptop and the JIRA server.

 

I have the server IP address, but I need the port number so that I can run a NC command.

Problem is no knows the port number ?

Is there a way I find this out programmatically or otherwise ?

 

Dani

2 answers

0 votes
Prashant Mali
Contributor
April 29, 2021

Hi @Dani Rubin ,

Bydefault Jira tooks 8080 port without any kind of customization. Please check with this if it is workable for you or else you can get this information from Jira Admin by two ways :-

1) The base URL value listed in Jira's General Configuration page (https://confluence.atlassian.com/adminjiraserver/configuring-the-base-url-938847830.html)

2) The server.xml file tells Jira's application server which ports to listen on.

Regards,

Prashant

Dani Rubin April 30, 2021

Hi @Prashant Mali 

Thank you, I will investigate these 2 options.

0 votes
Gonchik Tsymzhitov
Community Champion
April 29, 2021

Hi! 

First of all, welcome @Dani Rubin 

In that situation, you can double check does your Jira, works with SSO. 

Do you have token for auth?

Did you try some package from pypi ?

https://pypi.org/project/atlassian-python-api/ 

 

Cheers,

Gonchik Tsymzhitov

Dani Rubin April 30, 2021

Hi Gonchick

Generally we use SSL / AD authentication and I haven't required certificates for REST API.

I will look at that python package.

 

Thank you

Dani Rubin April 30, 2021

or SSH

Suggest an answer

Log in or Sign up to answer