Describe the bug
Joining a WhatsApp group using the documented endpoint fails with HTTP 500
on the WEBJS engine.
The invite code is valid because groups/join-info successfully returns
the group information, but groups/join fails inside whatsapp-web.js.
The issue reproduces on both WAHA 2026.7.1 and 2026.8.2.
Version
Get the WAHA version by calling GET /api/version
{
"version": "2026.8.2",
"engine": "WEBJS",
"tier": "CORE",
"browser": "/usr/bin/chromium",
"platform": "linux/x64",
"worker": {
"id": null
}
}
Try to update to
the latest version before
creating an issue!
Steps
To Reproduce Steps to reproduce the behavior:
-
Start an authenticated WEBJS session.
-
Obtain a valid WhatsApp group invite link.
-
Verify the invite:
GET /api/{session}/groups/join-info?code=REDACTED
-
The endpoint returns HTTP 200 with valid group information.
-
Attempt to join:
POST /api/{session}/groups/join
The endpoint returns HTTP 500:
Cannot read properties of undefined (reading 'joinGroupViaInvite')
Expected behavior
The account should join the group, or a membership approval request should
be created when admin approval is enabled
Docker Logs
{
"level": 30,
"req": {
"method": "GET",
"url": "/api/{session}/groups/join-info?code=<REDACTED_INVITE_CODE>",
"query": {
"code": "<REDACTED_INVITE_CODE>"
}
},
"res": {
"statusCode": 200
},
"responseTime": 426,
"msg": "request completed"
}
{
"level": 30,
"req": {
"method": "GET",
"url": "/api/sessions/{session}/me"
},
"res": {
"statusCode": 200
},
"responseTime": 1,
"msg": "request completed"
}
{
"level": 30,
"req": {
"method": "GET",
"url": "/api/{session}/lids/pn/<REDACTED_PHONE>%40c.us"
},
"res": {
"statusCode": 200
},
"responseTime": 4,
"msg": "request completed"
}
{
"level": 30,
"req": {
"method": "POST",
"url": "/api/{session}/groups/join"
},
"res": {
"statusCode": 500
},
"err": {
"type": "Error",
"message": "Cannot read properties of undefined (reading 'joinGroupViaInvite')",
"stack": "TypeError: Cannot read properties of undefined (reading 'joinGroupViaInvite')\n at WebjsClientCore.acceptInvite (/app/node_modules/whatsapp-web.js/src/Client.js:2134:21)\n at GroupsController.joinGroup (/app/dist/api/groups.controller.js:43:20)"
},
"responseTime": 13,
"msg": "request errored"
}
Describe the bug
Joining a WhatsApp group using the documented endpoint fails with HTTP 500
on the WEBJS engine.
The invite code is valid because
groups/join-infosuccessfully returnsthe group information, but
groups/joinfails inside whatsapp-web.js.The issue reproduces on both WAHA 2026.7.1 and 2026.8.2.
Version
Get the WAHA version by calling
GET /api/version{ "version": "2026.8.2", "engine": "WEBJS", "tier": "CORE", "browser": "/usr/bin/chromium", "platform": "linux/x64", "worker": { "id": null } }Try to update to
the latest version before
creating an issue!
Steps
To Reproduce Steps to reproduce the behavior:
Start an authenticated WEBJS session.
Obtain a valid WhatsApp group invite link.
Verify the invite:
GET /api/{session}/groups/join-info?code=REDACTED
The endpoint returns HTTP 200 with valid group information.
Attempt to join:
POST /api/{session}/groups/join
The endpoint returns HTTP 500:
Cannot read properties of undefined (reading 'joinGroupViaInvite')
Expected behavior
The account should join the group, or a membership approval request should
be created when admin approval is enabled
Docker Logs
{
"level": 30,
"req": {
"method": "GET",
"url": "/api/{session}/groups/join-info?code=<REDACTED_INVITE_CODE>",
"query": {
"code": "<REDACTED_INVITE_CODE>"
}
},
"res": {
"statusCode": 200
},
"responseTime": 426,
"msg": "request completed"
}
{
"level": 30,
"req": {
"method": "GET",
"url": "/api/sessions/{session}/me"
},
"res": {
"statusCode": 200
},
"responseTime": 1,
"msg": "request completed"
}
{
"level": 30,
"req": {
"method": "GET",
"url": "/api/{session}/lids/pn/<REDACTED_PHONE>%40c.us"
},
"res": {
"statusCode": 200
},
"responseTime": 4,
"msg": "request completed"
}
{
"level": 30,
"req": {
"method": "POST",
"url": "/api/{session}/groups/join"
},
"res": {
"statusCode": 500
},
"err": {
"type": "Error",
"message": "Cannot read properties of undefined (reading 'joinGroupViaInvite')",
"stack": "TypeError: Cannot read properties of undefined (reading 'joinGroupViaInvite')\n at WebjsClientCore.acceptInvite (/app/node_modules/whatsapp-web.js/src/Client.js:2134:21)\n at GroupsController.joinGroup (/app/dist/api/groups.controller.js:43:20)"
},
"responseTime": 13,
"msg": "request errored"
}