waha icon indicating copy to clipboard operation
waha copied to clipboard

[GOWS] - /api/sendVideo statusCode:500 connection reset by peer

Open AlexGoldovsky opened this issue 9 months ago • 1 comments

Describe the bug

Error when sending a video.

curl -X POST http://localhost:3000/api/sendVideo -H 'Content-Type: application/json' -H 'X-Api-Key: ...' -d '{ "chatId": "...", "session": "...", "file": { "url": "...", "mimetype": "video/mp4" } }' {"statusCode":500,"timestamp":"2026-02-21T...","exception":{"message":"2 UNKNOWN: failed to execute request: Post "https://media-cdg4-1.cdn.whatsapp.net/mms/video/...": write tcp :51958->185.60.219.60:443: write: connection reset by peer","code":2,"details":"failed to execute request: Post "https://media-cdg4-1.cdn.whatsapp.net/mms/video/...": write tcp :51958->185.60.219.60:443: write: connection reset by peer","metadata":{},"name":"Error","stack":"Error: 2 UNKNOWN: failed to execute request: Post "https://media-cdg4-1.cdn.whatsapp.net/mms/video/...": write tcp :51958->185.60.219.60:443: write: connection reset by peer\n at callErrorFromStatus (/app/node_modules/@grpc/grpc-js/build/src/call.js:32:19)\n at Object.onReceiveStatus (/app/node_modules/@grpc/grpc-js/build/src/client.js:193:76)\n at Object.onReceiveStatus (/app/node_modules/@grpc/grpc-js/build/src/client-interceptors.js:367:141)\n at Object.onReceiveStatus (/app/node_modules/@grpc/grpc-js/build/src/client-interceptors.js:327:181)\n at /app/node_modules/@grpc/grpc-js/build/src/resolving-call.js:135:78\n at process.processTicksAndRejections (node:internal/process/task_queues:84:11)\nfor call at\n at MessageServiceClient.makeUnaryRequest (/app/node_modules/@grpc/grpc-js/build/src/client.js:161:32)\n at MessageServiceClient.SendMessage (/app/node_modules/@grpc/grpc-js/build/src/make-client.js:105:19)\n at MessageServiceClient.SendMessage (/app/dist/core/engines/gows/grpc/gows.js:10456:30)\n at node:internal/util:495:21\n at new Promise ()\n at node:internal/util:481:12\n at /app/dist/plus/engines/gows/session.gows.plus.js:195:82\n at async TmpDir.use (/app/dist/utils/tmpdir.js:22:20)\n at async WhatsappSessionGoWSPlus.sendMedia (/app/dist/plus/engines/gows/session.gows.plus.js:185:16)\n at async WhatsappSessionGoWSPlus.sendVideo (/app/dist/plus/engines/gows/session.gows.plus.js:213:16)\n at async descriptor.value (/app/dist/core/abc/activity.js:9:20)"},"request":{"path":"/api/sendVideo","method":"POST","body":{"chatId":"[email protected]","session":"...","file":{"url":"...","mimetype":"video/mp4"}},"query":{}},"version":{"version":"2026.2.2","engine":"GOWS","tier":"PLUS","browser":null,"platform":"linux/x64","worker":{"id":null}}}

Version

Get the WAHA version by calling GET /api/version

{
  "version": "2026.2.2",
  "engine": "GOWS",
  "tier": "PLUS"
}

Steps

To Reproduce Steps to reproduce the behavior:

  1. send video using /api/sendVideo which is over 2MB
  2. get the error

Expected behavior

success is expected

Requests - Responses

curl -X POST http://localhost:3000/api/sendVideo -H 'Content-Type: application/json' -H 'X-Api-Key: ...' -d '{ "chatId": "...", "session": "...", "file": { "url": "...", "mimetype": "video/mp4" } }'

Docker Logs

[17:17:02.004] ERROR (7): [Session/.../Client/Socket] Error reading from websocket: failed to read: failed to read frame payload: read tcp :34476->185.60.219.60:443: read: connection reset by peer {"engine":"gows"}

Additional context

Trying to send a smaller file 1.2Mb from the same url works fine/

AlexGoldovsky avatar Feb 21 '26 17:02 AlexGoldovsky

Same Problem connection reset by peer. Some of sessinos is keep restarting. The Problem I think Whatsapp Block Some service using websocket The Numbers is working no Band..

patron:PLUS

hananah avatar Feb 21 '26 22:02 hananah