Push notifications for incoming Teams calls

Jeroen H 40 Reputation points
2024-03-19T11:14:25.73+00:00

Hi,

I'm trying to create an app that can catch incoming Teams call events.
I'm using this SDK documentation to achieve it. I mentions the possibility for push notifications (even specifially mentioning for incoming calls) that work when the app is running in the background using Azure Event Grid or Event Hub.

Next, I used the Event Grid and this quickstart to create an Incoming Call event for the Azure Communication Service that the SDK uses to get its Teams User Access Tokens.

My problem is that I can't get this event to trigger.
Calling a user that has an initialized callingAgent from the SDK does not trigger it.
What do I need to change for this to work?

Azure Communication Services
Azure Communication Services
An Azure communication platform for deploying applications across devices and platforms.
679 questions
Azure Event Hubs
Azure Event Hubs
An Azure real-time data ingestion service.
557 questions
Azure Event Grid
Azure Event Grid
An Azure event routing service designed for high availability, consistent performance, and dynamic scale.
314 questions
Microsoft Teams Development
Microsoft Teams Development
Microsoft Teams: A Microsoft customizable chat-based workspace.Development: The process of researching, productizing, and refining new or existing technologies.
2,846 questions
{count} votes

1 answer

Sort by: Most helpful
  1. SnehaAgrawal-MSFT 18,361 Reputation points
    2024-03-28T07:24:57.49+00:00

    @Jeroen H There are two separate things that you are mentioning here.

    1. Getting notifications to work. This has nothing to do with eventgrid. setting up event grid will not trigger "IncomingCallHandler".  https://learn.microsoft.com/en-us/azure/communication-services/concepts/notifications#deliver-push-notifications-via-azure-notification-hubs Follow the steps under Deliver push notifications via Azure Notification Hubs from the above link to get push notifications working.
    2. Now events was mentioned above. this will not result in getting your "incomingCallHandler" invoked. But you can get all the incoming call events to a webhook on your service.  You can follow - Quickstart - Subscribe to Azure Communication Services Events - An Azure Communication Services quickstart | Microsoft Learn

     You need a service which exposes a webhook publicly and you can should configure it to eventgrid. 

    Validate Azure Communication Services events - An Azure Communication Services how-to document | Microsoft Learn

    If you properly handle the validation event in the service, the event subscription should succeed on the portal.

    1. and 2) are orthogonal things. with events going to event grid to webhook to customer's service, they can potentially loop it back into their app if they have built their own push notification system. if not, please strictly follow 1) to getting push notifications working for the app. you can use 2) for auditing, tracking incoming calls and also if you want to answer the calls from a service/server app using our server sdk.
    1 person found this answer helpful.
    0 comments No comments