Skip to content

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Z-API — WhatsApp Integration Examples for Node.js

Connect your Node.js application to WhatsApp with Z-API. Explore practical examples through an interactive command-line menu, or use the service functions as a starting point for your own integration.

Prerequisites

  • Node.js and npm installed.
  • A Z-API account.
  • A Z-API instance connected to your WhatsApp account.

Getting Started

1. Clone the repository

git clone https://github.com/Z-API/whatsapp-api-nodejs.git
cd whatsapp-api-nodejs

2. Install dependencies

npm install

3. Configure your instance

Open index.js and set INSTANCE_API to your instance's API URL:

const INSTANCE_API = 'YOUR_INSTANCE_API_URL'

If you haven't set up an instance yet, create an account at z-api.io, connect your WhatsApp account, and copy your instance's API URL.

4. Run the examples

npm start

Follow the prompts in your terminal to explore the available examples.

Explore the Code

  • index.js — Configures your instance and starts the application.
  • prompt/ — Handles the interactive command-line menu.
  • services/ — Contains the integration functions you can call directly or adapt for your own application.

Build Your Integration

Use these examples to understand how Z-API requests work and bring WhatsApp connectivity into your application.

Ready to get started? Visit z-api.io.

About

Integrate WhatsApp into your Node.js app with Z-API. Explore practical examples, try an interactive CLI, and adapt the code to build your own integration.

Topics

Resources

Stars

25 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages