choco install meteor
curl https://install.meteor.com/ | sh
git clone https://github.com/SharpAI/ApiServer
cd ApiServer
meteor run
curl -X POST -H "Content-type: application/json" http://localhost:3000/api/v1/sign-up -d '{"username": "test11", "email": "[email protected]", "password": "xxxxxx"}'
{
"success": true
}
curl -X POST http://localhost:3000/api/v1/login/ -d "username=test11&password=xxxxxx"
{
"status": "success",
"data": {
"authToken": "mGRTZ_aNbL2EAobchvLmmlLmbn2e5EXdj8WR8DmSZw0",
"userId": "s9pxAWqwHzLaBKP5w"
}
}
curl -X POST -H "X-Auth-Token: mGRTZ_aNbL2EAobchvLmmlLmbn2e5EXdj8WR8DmSZw0" -H "X-User-Id: s9pxAWqwHzLaBKP5w" http://localhost:3000/api/v1/logout
{
"status": "success",
"data": {
"message": "You've been logged out!"
}
}