cancel
Showing results for 
Search instead for 
Did you mean: 

API Auth using Utility-HTTP

KSikha
Level 2
Hi,

I am try to do a API authentication using HTTP- Request. There i am giving bellow information.
URL-The api url
Body-It contains username, password token
proxy url
content type as application/json
method=post

But i am getting response as Access Denied. Your credentials could not be authenticated. Credentials are missing. You will not be permitted access until your credentials can be verified.
But the credentials being passed is correct. Could you please me here.

------------------------------
Kumari Shikha
------------------------------
8 REPLIES 8

harish.m
Level 12
Hi Shakia,

I encountered similar issue if  I recall it is some decision stage present in http utility vbo. I dont recall that stage name but  you need to update the stage name in order to use this utility vbo

------------------------------
Harish Mogulluri
developer
Ics
America/New_York
------------------------------
----------------------- If I answered your query. Please mark it as the "Best Answer" [FirstName] [LastName] [Designation] [JobTitle] [City] [State] [Phone]

Hi Harish,

Thank you for response.

The HTTP request action i am using inside utility-HTTP just has an  code stage. So not able to find any decision stage. 

Thanks

------------------------------
K Sikha
------------------------------

bruce.liu
Staff
Staff
Hi Kumari,

You did not specify which type of authentication you are dealing with. This is needed to determine how you would need to construct your HTTP request.

For example, if you are facing a simple basic HTTP authentication, you should be able to use the HTTP Request action straightaway by plugging in username and password, along with other resource related information. However the same cannot be said for more complex authentication methods like oAuth2.0, which involves a separate call to the authentication service to acquire a token and then use the token obtained for any subsequent web service calls. 

If you are able to specify clearly on exactly what you are working with, more specific advices can then be given.

------------------------------
Bruce Liu
Senior Product Consultant, Professional Services
Blue Prism
Australia/Sydney
------------------------------

Hi Bruce, 
Thank you for your response. 

I am dealing with basic authentication as it has username and password. But i am getting the error as mentioned. 

I am trying to connect to (https://company name.service-now.com/api/.....) Giving url, username, password, content type and method as post. 

Can you please suggest what all data should be given and how.

------------------------------
K Sikha
------------------------------

Hi Kumari,

Based on the info you have listed, I would envisage the VBO can be used in the following way. 

19757.png
Not sure if your proxy requires username and password. If not, just leave them as blank. I would also assume the username and password you had in the first post was what is needed for basic authentication, but not for proxy. 

Also I am using the latest version of the HTTP VBO from the DX, if it appears different than yours.

If you are still not getting results, I would suggest you use a tool like PostMan first. This would help with any things you may have missed in understanding the web service. If you have managed to have that configured, it should be easy to map it to Blue Prism.

Lastly it was not clear to me where the error message came from, if it was the proxy or it was the API authentication process itself. Take a note of the 3-digit HTTP status code returned, that would help pinpoint the exact area you need to investigate.

------------------------------
Bruce Liu
Senior Product Consultant, Professional Services
Blue Prism
Australia/Sydney
------------------------------

Hi Bruce, 

Yes, i have configured in similar way. In response i am getting access denied . Also, as you are asked, i am not getting any http error code in error. It's just the html tag i qm getting in response which has title as access denied.

------------------------------
K Sikha
------------------------------

Hi Kumari,

That is odd. It is worthwhile checking if your proxy requires credentials to be used. I have a feeling you were stopped before even made contact to the endpoint. 


------------------------------
Bruce Liu
Senior Product Consultant, Professional Services
Blue Prism
Australia/Sydney
------------------------------

AntonHosang1
Level 4
Confirm through other tools that everything runs smoothly, and if not, then you can start to identify how to fix the problem

Use Postman tool or even google chrome instead to see what happens when you visit the API
Observe if the site has certificate issues etc(Chrome asks you if you definitely want to continue to 'dangerous site' - HTTPVBO won't work without a tweaking to the VBO).


------------------------------
Anton Hosang
RPA Developer
Smart Automation Services
Europe/London
------------------------------