Create a new WhatsApp message template, or update an existing one.
hsm_id to create a new template.hsm_id as a query parameter to update an existing template.Templates must be approved by WhatsApp before they can be used. After creation, templates enter a PENDING state until reviewed.
Side effect: Enqueues a template sync job on success to update Kapso’s local template cache.
Project API key for authentication. This is the recommended authentication method.
Get your API key from the Kapso dashboard under Project Settings > API Keys.
WhatsApp Business Account ID
Template ID to update.
Request body for template creation or update.
name, language, category, and components
are required.hsm_id in the query string and provide
the fields you want to change.Template name (lowercase, underscore-separated)
"order_confirmation"
Language code (e.g., en, en_US)
"en_US"
Template category
AUTHENTICATION, MARKETING, UTILITY "UTILITY"
Format for template parameters (defaults to POSITIONAL if omitted).
NAMED: Parameters use unique names wrapped in double curly brackets (e.g., {{first_name}}, {{order_number}}). Values can appear in any order in send payloads.
POSITIONAL: Parameters use ordered array indices starting from 1 (e.g., {{1}}, {{2}}). Values must appear in order in send payloads.
NAMED, POSITIONAL "NAMED"
Template components. Supported types:
HEADER - Optional component at top. Formats: TEXT (1 param), IMAGE, VIDEO, DOCUMENT, LOCATION
BODY - Required text component. Supports multiple parameters (positional or named)
FOOTER - Optional text-only component. No parameters supported
BUTTONS - Optional interactive components. Types: QUICK_REPLY (10 max), PHONE_NUMBER (1 max), URL (2 max), COPY_CODE (1 max), OTP, CATALOG, MPM, FLOW