This post has been republished via RSS; it originally appeared at: Windows Blog.
In this post, we're announcing, and requesting feedback on a new proposal to extend the Notifications API to allow web apps to send incoming call notifications. Web applications have been able to alert users via notifications for about a decade now. By using the Notifications API, a web app can display messages in the operating system's built-in notification center. When used well, notifications can be a powerful tool to keep users informed about important events. This ability to integrate deeply within the operating system has been a key factor in making the web platform relevant for a wide range of application use cases.
Extending the Notifications API to support incoming calls
In our Incoming Call Notifications explainer, we’re proposing an extension to the Notifications API to solve this problem. We’ve also implemented a prototype of this explainer in Chromium. This new API extension proposal lets you create notifications that:- Are visually distinguished from other notifications.
- Have customized buttons, which can be used to answer or reject a call.
- Have a ringtone associated with them.
- And have a higher priority than other notifications, when supported by the platform.
options
parameter will now accept a new scenario
property, which can be set to "incoming-call"
to indicate that this notification is an incoming call notification:
With the above code, the notification makes it clear that this is an incoming call and lets the user easily start or reject the call.


Test the feature
To see the API in action, use our sample app in Microsoft Edge on Windows by using the following steps:- Start Microsoft Edge on Windows from the command line with the following feature flag:
msedge.exe --enable-features=IncomingCallNotifications
. - Open the calls notification sample app.
- Install the app on Windows, by clicking the App available button in the address bar.
- When the app is installed and running, click the Permission button to accept notifications from the sample app.
- Click the Show an incoming call notification button.
