In some cases an app may require permissions to use certain Homey App SDK functionality. In case a permission is not included in the App Manifest certain SDK manager methods will throw an error.
Adding permissions
Permissions are added to your /app.json
manifest, in an array named permissions
.
/app.json
{
"id": "com.athom.weather",
// ...
"permissions": [
"homey:manager:speech-output",
"homey:manager:ledring",
"homey:app:com.athom.example"
]
}
Available permissions
The following is a list of the permissions that an app may use (and the related manager):
Permission | Manager |
---|---|
homey:manager:api |
ManagerApi |
homey:manager:geolocation |
ManagerGeolocation |
homey:manager:ledring |
ManagerLedring |
homey:manager:speech-input |
ManagerSpeechInput |
homey:manager:speech-output |
ManagerSpeechOutput |
homey:wireless:433 |
ManagerRF (getSignal433 ) |
homey:wireless:868 |
ManagerRF (getSignal868 ) |
homey:wireless:ir |
ManagerRF (getSignalInfrared ) |
homey:wireless:ble |
ManagerBLE |
homey:wireless:nfc |
ManagerNFC |
An app should only include permissions it actually needs to function!
App-to-app communication
Apps can also talk to each other through their API's, however you need to define the correct permissions first.
Permissions for app to app communication look like this homey:app:<appId>
, for example homey:app:com.athom.example
or homey:app:com.yahoo.weather
.
Visit ApiApp to learn more about apps talking to each other.