Meta Cloud API: no MESSAGES_UPDATE for delivery statuses — TypeError reading 'name' when the status payload carries contacts without profile
Nobody has claimed this yet.
Assessment
- Difficulty
- 1/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 88/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- typescript
Research direction
Start in src/api/integrations/channel/meta/whatsapp.business.service.ts around line 390, then follow the statuses handling later in messageHandle. Verify that status callbacks with contacts lacking profile no longer throw and that MESSAGES_UPDATE processing can complete for sent, delivered, and read events.
Written by the indexing model from the issue text.
Description
What happens
On the Meta Cloud API channel (whatsapp.business.service.ts), no MESSAGES_UPDATE webhook is ever
emitted for delivery statuses. Every sent / delivered / read callback from Meta is logged and then
lost:
ERROR [ChannelStartupService] TypeError: Cannot read properties of undefined (reading 'name')
at Ls.messageHandle (/evolution/dist/main.js:231:774)
at Ls.eventHandler (/evolution/dist/main.js:231:9623)
Three of these per outgoing message (one per ack). Incoming messages are unaffected.
Cause
messageHandle reads the push name before anything else:
if (received.contacts) pushName = received.contacts[0].profile.name;
This assumes contacts only ever appears on an incoming-message event, where the entry does carry
profile.name. Meta's status callback now also carries a contacts array — but without profile, only
the recipient identity (the user_id that comes along with pricing_model: "PMP" / recipient_user_id):
{
"messaging_product": "whatsapp",
"metadata": { "display_phone_number": "<redacted>", "phone_number_id": "<redacted>" },
"contacts": [ { "wa_id": "<redacted>", "user_id": "BR.<redacted>" } ],
"statuses": [
{
"id": "wamid.<redacted>",
"status": "delivered",
"timestamp": "1787583812",
"recipient_id": "<redacted>",
"recipient_user_id": "BR.<redacted>",
"pricing": { "billable": true, "pricing_model": "PMP", "category": "marketing", "type": "regular" }
}
]
}
So received.contacts[0].profile is undefined, and reading .name throws. The if (received.statuses)
block that would emit MESSAGES_UPDATE sits ~350 lines further down inside the same try, so it is never
reached; the catch only logs. pushName is not used on the status path at all.
main and 2.4.0-rc2 still have the same unguarded line.
Suggested fix
- if (received.contacts) pushName = received.contacts[0].profile.name;
+ if (received.contacts) pushName = received.contacts?.[0]?.profile?.name;
Happy to open a PR if that is welcome.
Steps to reproduce
- Meta Cloud API channel instance,
messagesfield subscribed in the Meta app,MESSAGES_UPDATEin the
instance webhook events,DATABASE_SAVE_DATA_NEW_MESSAGE=true. - Send any message (template or plain text) through the instance.
- Meta posts the
sent/delivered/readcallbacks; each one logs theTypeErrorabove and no
MESSAGES_UPDATEwebhook is delivered, nor is aMessageUpdaterow written.
Environment
- Evolution API
2.3.7(Docker imageevoapicloud/evolution-api:v2.3.7), Postgres + Redis - Channel: Meta Cloud API (WhatsApp Business Platform), Graph API official cloud
- Observed 2026-08-24
- Dominant language
- TypeScript
- Stars
- 9.6k
- Forks
- 7.3k
- PR merge metrics
- No merged PRs in 30d
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from evolution-foundation/evolution-api
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
evolution-foundation/evolution-api#2700 · 1 comment ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
Difficulty 1/5 1-3 hours Newbie friendliness 76/100
All issues in evolution-foundation/evolution-api
Similar issues
-
calcite-components needs triage refactor
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Esri/calcite-design-system#15203 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 91/100
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
Difficulty 1/5 Under an hour Newbie friendliness 95/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Automattic/studio#4908 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 90/100