LogoLogo
No-code docsResources
  • 🖥️Welcome to the Bird API Docs
  • API Access
    • Access Policies
    • Access Roles
    • API Authorization
    • Common API usage
  • Conversations API
    • API reference
      • Channel configuration
        • Get conversations configuration
        • Update conversations configuration
      • Conversations messaging
        • Create conversation message
        • List conversation messages
        • Get conversation message
        • Update conversation message
        • Delete conversation message
        • Create pre-signed upload
      • Conversations management
        • Create conversation
        • List conversations
        • Get conversation
        • Update conversation
        • Delete conversation
      • Conversation Participants
        • Add participant to conversation
        • List participants
        • Get participant by ID
        • Get participant by identifier key and value
        • Update participant by ID
        • Update participant by identifier key and value
        • Delete participant
        • List participant conversations by ID
        • List participant conversations by identifier key and value
      • Workspace settings
        • Get antispam setting
        • Update antispam setting
        • Create allow/block rule
        • Get allow/block rule
        • List allow/block rules
        • Update allow/block rule
        • Delete allow/block rule
        • Add allow/block rules in bulk
        • Get allow/block bulk upload status
      • Events
  • Collaborations API
    • API reference
      • Agent Management
      • Team Management
      • Feeds
      • Feed item activity
      • Tags
      • Automation Rules
      • Business Hours
      • Capacity Rules
      • Routing Queues
      • Skills
      • SLA Policies
      • Macros
      • Sender Profiles
      • Ticket fields
  • Channels API
    • Supported channels
      • Programmable WhatsApp
        • Sending WhatsApp messages
        • Customer service window
        • Receiving messages
        • Message interactions
        • WhatsApp ISV integration
          • Setting up your customer workspaces
            • API Access
            • Associating your Facebook solution ID and business ID with your Bird CRM Organization
            • Creating a workspace for your customer
            • Buying a number through Bird
            • Subscribing to channel created webhooks
          • WhatsApp channel onboarding
            • Setting up the WhatsApp Embedded flow
            • Install WhatsApp phone number in Bird CRM
            • Subscribe to channel webhooks
      • Programmable SMS
        • Installing an SMS channel
          • US 10DLC API Installation
          • Toll-Free Numbers Verification API
        • Sending SMS messages
        • Receiving messages
        • Twilio Exit API
          • Using Twilio PHP SDK
          • Using Twilio Go SDK
          • Using Twilio Ruby SDK
        • Sinch Exit API
      • Programmable RCS
        • Sending messages
        • Receiving messages
        • Message interactions
      • Programmable Email
        • Sending Emails
        • Receiving messages
        • Message status
        • Message interactions
      • Programmable Line
        • Sending messages
        • Receiving messages
        • Message interactions
      • Programmable Telegram
        • Sending messages
        • Receiving messages
        • Message interactions
    • Message types
      • Text
      • Images
      • Files
      • List
      • Carousel
      • Template
    • Message status and interactions
      • Message Failure Codes
      • Message Failure Sources
        • SMS Platform Extended Error Codes
    • Send batch messages
    • API reference
      • Channel Groups
      • Messaging
      • Channels management
      • Channel connectors
      • Navigators
      • Compliance Keywords Messages
      • Conversions Sharing
      • Events
    • Rate Limit
  • Voice API
    • Installing a Voice channel
    • Voice Calls API
      • Initiate an outbound call
      • List calls from a channel
      • Get a call
      • Update a call
      • Answer a call
      • Ring a call
      • Hangup a call
      • Play a message in a call
      • Say Text-To-Speech (TTS)
      • Gather DTMF from a call
      • Forward a call
      • Record a Call
      • Record a call session
      • Update a call recording
      • List call recordings of a call
      • Get a call recording
      • Get a call insights
      • Get calls log
    • Recordings API
      • List Recordings
      • Get a Recording
      • Delete a Recording
      • List recording storage metrics
    • Transcriptions API
      • Initiate a Transcription
      • List Transcriptions
      • Get a Transcription
      • Delete a Transcription
    • Voice webhooks
    • Flash Calling API
  • Verify API
    • Verify API: Quick Start
  • Contacts API
    • Tracking Contact Events
      • API Reference
        • Get configuration
        • Track events
    • API reference
      • Manage workspace contacts
        • Create a contact
        • Get a contact
        • List contacts
        • Search contact by identifier
        • Update a contact
        • Create or update a contact by identifier
        • Delete a contact
      • Manage contact identifiers
        • Create contact identifier
        • List contact identifiers
        • Delete contact identifier
      • Manage contact attribute definition
        • Create attribute definition
        • Get attribute definition
        • List attribute definitions
      • Manage contact lists
        • Create a list
        • Get a list
        • List lists
        • Update a list
        • Delete a list
        • Add contacts to a list
        • Get contact list memberships
        • List contacts in a list
        • Remove contacts from a list
      • Lookup
        • Network/Country information for a phone number
  • Numbers API
    • API reference
      • Search Available Numbers
      • Buy a Number
      • List your Numbers
      • Get Long Code Number Details
      • Manage Endpoint Subscriptions
        • Cancel Number Subscription
      • Manage Endpoint Compliance Requirements
        • List Workspace compliace Requirements
        • Get Workspace Compliace Requirements
        • Update Workspace Compliace Requirements
      • 10DLC Compliance
        • Brands - Organization
          • Create a brand
          • List all brands
          • Get a brand
          • Update a brand
          • Delete a brand
          • Create a brand vetting
        • Brands - workspace
          • Create a brand
          • List all brands
          • Get a brand
          • Update a brand
          • Delete a brand
          • Create a brand vetting
          • List brand vettings
        • Campaigns
          • Optional: acting as Reseller
          • Create a campaign
          • List all campaigns
          • Get a campaign
          • Update a campaign
          • Delete a campaign
        • TCR Enums
        • Events
      • Toll-Free Numbers Verification API
      • Long Code Numbers
      • Short Code Numbers
      • Alphanumeric Senders
      • Events
  • Know-Your-Customer (KYC) API
    • List KYC forms
    • Get KYC form
    • Create KYC form entry
    • Update KYC form entry
    • List KYC form entries
    • Get a KYC form entry details
  • Reporting API
    • API reference
      • Channel Metrics
      • Flow Run Metrics
      • Wallet Metrics
      • Campaign Metrics
      • Message Metrics
  • Accounts API
    • API reference
      • Current user
        • Change password
        • Presigned upload
        • Memberships
        • Sessions
        • Configurations
          • Groups
            • Keys
      • IAM policies
      • Organizations
        • Upload media
        • Profile
        • Workspaces
        • Users
        • Access keys
        • Organization roles
        • Organization policies
        • Teams
          • Members
        • Approvals
          • Runs
            • Reviews
        • Configurations
          • Groups
            • Keys
      • Region groups
  • Touchpoints API
    • Supported Projects
      • Whatsapp Approved Message Templates
        • Creating WhatsApp Message templates
          • Text template blocks
          • Blocks Documentation
    • API reference
      • Projects
      • Message Templates
  • Notifications API
    • API Reference
      • Webhook subscriptions
        • Create a webhook subscription
        • List available webhook events
        • Get a webhook subscription
        • List webhook subscriptions
        • Update a webhook subscription
        • Delete a webhook subscription
        • Verifying a webhook subscription
        • Webhook subscription logs
  • Knowledge Base (KB) API
    • API reference
      • Documents
      • Folders
        • Import
      • Search
      • Presigned upload
  • Email API
    • Transmissions
    • Metrics
    • Events
    • Recipient Validation
    • SMTP API
  • Connectivity platform migration guide
    • Channels API and Conversations API
    • Migrating conversations API actions
    • Migrating WhatsApp channels
  • Client SDKs
    • Applications
    • Contact Profiles
      • Signed Identity
    • Push notifications
      • Quick Start
      • Subscribe contacts to push notification campaigns
      • Notification Display Priority
    • Event Tracking
      • Quick Start
      • Track Events
        • App
        • Audiences
        • Conference
        • Ecommerce
        • Hospitality
        • Lists
        • Messaging
        • Payments
        • Subscription
        • Suppressions
        • Survey
        • Web
    • App Inbox
      • Quick Start
      • Usage
      • Subscribe contacts to app inbox campaigns
    • SDK Integration
      • Android SDK
        • Notification Interactions
      • Swift SDK
        • Notification Interactions
      • Web SDK
        • Quick Start
        • Usage
        • API Reference
          • IdentityManager
          • BirdSdkApi
          • BirdTracker
            • Ecommerce
            • Conference
            • Messaging
            • Suppressions
            • Subscription
            • Survey
            • Web
            • Audiences
        • Web Push Notifications
          • Notification Interactions
  • Quickstarts
    • Conversations
    • Send an SMS message
    • Send an Email message
    • Send a WhatsApp message
Powered by GitBook
On this page
  • Text
  • Header, Body, or Footer Blocks
  • Images
  • Header Block
  • Files
  • Header Block
  • Authentication body block
  • Actions
  • Link Action Block
  • Reply Action Block
  • Authentication Action Block
  • Message types and block structures
  • Block IDs

Was this helpful?

  1. Touchpoints API
  2. Supported Projects
  3. Whatsapp Approved Message Templates
  4. Creating WhatsApp Message templates

Blocks Documentation

This documentation provides an overview of the different blocks that can be added to a channel template for the WhatsApp platform. Each block serves a specific purpose and can be customized to create rich and interactive conversations with users. The following blocks are available:

Text

Header, Body, or Footer Blocks

  • Role: header, body, or footer

  • Purpose: Displays text content in the header, body, or footer section of the message.

  • Properties:

    • text: Specifies the text to be displayed. The maximum length varies depending on the role.

{
  "type": "text",
  "role": "body",
  "text": {
    "text": "Hey there!"
  },
  "id": "tY5sE17ZbfU8LmH0qRkOpN"
}

Images

Header Block

  • Role: header

  • Purpose: Displays an image in the header section of the message.

  • Properties:

    • mediaUrl: The URL of the image to be displayed.

    • altText: Alternative text to be shown if the image cannot be loaded.

{
  "type": "image",
  "role": "header",
  "image": {
    "mediaUrl": "https://example.com/image.jpg",
    "altText": "Image Alt Text"
  },
  "id": "7vY1pgyRZ7ETflSK46d5qL"
}

Files

Header Block

  • Role: header

  • Purpose: Displays a file attachment in the header section of the message.

  • Properties:

    • mediaUrl: The URL of the file to be attached.

    • contentType: The type of file, such as PDF, JPEG, PNG, or MP4.

    • filename: The name of the file.

    • altText: Alternative text to be shown if the file cannot be loaded.

{
  "type": "file",
  "role": "header",
  "file": {
    "mediaUrl": "https://example.com/file.pdf",
    "contentType": "application/pdf",
    "filename": "Sample File",
    "altText": "File Alt Text"
  },
  "id": "9B02RxTQq3UnLmY8EJgDKo"
}

Authentication body block

  • Purpose: Specifically used for the authentication message type to provide users with their code and information around code expiration.

  • Properties:

    • addSecurityDisclaimer: Specifies whether to include a security disclaimer.

    • expirationTime: The expiration time for the authentication process in days (1-90). Optional.

{
  "type": "authentication-body",
  "authenticationBody": {
    "addSecurityDisclaimer": true,
    "expirationTime": 30
  },
  "id": "rB523rS4PsGlt15NhwcZ8"
}

Actions

Link Action Block

  • Purpose: Displays a text message with a link that users can interact with.

  • Properties:

    • text: The text to be displayed as the message content.

    • url: The URL to which the link should navigate.

{
  "type": "link-action",
  "linkAction": {
    "text": "Click Here",
    "url": "https://example.com"
  },
  "id": "X7htGhJWu9l5dSe2rTqOZV"
}

Reply Action Block

  • Purpose: Displays a text message with a reply option for users.

  • Properties:

    • text: The text to be displayed as the message content.

    • payload: An optional payload to be sent back when the reply option is selected.

    • imageUrl: An optional image URL to be displayed alongside the text.

{
  "type": "reply-action",
  "replyAction": {
    "text": "Reply Button",
    "payload": "reply_payload",
    "imageUrl": "https://example.com/image.jpg"
  },
  "id": "aF5n1rS3DkGlm64IhOcX9P"
}

Authentication Action Block

  • Purpose: Displays a button that users can click to copy the authentication code.

  • Properties:

    • copyAuthenticationCodeText: The text to be displayed for copying the authentication code.

{
  "type": "authentication-action",
  "authenticationAction": {
    "copyAuthenticationCodeText": "Copy Code",
    "oneTap": {
      "oneTapText": "One-Tap Authentication",
      "androidPackageName": "com.example.app",
      "androidSignatureHash": "signature_hash"
    }
  },
  "id": "p3F9tltd046dRbSjS56q2A"
}

Message types and block structures

There are 4 main message types supported by WhatsApp Approved templates. Each message type is made up of a block structure:

Message Type
Content block structure

Text message

  • Must contain text body (only 1 is allowed)

  • Can contain only 1 text footer

  • Can contain only 1 of the following headers: text | image | file header

  • Can contain only 1 link action. Cannot be combined with reply actions.

  • Can contain up to 3 reply actions. Cannot be combined with a link action.

Image message

  • Must contain text body (only 1 is allowed)

  • Can contain only 1 image

  • Can contain only 1 text footer

  • Can contain only 1 link action. Cannot be combined with reply actions.

  • Can contain up to 3 reply actions. Cannot be combined with a link action.

File message

  • Must contain text body (only 1 is allowed)

  • Can contain only 1 file

  • Can contain only 1 text footer

  • Can contain only 1 link action. Cannot be combined with reply actions.

  • Can contain up to 3 reply actions. Cannot be combined with a link action.

Authentication message

  • Must contain an authentication body

  • Must contain an authentication action

Block IDs

Here are some guidelines and considerations regarding the IDs for blocks:

  1. Uniqueness: Each block should have a unique ID within the conversation. This ensures that no two blocks have the same identifier, avoiding conflicts or ambiguity.

  2. ID Format: IDs can be alphanumeric strings, often generated using unique identifiers, such as UUIDs (Universally Unique Identifiers). These IDs should be sufficiently long and complex to minimize the chance of collision.

  3. ID Assignment: IDs can be assigned during the initial creation of the block.

{
  "type": "text",
  "role": "footer",
  "text": {
    "text": "Bye!"
  },
  "id": "cbA0XdmkFDAbJiGfS41kK9"
}

In the example above, the block has an ID of "cbA0XdmkFDAbJiGfS41kK9". This ID serves as a unique identifier for the block within the conversation. Other blocks in the conversation would have their own unique IDs.

Last updated 8 months ago

Was this helpful?

oneTap: An optional object representing the one-tap authentication configuration. Includes oneTapText, androidPackageName, and androidSignatureHash properties. Read more .

here