Hello,
I'm trying to execute a post request to a service in 6.2 and I keep getting a 401 (unauthorized) error.
req = WebRequest.Create(service)
req.ContentType =
"application/json"
req.Method =
"POST"
req.ContentLength = jsonBytes.Length
stream = req.GetRequestStream
stream.Write(jsonBytes, 0, jsonBytes.Length)
stream.Close()
response = req.GetResponse().GetResponseStream
reader =
New
System.IO.StreamReader(response)
result = reader.ReadToEnd
reader.Close()
response.Close()
I think I must be missing sending some authentication information. But, I can't figure out what...
Can anybody help me out here?
Thanks,
Mike