[英]Microsoft Graph .NET Client Library get verification record
I use Microsoft Graph .NET Client Library ( https://github.com/microsoftgraph/msgraph-sdk-dotnet ). 我使用Microsoft Graph .NET客户端库( https://github.com/microsoftgraph/msgraph-sdk-dotnet )。
I want to call this API method: 我想调用此API方法:
https://docs.microsoft.com/en-us/graph/api/domain-list-verificationdnsrecords?view=graph-rest-1.0 https://docs.microsoft.com/en-us/graph/api/domain-list-verificationdnsrecords?view=graph-rest-1.0
GET https://graph.microsoft.com/v1.0/domains/{domain-name}/verificationDnsRecords
I try to do the following: 我尝试执行以下操作:
List<QueryOption> options = new List<QueryOption>
{
new QueryOption("domain-name", domain)
};
var r = await graphClient.Domains.Request(options).Select(p => p.VerificationDnsRecords).GetAsync();
But I get an error like "Unknown domain-name" parameter. 但是我收到类似“未知域名”参数的错误。 I tried
id
instead of domain-name
and get the same. 我尝试用
id
代替domain-name
并得到相同的结果。
What is wrong and how to do? 怎么了?怎么办?
Found solution how to set domain name. 找到解决方案如何设置域名。 It should be:
它应该是:
await graphClient.Domains[domain].VerificationDnsRecords.Request().GetAsync();
without any QueryOption
没有任何
QueryOption
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.