RJ98 Posted March 24, 2022 Share Posted March 24, 2022 Hi there, I've been having an issue when I try to log in to sage via my app. I keep getting a server 500 error and I keep getting this error in the URL: error=temporarily_unavailable&error_description=The+backend+service+is+temporarily+not+available.+Please+try+again+later. Is this an issue on my side, or on the backend of sage? Thank you Link to comment Share on other sites More sharing options...
Steel, Mark Posted March 24, 2022 Share Posted March 24, 2022 Hi, thanks for your question. Have you been able to authenticate in the past? Is this a sporadic issue? Are you able to sign into the business via the ui app.sageone.com? Thanks Mark Link to comment Share on other sites More sharing options...
RJ98 Posted March 24, 2022 Author Share Posted March 24, 2022 @Steel, Mark Yes I have been able to authenticate via my app in the past, and I'm also able to login via the UI on sage one. Is this error referencing the backend on my app most likely? Link to comment Share on other sites More sharing options...
RJ98 Posted March 24, 2022 Author Share Posted March 24, 2022 @Steel, Mark Also when it asks me to give permission on my account, it doesn't come up with the name of my app on the permission screen, where its meant to be before the "is" at the start of the page Link to comment Share on other sites More sharing options...
Steel, Mark Posted March 25, 2022 Share Posted March 25, 2022 The 500 error is a generic response from our server. It implies that it is unable to route the request correctly. Regarding your app name not appearing when authorising the app - What name do you have set against the app in developer self service? To clarify the 500 error occurs after you've authorised the app, is that correct? If not could you provide us with the uri, header and body params please. Thanks Mark Link to comment Share on other sites More sharing options...
RJ98 Posted March 26, 2022 Author Share Posted March 26, 2022 @Steel, Mark Hi Mark, yes the 500 error appears after the user has authorised the app. I have double checked, and I have set the app name in the settings. I pass a state parameter too when the log in page for sage loads, could this be affecting this and does this get passed back through to the redirect uri. My app login for sage has been working for a while, have any major updates happened to the API in the last few months that could affect my code which could be creating the server 500 error, with the backend error? Thanks Link to comment Share on other sites More sharing options...
RJ98 Posted March 26, 2022 Author Share Posted March 26, 2022 @Steel, Mark I have the full URL here that causes the error. It is the redirect uri to my app. This is it: https://myapp.co.uk/account/platforms/platformredirect/?error=temporarily_unavailable&error_description=The+backend+service+is+temporarily+not+available.+Please+try+again+later.&state={'platform'%3A+'sage'} I think normally the access code is where the error parameter is. Why would sage be generating this as a parameter? Thanks Link to comment Share on other sites More sharing options...
RJ98 Posted March 26, 2022 Author Share Posted March 26, 2022 Here is the URL I use to load the Sage Log in UI. I have removed the client_id from the URL for security purposes. Is this the correct format: https://www.sageone.com/oauth2/auth/central?filter=apiv3.1&response_type=code?client_id=someclientid123&redirect_uri=https://www.myapp.co.uk/account/platforms/platformredirect/&response_type=code&scope=full_access&prompt=login&state={'platform': 'sage'} Thanks Link to comment Share on other sites More sharing options...
Steel, Mark Posted March 28, 2022 Share Posted March 28, 2022 Hi @RJ98 There's nothing changed with API v3.1 or the auth flow required. Looking at your params there seems to be some duplication with the response_code parameter which shouldn't cause an issue but would be worthwhile cleaning up. What we need to ascertain is if the issue is with your server together with the auth flow and parameters passed in your app. Would it be possible for you to use POSTMAN together with your registered client_id and secret to test the auth flow? We have an environment variable available from https://developer.sage.com/accounting/quick-start/preparing-to-create-test-data/ which will allow you to test this quickly. Please drop me a DM if you'd like to arrange a call to trouble shoot further. Thanks Mark Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now