minecraft-ping-ts
TypeScript icon, indicating that this package has built-in type declarations

1.0.4 • Public • Published

minecraft-ping-js

js-standard-style license

A Minecraft Server Pinger in Node.js

Example

const pinger = require('minecraft-ping-js');

// Promise
pinger.pingWithPromise('localhost', 25565).then(console.log).catch(console.error);

// Async
pinger.ping('localhost', 25565, (error, result) => {
    if (error) {
        console.error(error);
    } else {
        console.log(result);
    }
});

Output

{
  "version": { "name": "Requires MC 1.8 / 1.16", "protocol": 754 },
  "players": { "max": 200000, "online": 86460, "sample": [] },
  "description": "             §aHypixel Network  §c[1.8-1.16]\n              §e§lEASTER §b§lEVENT §c§l+ §a§lSALE",
  "favicon": "data:image/png;base64,<LONG_DATA>",
  "ping": 100
}

License

MIT

Readme

Keywords

Package Sidebar

Install

npm i minecraft-ping-ts

Weekly Downloads

15

Version

1.0.4

License

MIT

Unpacked Size

10.6 kB

Total Files

9

Last publish

Collaborators

  • honbra