Connections

POST /connections/{phoneNumber}

Changed on

Request

  • Base URL
    http://localhost:3025
  • Auth
    API key in header x-api-key

Path parameters

phoneNumberstring required
Example:+551234567890

Phone number for connection. Must have + prefix.

Request body

clientNamestring

Name of the client to be used on WhatsApp connection

webhookUrlstring uri required

URL for receiving updates

webhookVerifyTokenstring required

Token for verifying webhook

includeMediaboolean

Include media in messages.upsert event payload as base64 string

syncFullHistoryboolean

Sync full history of messages on connection.

groupsEnabledboolean

Enable full group message processing. When false, group messages are accumulated and sent as activity summaries.

autoPresenceSubscribeboolean

Automatically subscribe to presence updates when sending/receiving messages or typing status to/from a contact. Subscriptions are ephemeral and re-established automatically.

Example request

{
  "clientName": "My WhatsApp Client",
  "webhookUrl": "http://localhost:3026/whatsapp/+1234567890",
  "webhookVerifyToken": "a3f4b2"
}

Response

Connection initiated

Changes

    • breaking

      removed the media type application/json for the response with the status

    • breaking

      removed the success response with the status

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      added the non-success response with the status

    • info

      added the success response with the status