question

aravindanr avatar image
aravindanr asked hammer commented

Notifications not working in Sandbox

The AppNotificationReceiver is not receiving even after being correctly configured. I am sending a notification using the REST API, with correct app id, merchant id and auth token. I also receive a 200 OK response code. The app doesn't receive any notifications.

<receiver
        android:name=".receiver.NotificationReceiver"
        android:enabled="true"
        android:exported="true">
        <intent-filter>
            <action android:name="com.clover.sdk.app.intent.action.APP_NOTIFICATION" />
        </intent-filter>
    </receiver>

@Override
public void onReceive(Context context, AppNotification notification) {

    Log.d(TAG, "Notification:" + notification);

    if (notification.appEvent.equalsIgnoreCase(CHECKIN) || notification.appEvent.equalsIgnoreCase(CHECKOUT)) {
        Log.d(TAG, "Payload: " + notification.payload);
    }
}
1 comment
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

hammer avatar image hammer ♦ commented ·

Can you capture a logcat and put a http://pastebin.com/ link to it?

0 Likes 0 ·

0 Answers

Welcome to the
Clover Developer Community