Maytapi icon

Maytapi

Integrate with Maytapi WhatsApp Unofficial API

Chat → Pin Chat

AI-generated

Overview

This node integrates with the Maytapi WhatsApp Unofficial API to manage WhatsApp chats programmatically. Specifically, the "Pin Chat" operation allows users to pin or unpin a conversation in their WhatsApp instance. Pinning a chat keeps it at the top of the chat list for easy access, while unpinning removes it from the pinned section.

Common scenarios where this node is beneficial include:

  • Prioritizing important conversations by pinning them automatically based on certain triggers.
  • Managing chat visibility in bulk workflows, such as unpinning chats after a campaign ends.
  • Automating chat organization without manual intervention in the WhatsApp app.

Practical example:

  • Automatically pin a customer support chat when a new ticket is created to ensure quick follow-up.
  • Unpin promotional group chats after a marketing event concludes.

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" Phone ID Source is selected).
Conversation ID The unique identifier of the conversation to pin/unpin. Format examples: 905301234567@c.us (user), 905301234567-1234567890@g.us (group).
Action Choose whether to "Pin" the conversation to the top or "Unpin" it from pinned chats.

Output

The node outputs a JSON object representing the response from the Maytapi API for the pin/unpin action. This typically includes success status and any relevant metadata returned by the API.

No binary data output is produced by this operation.

Example output structure:

{
  "success": true,
  "message": "Conversation pinned successfully"
}

Dependencies

  • Requires an active Maytapi WhatsApp API account with valid API credentials (an API key credential).
  • 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.

Troubleshooting

  • Phone ID Missing Error: If no Phone ID is provided (neither in credentials nor custom), the node will throw an error stating "Phone ID is required." Ensure you have set the Phone ID correctly.
  • Invalid Conversation ID: Providing an incorrect or malformed conversation ID may cause API errors. Verify the format matches user or group IDs as specified.
  • API Authentication Errors: If the API key credential is invalid or expired, requests will fail. Check your Maytapi API credentials and renew if necessary.
  • Unsupported Operation Error: Attempting to use this operation with a wrong resource or operation combination will result in an error. Confirm that "Chat" resource and "Pin Chat" operation are selected.
  • Network Issues: Connectivity problems can cause request failures. Ensure your server can reach the Maytapi API endpoint.

Links and References


If you need details about other operations or resources, feel free to ask!

Discussion