Sending firebase push notification via postman
A push notification is a message that pops up on a mobile, web and desktop devices. App publishers can send them at any time; users don’t have to be in the app or using their devices to receive them.
Sending push notification via https://fcm.googleapis.com/fcm/send
will no longer work, instead you have to use new approach.
- Use new url
https://fcm.googleapis.com/v1/projects/{your-project-id}/messages:send
2. Generate Token from google play ground
a) https://developers.google.com/oauthplayground/
b) select Firebase Cloud Messaging API v1
c) Check https://www.googleapis.com/auth/firebase.messaging
d) Press Authorized APIs, choose firebase account and allow
e) Press exchange authorization code for tokens
c) copy the access_token
3. Go to postman, add header above url and header authorization with Bearer your_key
as value.
4. You can add your content inside body and push the notification.