Code: Select all
{"success":false,"error":104,"message":"Authorization header value doesn't match"}
Code: Select all
string url = String.Format("http://{0}/api/{1}", urlBase, method);
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(url);
request.Method = "POST";
request.Host = urlBase;
request.Headers.Add("X-Authorization", "Docebo " + code);
request.ContentType = "text/json";
StreamWriter requestStream = new StreamWriter(request.GetRequestStream());
requestStream.Write(json);
requestStream.Close();
With:
urlBase = gmigliarino.docebosaas.com
method = user/checkUsername
json = {"userid": "user.test"}
Thanks in advance!