GREEN-API for WhatsApp icon

GREEN-API for WhatsApp

Send and receive WhatsApp messages using Green-API.

Sending → sendFileByUpload

AI-generated

Summary

Send a file to a specified chat in WhatsApp by uploading it directly.

Inputs

  • chatId (required) — The chat identifier where the file will be sent, formatted as '79000000000@c.us'.
  • quotedMessageId — (optional) The ID of a message to be quoted.
  • caption — (optional) A caption to be included with the file.
  • fileName (required) — The name of the file being sent, e.g. 'image.jpg'.
  • filePath (required) — The local path to the file on the server, e.g. 'C:\Users\admin\Images\image.jpg'.

Output shape

no body — success/failure only

Ensure the file exists at the specified filePath and the chatId is valid.

Discussion