django-push-notifications
django-push-notifications copied to clipboard
Registrion_id Dummy For Android
I've searched google for this but no success. How can I get a dummy registration_id for Android to test with django-push-notifications? I'm not a mobile developer, just want to use this package functionalities via API.
Any idea?
If you look at the webpush section of the readme. You can use those code snippets to register your browser with FCM and retrieve a registration_id.
Thanks for the reply. If I get your point, after generating the key, I should create a js file with the code on the readme section and replace with my private key generated? Then try and access the file to get my registration id?
Correct. But the messages you send will only go to that browser instance. The registration id is not portable.
Thanks for the reply. I generated the code and place it in the js file.. insert it in my html page and I load the page, nothing like registration_id was found. What am I missing?
Do you get the pop-up asking if you want to allow notifications? If not, the service worker is not going to attempt to register to the back end server.
No, I didn't get any.
Let me look at the instructions again. Remember, if you are running this locally the connection needs to be SSL or FCM will not work.
Ohh.. I'm not on SSL.
If you are not using ssl on your server, it won't work. But you do not get any errors in the JS code.