A small library providing access to traitify's api
npm install -g traitify
var traitify = require('traitify');
traitify.setHost("lvh.me");
traitify.setVersion("v1");
traitify.setSecretKey("fakeKey");
var deckId = "Your Deck Id";
traitify.createAssessment(deckId, function(assessment){
// Use assessment here.
console.log(assessment);
});
var assessmentId = "Your Assessment Id";
traitify.getAssessment(assessmentId, function(assessment){
// Use assessment here.
console.log(assessment);
});
var assessmentId = "Your Assessment Id";
traitify.getSlides(assessmentId, function(assessment){
// Use assessment here.
console.log(assessment);
});
var assessmentId = "Your Assessment Id";
traitify.addSlide(assessmentId, {response: true, response_time: 1000}, function(assessment){
// Use assessment here.
console.log(assessment);
});
var assessmentId = "Your Assessment Id";
traitify.addSlides(assessmentId, [{id: "slide-uuid", "response":true, response_time: 1000}], function(assessment){
// Use assessment here.
console.log(assessment);
})
var assessmentId = "Your Assessment Id";
traitify.getPersonalityTypes(assessmentId, function(assessment){
// Use assessment here.
console.log(assessment);
});
npm test
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. test your code.
- 0.1.0 Initial release