Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can no longer send messages #79

Closed
owen2345 opened this issue Sep 5, 2023 · 26 comments
Closed

Can no longer send messages #79

owen2345 opened this issue Sep 5, 2023 · 26 comments

Comments

@owen2345
Copy link

owen2345 commented Sep 5, 2023

After I updated to the latest docker image, I can no longer send messages. I always receive {"success":false,"error":"session_not_connected"} even I restarted the session many times for different devices

@owen2345
Copy link
Author

owen2345 commented Sep 5, 2023

Note: The issue on whatsapp web looks like was fixed, could u pls release a new image with the fix? pedroslopez/whatsapp-web.js#2439 (comment)

@avoylenko
Copy link
Collaborator

new version just released and available on docker hub

@chrishubert
Copy link
Owner

I'll play with the CI/CD soon to set the versioning, following the wwjs versions

@owen2345
Copy link
Author

owen2345 commented Sep 5, 2023

The new release does not include the hotfix:

"whatsapp-web.js": "https://github.com/Julzk/whatsapp-web.js/tarball/jkr_hotfix_8"

@avoylenko
Copy link
Collaborator

avoylenko commented Sep 5, 2023

@owen2345 it's not true, check this out pedroslopez/whatsapp-web.js#2433

@chrishubert
Copy link
Owner

@owen2345 , in the spirit of this repository, we will deploy only the official releases from wwjs
I agree with the versioning to ensure that users get a chance to rollback in case of issues, but for the time being we will not include hotfixes in the repo directly

@mdestafadilah
Copy link

@chrishubert so we still waiting from repo official wwjs? still not send messages.

@avoylenko
Copy link
Collaborator

@mdestafadilah do you run the latest docker image?

@mdestafadilah
Copy link

@mdestafadilah do you run the latest docker image?

i'm not using docker btw

@avoylenko
Copy link
Collaborator

@mdestafadilah run git pull and npm i in the project folder and let me know if that helped.

@mdestafadilah
Copy link

@mdestafadilah run git pull and npm i in the project folder and let me know if that helped.

not work. still same, can't send message

@mdestafadilah
Copy link

Hi @avoylenko it's relate this case ?
#82 (comment)

@owen2345
Copy link
Author

owen2345 commented Sep 7, 2023

In my case I had to create another image: https://github.com/owen2345/whatsapp
And use this temporary fix: https://github.com/owen2345/whatsapp/blob/main/package.json#L5

"whatsapp-web.js": "https://github.com/Julzk/whatsapp-web.js/tarball/jkr_hotfix_8"

@mdestafadilah
Copy link

In my case I had to create another image: https://github.com/owen2345/whatsapp And use this temporary fix: https://github.com/owen2345/whatsapp/blob/main/package.json#L5

"whatsapp-web.js": "https://github.com/Julzk/whatsapp-web.js/tarball/jkr_hotfix_8"

it's resolved?

@owen2345
Copy link
Author

owen2345 commented Sep 8, 2023

Yes, it is working

@mdestafadilah
Copy link

Yes, it is working

Thanks it's working too, so i'm using your trick. if wwjs launch offically, may @chrishubert will update this repo.

@chrishubert
Copy link
Owner

@owen2345 I used the same dependency as your repo for the time being, until there is an official fix from wwebjs

@deepakvshinde
Copy link

I am also facing the same issue of not being able to send messages. but the session is active consistently if we restart the server then it works fine but the server is stuck after some time again. (using Ubuntu server). can anyone have an idea on this?

@yoyococo700
Copy link

Same issue here

I am also facing the same issue of not being able to send messages. but the session is active consistently if we restart the server then it works fine but the server is stuck after some time again. (using Ubuntu server). can anyone have an idea on this?

@avoylenko
Copy link
Collaborator

@deepakvshinde @yoyococo700 could you try the latest build?

@yoyococo700
Copy link

I just tried the v1.22.2-alpha.1 it seems to work perfectly! Thanks!

@mahmoudgoogle
Copy link

mahmoudgoogle commented Oct 16, 2023

I have the same problem when sending a message
request body

      {
  "chatId": "201100000@c.us",
  "contentType": "string",
  "content": "Hello World"
}

{
  "success": false,
  "error": "contentType invalid, must be string, MessageMedia, MessageMediaFromURL, Location, Buttons, or List"
}

```I use docker

@avoylenko
Copy link
Collaborator

@mdestafadilah the error message is self-explanatory. Double-check that you send a valid request.

@mahmoudgoogle
Copy link

@mdestafadilah the error message is self-explanatory. Double-check that you send a valid request.

I checked everything
Request body

{
   "chatId": "201100000@c.us",
   "contentType": "string",
   "content": "Hello World"
}

@avoylenko
Copy link
Collaborator

Do you have Content-Type: application/json header in your request?

@mahmoudgoogle
Copy link

Do you have Content-Type: application/json header in your request?
I forgot to add Content-Type
It's working now. Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants