Hi,
I have a free and Open source Marketplace app developed and is working fine since an year. But recently it stopped working and after debugging I identified that the issue is with oAuth authentication itself:
Technical Details about the app:
- App is a React based app and is built using CRA.
- The APP is available as Web, Browser Extension and Jira Cloud Forge app as well.
- The app is using @forge/bridge library and following code for calling Jira API.import { requestJira } from ‘@forge/bridge’;await requestJira(‘/rest/api/2/myself’, { method:‘GET’ });
- The above API is just a sample. However it is failing for any API calls.
- I had came across the following article and I am currently not participating in this Preview feature. However I tried setting features.autoUserConsent to true to see if that solves the issue and it doesn’t: https://developer.atlassian.com/platform/forge/simplified-user-consent/
- I have attached some screenshots of API response and console error log handled by my application. I also tried to debug the flow inside requestJira method and attached screenshot of that screen as well.
Expected Behavior:
- If a new user visits the app for the first time, when the first API call happens, the user would be prompted with the Consent screen to accept OAuth authentication.
- Once the user accepts it, the application works fine.
Current behavior:
- It continues to work for existing users who has already authenticated.
- If a new user visits the app for the first time, the consent screen is not showing up and call to requestJira() is also not failing in most of the cases. So the app keeps waiting for the promise to resolve from the requestJira() function call and the app is stuck in the loading screen for ever.
How to reproduce
- If you are using any forge based Jira Cloud app, just deauthorize yourself and try using the app. I believe it should break if my assumption is correct.
And this behavior is not just impacting this application or single instance of Jira. The company where I work for has a separate app built for internal use case and I tried to deauthorize myself from that app and now that is also not working. So I assume this issue is a global issue which started happening recently. But as I don’t see any questions related to this in community, was not very sure if I’m missing something.
The Web App and Browser extension version of same app which supports 3 different types of authentication which includes oAuth as well is working fine without any issues. Its just with this Forge App I am facing this issue.
Any insights are greatly appreciated. Thanks in advance.
Here are the mentioned screenshots:
I couldn’t add other images due to limitation in the count of media items I can add.
Regards,
Shridhar
https://jiraassistant.com/