Skip to main content
Version: v6

Mobile Messaging

Mobile Messaging SDK is designed and developed to easily enable push notification channel in your mobile application. In almost no time of implementation you get push notification in your application and access to the features of Infobip IP Messaging Platform. This document describes library integration steps for your Cordova project.

For more info see Cordova plugin docs

https://github.com/infobip/mobile-messaging-cordova-plugin

Stuck on a Cordova issue?

Don't waste precious time on plugin issues.

If you're building a serious project, you can't afford to spend hours troubleshooting. Ionic’s experts offer premium advisory services for both community plugins and premier plugins.

Installation

$ npm install com-infobip-plugins-mobilemessaging 
$ npm install @awesome-cordova-plugins/mobile-messaging
$ ionic cap sync

Supported Platforms

  • Android
  • iOS

Usage

React

Learn more about using Ionic Native components in React

Angular

import { MobileMessaging } from '@awesome-cordova-plugins/mobile-messaging/ngx';


constructor(private mobileMessaging: MobileMessaging) { }

...


this.mobileMessaging.init({
applicationCode: '<your_application_code>',
geofencingEnabled: '<true/false>',
defaultMessageStorage: '<true/false>',
ios: {
notificationTypes: ['alert', 'badge', 'sound']
},
android: {
notificationIcon: <String; a resource name for a status bar icon (without extension), located in '/platforms/android/app/src/main/res/mipmap'>,
multipleNotifications: <Boolean; set to 'true' to enable multiple notifications>,
notificationAccentColor: <String; set to hex color value in format '#RRGGBB' or '#AARRGGBB'>
}}, (err) => {
...
});

this.mobileMessaging.register('messageReceived').subscribe((message: Message) => {
...
});