Skip to main content
The Templates API gives you programmatic access to the message templates in a workspace — list approved templates for use in campaigns, or submit new templates for Meta’s review.
Templates approved in one language do not automatically apply to other languages. If you need to send the same template in multiple languages, submit a separate template for each language code (e.g. submit summer_sale_announcement once with "language": "en" and again with "language": "es").

GET /workspaces//templates

List all message templates in a workspace, with optional filtering by status, category, and pagination.

Path Parameters

string
required
The unique ID of the workspace whose templates you want to list.

Query Parameters

string
Filter templates by their Meta review status. Accepted values: pending, approved, rejected, paused.
string
Filter templates by category. Accepted values: marketing, utility, authentication.
integer
Page number to retrieve. Defaults to 1.
integer
Number of results per page. Defaults to 20. Maximum is 100.

Request

List approved marketing templates

Response


GET /workspaces//templates/

Retrieve the full details of a single template, including all components and, if the template was rejected, the rejection reason provided by Meta.

Path Parameters

string
required
The unique ID of the workspace.
string
required
The unique ID of the template to retrieve (e.g. tpl_3a1b2c4d5e).

Request

Get a template

Response


POST /workspaces//templates

Submit a new message template for Meta’s review. Templates are reviewed by Meta, typically within 24 hours. Once approved, they are available for use in messages and campaigns.

Path Parameters

string
required
The unique ID of the workspace to submit the template in.

Body Parameters

string
required
The template name. Must be lowercase with underscores and no spaces (e.g. order_confirmation_v1). This name is used when sending messages and cannot be changed after submission.
string
required
The template category, which affects Meta’s review criteria and messaging policies. Accepted values: marketing, utility, authentication.
string
required
The language code for this template (e.g. en, es, pt_BR, ar). Submit a separate template for each language you need.
array
required
An ordered array of component objects that define the template structure. Supported component types:

Request

Submit a template for approval

Response


DELETE /workspaces//templates/

Delete a template. Only templates with status rejected or draft can be deleted via the API. Templates with status approved or pending cannot be deleted from the API — manage those through the workspace dashboard.

Path Parameters

string
required
The unique ID of the workspace.
string
required
The unique ID of the template to delete.

Request

Delete a template

Response