title: Restful, Proxy and webapi
body: <p>I'm developing a consumer app for a publically avalible rest webservice.
  <br/> I'm having 2 problems: My proxy and the service authentication.
  <br/> i cant seem to get past my proxy, actually i do have a valid credential to get by it, but i dont know where or how to provide it!
  <br/> And second, i also dont know how to responde the basic authentication challenge issued by the web-service...
  <br/>I do can use it via browser, but i cant get it working on my c# app. Heres the code so far:<br/></p>
  
  <pre><code>HttpClient cli = new HttpClient();
  cli.BaseAddress = new Uri("http://myserver.com/");            
  HttpResponseMessage response = cli.GetAsync("api/service1").Result;
  
  textBox1.Text = response.Content.ReadAsStringAsync().Result;
  </code></pre>
  
  <p>the result in textBox1 so far is always a 407 error... Can anyone help?</p>
  
  <p>Edit1: Authentication on the webservice is of the type BASIC!<br/>
  Edit2: clientHandler.Credentials = new NetworkCredential("user", "P@ssw0rd"); does not work... server returns "This request requires HTTP authentication"</p>