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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@bugrecorder/sdk

v1.1.39

Published

A lightweight package for monitoring server-side performance metrics and catching errors.

Readme

@bugrecorder/sdk

A lightweight package for monitoring server-side performance metrics and catching errors.

LIMITATION

Please note that this package will work on your self hosted App (Node.js, Bun, Next.js, Deno on a VPS) means it will not work on any serverless platform Like (Vercel, AWS Lambda, Netlify, etc.).

Features

  • Server-side error catching and reporting
  • Real-time performance metrics monitoring (Specifickly to your Application server not whole server)
    • CPU usage tracking (percentage%)
    • Memory usage monitoring (Application Server usage)
    • Network metrics (how much network sent/recived from your Application server)
    • File Read and Write (how much megabyte read/write by your Application)

Installation

npm i @bugrecorder/sdk --save

This package can be used in :

  • Node.js
  • Next.js
  • Bun
  • Deno "npm:@bugrecorder/sdk"

First, initialize the SDK with your API key and domain:

client.init({
    apiKey: "1234567890",
    domain: "test.bugrecorder.com"
});

Track CPU, MEMORY, FILE (read/write), Network metrics

This will send the metric to the dashboard automatickly

client.monitor({
    serverName: "server_dev_1",
    onData: (data) => {
        console.log("data from monitor", data);
    },
    onError: (error) => {
        console.log("error from monitor", error);
    }
});

Send Server Side Errors

client.sendError({
    domain: "test.bugrecorder.com",
    message: "test",
    stack: "test",
    context: "test"
});

Notes:

  • for the File System metrics (disk_read,disk_write): it needs to be any Linux system to get the vales for mac or windows you will get disk_read:0 and disk_read:0

  • if you are using pm2 with cluster ( exec_mode: 'cluster', // enables load balancing), in order to track each instance it needs to have a seprate name so add instance_var: 'INSTANCE_ID' either into ecosystem.config.js file or cli

client.monitor({
      serverName: `server-${
        isNotEmpty(process.env.INSTANCE_ID) ? process.env.INSTANCE_ID : 'dev'
      }`})

this way you will have server-0 server-1 server-1 ....

Server Side Logging

You can use the logger to send logs to the dashboard. The logs will be stored and searchable in the dashboard.

import { logger } from '@bugrecorder/sdk';

logger.error(args);
logger.info(args);
logger.warning(args);
logger.debug(args);
logger.fatal(args);
logger.success(args);
logger.test(args);
logger.console(args);

Support

if you have any issue, or need support contact us at dev @ bugrecorder.com (remove space it was added to prevent spam)