Ping both Minecraft Bedrock and Java servers.
Go to file
Timofey Gelazoniya 1409882120
added installation instructions
2022-01-10 23:30:56 +03:00
example initial commit 2022-01-10 23:21:47 +03:00
lib initial commit 2022-01-10 23:21:47 +03:00
types initial commit 2022-01-10 23:21:47 +03:00
.gitignore initial commit 2022-01-10 23:21:47 +03:00
LICENSE initial commit 2022-01-10 23:21:47 +03:00
README.md added installation instructions 2022-01-10 23:30:56 +03:00
SECURITY.md initial commit 2022-01-10 23:21:47 +03:00
index.js initial commit 2022-01-10 23:21:47 +03:00
package.json change scope 2022-01-10 23:24:53 +03:00
yarn.lock initial commit 2022-01-10 23:21:47 +03:00

README.md

mineping

Collect information about Minecraft (both Java and Bedrock) using Node.js.

Description

mineping is a Javasript library thar provides Minecraft server ping protocol implementation. It can be used to collect information about the server, such as MODT, current online, server icon (java edition only) and etc.

Requirements

Node.js 14 or newer is required

Install

npm i @minescope/mineping

Example

Ping a Java server with default options:

import { pingJava } from 'mineping'

const data = await pingJava('mc.hypixel.net');
console.log(data);

Ping a Bedrock server with custom options:

import { pingBedrock } from 'mineping'

const data = await pingBedrock('mco.mineplex.com', {
    port: 19132,
    timeout: 500
})

More complex example can be found in the examples folder!

Acknowledgements

  • mcping crate for Rust
  • mcping-js library for quering Minecraft Java Edition servers