Is it possible to save FCM generated token in mysql database? I have node.js api server (node.js + express) with registration/authentication (using JWT) which is deploing to heroku. I need to add in my android app opportunity to send push notification. Is it possible save fcm token in my existing mysql db without using firebase realtime db.
1 Answer
Yes, you can.
But you need create some web services.
When a device with your app start and call the firebase register url the id/token is generated, your app need send this token to a Data Base using a web service.
Then to send a push notification to these device you can call an other web service who recover the token from ypur Data Base to send the push notification
2 Comments
anna
thank you for your answer, what web services do you mean ?
esdebon
A primitive web service can be a url who receive parameters using a GET method, yourdomain.com/webservice?token=4DFHWDF734HY8F4H&id=Mike Device. With NodeJS you can create a REST Web service using JSON