Class: Whatsapp::MessageHandler
- Inherits:
-
Object
- Object
- Whatsapp::MessageHandler
- Defined in:
- lib/whatsapp/message_handler.rb
Overview
Base class for incoming message handlers.
Subclass this and implement +#call+ to process incoming WhatsApp messages. Configure the handler in your initializer:
Whatsapp.configure do |config| config.message_handler = WhatsappMessageHandler end
Instance Method Summary collapse
-
#call(message, session:) ⇒ void
Process an incoming message.
Instance Method Details
#call(message, session:) ⇒ void
This method returns an undefined value.
Process an incoming message.
30 31 32 |
# File 'lib/whatsapp/message_handler.rb', line 30 def call(, session:) raise NotImplementedError, "#{self.class}#call must be implemented" end |