我正在尝试通过C#调用API,但是我收到的错误是我的字符串不是URI。
string url = "@http://api@myAddress.com:API_KEY@myAddress.com/api.php?_d=products&ajax_custom=1";
WebRequest webRequest = WebRequest.Create(url);
WebResponse webResp = webRequest.GetResponse();
return webResp.ToString();
我把请求放在地址栏中时效果很好......
答案 0 :(得分:2)
将@移出字符串文字:
ref.label