# TypeScript WhatsApp SDK: how few lines does it really take?

> npm install, an API key, a typed call: send WhatsApp messages from Node.js or Next.js, media and webhooks included, without a Meta business account.

Source: https://unlimitedmessaging.app/articles/typescript-sdk

TypeScript / Node.js SDK

# Send WhatsApp messages in TypeScript,  
_in a few lines._

Unlimited Messaging's TypeScript SDK gives you a fully typed client to send WhatsApp messages from Node.js, Next.js or any serverless runtime. Install the npm package, add your API key, and send - from your regular WhatsApp account, without Meta's official API.

[Get my API key](https://app.unlimitedmessaging.app)[See pricing](https://unlimitedmessaging.app/pricing)

The context

## What is Unlimited Messaging's TypeScript WhatsApp SDK?

The TypeScript SDK is a fully typed [npm](https://www.npmjs.com) package that wraps our REST API: you install the client, authenticate it with an API key, and send WhatsApp messages from Node.js, Next.js or a serverless function in a few lines.

Without an SDK, integrating WhatsApp in Node.js means writing raw HTTP calls with fetch: building the URL, serializing the JSON, handling authentication headers, parsing the response and guessing the exact shape of the payload. The TypeScript SDK does all of that for you: an UnlimitedMessagingApiClient object, typed methods like client.messages.messageSend(), and your editor's autocompletion guiding you through every field.

Because all request and response types are generated from the OpenAPI spec and exported with the package, a typo on a field name or a malformed recipient is caught at compile time - not in production. You keep the robustness of a real REST API, but with the ergonomics of a library designed for TypeScript.

And above all, the SDK relies on your regular WhatsApp account: no Meta Business account to verify, no template to get approved, no per-message billing. A POST becomes a method call, and sending WhatsApp from a Node or Next.js backend fits in three lines - OTPs, transactional notifications, bots.

![A laptop screen showing colorful code in a dark room, with the headline “WhatsApp from TypeScript in a few lines”.](https://unlimitedmessaging.app/_next/image?url=%2Fassets%2Farticles%2Fcovers%2Ftypescript-sdk-en.png&w=3840&q=75)

Definition
TypeScript SDK (Unlimited Messaging)

A fully typed npm package that wraps the Unlimited Messaging REST API to send WhatsApp messages, handle media and webhooks from any TypeScript or Node.js project.

Also called the Node.js WhatsApp SDK or JavaScript WhatsApp client - Unlimited Messaging's official npm package.

[Source: npm - the JavaScript package registry↗](https://www.npmjs.com)

Comparison

## Meta's official API in Node vs Unlimited Messaging TypeScript SDK

The same goal - sending a WhatsApp message from TypeScript code - but two very different levels of effort. On the left, Meta's official Cloud API called with raw fetch; on the right, our typed npm SDK. Line by line, here's what each one requires.

__Meta's official API in Node vs Unlimited Messaging TypeScript SDK__
| Meta's official API in Node (raw fetch)WhatsApp Cloud API | Unlimited Messaging TypeScript SDKtyped npm package |                                      |
| --------------------------------------------------------- | --------------------------------------------------- | ------------------------------------ |
| Installation                                              | No package, fetch written by hand                   | npm install @unlimited-messaging/sdk |
| Typing                                                    | None, untyped JSON payloads                         | Fully typed requests and responses   |
| Business account required                                 | Verified Meta Business account                      | Your regular WhatsApp account        |
| Templates                                                 | Meta approval required                              | No approval, free text               |
| Lines of code to send                                     | About ten (URL, headers, body, fetch)               | Three: import, client, send()        |
| Media                                                     | Upload then reference by media ID                   | Image, PDF or video by simple URL    |
| Webhooks                                                  | Endpoint to verify and host                         | Status webhooks ready to plug in     |
| Unlimited                                                 | Per-message billing                                 | Fixed price, unlimited messages      |

Our approach

## A TypeScript SDK built for Node.js and serverless

We keep the power of the REST API - media, webhooks, delivery statuses - and wrap it in a typed npm client that integrates in a few lines into any JavaScript project.

### Fully typed, end to end

Every request and response type is generated from the OpenAPI spec and exported with the package. Your editor autocompletes the fields, and payload errors are caught at compile time, not in production.

1. 01  
### Installed from npm  
One npm install @unlimited-messaging/sdk and the client is ready. Compatible with Node.js, Next.js, and most serverless runtimes.
2. 02  
### Media and webhooks included  
Send images, PDFs and videos by URL, and receive delivered / read / reply statuses via real-time JSON webhooks.
3. 03  
### Your account, unlimited  
The SDK sends from your regular WhatsApp account. No Meta official API, no templates, no per-message cost.

Lines to send a WhatsApp

3Lines to send a WhatsApp

Typed requests and responses

100 %Typed requests and responses

Meta business accounts required

0Meta business accounts required

From npm install to first send

5 minFrom npm install to first send

How it works

## Send a WhatsApp in TypeScript in three steps

1. 01  
### Install the SDK  
npm install @unlimited-messaging/sdk in your Node.js or Next.js project. The typed client is ready to use.
2. 02  
### Authenticate  
Generate an API key from the dashboard and pass it to the UnlimitedMessagingApiClient constructor. One key per project, revocable at any time.
3. 03  
### Call send()  
client.messages.messageSend({ recipient, text }) sends the WhatsApp message. Add a media URL if needed, and listen for delivery webhooks.

Key takeaway

### A raw fetch makes you code an integration. The SDK makes you write three lines.

If you work in TypeScript, you have no reason to assemble HTTP calls by hand to send a WhatsApp. Install the SDK, give it your API key, call send() - from a Node backend, a Next.js API route or a serverless function. You keep the typing, the media and the webhooks, without a Meta business account or templates, unlimited.

FAQ

## Questions about the TypeScript WhatsApp SDK

Install the package with npm install @unlimited-messaging/sdk, create an UnlimitedMessagingApiClient with your API key, then call client.messages.messageSend({ recipient, text }). Three lines are enough, from any Node.js or Next.js project.

Yes. All request and response types are generated from the OpenAPI spec and exported with the package, so your editor autocompletes the fields and errors are caught at compile time.

No. The SDK sends from your regular WhatsApp account, connected by scanning a QR code. No Meta Business account to verify, no template to get approved, no official Cloud API to set up.

Yes. You send images, PDFs and videos via a URL, and you receive real-time JSON webhooks for delivered, read and reply-received statuses.

Yes. The SDK targets standard Node.js and works in Next.js API routes, edge functions and most serverless platforms. Deno and Bun compatibility is on the roadmap.

Yes. Billing is a fixed-price monthly subscription, with no per-message cost like the official WhatsApp Business API imposes. You send as many WhatsApp messages as you need.

Sources

## Sources & references

To check the information in this article for yourself:

1. [01npm - the official JavaScript package registry↗npm](https://www.npmjs.com)
2. [02Node.js global Fetch API↗Node.js](https://nodejs.org/api/globals.html#fetch)
3. [03WhatsApp Cloud API - official documentation↗Meta for Developers](https://developers.facebook.com/docs/whatsapp/cloud-api)
4. [04WhatsApp Business - official overview↗WhatsApp](https://www.whatsapp.com/business)

![Ilian, senior software engineer](https://ilianazz.com/images/iliazz.png)

Written by

[Ilian](https://unlimitedmessaging.app/authors/ilian) · Senior Software Engineer

A senior software engineer, he founds and runs several tech companies. He builds products around messaging APIs, automation and AI integration, and shares here what he learns while building.

[View LinkedIn profile↗](https://www.linkedin.com/in/ilianAzz/)Updated November 6, 2026

![](https://unlimitedmessaging.app/assets/logos/whatsapp.svg)![](https://unlimitedmessaging.app/assets/logos/email.svg)![](https://unlimitedmessaging.app/assets/logos/sms.svg)

## Send your first WhatsApp in TypeScript today.

Create your account, generate your API key and install the SDK: three lines stand between you and your first WhatsApp message.

[Get my API key→](https://app.unlimitedmessaging.app)

Similar articles
* [![](https://unlimitedmessaging.app/_next/image?url=%2Fassets%2Farticles%2Fcovers%2Fpython-sdk-en.png&w=3840&q=75)Send WhatsApp messages from Python with one pip installSend WhatsApp messages from Python with pip install unlimited-messaging.](https://unlimitedmessaging.app/articles/python-sdk)
* [![](https://unlimitedmessaging.app/_next/image?url=%2Fassets%2Farticles%2Fcovers%2Fwhatsapp-api-en.png&w=3840&q=75)WhatsApp REST API: your first message from code, step by stepProgrammatic WhatsApp messaging via a simple REST API.](https://unlimitedmessaging.app/articles/whatsapp-api)
* [![](https://unlimitedmessaging.app/_next/image?url=%2Fassets%2Farticles%2Fcovers%2Fmcp-en.png&w=3840&q=75)What is a WhatsApp MCP server? The 2026 guideConnect any MCP-compatible AI assistant to WhatsApp via OAuth 2.0.](https://unlimitedmessaging.app/articles/mcp)
