Searches WhatsApp contacts based on a query. Returns all available contact information including name, phone number, WhatsApp ID, creation date, status, custom parameters, and other fields from the WATI API. Args: query: A search term to find matching contacts Returns: A list of contacts with all available contact information
Get WhatsApp messages matching specified criteria with optional context. Args: after: Optional ISO-8601 formatted string to only return messages after this date before: Optional ISO-8601 formatted string to only return messages before this date sender_phone_number: Optional phone number to filter messages by sender chat_waid: Optional WhatsApp ID (WAID) to filter messages by chat query: Optional search term to filter messages by content limit: Maximum number of messages to return (default 20) page: Page number for pagination (default 0) include_context: Whether to include messages before and after matches (default True) context_before: Number of messages to include before each match (default 1) context_after: Number of messages to include after each match (default 1)
Get WhatsApp chats matching specified criteria. Args: query: Optional search term to filter chats by name or WAID limit: Maximum number of chats to return (default 20) page: Page number for pagination (default 0) include_last_message: Whether to include the last message in each chat (default True) sort_by: Field to sort results by, either "last_active" or "name" (default "last_active")
Get WhatsApp chat metadata by WAID. Args: chat_waid: The WhatsApp ID (WAID) of the chat to retrieve include_last_message: Whether to include the last message (default True)
Get WhatsApp chat metadata by sender phone number. Args: sender_phone_number: The phone number to search for
Get the WhatsApp chat for the specified contact. Args: waid: The contact's WhatsApp ID (WAID) to search for limit: Maximum number of chats to return (default 20) page: Page number for pagination (default 0)
Send a WhatsApp message to a contact. Args: recipient: The recipient's phone number with country code but no + or other symbols (e.g., "85264318721") message: The message text to send Returns: A dictionary containing success status and a status message
Send a file such as a picture, raw audio, video or document via WhatsApp to the specified recipient. Args: recipient: The recipient's phone number with country code but no + or other symbols (e.g., "85264318721") media_path: The absolute path to the media file to send (image, video, document) Returns: A dictionary containing success status and a status message
Send any audio file as a WhatsApp audio message to the specified recipient. Args: recipient: The recipient's phone number with country code but no + or other symbols (e.g., "85264318721") media_path: The absolute path to the audio file to send Returns: A dictionary containing success status and a status message
Download media from a WhatsApp message and get the local file path. Args: message_id: The ID of the message containing the media chat_waid: The WhatsApp ID (WAID) of the chat containing the message Returns: A dictionary containing success status, a status message, and the file path if successful
Send an interactive WhatsApp message with buttons. Args: recipient: The recipient's phone number with country code but no + or other symbols (e.g., "85264318721") body_text: The main text content of the message buttons: List of button objects, each with 'text' key (and optionally 'id') header_text: Optional text to display in the header footer_text: Optional text to display in the footer header_image: Optional URL or local path to an image to display in the header header_video: Optional URL or local path to a video to display in the header header_document: Optional URL or local path to a document to display in the header Returns: A dictionary containing success status and a status message
Your Wati tenant ID
Your Wati authentication token
The base URL for the Wati API
Access and manage servers by signing in.