我收到错误代码401 Unauthorized
我已使用此代码格式:
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(EncodeSlugHeader(listurl));
request.Method = "GET";
request.Headers.Add("Authorization", "OAuth " + access_token);
request.Headers.Add("GData-Version", "2");
//both Headers.Add and Headers.Set still have Error
这是对的吗?因为我玩https://developers.google.com/oauthplayground/作为参考和它的工作,现在我现在正在将它实现到C#,我得到了回应401 Unauthorized。
request.Headers.Set("Authorization", "OAuth " + access_token);// ----> reference from https://developers.google.com/oauthplayground/