# List WhatsApp templates

Source: https://docs.vlayers.ai/reference/channels/list-whats-app-templates

`GET /v1/channels/whatsapp/templates` · scope `channels:read`

Returns the message templates Meta has approved for one of your WhatsApp senders, with their variables. Read only: sending templates is not available yet, so outside WhatsApp's 24-hour window you cannot message a person until they write to you again.

Requires an API key with the `channels:read` scope.

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `bindingId` | query | string | yes | The WhatsApp sender to read templates for (from `GET /v1/channels`). Example: `"0192f5a9-2b3c-7d4e-9f5a-6b7c8d9e0f12"` |

## Request

cURL:

```bash
curl "https://api.vlayers.ai/v1/channels/whatsapp/templates?bindingId=$BINDING_ID" \
  -H "Authorization: Bearer $VOICELAYER_API_KEY"
```

TypeScript:

```ts
import { createVoiceLayerClient, listWhatsAppTemplates } from '@voicelayer/api';

const client = createVoiceLayerClient({ apiKey: process.env.VOICELAYER_API_KEY!, throwOnError: true });

const { data } = await listWhatsAppTemplates({
  client,
  query: {
    bindingId: process.env.BINDING_ID!
  }
});
console.log(data.templates);
```

Python:

```python
import os
import voicelayer

config = voicelayer.Configuration(access_token=os.environ["VOICELAYER_API_KEY"])
with voicelayer.ApiClient(config) as client:
    api = voicelayer.ChannelsApi(client)
    result = api.list_whats_app_templates(
        binding_id=os.environ["BINDING_ID"],
    )
    print(result.templates)
```

## Response `200`

```json
{
  "templates": [
    {
      "name": "order_ready",
      "language": "en_US",
      "category": "UTILITY",
      "status": "APPROVED",
      "variables": [
        "1"
      ]
    }
  ]
}
```
