npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

lms-player-monitor

v1.0.0

Published

Monitor players connected to Lyrion Music Server

Readme

lms-player-monitor

Monitor players connected to Lyrion Music Server (LMS). Tested with LMS v9.x.

Installation

npm i lms-player-monitor

In package.json of your project, you must add the following section:

"overrides": {
  "cometd-nodejs-client": {
    "http-proxy-agent": "^7.0.2",
    "https-proxy-agent": "^7.0.6"
  }
}

This is because lms-player-monitor is a CommonJS module, whereas http-proxy-agent and https-proxy-agent (v8 and above) are ESM-only.

Usage

  1. Create a LmsPlayerMonitor instance:
import { LmsPlayerMonitor, Server } from 'lms-player-monitor';

const server: Server = {
    host: '192.168.1.30',
    // port: ... (defaults to 9000)
    // username: ... (for protected LMS)
    // password: ...
}

const monitor = new LmsPlayerMonitor({
  server
});
  1. Attach event listeners
// Server connected
monitor.on('serverConnect', () => { ... });

// Server disconnected
monitor.on('serverDisconnect', () => { ... });

// Player connected to server
monitor.on('playerConnect', (players) => { ... });

// Player disconnected from server
monitor.on('playerDisconnect', (players) => { ... });

// Player status updated
monitor.on('playerStatus', (status) => { ... });

// Player sync state changed
monitor.on('playerSync', (groups) => { ... });
  1. Start the monitor
await monitor.start();
  1. Stop the monitor
await monitor.stop()'

Additonal methods

Description

Retrieves the list of players currently associated with the server. Note this can include players that are disconnected but retained by the server in case they reconnect. To check whether a player is connected, observe its isConnected property.

Returns

Promise<Player[]>: A promise that resolves to an array of Player objects.

Example

const players = (await monitor.getPlayers()).filter(
  (player) => player.isConnected
);
console.log('Connected players:', players);

Description

Retrieves the status of the player identified by playerId.

Parameters

  • playerId: The player ID (string).

Returns

Promise<PlayerStatus>: A promise that resolves to a PlayerStatus object.

Example

const status = await monitor.getPlayerStatus('d8:3a:dd:58:58:72');

Running the example

Clone this repo, then:

$ npm i
$ npm run build
$ npm run example -- -h <server address> 

Changelog

1.0.0

  • Initial release

License

MIT. See LICENSE.