# Whatsapp

Your Toolhouse AI Worker can connect to Whatsapp using 17 specialized tools.

## Auth Connection

This service requires an auth connection to use its tools. You can set this up in your Toolhouse dashboard under [Auth Connections](https://toolhouse.app/auth-connections?authkit_slugs=whatsapp).

## Tools (17)

### `Whatsapp Create Message Template`

Integration name: **WHATSAPP\_CREATE\_MESSAGE\_TEMPLATE**

Create a new message template for the WhatsApp Business Account. Templates must be approved by WhatsApp before they can be used. Templates are required for marketing messages and messages sent outside the 24-hour window.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter    | Type   | Required | Example | Description                                                                                                                                                                              |
| ------------ | ------ | :------: | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `name`       | string |     ✅    | —       | Unique template name. Must be lowercase, alphanumeric with underscores only. Maximum 512 characters. Example: 'order\_confirmation\_v1'.                                                 |
| `category`   | string |     ✅    | —       | Template category. AUTHENTICATION: for OTP/verification codes. MARKETING: for promotional content (requires opt-in). UTILITY: for transactional updates like order status, appointments. |
| `language`   | string |     ✅    | —       | Template language code in ISO 639-1 format with country code. Examples: 'en\_US' (US English), 'es\_ES' (Spanish), 'pt\_BR' (Brazilian Portuguese).                                      |
| `components` | array  |     ✅    | —       | List of template components. Must include at least one BODY component. Can optionally include one HEADER and one BUTTONS component.                                                      |

***

### `Whatsapp Delete Message Template`

Integration name: **WHATSAPP\_DELETE\_MESSAGE\_TEMPLATE**

Delete a message template from the WhatsApp Business Account by name. This permanently removes the template and it cannot be recovered. When you delete a template by name, all templates with that name across all languages will be deleted. Names of deleted templates cannot be reused for 30 days. Important: Only delete templates that are no longer needed, as this operation is irreversible.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter | Type   | Required | Example | Description                                                                                             |
| --------- | ------ | :------: | ------- | ------------------------------------------------------------------------------------------------------- |
| `name`    | string |     ✅    | —       | The name of the template to delete. This will delete all templates with this name across all languages. |
| `waba_id` | string |          | —       | WhatsApp Business Account ID to target. If not provided, the first WABA owned by the business is used.  |

***

### `Whatsapp Get Business Profile`

Integration name: **WHATSAPP\_GET\_BUSINESS\_PROFILE**

Get the business profile information for a WhatsApp Business phone number. This includes business details like description, address, website, and contact info.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter         | Type   | Required | Example | Description                                                                        |
| ----------------- | ------ | :------: | ------- | ---------------------------------------------------------------------------------- |
| `fields`          | string |          | —       | Comma-separated list of fields to retrieve. Default includes all available fields. |
| `phone_number_id` | string |     ✅    | —       | The phone number ID to get the business profile for.                               |

***

### `Whatsapp Get Media Info`

Integration name: **WHATSAPP\_GET\_MEDIA\_INFO**

Get metadata and download URL for uploaded WhatsApp media. Returns media ID, download URL (valid for 5 minutes), MIME type, SHA256 hash, and file size. The download URL can be used to retrieve the actual media file.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter  | Type   | Required | Example | Description                                                                                              |
| ---------- | ------ | :------: | ------- | -------------------------------------------------------------------------------------------------------- |
| `media_id` | string |     ✅    | —       | The WhatsApp media ID to retrieve information for (obtained from media upload or webhook notifications). |

***

### `Whatsapp Get Message Templates`

Integration name: **WHATSAPP\_GET\_MESSAGE\_TEMPLATES**

Get all message templates for the WhatsApp Business Account. Templates are required for sending messages outside the 24-hour window and for marketing/utility messages.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter         | Type    | Required | Example | Description                                                                                                                                                                               |
| ----------------- | ------- | :------: | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `after`           | string  |          | —       | Cursor for pagination to get templates after this cursor.                                                                                                                                 |
| `limit`           | integer |          | —       | The maximum number of templates to retrieve. Default is 25.                                                                                                                               |
| `status`          | string  |          | —       | Filter by template status: APPROVED, PENDING, REJECTED, DISABLED, PAUSED, LIMIT\_EXCEEDED.                                                                                                |
| `waba_id`         | string  |          | —       | Optional: WhatsApp Business Account ID to query. If not provided, uses the waba\_id from your connection configuration. Only provide this if you need to override the configured WABA ID. |
| `category`        | string  |          | —       | Filter by template category: AUTHENTICATION, MARKETING, UTILITY.                                                                                                                          |
| `language`        | string  |          | —       | Filter by language code (e.g., 'en\_US', 'es\_ES').                                                                                                                                       |
| `name_or_content` | string  |          | —       | Filter templates by name or content substring.                                                                                                                                            |

***

### `Whatsapp Get Phone Number`

Integration name: **WHATSAPP\_GET\_PHONE\_NUMBER**

Retrieve detailed information about a specific WhatsApp Business phone number. Returns phone number details including verification status, quality rating, display number, verified business name, throughput limits, and webhook configuration. Use this to check phone number status, settings, and capabilities. To get available phone number IDs, first call WHATSAPP\_GET\_PHONE\_NUMBERS.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter         | Type   | Required | Example | Description                                                                                                                                                                                                                                                               |
| ----------------- | ------ | :------: | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `fields`          | string |          | —       | Comma-separated list of fields to retrieve. Available fields: id, display\_phone\_number, verified\_name, code\_verification\_status, quality\_rating, platform\_type, throughput, webhook\_configuration, last\_onboarded\_time. Default retrieves all available fields. |
| `phone_number_id` | string |     ✅    | —       | The WhatsApp Business phone number ID (e.g., '901139066420489'). Get this from the WHATSAPP\_GET\_PHONE\_NUMBERS action.                                                                                                                                                  |

***

### `Whatsapp Get Phone Numbers`

Integration name: **WHATSAPP\_GET\_PHONE\_NUMBERS**

Retrieve all phone numbers registered to your WhatsApp Business Account. Returns phone number IDs, display numbers, verification status, quality ratings, and messaging throughput limits. Use the phone number ID from the response to send WhatsApp messages via other API actions.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter | Type    | Required | Example | Description                                                                                                                                                                               |
| --------- | ------- | :------: | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `limit`   | integer |          | —       | Maximum number of phone numbers to return per page (1-100). Use lower values for faster responses or when you only need a few numbers.                                                    |
| `waba_id` | string  |          | —       | Optional: WhatsApp Business Account ID to query. If not provided, uses the waba\_id from your connection configuration. Only provide this if you need to override the configured WABA ID. |

***

### `Whatsapp Get Template Status`

Integration name: **WHATSAPP\_GET\_TEMPLATE\_STATUS**

Get the status and details of a specific message template. This is useful for checking if a template has been approved, rejected, or is still pending review.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter     | Type   | Required | Example | Description                                                                                                                                                                                                                                |
| ------------- | ------ | :------: | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `fields`      | string |          | —       | Comma-separated list of fields to retrieve. Valid fields include: id, name, status, category, language, components, previous\_category, parameter\_format, quality\_score, rejected\_reason. If not specified, returns all default fields. |
| `template_id` | string |     ✅    | —       | The ID of the template to check the status for.                                                                                                                                                                                            |

***

### `Whatsapp Send Contacts`

Integration name: **WHATSAPP\_SEND\_CONTACTS**

Send contacts WhatsApp number. Note: The message will be delivered to the recipient only if they have initiated a conversation first.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter         | Type   | Required | Example                                                                                                                                                                                                                                      | Description                                                                                                                                                                                                             |
| ----------------- | ------ | :------: | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `contacts`        | array  |     ✅    | `[{"org":{"title":"Engineer","company":"Acme Inc"},"name":{"last_name":"Smith","first_name":"Jane","formatted_name":"Jane Smith"},"emails":[{"type":"WORK","email":"jane@example.com"}],"phones":[{"type":"CELL","phone":"+14155551234"}]}]` | List of contacts to send. Each contact requires a name object with formatted\_name, first\_name, and last\_name. Optional fields: addresses, birthday (YYYY-MM-DD), emails, org (company/department/title), and phones. |
| `to_number`       | string |     ✅    | —                                                                                                                                                                                                                                            | The phone number to send the contacts to, including the country code without the + sign.                                                                                                                                |
| `phone_number_id` | string |     ✅    | —                                                                                                                                                                                                                                            | The phone number ID from which to send the contacts.                                                                                                                                                                    |

***

### `Whatsapp Send Interactive Buttons`

Integration name: **WHATSAPP\_SEND\_INTERACTIVE\_BUTTONS**

Send an interactive button message with up to 3 reply buttons to a WhatsApp user. Interactive button messages allow recipients to quickly respond by tapping predefined buttons. Perfect for yes/no questions, multiple choice selections, quick actions, or call-to-action scenarios. IMPORTANT REQUIREMENTS: - The recipient must be a registered WhatsApp user - The recipient must have messaged your business first within the last 24 hours (WhatsApp's customer service window) - You can include 1-3 buttons per message - Each button can have a title (max 20 chars) and unique ID (max 256 chars) Use cases: Customer service menus, appointment confirmations, feedback collection, product selections.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter             | Type   | Required | Example | Description                                                                                                                                                                                                                |
| --------------------- | ------ | :------: | ------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `buttons`             | array  |     ✅    | —       | List of 1-3 interactive buttons. Each button must have a unique ID and title.                                                                                                                                              |
| `body_text`           | string |     ✅    | —       | Main message text explaining the purpose or question for the buttons (maximum 1024 characters).                                                                                                                            |
| `to_number`           | string |     ✅    | —       | Recipient's phone number in international format without the + sign (e.g., '14155552345' for a US number). The recipient must be a registered WhatsApp user and must have messaged your business within the last 24 hours. |
| `footer_text`         | string |          | —       | Optional footer text displayed at the bottom of the message, below the buttons (maximum 60 characters).                                                                                                                    |
| `header_text`         | string |          | —       | Optional header text displayed at the top of the message (maximum 60 characters).                                                                                                                                          |
| `phone_number_id`     | string |     ✅    | —       | The WhatsApp Business phone number ID from which to send the message. Get this from the WHATSAPP\_GET\_PHONE\_NUMBERS action.                                                                                              |
| `reply_to_message_id` | string |          | —       | Optional message ID to reply to. Use this to create a threaded conversation by replying to a specific previous message.                                                                                                    |

***

### `Whatsapp Send Interactive List`

Integration name: **WHATSAPP\_SEND\_INTERACTIVE\_LIST**

Send an interactive list message to a WhatsApp number. List messages display a menu of options organized into sections. Users tap a button to view the list and select one option. Perfect for product catalogs, service menus, or guided workflows. Supports up to 10 sections with up to 10 items per section (100 total options). Note: Recipients must have messaged you first within the last 24 hours to receive this message.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter             | Type   | Required | Example | Description                                                                                                                                                                                                                                                                                            |
| --------------------- | ------ | :------: | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `sections`            | array  |     ✅    | —       | Sections containing list items (maximum 10 sections, minimum 1 section).                                                                                                                                                                                                                               |
| `body_text`           | string |     ✅    | —       | Body text for the list message (up to 1024 characters).                                                                                                                                                                                                                                                |
| `to_number`           | string |     ✅    | —       | The recipient's phone number in international format without the + sign (e.g., '15551234567' for a US number). Note: The recipient must have initiated a conversation with your WhatsApp Business account within the last 24 hours to receive this message.                                            |
| `button_text`         | string |     ✅    | —       | Text for the list button (up to 20 characters).                                                                                                                                                                                                                                                        |
| `footer_text`         | string |          | —       | Footer text for the list message (up to 60 characters).                                                                                                                                                                                                                                                |
| `header_text`         | string |          | —       | Header text for the list message (up to 60 characters).                                                                                                                                                                                                                                                |
| `phone_number_id`     | string |     ✅    | —       | The Meta-assigned numeric ID for the WhatsApp Business phone number to send from. This is NOT the actual phone number itself - it is a numeric ID (e.g., '901139066420489') assigned by Meta. Obtain it using WHATSAPP\_GET\_PHONE\_NUMBERS action which returns the 'id' field for each phone number. |
| `reply_to_message_id` | string |          | —       | The ID of the message to reply to (optional).                                                                                                                                                                                                                                                          |

***

### `Whatsapp Send Location`

Integration name: **WHATSAPP\_SEND\_LOCATION**

Send a location message with coordinates, name, and address to a WhatsApp user. This action allows you to share location information through WhatsApp Business API. The location message includes latitude/longitude coordinates, a location name, and address. Important: The recipient must have an active WhatsApp account. Additionally, you can only send free-form messages (like location messages) within the 24-hour customer service window after the recipient has initiated contact with your business. Outside this window, you must use approved message templates. Common error codes: - 133010: Recipient's phone number doesn't have a WhatsApp account - 131026: Message undeliverable (recipient may have blocked your business number) - 131047: Re-engagement message (outside 24-hour window, need to use template)

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter         | Type   | Required | Example | Description                                                                                                                                                                                             |
| ----------------- | ------ | :------: | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `name`            | string |     ✅    | —       | The name or title of the location (e.g., 'San Francisco City Hall', 'Golden Gate Bridge'). This will be displayed to the recipient.                                                                     |
| `address`         | string |     ✅    | —       | The full address of the location (e.g., '1 Dr Carlton B Goodlett Pl, San Francisco, CA 94102'). This provides context to the recipient about the location.                                              |
| `latitude`        | string |     ✅    | —       | The latitude coordinate of the location in decimal degrees format (e.g., '37.7749' for San Francisco). Range: -90 to 90.                                                                                |
| `longitude`       | string |     ✅    | —       | The longitude coordinate of the location in decimal degrees format (e.g., '-122.4194' for San Francisco). Range: -180 to 180.                                                                           |
| `to_number`       | string |     ✅    | —       | The recipient's WhatsApp phone number in international format without the + sign or spaces (e.g., '14155238886' for US number). The recipient must have a WhatsApp account registered with this number. |
| `phone_number_id` | string |     ✅    | —       | The WhatsApp Business phone number ID from which to send the location message. This is the ID of your WhatsApp Business phone number, not the phone number itself.                                      |

***

### `Whatsapp Send Media`

Integration name: **WHATSAPP\_SEND\_MEDIA**

Send a media message to a WhatsApp number. Note: The media will be delivered to the recipient only if they have texted first.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter         | Type   | Required | Example | Description                                                                                                                                                                                                                                                                                            |
| ----------------- | ------ | :------: | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `link`            | string |     ✅    | —       | The publicly accessible HTTPS URL of the media file to send. The URL must be accessible by WhatsApp servers and serve the appropriate content-type header. For media uploads, use WHATSAPP\_UPLOAD\_MEDIA action to get a media ID and use WHATSAPP\_SEND\_MEDIA\_BY\_ID instead.                      |
| `caption`         | string |          | —       | Optional caption text to accompany the media (max 1024 characters). Only supported for 'image', 'video', and 'document' media types. Captions are NOT supported for 'audio' and 'sticker' types.                                                                                                       |
| `to_number`       | string |     ✅    | —       | The phone number to send the media to, including the country code without the + sign.                                                                                                                                                                                                                  |
| `media_type`      | string |     ✅    | —       | The type of media to send. Options: 'audio' (voice messages), 'document' (PDFs, docs), 'image' (PNG, JPG), 'sticker' (WebP animated stickers), 'video' (MP4 videos). Note: Only 'image', 'video', and 'document' types support captions.                                                               |
| `phone_number_id` | string |     ✅    | —       | The Meta-assigned numeric ID for the WhatsApp Business phone number to send from. This is NOT the actual phone number itself - it is a numeric ID (e.g., '901139066420489') assigned by Meta. Obtain it using WHATSAPP\_GET\_PHONE\_NUMBERS action which returns the 'id' field for each phone number. |

***

### `Whatsapp Send Media By Id`

Integration name: **WHATSAPP\_SEND\_MEDIA\_BY\_ID**

Send media using a media ID from previously uploaded media. This is more efficient than sending media by URL as the media is already on WhatsApp servers. Use upload\_media action first to get the media ID. Note: The media will be delivered to the recipient only if they have texted first.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter             | Type   | Required | Example | Description                                                                           |
| --------------------- | ------ | :------: | ------- | ------------------------------------------------------------------------------------- |
| `caption`             | string |          | —       | Caption for the media (not supported for audio and sticker).                          |
| `filename`            | string |          | —       | Filename for document media.                                                          |
| `media_id`            | string |     ✅    | —       | The media ID from uploaded media (use upload\_media action to get this ID).           |
| `to_number`           | string |     ✅    | —       | The phone number to send the media to, including the country code without the + sign. |
| `media_type`          | string |     ✅    | —       | The type of media to send: audio, document, image, sticker, or video.                 |
| `phone_number_id`     | string |     ✅    | —       | The phone number ID from which to send the media.                                     |
| `reply_to_message_id` | string |          | —       | The ID of the message to reply to (optional).                                         |

***

### `Whatsapp Send Message`

Integration name: **WHATSAPP\_SEND\_MESSAGE**

Send a text message to a WhatsApp user. Important: The recipient phone number must be registered on WhatsApp and must have initiated a conversation with your business within the last 24 hours, OR you must use a template message (see WHATSAPP\_SEND\_TEMPLATE\_MESSAGE) for the first message outside the 24-hour window. For test accounts, recipient numbers must be added to the test recipient list in Meta Business Suite before sending messages.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter         | Type    | Required | Example | Description                                                                                                                                                                                                                                                                                            |
| ----------------- | ------- | :------: | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `text`            | string  |     ✅    | —       | The text content of the message to send. Supports Unicode characters including emojis. Maximum length: 4096 characters.                                                                                                                                                                                |
| `to_number`       | string  |     ✅    | —       | The recipient's WhatsApp phone number in international format without the + sign (e.g., '14155551234' for a US number). The number must be registered on WhatsApp.                                                                                                                                     |
| `message_id`      | string  |          | —       | Optional: The WhatsApp message ID (wamid) to reply to. When provided, this message will be sent as a reply to the specified message, creating a quoted reply thread. Leave empty to send a regular message.                                                                                            |
| `preview_url`     | boolean |          | —       | Set to True to show a preview card for URLs in the message. When enabled, WhatsApp will fetch and display URL metadata (title, description, image) for the first URL in the message. Default: False.                                                                                                   |
| `phone_number_id` | string  |     ✅    | —       | The Meta-assigned numeric ID for the WhatsApp Business phone number to send from. This is NOT the actual phone number itself - it is a numeric ID (e.g., '712594308615206') assigned by Meta. Obtain it using WHATSAPP\_GET\_PHONE\_NUMBERS action which returns the 'id' field for each phone number. |

***

### `Whatsapp Send Template Message`

Integration name: **WHATSAPP\_SEND\_TEMPLATE\_MESSAGE**

Send a template message to a WhatsApp number.

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter         | Type   | Required | Example | Description                                                                                                                            |
| ----------------- | ------ | :------: | ------- | -------------------------------------------------------------------------------------------------------------------------------------- |
| `to_number`       | string |     ✅    | —       | The phone number to send the template message to, including the country code without the + sign.                                       |
| `components`      | array  |          | —       | Template components with parameters to fill template variables. Use 'body' type with text parameters for simple variable substitution. |
| `language_code`   | string |          | —       | The language code for the template.                                                                                                    |
| `template_name`   | string |     ✅    | —       | The name of the template to be sent.                                                                                                   |
| `phone_number_id` | string |     ✅    | —       | The phone number ID from which to send the template message.                                                                           |

***

### `Whatsapp Upload Media`

Integration name: **WHATSAPP\_UPLOAD\_MEDIA**

Upload media files (images, videos, audio, documents, stickers) to WhatsApp servers. The uploaded media gets a media ID that can be used in send\_media or other messaging actions. Supported formats: - Images: JPEG, PNG (max 5MB) - Videos: MP4, 3GPP (max 16MB) - Audio: AAC, M4A, AMR, MP3, OGG (max 16MB) - Documents: PDF, DOC, DOCX, PPT, PPTX, XLS, XLSX (max 100MB) - Stickers: WebP (max 500KB, 512x512 pixels)

#### Parameters

Your Toolhouse AI worker will automatically pass these parameters as input when the tool is called.

| Parameter         | Type   | Required | Example | Description                                                                   |
| ----------------- | ------ | :------: | ------- | ----------------------------------------------------------------------------- |
| `media_type`      | string |     ✅    | —       | Type of media being uploaded: image, video, audio, document, or sticker.      |
| `file_to_upload`  | object |     ✅    | —       | Media file to upload to WhatsApp (max 16MB for most types, 100MB for videos). |
| `phone_number_id` | string |     ✅    | —       | The phone number ID to upload media for.                                      |

***


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.toolhouse.ai/toolhouse/integrations/whatsapp.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
