This topic was automatically generated from Slack. You can find the original thread here.
I’m trying to connect a ServiceNow instance according to the instructions in the docs, and I get to the point where I approve the authorization, but then eventually get a 504 error, that lands on a Pipedream URL. Is there a potential issue here? I’ve confirmed the settings within ServiceNow and I’m sure they’re correct, but I don’t know if this timeout is saying that Pipedream didn’t respond to ServiceNow, or that my ServiceNow instance didn’t respond to Pipedream.
So, very weirdly - when I went back in just now to add a new connected account to get the full URL, there was an active ServiceNow connection, and I just ran a test and it seemed to work….so! That’s a bit of a mystery. Looking at my browser history though, this was the URL:
So if that helps troubleshoot at all, great - otherwise I’ll keep going. I am currently setting up a connection to our dev instance, and OAuth registries get reset when moving between instances, so I’ll have to do this again when we go to test and prod anyway…so if there’s anything to learn, let me know!
It may have been an intermittent issue with just the OAuth handler on our end, based on that URL. I’ll forward this along and hopefully we have an error trace we can diganose from
Hey there! I don’t know if it makes sense to start a new thread or continue this one - but, as I mentioned above I had to do all the setup again now that I’m moving this to our production environment, I’m getting the same 504 error! This is the URL:
Hi Kevin, I’ve let our apps team know about this. Hopefully we’ll find a resolution. But in the meantime, have you checked ServiceNow’s status page? Perhaps they have a partial outage?
Do the logs happen to shed any light on what exactly was being attempted when the 504 error was returned? The logs in SNOW seem to indicate that the connection was successful, which is obviously wrong…but I’m wondering if I’m looking for the wrong logs, since the initial landing page on the instance where you authorize the app loads fine, the 504 is returned only after clicking Allow
Did you make any changes in the initial fields you provided when attempting to connect your account? The errors are now getting logged on our end, but we’re getting a 401 from ServiceNow during the OAuth flow, when attempting to request an access token:
I’ve reset the client secret several times - the way SNOW works, when you move the OAuth configurations between instances, they have to be reset anyway; the best guess I have is that there’s a missing role on the service account we’re using to login - is full admin required? I’ve tried applying some out-of-the-box REST and API related roles in SNOW (that we use with other connections) but we obviously try to not to give full admin to most accounts in production!
401 would indicate a credentials issue as Danny mentioned; can you try to connect and let us know if you are still running into issues Kevin? We can take a look at the logs to see what we see on our end. The 504 error to me does not sound like a role-related issue.
If it helps any - I’m sure the issue is with our instance of SNOW, because I spun up a fresh developer instance, and the connection worked. However, I got someone who is a full platform admin on our production instance of SNOW to try to do the authentication, and it still failed, even after resetting the client secret multiple times. So, I’m sure there’s an error on our end somewhere but I’m not sure exactly what it could be or where to look!
Hi Kevin, given that you’re able to test end-to-end with the fresh dev instance, I suspect as you mentioned that it has something to do with your particular instance. I tried testing again in dev and am unable to reproduce the error you’re seeing.
I did a little bit of Googling and found this thread that may be helpful - specifically, the “Things to Check”. There’s another thread here that links to a way to add additional logging. I’m wondering if it has anything to do with the version of the ServiceNow instance as well - when you have spun up a dev instance, is that the same version as the production one? Have you tested this in Postman, and do you also get the same 401 unauthorized error?
Given that this error appears to be on the SNOW side of things as well, it may be helpful to post to their Developer forum as it seems to be quite active as well.