sourcequery

A Source Server Query protocol implementation for node.js

SourceQuery

A Source Server Query protocol implementation for node.js

Protocol specification can be found here: https://developer.valvesoftware.com/wiki/Server_queries

Example Usage

var SourceQuery = require('sourcequery');
 
var sq = new SourceQuery(1000); // 1000ms timeout 
sq.open('87.106.131.249', 27015);
 
sq.getInfo(function(errinfo){
    console.log('Server Info:', info);
});
 
sq.getPlayers(function(errplayers){
    console.log('Online Players:', players);
});
 
sq.getRules(function(errrules){
    console.log('Server Rules:', rules);
});