title: How do you send a patch request from a c# client?
body: <p>I have a powershell script that does this :</p>
  
  <pre><code>    $uri = "$($tfsUri)/$($teamproject)/_apis/build/builds/$($buildID)?api-version=2.0"
      $data = @{keepForever = $keepForever} | ConvertTo-Json
      $response = $webclient.UploadString($uri,"PATCH", $data) 
  </code></pre>
  
  <p>I'm trying to rewrite this in C#, using a Webclient.</p>
  
  <pre><code>WebClient client = new WebClient();
  client.Encoding = System.Text.Encoding.UTF8;
  string reply = client.UploadString(url, "keepForever = true");
  Console.WriteLine(reply);
  </code></pre>
  
  <p>But I get : The remote server returned an error: (401) Unauthorized.</p>
  
  <p>This is TFS 2015 VNext, if that helps. </p>