GitXplorerGitXplorer
l

ExpressFirebaseNotificationServer

public
1 stars
0 forks
0 issues

Commits

List of commits on branch master.
Unverified
a2625a342d6407b2510d33e5981ca5baa1b773c6

Fix home page by re-adding in groups

lliezl200 committed 7 years ago
Unverified
b7436d76434b0b3cce19d9807f9964f24fc1cf64

Clean up remaining tag/ group code

lliezl200 committed 7 years ago
Unverified
868d40c03ee7d833eea3a0ef81724410459fbfa6

Clean up lint errors in routes/index.js

lliezl200 committed 7 years ago
Unverified
1ff96df58faf447d4bb9d5b9549f3e80e49044ee

Move eslint packages to dev dependencies + add babel package / babel config

lliezl200 committed 7 years ago
Unverified
568efcfb2786a0ef51ae7cf6a7df8a571df213c7

Clean up app.js

lliezl200 committed 7 years ago
Unverified
49558cb945f3e3db781c559be187851219b8d045

Add code linting with Airbnb's javascript guide

lliezl200 committed 7 years ago

README

The README file for this repository.

Simple Firebase Notifications

A simple Node script to send notifications to an iOS or Android device using Firebase Cloud Messaging.

How to run

npm install -s
node notification.js

if the notification was sent, done! will be printed in the console, the error will be printed otherwise.

Considerations

This is just an example and the following variables MUST be changed to your custom values in order for this to work:

  • client1

    This is the firebase token retrived by the device.

    Visit Android instructions and this and this for iOS instructions.

  • API_KEY

    Can be found in the firebase console, click in the 3 vertical dots in your proyect and then under the tab cloud messaging

  • serviceAccount

    This is the .json file you download form firebase

  • databaseURL

    Can be found in the firebase console under database

For further information about Firebase Cloud Messaging and how to build more complex notifications, please visit https://firebase.google.com/docs/cloud-messaging/downstream

RUN ACTUAL NODE SERVER

Clone repo and install dependencies

git clone https://github.com/liezl200/KironNodeNotificationServer.git

cd KironNodeNotificationServer && sudo npm install

Run app

Make sure you cd into the repo then run: npm start

Go to index

In your browser, navigate to the homepage: http://localhost:3000/(http://localhost:3000/)