With our Jira server instance we used to run a self written console application that uses the REST API over basic authentication to pull data out of Jira.
After migration to Jira cloud this doesn't work anymore because basic authentication is not longer supported.
After a few hours of research I found two other ways to authenticate. OAuth and Connected Apps. Both seem to need Callback Endpoints which a simple console application is not able to provide. And the OAuth examples seem all to show the use case of a third party web site that uses redirection to interactivly authorize a user.
Is there any other simple way, to authorize a console app to use the jira REST API without user interaction without the need to build an interactive website that a user must use to login or to build an web api with endpoints needed for a connected app?
The OAuth way is ok, but the process of getting the access token base on userid and passwort should be done by the console app. Not by an interactive website with redirect and callback url.
So basically, how can I get an access token for the REST API from a console app non interactively?
@Holger Thiemann Basic auth is still supported on jira cloud. However you can't use email + password, you must use email + API key. See https://developer.atlassian.com/cloud/jira/platform/basic-auth-for-rest-apis/
I would recommend to create a separate Jira user, and use their API key for a script. Don't use the API key of a Jira Admin, because the API key inherits all permissions of the user.
Hi, Jira users! Do you use Jira alongside Microsoft Teams? We want to hear how you’ve used the power of Jira Cloud and Microsoft Teams (via the Jira Cloud for Microsoft Teams app) to achieve a team...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events