Microsoft Teams 订阅电话
Microsoft Teams subscription call
所以我想在通话时收到通知 callRecord (/communications/callRecords)
所以我抓起自己的 this 示例并将任务函数更改为:
public async Task<ActionResult<string>> Get()
{
var graphServiceClient = GetGraphClient();
var sub = new Microsoft.Graph.Subscription();
sub.ChangeType = "created";
sub.NotificationUrl = config.Ngrok + "/api/notifications";
sub.Resource = "/communications/callRecords";
sub.ExpirationDateTime = DateTime.UtcNow.AddMinutes(5);
var newSubscription = await graphServiceClient
.Subscriptions
.Request()
.AddAsync(sub);
Subscriptions[newSubscription.Id] = newSubscription;
if (subscriptionTimer == null)
{
subscriptionTimer = new Timer(CheckSubscriptions, null, 5000, 15000);
}
return $"Subscribed. Id: {newSubscription.Id}, Expiration: {newSubscription.ExpirationDateTime}";
}
我还在我的应用程序中添加了图表 api 权限 CallRecords.Read.All
。事先我用更新的用户通知测试了这个例子,它运行良好。但是现在不会触发来电通知了。
同样如此,昨天一切正常,但今天我的 webhook 端点甚至没有触发一次。
我认为微软方面可能存在问题。我关注与我们有同样问题的人的这个问题here。
更新:Microsoft 的某人在链接的 Github 问题中回答:
There is currently an ongoing issue.
The related post is TM220340 in the M365 Admin Center.
所以他们确认问题已解决。
所以我想在通话时收到通知 callRecord (/communications/callRecords)
所以我抓起自己的 this 示例并将任务函数更改为:
public async Task<ActionResult<string>> Get()
{
var graphServiceClient = GetGraphClient();
var sub = new Microsoft.Graph.Subscription();
sub.ChangeType = "created";
sub.NotificationUrl = config.Ngrok + "/api/notifications";
sub.Resource = "/communications/callRecords";
sub.ExpirationDateTime = DateTime.UtcNow.AddMinutes(5);
var newSubscription = await graphServiceClient
.Subscriptions
.Request()
.AddAsync(sub);
Subscriptions[newSubscription.Id] = newSubscription;
if (subscriptionTimer == null)
{
subscriptionTimer = new Timer(CheckSubscriptions, null, 5000, 15000);
}
return $"Subscribed. Id: {newSubscription.Id}, Expiration: {newSubscription.ExpirationDateTime}";
}
我还在我的应用程序中添加了图表 api 权限 CallRecords.Read.All
。事先我用更新的用户通知测试了这个例子,它运行良好。但是现在不会触发来电通知了。
同样如此,昨天一切正常,但今天我的 webhook 端点甚至没有触发一次。
我认为微软方面可能存在问题。我关注与我们有同样问题的人的这个问题here。
更新:Microsoft 的某人在链接的 Github 问题中回答:
There is currently an ongoing issue. The related post is TM220340 in the M365 Admin Center.
所以他们确认问题已解决。