This project is to support the front end code for Authenticate.me-client-cordova-ionic.
You'll need to download nodejs
- This project uses parse.com as a database therefore you'll need to create an account at parse.com.
Once your account created, create an app (The name of the app doesn't matter, you'll only need the api keys, found under settings > keys).
- You'll need to create an instagram app (go to http://instagram.com/developer/) and a twitter app (go to https://dev.twitter.com/overview/documentation and select manage my apps) as well.
Note : if npm isn't defined you'll need to install node
git clone https://github.com/malikov/Authenticate.me-Node-Server.git
Then navigate to the repo :
cd Authenticate.me-Node-Server
Run :
npm install
This should install all dependencies for the project.
in the config.js file change the appropriate configuration variables for the twitter, instagram and parse.com app.
Replace for twitter
config.twitter.consumerKey = [YOUR TWITTER CLIENT ID];
config.twitter.consumerSecret = [YOUR TWITTER CLIENT SECRET]
config.twitter.callbackURL = [YOUR TWITTER URL CALLBACK];
Replace for instagram
config.instagram.clientID = [YOUR INSTAGRAM CLIENT ID];
config.instagram.clientSecret = [YOUR INSTAGRAM CLIENT_SECRET];
config.instagram.callbackURL = [YOUR INSTAGRAM URL CALLBACK];
Replace for parse.com
config.parse.appId = ['PARSE_API_KEY_ID'];
config.parse.jsKey = ['PARSE_API_JS_KEY'];
config.parse.masterKey = ['PARSE_MASTER_KEY'];
Then run:
node bin/www
the server should launch at localhost:3000.
Note : in order to test the oauth (instagram / twitter) authentication locally you'll want to change your host file on your windows machine (or use nginx with some reverse proxy settings) to match the url used for the callback.
For instance if I was to test the app locally I'd change the host to make sure 127.0.0.1 points to authenticate-app-me.herokuapp.com (therefore accessing the server locally would yield : http://authenticate-app-me.herokuapp.com:3000 ). Then I'd change the callback url to match : authenticate-app-me.herokuapp.com:3000.
once the server is live you can navigate to /oauth/instagram or oauth/twitter to test the login
tests
add facebook