3mora2 / WPP_Whatsapp

WPP_Whatsapp aim of exporting functions from WhatsApp Web to the python, which can be used to support the creation of any interaction, such as customer service, media sending, intelligence recognition based on phrases artificial and many other things, use your imagination
MIT License
57 stars 9 forks source link

how to run it #3

Closed aomar2010 closed 1 year ago

aomar2010 commented 1 year ago

Hi dear ,

could you please add comment about how to run the app

3mora2 commented 1 year ago

sync start

from WPP_Whatsapp import Create

# pass your session name
self = Create(session="test")
self.async_to_sync(self.start())

use self.async_to_sync to use async function as sync, i mean with out add await, if you need start clinet call await self.start() in async function or call self.async_to_sync(self.start())

aomar2010 commented 1 year ago

sync start

from WPP_Whatsapp import Create

# pass your session name
self = Create(session="test")
self.async_to_sync(self.start())

use self.async_to_sync to use async function as sync, i mean with out add await, if you need start clinet call await self.start() in async function or call self.async_to_sync(self.start())

Happy Eid Adha, it would be great help if you add in the project an example method , specially I'n not good I'm python

3mora2 commented 1 year ago

Happy Eid Adha, you want send or receive messages

aomar2010 commented 1 year ago

Happy Eid Adha, you want send or receive messages

yes please

3mora2 commented 1 year ago

see examples

3mora2 commented 1 year ago

@aomar2010 install new update pip install WPP_Whatsapp -U and try examples

aomar2010 commented 1 year ago

@aomar2010 install new update pip install WPP_Whatsapp -U and try examples

thank you Ammar , it works