Skip to content
This repository has been archived by the owner on Jan 30, 2020. It is now read-only.

A simple node script which watched your firebase database and adds users to a mailchimp list

License

Notifications You must be signed in to change notification settings

aaron-russell/Firebase-to-Mailchimp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Firebase-to-Mailchimp

Leaving this here for reference as firebase now lets you do this natively

A simple node script which watched your firebase database and adds users to a mailchimp list

This simple script runs and adds any new users to a firebase database and adds them to a mailchimp list.

Installation

Simply run:

npm install

Followed by:

node firebase-to-mailchimp.js

The script will watch the 'users' database and add anyone not on the list to the mailchimp list.

Firebase database structure

Here is my database structure this script is based off

"users": {
    "uid": {
        "name": "Test McTestface", 
        "email": "[email protected]",
        "mailchimp": false
    }
}

Once the user has been added successfully it will output

Adding firebase user [email protected](uid) to the mailchimp list.

It will also change the mailchimp: false in the database to be true, so not to add it the list again.

If an error occurs it will return the error to the console.

Authors

About

A simple node script which watched your firebase database and adds users to a mailchimp list

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published