I added Jira OAuth to my webapp following docs at https://developer.atlassian.com/server/jira/platform/oauth/ . I used sample code they provided in that article. Here is how it is working now:
1. Use will click `Login with Jira` button on webapp.
2. Backend will generate a token and open a new tab with URL something like `https://jira.company.com/plugins/servlet/oauth/authorize?oauth_token=ec3dj4byySM5ek3XW7gl7f4oc99obAlo`.
3. Above link will take user to Jira for authorization. When user click `Approve`. He will be given a verification code like 'qTJkPi'. He will submit this back to webapp.
4. Backend will exchange token (step-2) and verification code (step-3) with jira for a `Access Token`.
Here user has to copy the verification code manually and submit to webapp. Can we make Jira automatically redirect user to Webapp after authentication along with verification code?
HI I have answer to this as I have faced same problem and managed to solve this issue.
In you backend implementation, like in my case for java ,
You need to set callbackurl to your url instead of "oob" as mentioned in jira server document.
This will redirect to your url after authorisation along with verification code in URL.
OAuthGetTemporaryToken class has field "callback" which you need to set as custom url.
Hello Lokesh cherukuri, I was trying to develop the same type of web application by using Flask, and somehow I was managed to get an authorized token, But as you mentioned here I am also stuck in the stage of redirecting to my App after authenticated by JIRA, You asked this question ages ago, and I hope that you could found an answer, if Yes, would it be possible to share your answer with me and I would really appreciate if you can provide me a solid answer. Thanks
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.