Getting Http Status 0 when triggering REST Message to Get OAuth Access Token
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-05-2022 10:21 AM
Hi ,
I create a Rest Message in ServiceNow to call a 3rd party endpoint to request access token .
I have included the client id, client secret , grant type as client credentials , and audience in the Body and tested in Postman . I am able to get the response and getting access token.
But the same configuration when I do in service now using REST message , I am getitng Http Status as 0 and Error code as 1.
Error message as :Request not sent to uri=
Please suggest .
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-05-2022 02:13 PM
Hi, without any details of your configuration the forum can only guess at your issue.
Perhaps you can update this thread with clear and specific information?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-06-2022 03:54 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-05-2022 08:29 PM
Hi,
Share the configuration screenshots etc
If you are able to test via Postman then it should work fine in ServiceNow Rest Message as welll.
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-06-2022 01:40 AM
The same client id , client secret and other parameters I am usng in Postman and I am getting the token.
Please let me know what additional parameters I need to add in ServiceNow rest message.
Http Status : 401
Error message : Method failed: (/oauth/token) with code: 401 - Invalid username/password combo
Response : {"error":"access_denied","error_description":"Unauthorized"}
Rest Message Configuration :
====================
Iin POstman I am able to get the Token successfully when I am passing these parameters in the Body .
Please suggest.