# Error code when sending a WhatsApp Template Message via API

Are you trying to send a Template Message via API but you're receiving an error back? There are a few things you can check before sending a Template Message to avoid errors:&#x20;

* **You're using the correct API key.** Make sure that you're using a live key.&#x20;
* **You're sending along a Namespace ID.** This information is usually shared once your WhatsApp channel has been created. If you do not have this information, please contact support.&#x20;
* **Template Messages should be approved.** Go to your [WhatsApp template manager](https://dashboard.messagebird.com/en/whatsapp-template-manager/) and see if the Template Message has been approved.&#x20;
* **There's no error in the template name.** Go to your [WhatsApp template manager](https://dashboard.messagebird.com/en/whatsapp-template-manager/) to see which name was set up.&#x20;
* **The language matches the Template Message.**&#x20;
* **All parameters are completed.** If you register a message with 3 variables, make sure to add 3 variables in your API request as well.&#x20;

If after checking this the issue still persists, please reach out to our Support team via [this page](https://www.messagebird.com/contact)  with your API call and API request[.](mailto:support@message.com)


---

# 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.bird.com/connectivity-platform/troubleshooting/error-code-when-sending-a-whatsapp-template-message-via-api.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.
