new dbmysql.Database({ hostname: 'localhost', user: 'root', password: 'password', database: 'node' }).connect(function(error, server) { if (error) { throw new Error('ERROR: ' + error); } console.log(server); }); { version: '5.5.24', hostname: 'localhost', user: 'root', database: 'node' }