Installation
Requirement:
cordova-android >= 12.0.0.
- Install plugin:
ionic cordova plugin add cordova-plugin-reteno --variable SDK_ACCESS_KEY=YOUR_KEY- Install Ionic wrapper from npmjs:
npm install awesome-cordova-plugins-reteno @awesome-cordova-plugins/coreChoose the wrapper major that matches your @awesome-cordova-plugins/core (v5–v9). API is identical across versions — see the compatibility matrix in Setup overview.
- Add Android platform if needed:
ionic cordova platform add androidConfigure via config.xml
config.xml<widget ...>
<plugin name="cordova-plugin-reteno" spec="cordova-plugin-reteno">
<variable name="SDK_ACCESS_KEY" value="YOUR_KEY" />
</plugin>
</widget>Notes:
SDK_ACCESS_KEYprecedence: plugin variables (ionic cordova plugin add --variable ...orconfig.xml) → AndroidManifest meta-data injected by plugin.- If you changed plugin variables, usually you need reinstall/re-add:
ionic cordova plugin rm cordova-plugin-reteno && ionic cordova plugin add ...- or
ionic cordova platform rm android && ionic cordova platform add android
Request Notification Permission (Android 13+)
Android 13+ (targetSdkVersion >= 33) requires runtime permission for notifications. The plugin injects POST_NOTIFICATIONS into the manifest, but you still must request it at runtime:
const granted = await this.reteno.requestNotificationPermission();
// granted: 1 — granted, 0 — declinedInitialize SDK
Use Platform.ready() and call this.reteno.init(...) once. Full example is in Setup overview.
Firebase Cloud Messaging
- Download
google-services.jsonfrom Firebase Console. - Place it in project root or
resources/android/.




Official references:
Without Firebasex
If you do not need cordova-plugin-firebasex features, Reteno push still works on Android. For FCM to work, your Cordova Android project must have:
google-services.jsonfrom Firebase Console.- Google Services Gradle plugin (
com.google.gms.google-services) applied.
How to verify:
platforms/android/app/google-services.jsonexists.platforms/android/app/build.gradlecontainscom.google.gms.google-services.- Build logs do not contain
google-services.json not found.
Warning: Reteno + Firebasex
If Firebasex registers its own FirebaseMessagingService, Reteno may not receive FCM callbacks.
Custom FCM Service (optional)
Only if you need custom native handling: extend RetenoFirebaseMessagingService and call super methods.
Capacitor Setup (Android)
Capacitor uses Cordova plugins through a compatibility layer, but does not execute Cordova plugin hooks. Some automatic steps from Cordova must be done manually.
1. Install plugin and sync
npm install cordova-plugin-reteno
npx cap sync androidInstall the Ionic wrapper from npm:
npm install awesome-cordova-plugins-reteno @awesome-cordova-plugins/core2. Configure SDK_ACCESS_KEY in capacitor.config.ts
SDK_ACCESS_KEY in capacitor.config.tsimport { CapacitorConfig } from '@capacitor/cli';
const config: CapacitorConfig = {
// ...
cordova: {
preferences: {
SDK_ACCESS_KEY: 'YOUR_KEY',
},
},
};
export default config;The plugin's reteno.gradle script automatically reads this value from capacitor.config.json (generated by Capacitor CLI from capacitor.config.ts) and patches the Android manifest at build time. No manual manifest editing is required.
Then run:
npx cap sync androidYou can also pass key explicitly in JS:
await this.reteno.init({ accessKey: 'YOUR_KEY' });3. Add google-services.json manually
google-services.json manuallyCordova hook that auto-copies google-services.json does not run in Capacitor.
- Download
google-services.jsonfrom Firebase Console. - Copy it to
android/app/google-services.json. - Run
npx cap sync android.
4. Verify Google Services Gradle plugin
Check android/app/build.gradle contains:
apply plugin: 'com.google.gms.google-services'If not, add it manually or install @capacitor-firebase/messaging (or similar).
5. Initialize and request permission
await this.reteno.init();
const granted = await this.reteno.requestNotificationPermission();Deeplinks in Push Payloads
Reteno can deliver deeplinks, but routing inside Ionic app should be handled by app-level deeplink layer (scheme/App Links/provider).
