The HTTP request is unauthorized with client authentication scheme 'Anonymous'. The authentication header received from the server was 'BASIC realm="Service-now"'.

sunitajodha
Kilo Explorer

I have tried to access SOAP service using c# code. I have selected basic authentication type but still it is taking Anonymous   and giving the following error:

"The HTTP request is unauthorized with client authentication scheme 'Anonymous'. The authentication header received from the server was 'BASIC realm="Service-now"'."

5 REPLIES 5

paramveer
Mega Guru

what user name/password you have used for authentication ? For service now web service, there should be a active user in sys_user table with having SOAP role only can access the web service.



Thanks,


Param


I have passed the user name and password like this:



servicenow.ClientCredentials.UserName.UserName = "username";


servicenow.ClientCredentials.UserName.Password = "*******";



I have checked Using SOAP UI tool then I am able to see results. Also I am able to login to instance through browser.


Is there any other way to check that user is active and can access web service.



I believe user must have entry in the mention table.


paramveer
Mega Guru

If it's working by SOAP UI tool, then web service is fine from servicenow side. You need to check with c# experts what could be the problem during a SOAP call.


Thanks,


Param


testhachem
Kilo Explorer

Hello

i can the same problem ,need your help please!!

thanks,

Hachem