WhatsApp · Schema

TextMessage

TextMessage from WhatsApp API

Properties

Name Type Description
body string Message text
preview_url boolean Set true to render URL previews
View JSON Schema on GitHub

JSON Schema

whatsapp-cloud-api-text-message-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/whatsapp/refs/heads/main/json-schema/whatsapp-cloud-api-text-message-schema.json",
  "title": "TextMessage",
  "description": "TextMessage from WhatsApp API",
  "type": "object",
  "properties": {
    "body": {
      "type": "string",
      "description": "Message text",
      "maxLength": 4096,
      "example": "Hello from WhatsApp!"
    },
    "preview_url": {
      "type": "boolean",
      "description": "Set true to render URL previews",
      "default": false,
      "example": true
    }
  },
  "required": [
    "body"
  ]
}