gpt4 book ai didi

c# - RestRequest 类在哪里?

转载 作者:可可西里 更新时间:2023-11-01 07:45:56 25 4
gpt4 key购买 nike

the getting started of maingun API 的 C# 选项卡中,我找到了以下代码。

public static RestResponse SendSimpleMessage() {
RestClient client = new RestClient();
client.BaseUrl = "https://api.mailgun.net/v2";
client.Authenticator =
new HttpBasicAuthenticator("api",
"key-3ax6xnjp29jd6fds4gc373sgvjxteol0");
RestRequest request = new RestRequest();
request.AddParameter("domain",
"samples.mailgun.org", ParameterType.UrlSegment);
request.Resource = "{domain}/messages";
request.AddParameter("from", "Excited User <me@samples.mailgun.org>");
request.AddParameter("to", "sergeyo@profista.com");
request.AddParameter("to", "serobnic@mail.ru");
request.AddParameter("subject", "Hello");
request.AddParameter("text", "Testing some Mailgun awesomness!");
request.Method = Method.POST;
return client.Execute(request);
}

当我用谷歌搜索类的名称时,我在不同的上下文中找到了对此类的多个引用。但是,我似乎无法在 mailgun 网站、谷歌或 MSDN 上的任何地方找到 RestRequest 类的完全限定名称来查找它的文档。

谁能指出这个类是在哪里定义的?

最佳答案

代码看起来像是使用了RestSharp .

关于c# - RestRequest 类在哪里?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14507601/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com