Personal tools

WebAPI

From MozillaWiki

(Redirected from WebAPI/)
Jump to: navigation, search

The Mozilla WebAPI team is pushing the envelope of the web to include --- and in places exceed --- the capabilities of competing stacks.

Contents

Contributing

WebAPI work is being tracked by Mozilla bug 673923. Find an dependent bug that interests you (and is unassigned), and assign it to yourself.

Documentation

This wiki page's purpose is mostly to be able to track the advancement of the work on the different APIs covered by the WebAPI team and help working on those. If you are interested in documentation for these Web APIs, you should look at the following MDN documentation page: https://developer.mozilla.org/docs/WebAPI

APIs

Here's a list of the APIs that we're working on. Some of them are done, and some of them we haven't gotten further than acknowledge that we probably need them.

Planned for initial release of B2G (aka Basecamp)

Unless otherwise noted, APIs listed in the table below were available in Firefox OS v1.0.1 or will be available in v1.1.

API Description Standardization Availability See also
WebTelephony Allow placing and answering phone calls as well as build in-call UI. W3C ED (SysApps) D A B bug 674726, Security
Vibration API Control device vibration for things like haptic feedback in games. Not intended to solve things like vibration for notification. W3C CR (Device APIs) D A B bug 679966, Security
WebSMS Send/receive SMS messages as well as manage messages stored on device. W3C ED (SysApps) D A B bug 674725, Security
Idle API Get notifications when user is idle. Needs plan D A B bug 715041, Security
Screen Orientation Get notification when screen orientation changes as well as control which screen orientation a page/app wants. W3C WD (WebApps) D A B bug 720794 bug 740188 bug 673922, Security
Settings API Set system-wide configurations that are saved permanently on the device. Future? D A B bug 678695, Security
Power Management API Turn on/off screen, cpu, device power, etc. Listen and inspect resource lock events. Future? D A B bug 708964, Security
Mobile Connection API Expose signal strength, operator, etc for GSM and other mobile connections. This does not cover WiFi. Future? D A B bug 729173, Security
TCP Socket API Low-level TCP socket API. Will also include SSL support. W3C ED (SysApps) D A B bug 733573 bug 892833, Security
Geolocation API Access to the end user's location. W3C CR D A B Security
WiFi Information API Privileged API to get a list of available WiFi networks. Also get signal strength and name of currently connected network, etc. Future? D A B Security
Device Storage API Add/Read/Modify files stored on a central location on the device. For example the "pictures" folder on modern desktop platforms or the photo storage in mobile devices. Needs plan D A B bug 717103, Security
Contacts API Add/Read/Modify the device contacts address book. W3C ED (SysApps) D A B bug 674720, bug 857730 for Android, Security
Mouse Lock API Lock access to mouse and get access to movement deltas rather than coordinates. W3C ED D A B bug 633602
Open WebApps Install web apps and manage installed webapps. Also allows an installed webapp to get payment information. Everything needed to build a Open WebApps app store. W3C WD (SysApps) D A B bug 697006, Security
WebBluetooth Low level access to Bluetooth hardware. Future? D A B bug 674737, Security
Network Information API Get basic information about current network connectivity. Example: "How fast of a connection do I have?". W3C ED D A B bug 677166 bug 713199, Security
Battery Status API Information about battery charge level and if device is plugged in. W3C CR (DAP) D A B bug 678694, Security
Alarm API Schedule a notification, or for an application to be started, at a specific time. W3C WD (SysApps) D A B {Security
Browser API Enables implementing a browser completely in web technologies. Future? D A B bug 693515, Security
Time/Clock API Set current time. Timezone will go in the Settings API. Future? D A B bug 714357, bug 714358, API proposed
Web Activities Delegate an activity to another application. Discussed in Device APIs D A B bug 715814 bug 776027 for Android
Push Notifications API Allow the platform to send notification messages to specific applications. W3C ED (Webapps) D A B bug 822712 for B2G, bug 834033 for Android
Permissions API Allow Settings app to manage all app permissions in a centralized location Future? D A B bug 707625, Security
WebFM API For FM radio feature. Future? D A B bug 749053, Security
FileHandle API Writable files with locking. Needs plan D A B bug 726593
Network Stats API Monitor data usage and expose data to privileged apps Future? D A B bug 746069
WebPayment Allow web content to initiate payments and refunds for virtual goods. For the server implementation, see WebPaymentProvider. Beginning D A B
IndexedDB Client-side storage of structured data and high performance searches on this data W3C WD D A B bug 553412, Security
Archive API Blob support for Zip file contents Future? D A B bug 772434
Ambient light sensor Device light sensor support W3C WD D A B bug 738465
Proximity sensor Device proximity sensor support W3C WD D A B bug 738131
SystemXHR External (non-same origin) XMLHttpRequests  ? D A B  ?

Planned for the future

API Bugs Description Progress Availability
Resource lock API bug 697132 Prevent resources from being turned off, for example screen dimming, WiFi turning off, CPU going into sleep mode etc. Complete.
Security Design Complete
UDP Datagram Socket API bug 745283 Low-level UDP API. Planning. (Not P1 for basecamp)
USB file-reading API bug 748350 bug 737153 When enabled, allows mounting of device storage as a USB filesystem on the tethered computer. Must be complete by June/July.
Not really a webAPI, no security design.
Camera API This is part of the larger WebRTC effort. This is a big piece of work so see the link. API and implementation underway.
Security Design Complete
Peer to Peer API This is part of the larger WebRTC effort. This is a big piece of work so see the link. API and implementation underway.
WebNFC bug 674741 Low level access to NFC hardware. So far focusing on NDEF support. Shipped in 1.3.
Security Design Complete
WebUSB bug 674718 Low level access to USB hardware. Security Design Complete
HTTP-cache API Query what's stored in the browsers http-cache. Add/remove entries. Update expiration time. Get data directly from cache. None
Calendar API Add/Read/Modify to the device calendar. Implementation not planned ATM. If/when implemented, it should mimic WebAPI/ContactsAPI.
Spellcheck API Enable webpages to check if a piece of text is correctly spelled as well as get suggestions for corrections. None
Background services Enable a web application to run in the background and perform tasks like syncing or respond to incoming messages. Initial proposal of API.
Security Design Active
LogAPI Allows to register the user activity on the phone. API proposal exists. Not planned for 1.0.
Keyboard/IME API bug 737110 (WebAPI mailing list post, Extended API mailing list post) Enables implementing virtual keyboards. Only exposed to certified apps for V1. Controlled via a setting instead.] D A B
DataStore API bug 871445 Shared app/site data stores with a mechanism for multiple applications to concurrently synchronize shared data into local caches Standardization: W3C ED (SysApps) D A B

Legend

D = Desktop, A = Android, B = B2G
only available to certified apps on this platform
only available to privileged and certified apps on this platform
implemented and preference enabled by default on on this platform
implemented but requires explicitly turning on the preference on this platform
not implemented for this platform
not currently planned for this platform

Process

A draft specification and prototype implementation of new Web APIs will be discussed publicly on our mailing list and at our public meetings (see below). Once we have an API that we feel that we are satisfied with, we will submit the new API for standardization to the W3C.

The goal is to standardize all APIs.

Design Principles

Security

Security will be a central aspect of all the APIs that we design. We wouldn't want any random webpage to be able to read the user's contact list, or able to issue arbitrary commands to any USB device which is hooked up to the user's computer.

In some cases the solution will be to simply ask the user, like we do today for Geolocation for example. In other cases, where security implications are scarier or where describing the risk to the user is harder, we'll have to come up with better solutions.

This is an area where we're still doing a lot of research. I really want to emphasize that we don't have all the answers yet, but that we plan on having them before we roll out these APIs to millions of users.

Low Level vs. High Level

One question that often comes up, is should we do low level APIs, like USB access, or high level APIs, like camera access?

In many cases we are going to want to do both high level and low level APIs, with an initial priority on low level. High level APIs will let us create more friendly APIs, which are both easier to use for developers, and better for users since we can provide better security guarantees. However low level APIs will provide support for a wider range of hardware and use cases and will get the browser out of the critical path for innovation.

Plans

Plans for 2013

Meetings

Meeting Details:

  • Agenda for this week (create below if it doesn't exist yet)
  • Tuesdays alternating 8:00 AM Pacific Time and 4:00 PM Pacific Time (watch mailing list for announcement)
  • WebAPI Vidyo room
  • Dial-in: conference# 98413
    • US/California/Mountain View: +1 650 903 0800, x92 Conf# 98413
    • US/California/San Francisco: +1 415 762 5700, x92 Conf# 98413
    • US/Oregon/Portland: +1 971 544 8000, x92 Conf# 98413
    • CA/Vancouver: +1 778 785 1540, x92 Conf# 98413
    • CA/Toronto: +1 416 848 3114, x92 Conf# 98413
    • UK/London: +44 (0)207 855 3000, x92 Conf# 98413
    • FR/Paris: +33 1 44 79 34 80, x92 Conf# 98413
    • US/Toll-free: +1 800 707 2533, (pin 369) Conf# 98413
  • San Francisco: Amoeba conference room (7th floor)
  • London: Allo Allo conference room
  • Toronto: Spadina conference room
  • Join irc.mozilla.org #webapi for back channel

Notes will be taken on etherpad: https://etherpad.mozilla.org/webapi-meetingnotes

Meeting Notes

Create a new weekly agenda from the template:

Remember: You'll still need to link it below!

2014

Communication

Mailing-list / Newsgroup

You can subscribe to the mailing list here: https://lists.mozilla.org/listinfo/dev-webapi

And the web based API is here: http://groups.google.com/group/mozilla.dev.webapi/topics

The newsgroup lives on the news.mozilla.org server and has the name mozilla.dev.webapi

IRC

Find us on irc.mozilla.org in #webapi. Need help to use Mozilla IRC servers?

See also

Demos

Other efforts

Subpages of WebAPI

WebAPI/0-0-0WebAPI/2011-08-23
WebAPI/2011-08-30WebAPI/2011-09-06WebAPI/2011-09-20
WebAPI/2011-09-27WebAPI/2011-10-04WebAPI/2011-10-11
WebAPI/2011-10-18WebAPI/2011-10-25WebAPI/2011-11-01
WebAPI/2011-11-08WebAPI/2011-11-15WebAPI/2011-11-22
WebAPI/2011-11-29WebAPI/2011-12-13WebAPI/2011-12-20
WebAPI/2012-01-03WebAPI/2012-01-10WebAPI/2012-01-17
WebAPI/2012-01-24WebAPI/2012-01-31WebAPI/2012-02-07
WebAPI/2012-02-14WebAPI/2012-02-28WebAPI/2012-03-06
WebAPI/2012-03-13WebAPI/2012-03-20WebAPI/2012-04-03
WebAPI/2012-04-10WebAPI/2012-04-24WebAPI/2012-05-01
WebAPI/2012-05-08WebAPI/2012-05-15WebAPI/2012-05-22
WebAPI/2012-05-29WebAPI/2012-06-05WebAPI/2012-06-12
WebAPI/2012-06-19WebAPI/2012-06-26WebAPI/2012-07-03
WebAPI/2012-07-10WebAPI/2012-07-17WebAPI/2012-07-24
WebAPI/2012-07-31WebAPI/2012-08-07WebAPI/2012-08-14
WebAPI/2012-08-21WebAPI/2012-09-04WebAPI/2012-09-11
WebAPI/2012-09-18WebAPI/2012-09-25WebAPI/2012-10-02
WebAPI/2012-10-09WebAPI/2012-10-16WebAPI/2012-10-23
WebAPI/2012-10-30WebAPI/2012-11-13WebAPI/2012-11-20
WebAPI/2012-11-27WebAPI/2012-12-04WebAPI/2012-12-11
WebAPI/2012-12-18WebAPI/2013-01-15WebAPI/2013-01-22
WebAPI/2013-01-29WebAPI/2013-02-12WebAPI/2013-02-19
WebAPI/2013-02-26WebAPI/2013-03-05WebAPI/2013-03-12
WebAPI/2013-03-19WebAPI/2013-03-26WebAPI/2013-04-02
WebAPI/2013-04-09WebAPI/2013-04-23WebAPI/2013-04-30
WebAPI/2013-05-07WebAPI/2013-05-14WebAPI/2013-05-21
WebAPI/2013-05-28WebAPI/2013-06-04WebAPI/2013-06-11
WebAPI/2013-06-18WebAPI/2013-06-25WebAPI/2013-07-02
WebAPI/2013-07-16WebAPI/2013-07-23WebAPI/2013-07-30
WebAPI/2013-08-06WebAPI/2013-08-13WebAPI/2013-08-20
WebAPI/2013-08-27WebAPI/2013-09-03WebAPI/2013-09-10
WebAPI/2013-09-17WebAPI/2013-09-24WebAPI/2013-10-01
WebAPI/2013-10-08WebAPI/2013-10-15WebAPI/2013-10-22
WebAPI/2013-10-29WebAPI/2013-11-05WebAPI/2013-11-12
WebAPI/2013-11-19WebAPI/2013-11-26WebAPI/2013-12-03
WebAPI/2013-12-10WebAPI/2013-12-17-take2WebAPI/2014-01-07
WebAPI/2014-01-14WebAPI/2014-01-21WebAPI/2014-02-04
WebAPI/2014-02-11WebAPI/2014-02-18WebAPI/2014-03-04
WebAPI/2014-03-11WebAPI/2014-03-18WebAPI/2014-03-25
WebAPI/2014-04-01WebAPI/2014-04-15WebAPI/2014-04-18
WebAPI/2014-04-22WebAPI/AlarmAPIWebAPI/AppDefinedTeleophony
WebAPI/AppDefinedTelephonyWebAPI/ArchiveAPIWebAPI/AudioChannels
WebAPI/B2G1.0WebAPI/BatteryAPIWebAPI/BrowserAPI
WebAPI/CalendarAPIWebAPI/CameraControlWebAPI/ContactsAPI
WebAPI/ContactsAPI/2012WebAPI/DataStoreWebAPI/DeviceIndexedDB
WebAPI/DeviceStorageAPIWebAPI/DeviceStorageAPI2WebAPI/Direct Billing
WebAPI/Docs scheduleWebAPI/ExposureGuidelines
WebAPI/FileHandleAPIWebAPI/IdleAPIWebAPI/Inter App Communication
WebAPI/Inter App Communication Alt proposalWebAPI/KeboardIME
WebAPI/LogAPIWebAPI/Navigator.hasFeatureWebAPI/NetworkAPI
WebAPI/PlannedWorkWebAPI/PowerManagementAPIWebAPI/ProposedDeviceStorageAPIWithNotifications
WebAPI/PushWebAPI/Push/MeetingsWebAPI/Push/Requirements
WebAPI/PushAPIWebAPI/PushAPI oldWebAPI/ResourceLockAPI
WebAPI/ResourceStatsWebAPI/ScreenOrientationWebAPI/Security
WebAPI/Security/AlarmWebAPI/Security/BackgroundWebAPI/Security/Battery
WebAPI/Security/BluetoothWebAPI/Security/BrowserAPIWebAPI/Security/Camera
WebAPI/Security/ContactsWebAPI/Security/DeviceStorageWebAPI/Security/FMRadioAPI
WebAPI/Security/GeolocationWebAPI/Security/IdleWebAPI/Security/MobileConnection
WebAPI/Security/NetworkInfoWebAPI/Security/NetworkInformationWebAPI/Security/OpenWebApp
WebAPI/Security/PermissionsAPIWebAPI/Security/PowerManagementWebAPI/Security/ResourceLock
WebAPI/Security/SMSWebAPI/Security/ScreenOrientationWebAPI/Security/Sensor
WebAPI/Security/SettingsWebAPI/Security/TCPSocketWebAPI/Security/Vibration
WebAPI/Security/WebNFCWebAPI/Security/WebTelephonyWebAPI/Security/WebUSB
WebAPI/Security/WifiWebAPI/Security/indexDBWebAPI/Security/pushNotificationsAPI
WebAPI/SettingsAPIWebAPI/SimpleCellIDWebAPI/SimplePush
WebAPI/SimplePush/MeetingsWebAPI/SimplePush/Meetings/2013-02-26WebAPI/SimplePush/Meetings/2013-02-27
WebAPI/SimplePush/ProtocolWebAPI/SimplePush/ServerAPIWebAPI/SpeakManager
WebAPI/SpeakerManagerWebAPI/Storage2013WebAPI/WebActivities
WebAPI/WebBluetoothWebAPI/WebIccManager/Multi-SIMWebAPI/WebMMS
WebAPI/WebMobileConnectionWebAPI/WebMobileConnection/Multi-SIMWebAPI/WebMobileConnection嗎
WebAPI/WebNFCWebAPI/WebPaymentWebAPI/WebPayment/Multi-SIM
WebAPI/WebPaymentProviderWebAPI/WebPrintAPIWebAPI/WebSMS
WebAPI/WebSMS/Multi-SIMWebAPI/WebSTKWebAPI/WebSerial
WebAPI/WebSocketOverAppsWebAPI/WebTelephonyWebAPI/WebTelephony/Multi-SIM
WebAPI/WebUSBWebAPI/WebVoicemailWebAPI/WebVoicemail/Multi-SIM
WebAPI/XHRBatch