This is a sample demonstrating calling kiosk APIs from an extension in kiosk mode.
background.js
handles receiving calls from external websites listed in the externally_connectable
key of the manifest.json
file. When receiving a message, the extension then calls specific APIs that are not normally exposed on the webpage or not available to be called from a webpage, such as restart which is only available to kiosk applications.
The manifest.json
file describes the extension and provides key metadata about the extension. One important thing to note here is the externally_connectable
field in the manifest. This field allows websites from that wildcard location *://chromeos.dev/*
to call the extension. We have a sample PWA deployed to that URL currently for users that are interested in testing the extension with a PWA.
Note that you will need to replace these 2 fields in the manifest.json file accordingly to match your self hosted extension information:
- key
- version
This is for self hosting the extension you want to test your PWA with. For more information on self hosting, the Chrome Enterprise Team has written this document which goes over in great detail self hosting extensions and accessing them within your organization.
Note that you will need to replace these 3 fields in the manifest.xml file accordingly to match your self hosted extension information:
- appid
- codebase
- version