Skip to content

Instantly share code, notes, and snippets.

@randallknutson
Created July 17, 2015 14:58
Show Gist options
  • Save randallknutson/58da47fad0035de19a28 to your computer and use it in GitHub Desktop.
Save randallknutson/58da47fad0035de19a28 to your computer and use it in GitHub Desktop.
Authentication Example.
var request = require('request');
request.post(
'https://formio.form.io/app/api/user/login/submission',
{
data: {
'user.email': email,
'user.password': password
}
},
function (error, response, body) {
if (!error && response.statusCode == 200) {
token = res.headers['x-jwt-token'];
}
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment