Giter Site home page Giter Site logo

Comments (3)

lent0s avatar lent0s commented on August 17, 2024

@dimitrii9000
Good afternoon!
To process incoming call notifications, you must enable the "incomingCallWebhook": "yes" option in the instance settings
You can get acquainted with the type of webhook notifications about calls here

from whatsapp-chatbot-python.

lent0s avatar lent0s commented on August 17, 2024

@dimitrii9000
At the moment, the bot does not have an incoming call handler. Clients can add it themselves. We will take your wishes into account and add this feature in future releases

from whatsapp-chatbot-python.

dimitrii9000 avatar dimitrii9000 commented on August 17, 2024

Thanks!
For any other interested parties, it's quite easy to add custom handler to handle calls

from whatsapp_chatbot_python.manager.observer import Observer


class WhatsappMessageHandler:
    def __init__(self, bot: GreenAPIBot):
        self.bot = bot
        self.bot.router.incoming_call = Observer(self.bot.router)
        self.bot.router.observers["incomingCall"] = self.bot.router.incoming_call

        @self.bot.router.incoming_call()
        def message_handler(notification: Notification) -> None:
            logging.info(notification.event)

from whatsapp-chatbot-python.

Related Issues (8)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.