我已经在 C# 中验证并授权了 UCWA API。应用程序 ID 也是使用生成的令牌生成的。当我尝试使用以下代码创建 lync 会议时,我收到错误“内部服务器错误”。错误:-
{"code":"ServiceFailure","message":"Your request couldn't be completed.","debugInfo":{"errorReportId":"e2c35f5e0b274c4185d08837dd7e16a3"}}
我的代码是:-
onlinemeetingURL = "https://lynctswebint.Mycompany.com/ucwa/oauth/v1/applications/101030060103/onlineMeetings/myOnlineMeetings";
request = new RestRequest(onlinemeetingURL, Method.POST);
request.AddHeader("Accept", "application/json");
request.AddHeader("Host", "lynctswebint.Mycompany.com");
request.AddHeader("expirationTime","1482572914000");
request.AddHeader("Authorization", String.Format("{0} {1}", applicationTokenType, applicationToken));
var applicationBody = @"""lobbyBypassForPhoneUsers"" : ""Disabled"",""phoneUserAdmission"" : ""Disabled"",""description"":""{0}"",""subject"":""{1}"",""attendees"":""{2}"",""leaders"":""{3}""";
request.RequestFormat = DataFormat.Xml;
request.AddParameter(
"application/json",
"{" + string.Format(applicationBody, "This is a test for UCWA meeting creation", "Test UCWA meeting creation", "sip:testonline.lync@Mycompany.com", "sip:lync.test@Mycompany.com") + "}",
ParameterType.RequestBody);
ucwaClient.ExecuteAsync(request, this.functionToCall);
没有关于此错误的更多详细信息。我为此使用了restSharp库。