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

whatsapp-web-x

v1.0.0

Published

A student fork of whatsapp-web.js. Teaching module for interacting with the WhatsApp Web API.

Downloads

6

Readme


NOTE

This library has a significant number of console.log statements that are integral to its function as a teaching tool and therefore cannot be removed. It is designed for educational purposes only, and you should use the official library to build production bots.


🛠️ Contributions & Support

This library uses the exact same functions as the official whatsapp-web.js library, ensuring that all functionalities will work as expected. If you encounter any errors, please open an issue. If you believe you can contribute, you are welcome to fork the repository and submit a pull request. While it will be carefully reviewed, please note that changes that do not align with the educational purpose of this fork will not be accepted.


🚀 The WhatsApp-Web.js Educational Fork

TL;DR

This is a teaching fork of whatsapp-web.js.
We added console.log statements inside the core library so you can watch how data flows in and out, making it easier to understand how Node.js libraries actually work.


About

Welcome to the WhatsApp-Web.js Educational Fork!
This is a modified version of the official whatsapp-web.js library, meticulously crafted to help aspiring developers understand how a Node.js library works behind the scenes.

Our primary focus is on teaching students what the library expects as input and what it produces as a result.
To achieve this, we have strategically placed console.log statements directly within the library's core functions.
This means you will see a detailed log of data flowing through the library as you interact with it—all without needing to add any logging code to your own project!

This is a learning tool, and in no way have we modified the code to do unauthorized activities or enabled any form of misuse of the library.

Who We Are

This educational fork was proudly modded by Ernest Tech House and coded by Pease Ernest.

A WhatsApp API client that connects through the WhatsApp Web browser app

The library works by launching the WhatsApp Web browser application and managing it using Puppeteer to create an instance of WhatsApp Web, thereby mitigating the risk of being blocked.
The WhatsApp API client connects through the WhatsApp Web browser app, accessing its internal functions.
This grants you access to nearly all the features available on WhatsApp Web, enabling dynamic handling similar to any other Node.js application.

[!IMPORTANT]
It is not guaranteed you will not be blocked by using this method. WhatsApp does not allow bots or unofficial clients on their platform, so this shouldn't be considered totally safe.


Links


Installation

The module is now available on npm!

📦 Installation

npm install whatsappweb-x.j


> \[!NOTE]
> **Node `v18+` is required.**

---

## QUICK STEPS TO UPGRADE NODE

### Windows

#### Manual

Get the latest LTS from the [official Node.js website](https://nodejs.org/en/download/).

#### npm

```powershell
sudo npm install -g n
sudo n stable

Choco

choco install nodejs-lts

Winget

winget install OpenJS.NodeJS.LTS

Ubuntu / Debian

curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash - &&\
sudo apt-get install -y nodejs

Example usage

const { Client } = require('whatsapp-web.js');

const client = new Client();

client.on('qr', (qr) => {
    // Generate and scan this code with your phone
    console.log('QR RECEIVED', qr);
});

client.on('ready', () => {
    console.log('Client is ready!');
});

client.on('message', msg => {
    if (msg.body == '!ping') {
        msg.reply('pong');
    }
});

client.initialize();

See example.js for more use cases. For further details on saving and restoring sessions, check out the Authentication Strategies.


Supported features

| Feature | Status | Why this is a great feature to study | | :----------------------------------------------- | :------------------------------------------------------------------------------------------------------------------------------------ | :------------------------------------------------------------------------------ | | Multi Device | ✅ | Learn how a single bot can manage multiple simultaneous connections. | | Send messages | ✅ | Understand how a string of text is packaged and sent to an endpoint. | | Receive messages | ✅ | See the full message object data you receive, from the body to the sender's ID. | | Send media (images/audio/documents) | ✅ | Explore how media files are handled and uploaded. | | Send media (video) | ✅ (requires Google Chrome) | Learn about browser dependencies and specific video handling. | | Send stickers | ✅ | See how custom content is converted into a WhatsApp-supported format. | | Receive media (images/audio/video/documents) | ✅ | Witness how incoming media is processed and converted into usable data. | | Send contact cards | ✅ | Discover how to handle complex data types like contact information. | | Send location | ✅ | Study how geospatial coordinates are formatted and sent. | | Send buttons | ❌ (DEPRECATED) | A great example of a feature being phased out and how a library manages it. | | Send lists | ❌ (DEPRECATED) | Another opportunity to see how deprecation is handled. | | Receive location | ✅ | Observe how incoming location data is parsed. | | Message replies | ✅ | Learn the mechanics of replying to a specific message thread. | | Join groups by invite | ✅ | See how an invite link is converted to a group ID. | | Get invite for group | ✅ | Study the process of generating and retrieving a new invite link. | | Modify group info (subject, description) | ✅ | Understand how metadata changes are sent and received. | | Modify group settings (send messages, edit info) | ✅ | Learn how permissions and group settings are toggled programmatically. | | Add group participants | ✅ | Witness how participant IDs are added to a group. | | Kick group participants | ✅ | See how participants are removed from a group. | | Promote/demote group participants | ✅ | Study the process of changing a user's role. | | Mention users | ✅ | Learn how to tag specific users in a message. | | Mention groups | ✅ | Observe how an entire group can be mentioned. | | Mute/unmute chats | ✅ | See how chat notifications are controlled. | | Block/unblock contacts | ✅ | A key feature for understanding contact management. | | Get contact info | ✅ | Explore how contact data is retrieved. | | Get profile pictures | ✅ | Learn how image data is fetched. | | Set user status message | ✅ | Understand how user profiles are updated. | | React to messages | ✅ | See how emoji reactions are handled. | | Create polls | ✅ | The perfect example for understanding how complex objects are created and sent. | | Channels | ✅ | A new feature to learn from. | | Vote in polls | 🔜 | Stay tuned! | | Communities | 🔜 | Stay tuned! |


Contributing

As this is a carefully crafted educational library, we are not accepting any further modifications at this time. However, if you find a bug or a typo in our learning-focused code, please feel free to open an issue!


Supporting the project

You can support Ernest Tech House through the links below:


Disclaimer

This project is not affiliated, associated, authorized, endorsed by, or in any way officially connected with WhatsApp or any of its subsidiaries or affiliates. The official WhatsApp website can be found at whatsapp.com.

"WhatsApp" as well as related names, marks, emblems and images are registered trademarks of their respective owners.

Also it is not guaranteed you will not be blocked by using this method. WhatsApp does not allow bots or unofficial clients on their platform, so this shouldn't be considered totally safe.


License

Copyright 2025 Pease Ernest

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this project except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.