Device Capabilities and Plugins
Device Capabilities and Plugins
The exam tests how to use Cordova plugins safely in OutSystems mobile apps and how to handle permissions and native-only behavior.
Core rules
- Add plugins through Manage Dependencies; configure native settings in Extensibility Configurations.
- Plugins run in the native shell, not in a desktop browser preview; test on a real device or emulator.
- Request runtime permissions before using camera, location, contacts, or notifications; handle denial gracefully.
- Use the JavaScript API only when a supported plugin or action does not exist.
- Keep plugin versions compatible with the MABS version used by your environment.
Worked example
A barcode-scanning screen calls the Barcode plugin from a Client Action. First check camera permission; if denied, show a Feedback Message and a button to open settings. On success, write the scanned value to a Local Entity and navigate to the detail screen. On error, log the message and allow retry. Reasoning: permission handling is part of the feature, and native plugin calls can fail in ways browser code does not.
Traps
- Expecting a plugin to work in Service Studio preview.
- Calling a plugin before requesting permission.
- Storing large base64 images in client variables.
- Using an unsupported plugin version after a platform upgrade.
- Ignoring plugin error codes and assuming success.