Skip to content

[BUG]sendStatus (image) accepted successfully but media unavailable/corrupted on receiver side — sendMedia to group with same file works fine #2649

Description

@camarguinhocap-max

📋 Bug Description

Descrição do problema
Ao enviar imagens via /message/sendStatus/{instance} (type: image), a API aceita a
requisição com sucesso (200, remoteJid: status@broadcast, mimetype: image/jpeg,
mediaKey/url válidos), mas ao visualizar o Status em outro dispositivo, aparece o erro:
"A imagem não está disponível porque há um erro no arquivo de imagem."

O mesmo arquivo, enviado via /message/sendMedia/{instance} para um grupo, é entregue
e renderiza normalmente. Isso indica que o problema está no processamento interno
específico do sendStatus, não no arquivo em si.

Possivelmente relacionado a #2056 e #1524, mas com evidência adicional de que o
sendMedia para grupo com o mesmo arquivo funciona corretamente — o que restringe o
problema ao processamento interno do sendStatus.

Ambiente

  • Evolution API versão: [preencher — confere no seu .env/painel]
  • Integração: Baileys
  • Self-hosted, Windows

Passos para reproduzir

  1. POST /message/sendStatus/{instance} com body:
    {"type":"image","content":"data:image/jpeg;base64,...","caption":"...","allContacts":true}
  2. Resposta retorna sucesso (200), com key.remoteJid = status@broadcast
  3. Status aparece na lista de Status do contato, mas ao abrir mostra "imagem não
    disponível" — testado em múltiplos dispositivos diferentes visualizando

Já testado e descartado como causa

  • Formato do arquivo (testado com JPEG e WebP, ambos falham)
  • Fonte da imagem (Amazon, Shopee, Mercado Livre — falha em todas, de forma inconsistente
    entre elas, não isolado a uma fonte específica)
  • Tamanho do arquivo (falha em imagens pequenas e grandes, ~90KB testado)
  • Envio via base64 com backgroundColor adicional (não resolveu)
  • Confirmado que o mesmo arquivo, mesmo caption, funciona normalmente via sendMedia
    para grupo — descarta problema no arquivo de origem

Resposta de sucesso recebida (exemplo, dados sensíveis removidos)
{
"key": {
"remoteJid": "status@broadcast",
"fromMe": true,
"id": "3EB049C98D7225D99C83E1"
},
"message": {
"imageMessage": {
"url": "https://mmg.whatsapp.net/...",
"mimetype": "image/jpeg",
"caption": "..."
}
},
"messageType": "imageMessage",
"status": "PENDING"
}

Comportamento esperado
A imagem enviada via sendStatus deveria ser renderizada corretamente para quem
visualiza o Status, da mesma forma que já acontece com sendMedia para grupos.

🔄 Steps to Reproduce

  1. POST /message/sendStatus/{instance} with body:
    {"type":"image","content":"data:image/jpeg;base64,...","caption":"...","allContacts":true}
  2. Response returns success (200), with key.remoteJid = status@broadcast
  3. Status appears in the contact's status list, but opening it shows "image not available" — tested across multiple different devices viewing it
  4. Same image file, same caption, sent via /message/sendMedia/{instance} to a group works normally

✅ Expected Behavior

The image sent via sendStatus should render correctly for whoever views the Status, the same way it already works with sendMedia for groups.

❌ Actual Behavior

The API accepts the request successfully (200, remoteJid: status@broadcast, mimetype: image/jpeg, valid mediaKey/url), but when viewing the Status on another device, this error appears: "A imagem não está disponível porque há um erro no arquivo de imagem" (image not available due to a file error). This indicates the issue is in sendStatus's internal processing, not the file itself.

Possibly related to #2056 and #1524, but with additional evidence that sendMedia to a group with the same exact file works correctly — narrowing the issue specifically to sendStatus.

Already tested and ruled out as the cause:

  • File format (tested with JPEG and WebP, both fail)
  • Image source (Amazon, Shopee, Mercado Livre — fails across all, inconsistently, not isolated to one source)
  • File size (fails on both small and large images, ~90KB tested)
  • Sending base64 with an additional backgroundColor field (did not fix it)
  • Confirmed the same file + caption works normally via sendMedia to a group — rules out a broken source file

🌍 Environment

  • OS: Windows (self-hosted, local)
  • Evolution API version: 2.4.0
  • Integration: Baileys

📋 Logs

Success response example (sensitive data removed):
{
  "key": {
    "remoteJid": "status@broadcast",
    "fromMe": true,
    "id": "3EB049C98D7225D99C83E1"
  },
  "message": {
    "imageMessage": {
      "url": "https://mmg.whatsapp.net/...",
      "mimetype": "image/jpeg",
      "caption": "..."
    }
  },
  "messageType": "imageMessage",
  "status": "PENDING"
}

📝 Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions