Skip to content

Instantly share code, notes, and snippets.

@lfowlie
lfowlie / gist:41beeb90e5151cbb59994f952b6a6682
Last active April 14, 2020 16:57
Conversation Definition Examples
## Communication ##
OPT_IN_FLOW = [ReceiveMessageStep('START'), UpdateOptedOutStatus(False), SendMessageStep(MessageType.ON_BOARDING_MESSAGE)]
OPT_OUT_FLOW = [ReceiveMessageStep('STOP'), UpdateOptedOutStatus(True), SendMessageStep(MessageType.STOP_MESSAGE)]
HELP_FLOW = [ReceiveMessageStep('HELP'), SendMessageStep(MessageType.HELP_MESSAGE)]
## Rescheduling ##
_skip_message_branch = [SKIP_RESCHEDULE_APPOINTMENT, SendMessageStep(MessageType.SKIP_MESSAGE)]
RESCHEDULE_FLOW = [
SendMessageStep(MessageType.APPOINTMENT_AVAILABLE_MESSAGE),
ReceiveMessageStep(['YES', 'SKIP', 'NO']),
0, 0, 0, 0
0, 0, 0, 0
0, 0, 0, 0
0, 0, 0, 0
0, 0, 0, 0
0, 0, 0, 0
0, 0, 0, 0
0, 0, 0, 0
0, 0, 0, 0
0, 0, 0, 0