Actions12
- Sesiones Actions
- Mensajería Actions
- Chats y Mensajes Actions
Overview
This node allows sending various types of messages through the "Expertos en IA" API, specifically focusing here on sending voice audio messages within chats. It is useful for automating communication workflows where audio messages need to be sent programmatically, such as customer support follow-ups, notifications, or interactive voice responses.
For the Enviar Audio (Voz) operation under the Mensajería resource, the node sends an audio file (voice message) to a specified chat by providing the chat ID and a URL pointing to the audio file. Optionally, it can reply to a specific message in the chat.
Practical examples:
- Sending a voice greeting or announcement to a customer.
- Delivering audio instructions or alerts automatically.
- Responding with voice notes in chatbots or automated messaging systems.
Properties
| Name | Meaning |
|---|---|
| ID del Chat | The unique identifier of the chat where the audio message will be sent (e.g., 12345@c.us). |
| URL del Audio | The direct URL to the audio file to send as a voice message (must be accessible). |
| Responder a Mensaje | Optional ID of a message in the chat to which this audio message should reply. |
Output
The node outputs a JSON object containing the response from the Expertos en IA API after attempting to send the audio message. This typically includes details about the sent message, such as message ID, status, timestamps, or any error information if the request failed.
No binary data output is produced by this node; all results are returned as JSON.
Example output structure (simplified):
{
"messageId": "abc123",
"status": "sent",
"chatId": "12345@c.us",
"timestamp": 1680000000
}
Dependencies
- Requires an active API key credential for the Expertos en IA service.
- Needs network access to the provided audio file URL.
- The node makes HTTP requests to
https://api.expertosenia.com/api/sendVoice. - Proper session management via a session name (defaulted to
"default"if not specified).
Troubleshooting
- Invalid chat ID: Ensure the chat ID is correctly formatted and corresponds to an existing chat.
- Audio URL inaccessible: The URL must be publicly accessible or reachable by the API server; otherwise, the message will fail to send.
- Missing or invalid API key: Verify that the API key credential is set up correctly in n8n.
- Empty or incorrect reply_to ID: If replying to a message, ensure the message ID exists; otherwise, omit this property or leave it empty.
- API errors: The node returns error details in the output JSON if the API call fails. Check the error message and stack trace for debugging.
Links and References
- Expertos en IA API Documentation
- n8n official documentation on creating custom nodes