N8N Tools - Uazapi icon

N8N Tools - Uazapi

Complete Uazapi integration - Premium WhatsApp API with advanced messaging and automation

Overview

This node integrates with the Uazapi WhatsApp API to manage and interact with WhatsApp instances, messages, media, contacts, groups, and webhooks. Specifically, for the Instance - Get Chats operation, it retrieves all active chats from a configured WhatsApp instance.

Use cases include:

  • Monitoring active chat sessions on a WhatsApp instance.
  • Fetching chat metadata for analytics or automation workflows.
  • Integrating WhatsApp chat data into CRM or support systems.

Example: Automatically retrieve all active chats to trigger follow-up actions or notifications based on ongoing conversations.

Properties

Name Meaning
Additional Fields Optional extra parameters to customize the request. For this operation, no specific fields are used but the collection is available for extensibility.

The provided input properties JSON defines "Additional Fields" with options like Reply to Message ID, Delay, Disable Link Preview, and Mention Users, but these are not applicable for the Instance - Get Chats operation as it only requires the instance identifier internally.

Output

The output is a JSON object containing the response from the Uazapi API endpoint /v1/chats. This typically includes an array of active chat objects with details such as chat IDs, participants, last message timestamps, and other metadata relevant to each chat session.

No binary data is returned by this operation.

Example output structure (simplified):

{
  "chats": [
    {
      "id": "chat-id-123",
      "name": "Contact or Group Name",
      "lastMessageTimestamp": "2024-06-01T12:34:56Z",
      "unreadCount": 2,
      ...
    },
    ...
  ]
}

Dependencies

  • Requires an API key credential for authenticating with the Uazapi WhatsApp API.
  • Needs configuration of the API base URL, API token, and instance ID within the node credentials.
  • The node sends requests through a proxy service hosted at https://n8ntools.io/api/v1/proxy/uazapi which requires an additional API key for access.

Troubleshooting

  • Common issues:

    • Invalid or expired API token or instance ID will cause authentication failures.
    • Network connectivity problems to the proxy or Uazapi endpoints.
    • Insufficient permissions or incorrect instance configuration may result in empty or error responses.
  • Error messages:

    • "Unknown resource: instance": Indicates the resource parameter was set incorrectly.
    • HTTP 401 Unauthorized: Check API token and credentials.
    • HTTP 404 Not Found: Instance ID might be invalid or the instance is not active.
  • Resolutions:

    • Verify and update API credentials and instance ID.
    • Ensure the WhatsApp instance is properly connected and active.
    • Confirm network access to the proxy and Uazapi services.

Links and References

Discussion