I have send FCM notification from server to users. It works fine(until api 25) but in Oreo when the application have not in background(services are closed) (or) completely close
only data notifications is handled on android Oreo
try to remove the notification
`
remove this key notification
{"notification":
{
"title": "notification_title",
"body": "notification_body"
},
// keep only the data key
"data":
{
"example":"hey",
"example2":"you need me."
},
"priority" : "high",
"registration_ids":
[]
`
when the app is in background .. the onRecievedMessage will not called if the payload is contains both notification key and data key ..
so remove the notification .. and only keep the data key .. and it will work well