Home Schema Example JSON Schema

WhatsApp Template Components

Type: array

WhatsApp template components based on the documentation.

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Component

Type: object

Individual component within a WhatsApp template.

No Additional Properties

Type: object

The following properties are required:

  • type
  • text
Type: object

The following properties are required:

  • type
  • format
Type: object

The following properties are required:

  • type
  • buttons

Type

Type: enum (of string)

Whether it is a HEADER, BODY, FOOTER, or BUTTONS.

Must be one of:

  • "HEADER"
  • "BODY"
  • "FOOTER"
  • "BUTTONS"

Format

Type: enum (of string)

The content type within the component.

Must be one of:

  • "TEXT"
  • "IMAGE"
  • "DOCUMENT"
  • "VIDEO"
  • "LOCATION"

Example

Type: object

An example provided by WhatsApp.

Text

Type: string

For text content.

Must be at least 1 characters long

Buttons

Type: array of object

For CTA and quick reply buttons

No Additional Items

Each item of this array must be:

Type: object
No Additional Properties

Type

Type: enum (of string)

The button type.

Must be one of:

  • "QUICK_REPLY"
  • "URL"
  • "PHONE_NUMBER"
  • "VOICE_CALL"

Text

Type: string

Text to display for the button.

Must be at least 1 characters long

Example

Type: object

An example provided by WhatsApp.

URL

Type: stringFormat: uri

URL for URL button.

Phone Number

Type: string

Phone number for PHONE_NUMBER buttons.

Must match regular expression: ^\+[\d]{5,}$