---
description: Overview of message generation and storage in iCycle
---

# Messsaging Services Overview

## Problem Domain

TurnContext objects hold all data for the current activity taking place. The messageParser class is the main context handler and extracts key information from the object to make decisions.

Normal messages are logged in the local database and in Apache Cassandra if configured.

Dialogs are initiated via specified text commands.

![BotCaptain Context Overview](https://2970422944-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MIy853ylmwJWOGNM8Ow%2F-MP7NpU-c67gq2mk4KUT%2F-MP7OfROHidcQ3s5Pf_l%2FICyclePicture7.png?alt=media\&token=8356a104-cb77-443f-bdd4-d50c93f5f822)

{% hint style="success" %}
&#x20;These commands should be added to the messageParser object and follow the naming convention \[dialog name]Dialog&#x20;
{% endhint %}

![Line 94 - 108 in messageParser](https://2970422944-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MIy853ylmwJWOGNM8Ow%2F-MP4y-_1LLuaKdlSsSAT%2F-MP59dS94jYavRsp5Wai%2Fimage.png?alt=media\&token=b431d167-6470-4403-b28c-117943382657)



## Persistence Domain

Data that persists has the option of being encrypted. Botcaptain's local persistence can be encrypted via the fileIO.encryptText method. Apache Cassandra databases have the option of encryption as well. Consult the cloud service provider's documentation for more information.

![BotCaptain Local Persistence Overview](https://2970422944-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MIy853ylmwJWOGNM8Ow%2F-MP7NpU-c67gq2mk4KUT%2F-MP7QMQcKI9wdd4Zc-kg%2FICyclePicture8.png?alt=media\&token=bcf86e78-3514-46b3-8bbd-ff64c77fa4e0)

