Backendless Support
 
Answered

push notification - Android

Hi,

I am trying to push a notification to a specific device using API provided by your documentation, I followed the instructions and tried:

deliveryOptions.addPushSinglecast( receiver-device-id );

but addPushSinglecast is not available, I found setPushSinglecast instead, which requires list <String> as argument

I could not find any documentation/examples on how to use this

Can you please provide some help/

Thanks,

Mohammed

Leave a Comment

Comments (3)

photo
1

Hi Mohammed,

The documentation you are referencing is for version 3 of Backendless (see attached screenshot). In Backendless 4 you should use setPushSinglecast method which accepts list <String> argument. Docs for message publishing in Backendless 4: https://backendless.com/docs/android/doc.html#messaging_publish_push_notifications

Regards, Anton

photo
1

Hi Anton,

Please check V 4 it still shows addpushnotification

photo
1

Hi Mohammad,

Thank you for pointing that! I have created an internal documentation ticket (ID: BKNDLSS-16817) to fix this.

As for the usage, you only need to form a List now in version 4, e.g.:

  1. deliveryOptions.setPushSinglecast( Arrays.asList( receiver-device-id ) );

photo