evolution-api icon indicating copy to clipboard operation
evolution-api copied to clipboard

Erro Webhook para n8n - WebhookController

Open GuianaStore opened this issue 1 year ago • 7 comments

Welcome!

  • [x] Yes, I have searched for similar issues on GitHub and found none.

What did you do?

Ao habilitar o webhook para n8n apareceu esse erro no backend:

[Evolution API] v2.2.3 1821 - Tue Jun 17 2025 15:45:16 ERROR [WebhookController] [object]
{ local: 'ChannelStartupService.sendData-Webhook', message: 'Tentativa 7/10 falhou: write EPROTO 0088C1D5EA7A0000:error:0A00010B:SSL routines:ssl3_get_record:wrong version number:../ssl/record/ssl3_record.c:354:\n', hostName: undefined, syscall: 'write', code: 'EPROTO', error: -71, stack: 'Error: write EPROTO 0088C1D5EA7A0000:error:0A00010B:SSL routines:ssl3_get_record:wrong version number:../ssl/record/ssl3_record.c:354:\n' + '\n' + ' at Function.AxiosError.from (/root/js/evolution-api/node_modules/axios/lib/core/AxiosError.js:92:14)\n' + ' at RedirectableRequest.handleRequestError (/root/js/evolution-api/node_modules/axios/lib/adapters/http.js:620:25)\n' + ' at RedirectableRequest.emit (node:events:517:28)\n' + ' at ClientRequest.eventHandlers. (/root/js/evolution-api/node_modules/follow-redirects/index.js:49:24)\n' + ' at ClientRequest.emit (node:events:517:28)\n' + ' at TLSSocket.socketErrorListener (node:_http_client:501:9)\n' + ' at TLSSocket.emit (node:events:517:28)\n' + ' at emitErrorNT (node:internal/streams/destroy:151:8)\n' + ' at emitErrorCloseNT (node:internal/streams/destroy:116:3)\n' + ' at processTicksAndRejections (node:internal/process/task_queues:82:21)\n' + ' at Axios.request (/root/js/evolution-api/node_modules/axios/lib/core/Axios.js:45:41)\n' + ' at processTicksAndRejections (node:internal/process/task_queues:95:5)\n' + ' at WebhookController.retryWebhookRequest (/root/js/evolution-api/src/api/integrations/event/webhook/webhook.controller.ts:200:9)\n' + ' at WebhookController.emit (/root/js/evolution-api/src/api/integrations/event/webhook/webhook.controller.ts:120:13)\n' + ' at EventManager.emit (/root/js/evolution-api/src/api/integrations/event/event.manager.ts:107:5)\n' + ' at BaileysStartupService.sendDataWebhook (/root/js/evolution-api/src/api/services/channel.service.ts:443:5)', name: 'Error', url: 'https://n8n.chatbiblia.com.br:3038/webhook-test/d2a965fd-4a5b-4990-a878-305622704937', server_url: 'https://evo.chatbiblia.com.br' }

What did you expect?

Que o webhook fosse enviado/recebido no N8N.

What did you observe instead of what you expected?

[Evolution API] v2.2.3 1821 - Tue Jun 17 2025 15:45:16 ERROR [WebhookController] [object]
{ local: 'ChannelStartupService.sendData-Webhook', message: 'Tentativa 7/10 falhou: write EPROTO 0088C1D5EA7A0000:error:0A00010B:SSL routines:ssl3_get_record:wrong version number:../ssl/record/ssl3_record.c:354:\n', hostName: undefined, syscall: 'write', code: 'EPROTO', error: -71, stack: 'Error: write EPROTO 0088C1D5EA7A0000:error:0A00010B:SSL routines:ssl3_get_record:wrong version number:../ssl/record/ssl3_record.c:354:\n' + '\n' + ' at Function.AxiosError.from (/root/js/evolution-api/node_modules/axios/lib/core/AxiosError.js:92:14)\n' + ' at RedirectableRequest.handleRequestError (/root/js/evolution-api/node_modules/axios/lib/adapters/http.js:620:25)\n' + ' at RedirectableRequest.emit (node:events:517:28)\n' + ' at ClientRequest.eventHandlers. (/root/js/evolution-api/node_modules/follow-redirects/index.js:49:24)\n' + ' at ClientRequest.emit (node:events:517:28)\n' + ' at TLSSocket.socketErrorListener (node:_http_client:501:9)\n' + ' at TLSSocket.emit (node:events:517:28)\n' + ' at emitErrorNT (node:internal/streams/destroy:151:8)\n' + ' at emitErrorCloseNT (node:internal/streams/destroy:116:3)\n' + ' at processTicksAndRejections (node:internal/process/task_queues:82:21)\n' + ' at Axios.request (/root/js/evolution-api/node_modules/axios/lib/core/Axios.js:45:41)\n' + ' at processTicksAndRejections (node:internal/process/task_queues:95:5)\n' + ' at WebhookController.retryWebhookRequest (/root/js/evolution-api/src/api/integrations/event/webhook/webhook.controller.ts:200:9)\n' + ' at WebhookController.emit (/root/js/evolution-api/src/api/integrations/event/webhook/webhook.controller.ts:120:13)\n' + ' at EventManager.emit (/root/js/evolution-api/src/api/integrations/event/event.manager.ts:107:5)\n' + ' at BaileysStartupService.sendDataWebhook (/root/js/evolution-api/src/api/services/channel.service.ts:443:5)', name: 'Error', url: 'https://n8n.chatbiblia.com.br:3038/webhook-test/d2a965fd-4a5b-4990-a878-305622704937', server_url: 'https://evo.chatbiblia.com.br' }

Screenshots/Videos

No response

Which version of the API are you using?

2.2.3

What is your environment?

Linux

Other environment specifications

No response

If applicable, paste the log output

[Evolution API] v2.2.3 1821 - Tue Jun 17 2025 15:45:16 ERROR [WebhookController] [object]
{ local: 'ChannelStartupService.sendData-Webhook', message: 'Tentativa 7/10 falhou: write EPROTO 0088C1D5EA7A0000:error:0A00010B:SSL routines:ssl3_get_record:wrong version number:../ssl/record/ssl3_record.c:354:\n', hostName: undefined, syscall: 'write', code: 'EPROTO', error: -71, stack: 'Error: write EPROTO 0088C1D5EA7A0000:error:0A00010B:SSL routines:ssl3_get_record:wrong version number:../ssl/record/ssl3_record.c:354:\n' + '\n' + ' at Function.AxiosError.from (/root/js/evolution-api/node_modules/axios/lib/core/AxiosError.js:92:14)\n' + ' at RedirectableRequest.handleRequestError (/root/js/evolution-api/node_modules/axios/lib/adapters/http.js:620:25)\n' + ' at RedirectableRequest.emit (node:events:517:28)\n' + ' at ClientRequest.eventHandlers. (/root/js/evolution-api/node_modules/follow-redirects/index.js:49:24)\n' + ' at ClientRequest.emit (node:events:517:28)\n' + ' at TLSSocket.socketErrorListener (node:_http_client:501:9)\n' + ' at TLSSocket.emit (node:events:517:28)\n' + ' at emitErrorNT (node:internal/streams/destroy:151:8)\n' + ' at emitErrorCloseNT (node:internal/streams/destroy:116:3)\n' + ' at processTicksAndRejections (node:internal/process/task_queues:82:21)\n' + ' at Axios.request (/root/js/evolution-api/node_modules/axios/lib/core/Axios.js:45:41)\n' + ' at processTicksAndRejections (node:internal/process/task_queues:95:5)\n' + ' at WebhookController.retryWebhookRequest (/root/js/evolution-api/src/api/integrations/event/webhook/webhook.controller.ts:200:9)\n' + ' at WebhookController.emit (/root/js/evolution-api/src/api/integrations/event/webhook/webhook.controller.ts:120:13)\n' + ' at EventManager.emit (/root/js/evolution-api/src/api/integrations/event/event.manager.ts:107:5)\n' + ' at BaileysStartupService.sendDataWebhook (/root/js/evolution-api/src/api/services/channel.service.ts:443:5)', name: 'Error', url: 'https://n8n.chatbiblia.com.br:3038/webhook-test/d2a965fd-4a5b-4990-a878-305622704937', server_url: 'https://evo.chatbiblia.com.br' }

Additional Notes

No response

GuianaStore avatar Jun 17 '25 18:06 GuianaStore

Aqui o Webhook nem recebe POST

RafaFenix avatar Jun 17 '25 22:06 RafaFenix

Aqui o Webhook nem recebe POST

Aqui tbm não. Quando eu ativo nas configurações da evolution-api o webhook com o link da n8n já dá esse problema...

GuianaStore avatar Jun 18 '25 13:06 GuianaStore

Mesma coisa por aqui. Não consigo mais usar o webhook. Mesmo configurando CONFIG_SESSION_PHONE_VERSION para a versão que mostra no meu whatsapp web, etc...

2025-06-18T15:11:45.394550155Z [Evolution API] v2.3.0 198 - Wed Jun 18 2025 12:11:45 ERROR [WebhookController] [object]
2025-06-18T15:11:45.395510864Z { 2025-06-18T15:11:45.395545604Z local: 'p.sendData-Webhook', 2025-06-18T15:11:45.395553371Z message: 'Erro não recuperável (404): Request failed with status code 404. Cancelando retentativas.', 2025-06-18T15:11:45.395560230Z statusCode: 404, 2025-06-18T15:11:45.395565165Z url: 'https://'', 2025-06-18T15:11:45.395570465Z server_url: 'https://evo-' 2025-06-18T15:11:45.395575494Z } 2025-06-18T15:11:45.395580248Z 2025-06-18T15:11:45.396065681Z [Evolution API] v2.3.0 198 - Wed Jun 18 2025 12:11:45 ERROR [WebhookController] [object]
2025-06-18T15:11:45.397013881Z { 2025-06-18T15:11:45.397030550Z local: 'p.sendData-Webhook', 2025-06-18T15:11:45.397037734Z message: 'Todas as tentativas falharam: Request failed with status code 404', 2025-06-18T15:11:45.397043696Z hostName: undefined, 2025-06-18T15:11:45.397049439Z syscall: undefined, 2025-06-18T15:11:45.397055041Z code: 'ERR_BAD_REQUEST', 2025-06-18T15:11:45.397060460Z error: undefined, 2025-06-18T15:11:45.397065747Z stack: 'AxiosError: Request failed with status code 404\n' + 2025-06-18T15:11:45.397071912Z ' at settle (/evolution/node_modules/axios/dist/node/axios.cjs:2053:12)\n' + 2025-06-18T15:11:45.397078102Z ' at IncomingMessage.handleStreamEnd (/evolution/node_modules/axios/dist/node/axios.cjs:3170:11)\n' + 2025-06-18T15:11:45.397084356Z ' at IncomingMessage.emit (node:events:536:35)\n' + 2025-06-18T15:11:45.397096714Z ' at endReadableNT (node:internal/streams/readable:1698:12)\n' + 2025-06-18T15:11:45.397102992Z ' at process.processTicksAndRejections (node:internal/process/task_queues:82:21)\n' + 2025-06-18T15:11:45.397141020Z ' at Axios.request (/evolution/node_modules/axios/dist/node/axios.cjs:4280:41)\n' + 2025-06-18T15:11:45.397172606Z ' at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n' + 2025-06-18T15:11:45.397180080Z ' at async ni.retryWebhookRequest (/evolution/dist/main.js:274:53617)\n' + 2025-06-18T15:11:45.397187546Z ' at async ni.emit (/evolution/dist/main.js:274:52428)\n' + 2025-06-18T15:11:45.397193482Z ' at async ai.emit (/evolution/dist/main.js:274:58037)\n' + 2025-06-18T15:11:45.397199330Z ' at async Bs.sendDataWebhook (/evolution/dist/main.js:156:16880)', 2025-06-18T15:11:45.397204962Z name: 'AxiosError', 2025-06-18T15:11:45.397210280Z url: 'https://
'', 2025-06-18T15:11:45.397215947Z server_url: 'https://evo-' 2025-06-18T15:11:45.397221074Z } 2025-06-18T15:11:45.397226320Z


Url e server_url eu escondi, não é o que esta ai.

andersonid avatar Jun 18 '25 17:06 andersonid

Consegui resolver aqui, dois passos:

1º passo, usar essa versão CONFIG_SESSION_PHONE_VERSION= 2.3000.1020885143

2ºPasso

  • Desabilitar

Image

Maidei o teste e deu certo aqui.

Espero que ajude quem ver esse post

RafaFenix avatar Jun 18 '25 21:06 RafaFenix

Consegui resolver aqui, dois passos:

1º passo, usar essa versão CONFIG_SESSION_PHONE_VERSION= 2.3000.1020885143

2ºPasso

* Desabilitar

Image

Maidei o teste e deu certo aqui.

Espero que ajude quem ver esse post

Não funcionou comigo esse phone version.

EDIT: Com esse ..PHONE_VERSION=2.3000.1024068999 funcionou novamente!

andersonid avatar Jun 19 '25 05:06 andersonid

Obrigado pela dica Andersonid

Funcionou usando : PHONE_VERSION=2.3000.1024068999

gcbcarneiro avatar Jun 25 '25 17:06 gcbcarneiro

mesmo problema aqui, CONFIG_SESSION_PHONE_VERSION=2.3000.1024829850 Webhook by Events disabled

augustobr1to avatar Jul 17 '25 00:07 augustobr1to