The Node.js SDK re-exports the WAJS namespace for TypeScript. This reference describes types from WA-JS 4.8.5-rc.0. For operations available on a connected Node.js client, see Whatsapp. For functions running inside WhatsApp Web, see the WA-JS browser API.
WPP.chat.sendListMessage('[number]@c.us', {
buttonText: 'Click Me!', //required
description: "Hello it's list message", //required
title: 'Hello user', //optional
footer: 'Click and choose one', //optional
sections: [{
title: 'Section 1',
rows: [{
rowId: 'rowid1',
title: 'Row 1',
description: "Hello it's description 1",
},{
rowId: 'rowid2',
title: 'Row 2',
description: "Hello it's description 2",
}]
}]
});
Send a list message