我結束了在C#中使用這樣的:
WebRequest myRequest = WebRequest.Create("https://host.domain.com:8243/services/ProductsProxy.ProductsProxyHttpEndpoint/ProductID/123456");
// Set 'Preauthenticate' property to true. Credentials will be sent with the request.
myRequest.PreAuthenticate = true;
string UserName = "myuser";
string Password = "myPassword";
// Create a New 'NetworkCredential' object.
NetworkCredential networkCredential = new NetworkCredential(UserName, Password);
// Associate the 'NetworkCredential' object with the 'WebRequest' object.
myRequest.Credentials = networkCredential;
// Set a timeout value
myRequest.Timeout = 100;
//Trust all certificates since I'm just doing dev and don't have a cert yet.
System.Net.ServicePointManager.ServerCertificateValidationCallback = ((sender, certificate, chain, sslPolicyErrors) => true);