evollu / evollu/react-native-fcm

FCM Payload Custom_notification runs only on Android Emulator

Open
#1,091 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
1.7k
Forks
661
PR merge metrics
No merged PRs in 30d

Description

I've followed all the tutorial about how to implement correct fcm payload, and ir works on emulator android but not after building a release on real device.

It seems that the "custom notification" is not recognized and i can only send "notification" in the payload :
```
$url = 'http://fcm.googleapis.com/fcm/send';
$fields = array (
'to' => $id,
'data' => array (
'custom_notification' => array (
'title' => 'Nouvelle offre de service !',
'body' => 'Vous avez',
'targetScreen' =>"offer",
'ID' =>"200",
'color' => '#3e5baa',
'priority' => 'high',
'sound' => 'default',
'icon' => "ic_launcher",
'show_in_foreground'=> true,
)
)
);
```
Do you have any idea ?

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.