HTTP 401 Unauthorized When Calling Marketplace API via Postman

sourav_9
Giga Contributor

Hi everyone,

I'm troubleshooting an issue where a user is receiving an HTTP 401 Unauthorized response when calling a ServiceNow Marketplace-related API through Postman using Bearer token authentication.

The Authorization header appears to be configured correctly, and the user is supplying a Bearer token, but the request is still being rejected with a 401 response.

What are the most common causes of this issue? In particular, I'm interested in understanding whether it is typically related to:

  • An expired or invalid access token

  • Incorrect OAuth configuration

  • Missing scopes or permissions

  • Incorrect endpoint or environment

  • Any other common authentication-related issues

Are there specific checks or logs that you would recommend reviewing first when investigating this type of error?

Thank you.

1 REPLY 1

Tanushree Maiti
Tera Patron

 

Hi  @sourav_9 

 

  • To successfully implement Bearer Token authentication for a web service in ServiceNow, you need send the token in the request header  as Authorization: Bearer <token>
  • Confirm your Bearer token has not expired. Generate a fresh token and retry the endpoint
  • Always use https:// instead http:// in your Postman collection URL

  • Assign the snc_platform_rest_api_access role to your integration user to permit inbound REST endpoint communication

  • For integration user profile, Set Web Service Access Only and Internal Integration User
  •  
Please Accept the solution if it assisted you with your question & Mark this response as Helpful.
Regards
Tanushree Maiti
ServiceNow Technical Architect
LinkedIn: https://www.linkedin.com/in/tanushreemaiti