Affibot icon

Affibot

Send messages and manage WhatsApp via Affibot

Message → Send Document

AI-generated

Summary

Send a document to a WhatsApp recipient via Affibot.

Inputs

  • session (required) — The session ID of the device.
  • to (required) — Recipient JID (e.g. 628xxx@s.whatsapp.net).
  • text — Caption for the document.
  • documentUrl (required) — URL of the document to send.
  • documentName (required) — Filename for the document (e.g. report.pdf).
  • isGroup — Set to true if the recipient is a group.

Output shape

json

The API response from the /api/send-document endpoint.

Examples

Example 1: Send a PDF invoice to a customer.

Set Session ID to your device session, To to customer@s.whatsapp.net, Document URL to the file location, Document Name to invoice.pdf, and optionally add a caption in Text.

Links

Discussion