balena-cli/lib/cli-modules/auth/auth.coffee
2014-10-31 14:47:18 -04:00

9 lines
271 B
CoffeeScript

server = require('../../server/server')
exports.getToken = (credentials, callback) ->
server.post '/login_', credentials, (error, response) ->
return callback(error, response?.body)
exports.login = (credentials, callback) ->
exports.getToken(credentials, callback)