Class Section

java.lang.Object
com.whatsapp.api.domain.messages.Section

public class Section extends Object

Required for List Messages and Multi-Product Messages

  • products: Required for Multi-Product Messages - Array of product objects. There is a minimum of 1 product per section and a maximum of 30 products across all sections
  • rows: Required for List Messages - Contains a list of rows. You can have a total of 10 rows across your sections.
    - Each row must have a:
    • title: Required - Maximum length: 24 characters
    • ID: Required - Maximum length: 200 characters
    • description: Optional - Maximum length: 72 characters
  • title: Required if the message has more than one section - Title of the section
  • Field Details

    • title

      public String title
      The Title.
    • products

      public List<Product> products
      The Products.
    • rows

      public List<Row> rows
      The Rows.
  • Constructor Details

    • Section

      public Section()
  • Method Details

    • getTitle

      public String getTitle()
      Gets title.
      Returns:
      the title
    • setTitle

      public Section setTitle(String title)
      Sets title.
      Parameters:
      title - the title
      Returns:
      the title
    • getProducts

      public List<Product> getProducts()
      Gets product items.
      Returns:
      the product items
    • setProducts

      public Section setProducts(List<Product> products)
      Sets product items.
      Parameters:
      products - the products
      Returns:
      the product items
    • addProductItem

      public Section addProductItem(Product product)
      Add product item section.
      Parameters:
      product - the product
      Returns:
      the section
    • getRows

      public List<Row> getRows()
      Gets rows.
      Returns:
      the rows
    • setRows

      public Section setRows(List<Row> rows)
      Sets rows.
      Parameters:
      rows - the rows
      Returns:
      the rows
    • addRow

      public Section addRow(Row row)
      Add row section.
      Parameters:
      row - the row
      Returns:
      the section