Skip to main content
GET
/
v1
/
templates
/
{templateId}
Get template
curl --request GET \
  --url https://api.zavu.dev/v1/templates/{templateId} \
  --header 'Authorization: Bearer <token>'
{
  "id": "<string>",
  "name": "order_confirmation",
  "language": "en",
  "body": "Hi {{1}}, your order {{2}} has shipped.",
  "category": "UTILITY",
  "status": "draft",
  "variables": [
    "<string>"
  ],
  "headerType": "<string>",
  "headerContent": "<string>",
  "footer": "<string>",
  "buttons": [
    {
      "type": "<string>",
      "text": "<string>",
      "url": "<string>",
      "phoneNumber": "<string>"
    }
  ],
  "whatsapp": {
    "templateName": "<string>",
    "namespace": "<string>",
    "status": "<string>"
  },
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

templateId
string
required

Response

Template details.

id
string
required
name
string
required

Template name (must match WhatsApp template name).

Example:

"order_confirmation"

language
string
required

Language code.

Example:

"en"

body
string
required

Template body with variables: {{1}}, {{2}}, etc.

Example:

"Hi {{1}}, your order {{2}} has shipped."

category
enum<string>
required

WhatsApp template category.

Available options:
UTILITY,
MARKETING,
AUTHENTICATION
status
enum<string>
default:draft
Available options:
draft,
pending,
approved,
rejected
variables
string[]

List of variable names for documentation.

headerType
string

Type of header (text, image, video, document).

headerContent
string

Header content (text or media URL).

Footer text for the template.

buttons
object[]

Template buttons.

whatsapp
object

WhatsApp-specific template information.

createdAt
string<date-time>
updatedAt
string<date-time>