Authentication Issue - Power Automate Trying to access ServiceNow

Nilanjan1
Mega Sage

Dear All,

I have been struggling with the issue.

We are trying to access a custom table through the Power Automate tool, however I am receiving a forbidden error or a SSL certificate error.  There is a functional ID created  & roles has been assigned to this functional ID (SOAP, rest_service, custom roles that are created for the custom table & enabled web_service setting as well). However the authentication issue is still there.

Also we have set up OAuth, but the issue is the same. 

However, we tested with another functional ID which is not a part of Active Directory the connection is getting successfully created from Power Automate to ServiceNow. 

I am not sure what more to check, can someone guide. 

If you need any more information please let me know. Below screenshot from Postman showing the authentication issue. 

find_real_file.png

Regards

Nilanjan

4 REPLIES 4

Frank Tate
Giga Guru
Giga Guru

The problem is that you can't use an Active Directory user as a service account with BA authentication for REST API calls. That's why it works for the non-AD ("local") user. 

So, you should focus on OAuth, since that can be used in this case. Here is a great article from @Ankur Bawiskar on this topic:

https://community.servicenow.com/community?id=community_blog&sys_id=56086e4fdb9014146064eeb5ca961957

If you still have problems using OAuth, you need to provide as many details as possible about how you've actually configured it in comparison with the above article.

Frank

Please mark this as Helpful/Correct.

Thank you Frank, the article is really helpful. I have checked the article and the configuration is exactly the same. I have created a local user and used a basic authentication it worked but when I am using the oAuth 2.0, with all the steps that is mentioned. it is giving me an 401 Error .

 

find_real_file.png

Try changing the method to POST instead of GET and try again.

 

Please mark helpful and correct if my answer helped you to resolve the issue

 

Regards,

Praveen

Nilanjan1
Mega Sage

Thank you so much, the basic authentication worked for me. however we are unable to check on the oAuth Issue, it seems that it is erroring out. However we are using an AD account. 

Is there any reason why ServiceNow does not use the AD account for normal and oAuth method of authentication. 

Regards

Nilanjan