Pipes.bot

Webhooks

Receive WhatsApp messages via HTTP POST to your server.

Pipes.bot can deliver incoming WhatsApp messages to your server as HTTP webhooks. Instead of maintaining a persistent WebSocket connection, your server receives a POST request for each message — including text, images, audio, video, documents, and more.

Pool numbers

A pool number is a WhatsApp phone number managed by Pipes.bot. When you activate a pool number, everytime someone messages it, the message is proxied to your endpoint (until you deactivate it).

How it works

  1. You provide a publicly accessible HTTPS endpoint when activating your pool number
  2. When a WhatsApp message arrives on your pool number, Pipes.bot sends a POST request to your endpoint
  3. Your server processes the payload and responds with a 2xx status code

Media files (images, audio, video, documents, stickers) are automatically downloaded from WhatsApp and stored temporarily. The webhook payload includes a download URL you can use to fetch the file.

If your endpoint is unreachable, Pipes.bot retries delivery with exponential backoff and falls back to WebSocket queuing.

Choosing between WebSocket and Webhook

WebSocketWebhook
ConnectionPersistent, bidirectionalStateless HTTP POST
Best forReal-time apps, bots with instant repliesServerless functions, background processing
RequiresLong-lived processPublicly accessible URL
Offline handlingMessages queued until reconnectRetried with backoff, then queued

You can switch delivery method at any time from the pool numbers dashboard without losing messages.

Setting up webhooks

During activation

When activating a pool number, select Webhook as your delivery method and provide:

  • Webhook URL -- your HTTPS endpoint (e.g. https://api.example.com/pipes/webhook)
  • Webhook Secret (optional) -- a shared secret for HMAC signature verification

You can generate a random secret or provide your own (16-256 characters).

Testing your endpoint

Before completing activation, use the Test Connection button to verify your endpoint is reachable. Pipes.bot sends a test payload with pipes.test: true so your server can identify and ignore test deliveries.

Changing delivery method

Open the settings for any active pool number and switch between WebSocket and Webhook. Your existing secret is preserved when switching back.

On this page