getting an error when doing oauth based authentication

Ravish Shetty
Kilo Sage

Hi all

 

getting below error of 'User Not Authorized' and 'Missing required API access scope: test' when doing OAuth based authentication. the bearer token used is correct because when i use an incorrect one, i get a different error.

 

RavishShetty_0-1776179527129.png

 

below is the oauth setting in servicenow

 

RavishShetty_0-1776179666144.png

 

 

Thanks

Ravish

 

2 REPLIES 2

Tanushree Maiti
Tera Patron

Hi @Ravish Shetty ,

 

Navigate to the Authentication Scope table and create the following scopes:

  1. table_read
  2. table_read_write

 

refer: Restrict access available to OAuth Client using REST API Auth Scopes

        Limit the access granted to an OAuth client by using REST API authentication scopes.

 

AndersBGS
Tera Patron

Hi @Ravish Shetty 

 

Have you remembered to set baerer in the header?

Have you ensured to provide correct user access?