Actions39
- Chatbot Actions
- Contact Actions
- Message Actions
- Panel Actions
- Sequence Actions
- Session Actions
Overview
The node interacts with the WTS Chat API to manage contacts and retrieve contact data. Specifically, the "Get All Contacts" operation fetches a list of contacts from the system, supporting filtering, sorting, pagination, and inclusion of additional details such as tags or custom fields.
This node is useful in scenarios where you need to synchronize contact lists, analyze customer data, or automate workflows based on contact attributes. For example, you could use it to:
- Retrieve all active contacts created within a specific date range.
- Fetch contacts including their tags and custom fields for segmentation.
- Paginate through large contact lists automatically to process or export them.
Properties
| Name | Meaning |
|---|---|
| Include Details | Choose which additional details to include with each contact. Options: Tags, CustomFields |
| Status | Filter contacts by status. Options: Active, Archived, Blocked, Undefined (default is Active) |
| CreatedAt.After | Filter contacts created after this date/time (format: YYYY-MM-DD hh:mm, timezone-aware) |
| CreatedAt.Before | Filter contacts created before this date/time |
| UpdatedAt.After | Filter contacts updated after this date/time |
| UpdatedAt.Before | Filter contacts updated before this date/time |
| Auto Pagination | Enable automatic pagination to fetch multiple pages of results |
| Max Pages | Maximum number of pages to fetch when auto pagination is enabled (1 to 100) |
| Page Number | The page number to retrieve when auto pagination is disabled |
| Page Size | Number of contacts per page (1 to 100) |
| Order By | Field name to sort the contacts by |
| Order Direction | Sort direction. Options: Ascending, Descending |
Output
The output is an array of JSON objects, each representing a contact retrieved from the WTS Chat API. Each contact object includes standard contact fields such as name, email, phone number, and optionally additional details like tags and custom fields if requested.
If the node is configured to paginate automatically, the output will contain contacts aggregated across multiple pages up to the specified maximum.
No binary data is output by this operation.
Dependencies
- Requires an API key credential for authenticating with the WTS Chat API.
- The node uses the WTS Core Service internally to perform API calls related to contacts.
- No additional environment variables are required beyond the API key credential configuration.
Troubleshooting
- Invalid Email Error: When creating a contact, if the email format is invalid, the node throws an error "Invalid email!". Ensure emails conform to standard formats.
- Empty Contact ID: For operations requiring a contact ID, providing an empty or missing ID will cause errors prompting to fill in the field.
- API Errors: Any API-related errors from the WTS Chat service are wrapped and thrown as node errors. Check your API key validity and network connectivity.
- Pagination Limits: If auto pagination is enabled but max pages is set too low, not all contacts may be retrieved. Adjust max pages accordingly.
- Date Filters: Date/time filters must be provided in the correct format (YYYY-MM-DD hh:mm) and consider time zone settings to avoid unexpected filtering results.
Links and References
- WTS Chat API Documentation (general reference for API endpoints)
- n8n documentation on Using Credentials
- n8n documentation on Pagination