Commit Graph

558 Commits

Author SHA1 Message Date
Josias Maceda
0116bc4c9f fix: integrate Typebot status change events for webhook in chatbot controller and service 2025-09-09 11:49:13 -03:00
Davidson Gomes
20352e77ef Merge pull request #1878 from LuisSantosJS/reconnect-rabbitmq
Reconnect rabbitmq
2025-08-29 07:16:13 -03:00
nestordavalos
57b19d85d5 feat(whatsapp): Convert outgoing images to JPEG before sending
All images sent via the Baileys integration are now pre-processed and converted to JPEG format using the `sharp` library. This ensures better compatibility and prevents potential issues with unsupported formats.

- Images from URLs are now downloaded via axios before processing, which allows for the use of a proxy.
- The default filename and mimetype are updated to `image.jpg` and `image/jpeg` to reflect the conversion.
2025-08-28 00:17:15 -03:00
luissantosjs
b325500310 improve rabbit controller 2025-08-26 19:15:59 +01:00
luissantosjs
4681576cfc up 2025-08-22 22:49:40 +01:00
luissantosjs
7a99fba556 feat: enhance RabbitMQ controller with improved connection management and shutdown procedures 2025-08-20 12:29:45 +01:00
Davidson Gomes
33a922995b Merge pull request #1838 from bilaliqbalr/patch-2
Some checks failed
Build Docker image / Build and Deploy (push) Has been cancelled
Added key id into webhook payload in n8n service
2025-08-15 12:49:10 -03:00
Bilal Iqbal
74cb65c4ea Added key id into webhook payload in n8n service 2025-08-14 00:51:41 +05:00
Davidson Gomes
a8343a8739 Merge pull request #1802 from frieck/main
Some checks failed
Build Docker image / Build and Deploy (push) Has been cancelled
Securing websockets
2025-08-04 19:18:30 -03:00
Felipe Augusto Rieck
fb11f3f99c Code quality 2025-08-04 18:19:14 -03:00
Felipe Augusto Rieck
d4eb61f64d Improving localhost check 2025-08-04 18:14:33 -03:00
Felipe Augusto Rieck
4f043f9576 Securing websockets 2025-08-04 16:34:20 -03:00
William Dumes
79f4a22217 refactor: lint check 2025-08-04 13:56:16 -03:00
William Dumes
fe8280ab7b Merge branch 'main' of github.com:apresentame/evolution-api into fix/webhook_event 2025-08-01 09:41:28 -03:00
William Dumes
bc11d0f751 fix: corrigido delete de mensagem quando nao salvo no banco de dados 2025-07-31 17:27:06 -03:00
Davidson Gomes
b5c67774dc chore: remove CONFIG_SESSION_PHONE_VERSION and update related code
- Removed the CONFIG_SESSION_PHONE_VERSION environment variable from the configuration and Docker files.
- Updated the BaileysStartupService to directly fetch the latest WhatsApp Web version without relying on the removed environment variable.
- Adjusted the index router to reflect the changes in the WhatsApp Web version retrieval.
2025-07-29 09:20:08 -03:00
William Dumes
6101c8d651 fix: corrigido disparo de eventos quando nao usa a opcao da ENV de salvar mensagens no banco 2025-07-25 17:08:14 -03:00
Davidson Gomes
c66485ef98 Merge pull request #1748 from coreh/fix-url-corruption-querystring
Some checks failed
Build Docker image / Build and Deploy (push) Has been cancelled
Avoid corrupting media URLs with query strings
2025-07-25 16:56:06 -03:00
Willian Coqueiro
23f54d1d96 lint 2025-07-25 12:13:56 +00:00
Willian Coqueiro
5191438acf fix: update error handling messages and correct group parameter in createContact method 2025-07-25 12:02:17 +00:00
Marco Buono
96d3ec2017 fix: avoid corrupting URLs with query strings 2025-07-23 16:06:14 -03:00
Rafael Souza
afd0e01ddb fix lint 2025-07-17 15:59:33 -03:00
Rafael Souza
b3dae7a68e Ignore events that are not messages 2025-07-17 15:40:31 -03:00
Rafael Souza
44d4781f6f Ignore events that are not messages 2025-07-17 15:37:37 -03:00
Rafael Souza
e304b1dcdf Fix erro key 2025-07-17 15:32:25 -03:00
Rafael Souza
f8f2153cb4 Fix erro key 2025-07-17 15:29:04 -03:00
Davidson Gomes
cdef7dc9f9 Merge pull request #1728 from KokeroO/develop
Some checks failed
Build Docker image / Build and Deploy (push) Has been cancelled
Fix: [Chatwoot] Corrige mensagens editas
2025-07-17 11:55:55 -03:00
Willian Coqueiro
419300b31f refactor: simplify edited message check in BaileysStartupService 2025-07-17 02:24:21 +00:00
Davidson Gomes
d98fa5259e Merge branch 'develop' into feat/add-async-lock 2025-07-16 19:22:44 -03:00
Santosl2
05886ec684 feat: enhance message processing with retry logic for error handling 2025-07-15 21:41:25 -03:00
Santosl2
89d4d341f6 feat: add BaileysMessageProcessor for improved message handling and integrate rxjs for asynchronous processing 2025-07-15 21:35:25 -03:00
Davidson Gomes
e321609b93 refactor: Simplify conditional check for contact updates in ChatwootService
Some checks failed
Build Docker image / Build and Deploy (push) Has been cancelled
2025-07-14 14:52:02 -03:00
Davidson Gomes
2fb3eac383 Merge pull request #1715 from AlexisJusviack/fix/getBase64-template-support
Fix: Support media extraction from templateMessage in getBase64FromMediaMessage
2025-07-14 14:44:43 -03:00
Davidson Gomes
4a5696eda9 Merge pull request #1704 from rafwell/develop
Throw exception if download media fail
2025-07-14 14:44:29 -03:00
Davidson Gomes
d458c978f3 Merge branch 'develop' into develop 2025-07-14 14:42:18 -03:00
AlexisJusviack
bd35d7977c Fix: Support media extraction from templateMessage in getBase64FromMediaMessage
### Fix: Add support for templateMessage media in getBase64FromMediaMessage

#### What this does
Adds support to download media from `templateMessage` structures in `getBase64FromMediaMessage`, by checking for `hydratedTemplate` and `hydratedFourRowTemplate`.

#### Why it's needed
Currently, media inside templates (e.g. `imageMessage`, `videoMessage`, `documentMessage`) is not processed by the method, which leads to errors or media being skipped.

#### How it works
If a `templateMessage` is detected, the code looks into the inner hydrated template and assigns the correct `mediaMessage` and `mediaType`. Then it proceeds as usual with the download logic.

#### Example message
```json
{
  "message": {
    "templateMessage": {
      "hydratedTemplate": {
        "imageMessage": {
          "mimetype": "image/jpeg",
          "fileLength": 123456,
          "url": "https://..."
        }
      }
    }
  }
}
2025-07-11 23:50:58 -03:00
Willian Coqueiro
37319966db Remove redudantent code 2025-07-09 18:42:35 +00:00
Willian Coqueiro
630f5c5624 fix:
- [Baileys] Trocar @lids em remoteJid por senderPn em todos os serviços;
 - [Baileys] Adicionar valor @lid recebido em remoteJid para previousRemoteJid (Posteriormente utilizasse em ChatwootService);
 - Minors fixes;
2025-07-09 18:35:57 +00:00
Rafael Souza
9acccf723d Throw exception if download media fail 2025-07-08 17:43:21 -03:00
Davidson Gomes
3c917af602 Merge pull request #1660 from KokeroO/develop
fix(whatsapp-baileys): Verifica eventos com falhas e fallback para erro ao baixar mídias
2025-06-27 09:55:22 -03:00
KokeroO
52798fd761 fix(whatsapp-baileys): adjust indentation and access modifier for getBase64FromMediaMessage method 2025-06-27 09:29:12 -03:00
KokeroO
34446d188e fix(whatsapp-baileys):
- Implement broken event checking before duplicate message checking. (Do not process failed events).
- Implement error handling when downloading media with a fallback mechanism.
2025-06-27 09:03:32 -03:00
Davidson Gomes
ef31b6de1f Merge pull request #1655 from KokeroO/develop
fix/references-instanceName-typebot
2025-06-26 17:10:58 -03:00
KokeroO
d7afe5d7ab fix(typebot): update instance query to use instance name instead of instance ID 2025-06-26 14:53:54 -03:00
Davidson Gomes
72fb2f408b feat(rabbitmq): implement robust connection handling with reconnection logic and error logging 2025-06-26 14:25:37 -03:00
KokeroO
e4f7856ca9 fix(typebot): update instance query to use instanceName instead of instanceId 2025-06-26 14:05:28 -03:00
Willian Coqueiro
0302944654 Corrige ref. instance typebot.controller.ts 2025-06-26 11:42:27 -03:00
Davidson Gomes
1a1d9fc957 refactor: add validation for media content in Evolution and Business services to enhance error handling 2025-06-23 16:42:29 -03:00
Davidson Gomes
8ea4d65bc2 refactor: enhance media handling in Baileys service with validation for valid media content 2025-06-23 16:42:24 -03:00
Davidson Gomes
873fdcb22a Merge pull request #1633 from VCalazans/FIX/ISSUE-28
🐛 fix: Phone number as message ID for Evo AI #ISSUE 28
2025-06-23 15:35:56 -03:00