-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
When calling the /api/{session}/channels endpoint using the WEBJS engine, the API returns a 500 Internal Server Error. This seems to be related to a breaking change in the WhatsApp Web internal structure that whatsapp-web.js (and WAHA) uses to fetch channel information.
Side effect: Unable to send messages to @newsletter
Version
{
"version": "2026.1.3",
"engine": "WEBJS",
"tier": "CORE",
"browser": "/usr/bin/chromium",
"platform": "linux/x64"
}Steps
Steps to Reproduce
- Start WAHA with WEBJS engine.
- Authenticate a session (e.g., default).
- Make a GET request to /api/default/channels.
- See error response.
Expected behavior
The API should return a list of WhatsApp Channels for the session.
Actual behavior
The API returns a 500 Error with the message: Cannot read properties of undefined (reading 'getModelsArray').
Requests - Responses
{
"statusCode": 500,
"timestamp": "2026-02-02T18:46:33.736Z",
"exception": {
"message": "Cannot read properties of undefined (reading 'getModelsArray')",
"name": "TypeError",
"stack": "TypeError: Cannot read properties of undefined (reading 'getModelsArray')\n at window.WWebJS.getChannels (evaluate at WPage.evaluate (/app/dist/core/engines/webjs/WPage.js:13:36), <anonymous>:631:59)\n at evaluate (evaluate at WPage.evaluate (/app/dist/core/engines/webjs/WPage.js:13:36), <anonymous>:1:39)\n at #evaluate (/app/node_modules/puppeteer-core/lib/cjs/puppeteer/cdp/ExecutionContext.js:391:56)\n at async ExecutionContext.evaluate (/app/node_modules/puppeteer-core/lib/cjs/puppeteer/cdp/ExecutionContext.js:277:16)\n at async IsolatedWorld.evaluate (/app/node_modules/puppeteer-core/lib/cjs/puppeteer/cdp/IsolatedWorld.js:100:16)\n at async CdpFrame.evaluate (/app/node_modules/puppeteer-core/lib/cjs/puppeteer/api/Frame.js:362:20)\n at async CdpPage.evaluate (/app/node_modules/puppeteer-core/lib/cjs/puppeteer/api/Page.js:818:20)\n at async WPage.evaluate (/app/dist/core/engines/webjs/WPage.js:13:20)\n at async WebjsClientCore.getChannels (/app/node_modules/whatsapp-web.js/src/Client.js:1191:26)\n at async WhatsappSessionWebJSCore.channelsList (/app/dist/core/engines/webjs/session.webjs.core.js:886:22)\n at async descriptor.value (/app/dist/core/abc/activity.js:9:20)"
},
"request": {
"path": "/api/default/channels",
"method": "GET",
"query": {}
},
"version": {
"version": "2026.1.3",
"engine": "WEBJS",
"tier": "CORE",
"browser": "/usr/bin/chromium",
"platform": "linux/x64"
}
}Docker Log
{"level":30,"time":1770058074325,"pid":48,"hostname":"dcc6367043b1","reqId":244,"req":{"id":244,"method":"GET","url":"/api/default/channels","query":{},"params":{"path":["api","default","channels"]}},"res":{"statusCode":500},"err":{"type":"Error","message":"Cannot read properties of undefined (reading 'getModelsArray')","stack":"TypeError: Cannot read properties of undefined (reading 'getModelsArray')\n at window.WWebJS.getChannels (evaluate at WPage.evaluate (/app/dist/core/engines/webjs/WPage.js:13:36), <anonymous>:631:59)\n at evaluate (evaluate at WPage.evaluate (/app/dist/core/engines/webjs/WPage.js:13:36), <anonymous>:1:39)\n at #evaluate (/app/node_modules/puppeteer-core/lib/cjs/puppeteer/cdp/ExecutionContext.js:391:56)\n at async ExecutionContext.evaluate (/app/node_modules/puppeteer-core/lib/cjs/puppeteer/cdp/ExecutionContext.js:277:16)\n at async IsolatedWorld.evaluate (/app/node_modules/puppeteer-core/lib/cjs/puppeteer/cdp/IsolatedWorld.js:100:16)\n at async CdpFrame.evaluate (/app/node_modules/puppeteer-core/lib/cjs/puppeteer/api/Frame.js:362:20)\n at async CdpPage.evaluate (/app/node_modules/puppeteer-core/lib/cjs/puppeteer/api/Page.js:818:20)\n at async WPage.evaluate (/app/dist/core/engines/webjs/WPage.js:13:20)\n at async WebjsClientCore.getChannels (/app/node_modules/whatsapp-web.js/src/Client.js:1191:26)\n at async WhatsappSessionWebJSCore.channelsList (/app/dist/core/engines/webjs/session.webjs.core.js:886:22)\n at async descriptor.value (/app/dist/core/abc/activity.js:9:20)","name":"TypeError"},"responseTime":5,"msg":"request errored"}
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working