WAHA

Connect with Whatsapp HTTP API

Actions116

Overview

This node operation allows sending a file in a chat session. It is useful for automating the process of sharing files such as images, documents, or other media within a chat conversation. For example, it can be used to send a product brochure to a customer or share an image in a support chat.

Use Case Examples

  1. Sending an image file to a specific chat ID with an optional caption.
  2. Replying to a particular message in a chat by sending a file as a response.

Properties

Name Meaning
Session The chat session identifier used to send the file.
Chat Id The identifier of the chat where the file will be sent.
File The file object containing mimetype, filename, and URL of the file to be sent.
Reply To The ID of the message to which this file message is a reply.
Caption An optional caption to accompany the file being sent.
Request Options Additional settings for the request such as batching, SSL handling, proxy, and timeout.

Output

JSON

  • sentFileId - Identifier of the sent file message.
  • status - Status of the file sending operation.
  • chatId - The chat ID where the file was sent.

Dependencies

  • Requires an active chat session and valid chat ID to send files.
  • May require network access to the file URL provided.

Troubleshooting

  • Ensure the session and chat ID are valid and active; invalid IDs will cause failures.
  • File URL must be accessible and correctly formatted JSON; malformed JSON or inaccessible URLs will cause errors.
  • If SSL issues occur, consider enabling 'Ignore SSL Issues' option, but be aware of security risks.
  • Proxy settings must be correct if used; incorrect proxy configuration can block requests.
  • Timeouts can occur if the server is slow or unresponsive; adjust timeout settings accordingly.

Discussion