Skip to main content

Set Permissions

Adding Permissions

To request a permisison you must firstly have added these permissions you require to your application's manifest.

Permissions are represented with a tag like the following:

<uses-permission android:name="android.permission.CAMERA" />

A complete list of the possible permissions is found here.

To add these permissions you need to add some additional configuration to apm. Firstly add a custom Android configuration file by running:

apm generate config android

Edit the config/android/AndroidManifest.xml file that was generated to resemble the following, adding the required permissions, eg:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools">

<uses-permission android:name="android.permission.CAMERA" />

</manifest>

You can add any other additions you require in your application here and these will be merged by apm when you generate your application descriptor.

info

Make sure you regenerate your application descriptor after modifying this file. See the section in add the extension for details.