Templates API
LeadPattern Templates API: 7 endpoints with request parameters, response schemas, error codes and cURL, Node.js and Python examples.
POSTCreate Template
/templateSubmit a new WhatsApp message template to Meta for approval. Use {{variable_name}} syntax for dynamic placeholders.POSTCreate Authentication Template/template/authSubmit a new AUTHENTICATION/OTP template to Meta for approval. Meta auto-generates the body wording ("Your verification code is {{1}}.") and fixes the Copy Code button label — neither is customizable; only the security-recommendation line and code-expiry footer are configurable.GETList Templates/template?page=1&limit=10Retrieve paginated templates. Filter by category or search by name.GETGet Template Status/template/:name/statusLook up a single template's approval status (APPROVED, PENDING, REJECTED, PAUSED) by name.POSTPreview Template/template/:name/previewRender a template's resolved display text and raw component payload with variable values substituted. Omit a variable to get a bracketed placeholder like [customer_name] instead.PUTEdit Template/template/:nameEdit an APPROVED template's components. Meta re-reviews the template after an edit. Limited to 1 edit per 24 hours and 10 per month; AUTHENTICATION templates cannot be edited here.DELETEDelete Template/template/:nameDelete a template from Meta and mark it as deleted in the system.
