WhatsApp list messages via API: sections and rows

Send interactive list messages through the CRPRO Hub: sections, the 10-row total, title and description limits and reading list_reply from the webhook.

When a question has more than three answers, reply buttons run out of room and an interactive list takes over. The customer sees one button that opens a menu of up to ten rows, grouped in sections, and picks one. This tutorial sends a list through the CRPRO Hub, sets out where the Hub's limits differ from Meta's published ones and shows how the selection comes back.

What does a list message look like?

Short answer: type interactive with an interactive object of type list, a body, and an action containing a button label and one or more sections of rows.

curl -X POST https://crprohub.com/api/v1/channels/CHANNEL_UUID/messages \ -H "Authorization: Bearer hub_pk_EXAMPLE_NOT_REAL" \ -H "Idempotency-Key: pick-topic-conv-77" \ -H "Content-Type: application/json" \ -d '{ "to": "5521999999999", "type": "interactive", "interactive": { "type": "list", "header": { "type": "text", "text": "How can we help?" }, "body": { "text": "Choose the topic closest to your question." }, "footer": { "text": "Support" }, "action": { "button": "See topics", "sections": [ { "title": "Orders", "rows": [ { "id": "orders_status", "title": "Order status", "description": "Where is my order" }, { "id": "orders_cancel", "title": "Cancel an order" } ] }, { "title": "Account", "rows": [ { "id": "account_invoice", "title": "Invoices", "description": "Download a copy" } ] } ] } } }'

The reply is a 202 with a message_id. As with every interactive message, it is a free-form message, so it needs an open 24-hour service window. The authenticated call is covered in the quickstart.

What are the limits for lists?

Short answer: up to 10 rows in total across all sections, up to 10 sections, a button label of 20 characters, row and section titles of 24 characters, row descriptions of 72 characters and row ids of 200 characters.

ElementLimit in the Hub schema
Sections1 to 10
Rows1 to 10 per section, and 10 in total
Button label (action.button)1 to 20 characters
Section titleOptional, up to 24 characters
Row id1 to 200 characters
Row title1 to 24 characters
Row descriptionOptional, up to 72 characters
HeaderOptional, text only, up to 60 characters
Body1 to 1,024 characters
FooterOptional, up to 60 characters

Two differences from Meta's list reference deserve attention. Meta states a body limit of 4,096 characters for lists, while the Hub validates 1,024, so keep the body short enough for the Hub. Meta also marks the section title as required, while the Hub's schema leaves it optional. To stay safe with both, always send a section title. The Hub counts rows across sections, so two sections of six rows are refused with 400 INVALID_MESSAGE even though each section on its own would be valid.

How can a list be built from data?

Short answer: truncate nothing silently. Validate lengths and the total row count in code, and decide explicitly what to drop.

function listMessage(to, { header, body, button, sections }) { const rows = sections.reduce((n, s) => n + s.rows.length, 0) if (rows < 1 || rows > 10) throw new RangeError(`rows must be 1-10, got ${rows}`) if (button.length > 20) throw new RangeError('button label over 20 characters') for (const s of sections) { if (s.title.length > 24) throw new RangeError(`section title too long: ${s.title}`) for (const r of s.rows) { if (r.title.length > 24) throw new RangeError(`row title too long: ${r.title}`) if (r.description && r.description.length > 72) throw new RangeError(`description too long for ${r.id}`) } } return { to, type: 'interactive', interactive: { type: 'list', header: header ? { type: 'text', text: header } : undefined, body: { text: body }, action: { button, sections }, }, } }

A common design choice is to show the most requested options first and put a final row such as Talk to a person in a separate section. Since the cap is ten rows, a long catalogue needs a different approach, for instance a first list of categories and a second list that depends on the category chosen.

How does the selected row come back?

Short answer: as a message.received event of type interactive, with a list_reply object holding the id, title and description of the row. Compare the id.

Meta's list reference states that the inbound message has interactive.type list_reply, with the row id you defined in interactive.list_reply.id and the selected title and description. It also includes a context object. In the Hub, the normalized event exposes the interactive content under data.content.interactive, and the raw Meta message sits in data.message. The webhooks reference describes the envelope and the two payload modes.

function readSelection(event) { const i = event.data.content?.interactive if (i?.type === 'list_reply') return i.list_reply.id if (i?.type === 'button_reply') return i.button_reply.id return null } const ROUTES = { orders_status: (ctx) => sendOrderStatus(ctx), orders_cancel: (ctx) => startCancellation(ctx), account_invoice: (ctx) => sendLatestInvoice(ctx), } const id = readSelection(event) if (id && ROUTES[id]) await ROUTES[id](ctx)

What if there are more than ten options?

Short answer: split the choice in two steps. Send a list of categories first, then a second list with the options of the category the customer picked.

The ten-row cap is a platform limit, not something to engineer around by sending several lists at once. A two-step menu keeps each list short and fits the way people scan a phone screen. The first list has row ids such as cat_orders and cat_account; when one arrives, your handler looks up the options for that category and sends the second list, with ids that carry both levels, for example orders_status. Keep a small piece of state, or encode the category in the second-level ids, so a late tap on an old list is still understood.

const MENU = { cat_orders: [ { id: 'orders_status', title: 'Order status' }, { id: 'orders_cancel', title: 'Cancel an order' }, ], cat_account: [ { id: 'account_invoice', title: 'Invoices' }, { id: 'account_email', title: 'Change email' }, ], } async function onSelection(id, ctx) { if (MENU[id]) { // first step done: show the second list for this category return send(listMessage(ctx.to, { body: 'Pick one option.', button: 'Options', sections: [{ title: 'Options', rows: MENU[id] }], }), `menu-${ctx.conversationId}-${id}`) } return ROUTES[id]?.(ctx) }

Which errors can occur when sending lists?

Short answer: 400 INVALID_MESSAGE for anything the schema rejects, 429 RATE_LIMITED when you exceed the send limits, and failed statuses afterwards for window or recipient problems.

The synchronous rejections are the easy ones: too many rows, a title longer than 24 characters, an empty sections array or an extra field. They come back immediately and nothing is queued. The 60 messages per minute per channel limit and the 120 requests per minute per organization and credential limit apply to lists like any other send, and a 429 should be retried with backoff, reusing the same Idempotency-Key. Problems that Meta finds later, such as a send outside the 24-hour window, are reported in message.status events, so the checks in your logs should include both the HTTP status and the later webhook.

How should a menu with lists be structured?

Short answer: keep it shallow, label rows with the customer's words and always provide a way to reach a person.

  • Order rows by frequency, not by your org chart.
  • Use descriptions for the detail that titles cannot fit in 24 characters.
  • Use sections to separate topics, not to hide a long flat list.
  • Treat every id as a versioned contract; do not reuse an id for a different meaning.
  • Handle typed text as well: the customer may ignore the menu.

Because the Hub rejects invalid lists synchronously, errors in the structure show up in development as 400 responses. Failures that come from the window or the recipient arrive later as message.status events.

How can lists be kept readable?

Short answer: short titles, useful descriptions, a sensible order and no more sections than the topic needs.

A row title has 24 characters, which forces choices about wording. Put the distinguishing word first, so truncation on small screens does not hide it, and use the 72-character description for the detail the title cannot hold. The order matters more than people expect: customers tend to pick near the top. Resist the temptation to fill all ten rows just because they are available; a menu of five clear options often performs better than ten similar ones. If the content is long, the two-step approach described above keeps each list focused.

  • Lead with the distinguishing word in each title.
  • Use descriptions for detail, not for repeating the title.
  • Order rows by how often they are chosen.
  • Use two or three sections at most.
  • Test the list on a small phone screen.

How should a list menu be introduced?

Short answer: begin with the five most common intents, watch which rows are chosen and adjust the order and wording from real data.

A menu is easy to build and hard to get right at the first attempt. Launch with fewer rows than the maximum, record the id of every selection and review the counts after a representative period. Rows that nobody chooses are candidates for removal or for a different title, while a row chosen far more than others may deserve its own shortcut. Because ids are stable, you can rename a title without breaking the handler, so wording experiments carry little risk. Keep an escape row for talking to a person, so a customer whose need is not listed is not stranded.

  • Record the selected row id for every list reply.
  • Review counts and reorder rows from the data.
  • Rename titles freely; keep ids stable.
  • Always offer a way out to a person.
  • Retire rows by removing them, not by reusing their ids.

Frequently asked questions

How many options can a list hold?

Ten rows in total across all sections. The Hub rejects a list with more, even if each section is within the per-section limit.

Is the section title required?

The Hub's schema makes it optional, but Meta's reference marks it as required. Send a section title in every section to avoid depending on that difference.

What is the maximum body length for a list at the Hub?

1,024 characters. Meta's reference states 4,096 for lists, but the Hub validates the lower figure, so use it.

How can the application tell which row the customer picked?

Read interactive.list_reply.id in the inbound event. The id is the value you set on the row; the title and description are also returned but are labels.

Fontes

Documentação oficial da Meta, conferida em 31 de outubro de 2026.