Web APIs is a collective term used for various APIs that are available to JavaScript in the window context of a loaded HTML document. Firefox OS has additional Web APIs for hardware capabilities on smartphones and tablets, which do not usually exist on desktop or laptop computers. For example, the camera API can be used to open the camera of the device whenever required by a Firefox OS app. There are various APIs that have access to sensitive data, such as the contacts and settings API. Further in this chapter, you will study most of these APIs in detail.
According to Mozilla, there are more than 30 standard WebAPIs for Firefox OS. These APIs assist a developer to gain privileges for interacting with the hardware component of the device. For security purposes, not all of the APIs are open for developers to use in their projects directly, and these APIs require a certified level of permission. This permission is not for third-party developers, and is only available for...