curl -X POST "https://backend.conversales.in/api/v1/createTemplate" \
-H "X-API-Key: 3kJ9mP2nQ8rT5vW7xY1zA4bC6dE8fG0hI" \
-H "Content-Type: application/json" \
-d '{
"name": "order_confirmation",
"category": "UTILITY",
"language": "en",
"components": [
{
"type": "HEADER",
"format": "TEXT",
"text": "Order #{{1}} confirmed",
"example": {
"header_text_named_params": [
{ "param_name": "order_id", "example": "#12345" }
]
}
},
{
"type": "BODY",
"text": "Hi {{1}}, your order for {{2}} has been confirmed and will arrive by {{3}}.",
"example": {
"body_text_named_params": [
{ "param_name": "customer_name", "example": "Jane" },
{ "param_name": "product_name", "example": "Wireless earbuds" },
{ "param_name": "delivery_date", "example": "2025-11-05" }
]
}
},
{
"type": "BUTTONS",
"buttons": [
{ "text": "View Order", "type": "URL", "url": "https://shop.example.com/orders/12345" },
{ "text": "Contact Support", "type": "PHONE_NUMBER", "phone_number": "+15551234567" }
]
}
]
}'
{
"statusCode": 200,
"message": "Template created successfully",
"data": {
"templateId": "template_123456",
"name": "welcome_message",
"status": "PENDING",
"category": "MARKETING"
}
}
Create a new WhatsApp message template
curl -X POST "https://backend.conversales.in/api/v1/createTemplate" \
-H "X-API-Key: 3kJ9mP2nQ8rT5vW7xY1zA4bC6dE8fG0hI" \
-H "Content-Type: application/json" \
-d '{
"name": "order_confirmation",
"category": "UTILITY",
"language": "en",
"components": [
{
"type": "HEADER",
"format": "TEXT",
"text": "Order #{{1}} confirmed",
"example": {
"header_text_named_params": [
{ "param_name": "order_id", "example": "#12345" }
]
}
},
{
"type": "BODY",
"text": "Hi {{1}}, your order for {{2}} has been confirmed and will arrive by {{3}}.",
"example": {
"body_text_named_params": [
{ "param_name": "customer_name", "example": "Jane" },
{ "param_name": "product_name", "example": "Wireless earbuds" },
{ "param_name": "delivery_date", "example": "2025-11-05" }
]
}
},
{
"type": "BUTTONS",
"buttons": [
{ "text": "View Order", "type": "URL", "url": "https://shop.example.com/orders/12345" },
{ "text": "Contact Support", "type": "PHONE_NUMBER", "phone_number": "+15551234567" }
]
}
]
}'
{
"statusCode": 200,
"message": "Template created successfully",
"data": {
"templateId": "template_123456",
"name": "welcome_message",
"status": "PENDING",
"category": "MARKETING"
}
}
MARKETING, UTILITY, or AUTHENTICATIONen, en_US)Show Component Object Properties
HEADER, BODY, FOOTER, BUTTONSTEXT, IMAGE, VIDEO, DOCUMENT,
LOCATIONShow Example Properties
Show Button Object Properties
URL, PHONE_NUMBER, QUICK_REPLY, COPY_CODE,
FLOW, MPM, OTP, VOICE_CALLONE_TAP, ZERO_TAP, COPY_CODEcurl -X POST "https://backend.conversales.in/api/v1/createTemplate" \
-H "X-API-Key: 3kJ9mP2nQ8rT5vW7xY1zA4bC6dE8fG0hI" \
-H "Content-Type: application/json" \
-d '{
"name": "order_confirmation",
"category": "UTILITY",
"language": "en",
"components": [
{
"type": "HEADER",
"format": "TEXT",
"text": "Order #{{1}} confirmed",
"example": {
"header_text_named_params": [
{ "param_name": "order_id", "example": "#12345" }
]
}
},
{
"type": "BODY",
"text": "Hi {{1}}, your order for {{2}} has been confirmed and will arrive by {{3}}.",
"example": {
"body_text_named_params": [
{ "param_name": "customer_name", "example": "Jane" },
{ "param_name": "product_name", "example": "Wireless earbuds" },
{ "param_name": "delivery_date", "example": "2025-11-05" }
]
}
},
{
"type": "BUTTONS",
"buttons": [
{ "text": "View Order", "type": "URL", "url": "https://shop.example.com/orders/12345" },
{ "text": "Contact Support", "type": "PHONE_NUMBER", "phone_number": "+15551234567" }
]
}
]
}'
{
"statusCode": 200,
"message": "Template created successfully",
"data": {
"templateId": "template_123456",
"name": "welcome_message",
"status": "PENDING",
"category": "MARKETING"
}
}