Actions55
- Message Actions
- Contact Actions
- Chat Actions
- Group Actions
- Queue Actions
- Account Actions
- Session Actions
- Session Control Actions
- Call Actions
Chat → Favorite Chat
AI-generatedOverview
The node integrates with the Maytapi WhatsApp Unofficial API to manage WhatsApp chats and perform various chat-related actions. Specifically, the "Favorite Chat" operation allows users to add or remove a chat from their favorites list. This is useful for prioritizing important conversations or quickly accessing frequently used chats.
Practical scenarios include:
- Marking key customer support chats as favorites for quick retrieval.
- Removing chats from favorites when they are no longer a priority.
- Automating chat management workflows based on business logic.
Properties
| Name | Meaning |
|---|---|
| Phone ID Source | Select how to provide the Phone ID: either "From Credentials" (uses stored credentials) or "Custom" (enter manually). |
| Phone ID | The WhatsApp instance Phone ID to use (required if "Custom" is selected as Phone ID Source). |
| Conversation ID | The unique identifier of the conversation to favorite/unfavorite. Format examples: user phone number with @c.us suffix or group ID with @g.us suffix. |
| Action | Whether to "Add" the chat to favorites or "Remove" it from favorites. |
Output
The output JSON contains the response from the Maytapi API after performing the favorite/unfavorite action on the specified chat. It typically includes success status and any relevant data returned by the API about the updated chat state.
No binary data output is produced by this operation.
Example output structure:
{
"success": true,
"message": "Chat added to favorites"
}
or
{
"success": true,
"message": "Chat removed from favorites"
}
Dependencies
- Requires an API key credential for the Maytapi WhatsApp API.
- The Phone ID must be provided either via credentials or custom input.
- The node makes HTTP requests to the Maytapi API endpoint
https://api.maytapi.com/api. - Proper configuration of the Maytapi API credentials in n8n is necessary.
Troubleshooting
- Missing Phone ID: If neither credentials nor custom Phone ID is provided, the node will throw an error stating that the Phone ID is required.
- Invalid Conversation ID: Ensure the conversation ID is correctly formatted (e.g.,
905301234567@c.usfor individual chats or905301234567-1234567890@g.usfor groups). - API Errors: Any errors returned by the Maytapi API (such as invalid action types or unauthorized access) will be surfaced as error messages. Verify API key validity and permissions.
- Action Type Errors: Only "add" or "remove" are valid actions; other values will cause errors.
Links and References
This summary covers the "Favorite Chat" operation under the "Chat" resource, detailing its purpose, inputs, outputs, dependencies, and common troubleshooting tips.