kidtronnix / hapi-dash

Boilerplate Hapi Web and API Server Example, with frontend dashboard.
hapi-dash.smaxwellstewart.com
MIT License
113 stars 19 forks source link

Best way to add a few more features #8

Closed kiritbasu closed 9 years ago

kiritbasu commented 9 years ago

I'm new to node/hapi etc and am looking for some advice;

  1. Can you post a sample of how to authenticate (perhaps using curl) before calling any of the api server methods?
  2. I want to allow my users to authenticate on the gui using fb/twitter etc, whats the best library to use with this hapi project? Bell/passportjs? Feature request: please add functionality to allow fb/twitter auth.
kidtronnix commented 9 years ago

@KReetr sure no probs:

  1. Here is how to authenticate.
curl -H "Content-Type: application/json" -X POST -d '{"email":"hapi.dashboard@gmail.com","password":"guest"}' http://hapi-dash.smaxwellstewart.com/login
  1. hapijs/bell is the best place to look for that kinda functionality for sure. No plans to implement that functionality at the moment. But if I feel brave might attempt a new release of this repo.
kidtronnix commented 9 years ago

Also just to add while that is the curl call the cookie has to be stored and used for future calls.