2. Requirements and use cases
This specification must meet the following requirements:
- An implementation which uses only the existing notification platforms in major platforms to display notifications must be able to comply with the specification.
- The specification must allow compliant implementations regardless of platform or device.
- The specification must provide controls to users in order to prevent unwanted notifications to be displayed.
- The specification must define an event model for interactive notifications.
- The specification must address security issues.
- The specification should not require any implementation to display persistent notifications.
- The specification should be compatible with other Web technologies, such as HTML and SVG.
The specification attempts to address the following use cases:
- An application alerts the user "you've got mail" in the form of an ambient notification, with no interaction necessary.
- An application alerts the user "you've got mail" as an interactive notification which allows the user to easily return to the inbox.
- A calendar application alerts the user for an upcoming meeting, and allows the user to easily specify a "snooze" delay of several possible time periods.
- A system alerts the user "your printer is out of paper".
- An application with multiple simultaneous execution contexts (like a multi-tab email application) wants to show notifications without creating duplicate notifications.
3. Introduction
This section is not normative.
This specification provides an API to generate notifications to
alert users outside of the web page. It does not specify exactly how a user
agent should display these notifications; the best presentation depends on the device
where the user agent is run. When this specificiation refers to displaying
notifications on the "desktop", it generally refers to some static display
area outside the web page, but may take several forms, including:
- a corner of the user's display,
- an area within the chrome of the user agent,
- the "home" screen of a mobile device,
- et al.
This specification does not define exactly how the user agent should display
the notification, and the API is designed to be flexible with respect to
presentation options.
3.1. Security
Notifications should only be presented when the user has indicated they are desired;
without this they could create a negative experience for the user.