wa-js: Access WhatsApp Web Functions from JavaScript

wa-js: Access WhatsApp Web Functions from JavaScript

Summary

WA-JS exports WhatsApp Web functions through a JavaScript global API for browser-based integrations and automation. It suits developers building chat, group, business, or account workflows that run in WhatsApp Web.

At a glance

Language
TypeScript
License
Apache-2.0
Stars
816
Forks
245
Added to OSRepos
October 11, 2025
Last analyzed
October 3, 2026
View on GitHub

Topics

Click on any tag to explore related repositories

Use at your own risk

OSRepos shares public repositories for knowledge and discovery only. Any installation, execution, configuration, or use of code from these repositories is the user's own responsibility. Always review the repository, source code, dependencies, licenses, and security implications before running or installing anything. OSRepos is not responsible for issues, damages, or losses resulting from third-party repositories.

Overview

WA-JS is a TypeScript library that exposes selected functions from WhatsApp Web through a global WPP object. After its bundle is injected into the WhatsApp Web page, developers can call APIs for messaging, contacts, groups, account settings, and other features without building each interaction from scratch.

It is intended as a building block for browser integrations and automation, rather than a standalone messaging service. Since it works by extracting functions from WhatsApp Web, it depends on that web application and its internal behavior.

Key Features

  • Exposes WhatsApp Web functionality under organized modules such as WPP.chat, WPP.contact, and WPP.group.
  • Sends text and file messages and provides chat and message operations.
  • Supports contacts, groups, communities, channels, statuses, and connection events.
  • Includes business-oriented APIs for catalogs, carts, orders, and labels.
  • Provides account features such as profile and privacy settings, plus custom chat lists.
  • Builds an injectable bundle and includes Playwright tests and tools to compare WhatsApp Web versions.

Use Cases

  • A developer can add messaging and media-sending workflows to a browser-based customer support tool.
  • An automation developer can respond to chat events or manage groups from a script running in WhatsApp Web.
  • A business integration can work with WhatsApp catalogs, carts, orders, and chat labels where those account features apply.
  • A team maintaining a WhatsApp Web integration can use the tests and version comparison scripts to identify breakage after web updates.

Project Facts

  • Language: TypeScript
  • License: Apache-2.0
  • Stars: 816
  • Forks: 245
  • Topics: wa, wajs, whatsapp, whatsapp-api, whatsapp-bot, whatsapp-chatbot, whatsapp-integration, whatsapp-sdk, whatsapp-web, whatsapp-web-api, whatsapp-web-automation, wpp
  • Archived: No

Getting Started

Install dependencies and build the bundle:

npm install
npm run build:prd

The build produces dist/wppconnect-wa.js, which is intended for injection into WhatsApp Web. See the README for local launch, testing, and usage examples.

Alternatives

  • BuilderBot: BuilderBot focuses on building WhatsApp chatbots with conversation flows, while wa-js exposes WhatsApp Web functions for broader browser-based workflows.

Considerations

  • WA-JS must run in the WhatsApp Web page, so it is not a standalone API client or server-side messaging service.
  • The library extracts functions from WhatsApp Web, whose internal changes may break integrations. The project provides smoke tests and version comparison tools, but consumers should validate their workflows against current versions.
  • Some APIs are account-specific. For example, labels are for business accounts, while custom lists work across account types.
  • Use involves automating or integrating with WhatsApp Web. Check applicable WhatsApp terms and account requirements before deploying workflows.

Found this useful?

Share it with someone who would like wa-js.

Comparisons

Source repository

Open the original repository on GitHub.

20 counted GitHub visits

View on GitHub

Related repositories

Similar repositories that may be relevant next.

OS
OSRepos

Analysis and discovery of open source repositories. Find interesting projects and follow their updates.

Monitor your website with YourWebsiteScore

OSRepos shares public repositories for knowledge and discovery only. Any installation, execution, configuration, or use of third-party repository code is at your own risk. Always review source code, dependencies, licenses, and security implications before running anything.

© 2025 OSRepos. Built with Nuxt 3 and lots of ❤️