GLPI Oauth authentication to serviceNow
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hi Eveyone,
Has anyone implemented OAuth authentication between GLPI and ServiceNow?
Here is my configuration:
I created :
- A mid Server
- A rest Message
HTTP Methods:
One method called "test" to initialize the session in GLPI using initSession.
When I test this method, I receive a session_token, so it works correctly.
However, when I try to Get OAuth Token, I reach the authorization page.
When I click "Accept", I get the following error:
HTTP Error 401 - Unauthorized
--
I also created an application Registry for the Get OAuth Token in the form with the necessary data/url for GLPI connection.
The grand type is "Authorization Code" for the registry and for OAuth Entity Profile.
After some analysis, it seems that when I click Get OAuth Token, the function does not work through the MID Server.
However, I’m not sure if this is the actual problem. If it is, I don’t know how to involve the MID Server when clicking Get OAuth Token.
Thank You for your Help
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hello @Tanushree Maiti
Yes, It was typo mistake for token URL.
I put my instance IP address in the Authorized redirect URLs in GLPI but still doesn't work.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
If you are using Postman as an example, do you recieve the Auth token through the same network the mid server resides on or is it accessible from the internet? You need to allow a property to make oauth through a mid, otherwise it will always fetch the token through the internet.
https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB1645211
Also what you can try:
open the outbound http message logs and look for the actual authentication response message. For this one if the http log message is basic you need to modify 2 properties, the http log level override property (false to true) and the level itself to all , so you will see the actual message.
Regards,
**Martin Virag**
ServiceNow MVP 2026
