c6d294385f
The send_reply function makes it easier for bots to send messages. This commit updates all bots to make use of this function, when possible.
19 lines
527 B
Python
19 lines
527 B
Python
# See readme.md for instructions on running this code.
|
|
|
|
|
|
class HelloWorldHandler(object):
|
|
def usage(self):
|
|
return '''
|
|
This is a boilerplate bot that responds to a user query with
|
|
"beep boop", which is robot for "Hello World".
|
|
|
|
This bot can be used as a template for other, more
|
|
sophisticated, bots.
|
|
'''
|
|
|
|
def handle_message(self, message, client, state_handler):
|
|
content = 'beep boop'
|
|
client.send_reply(message, content)
|
|
|
|
handler_class = HelloWorldHandler
|