> ## Documentation Index
> Fetch the complete documentation index at: https://superofficeas-bugfix-ty-screen-designer-paradox.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# chat_message table

> This table contains messages in a chat session.

## chat\_message Table (333)

This table contains messages in a chat session.

## Fields

| Name               | Description                                                                  | Type                                                              | Nullable |
| ------------------ | ---------------------------------------------------------------------------- | ----------------------------------------------------------------- | :------: |
| id                 | The primary key (auto-incremented)                                           | PK                                                                |    No    |
| session\_id        | The reference to the associated chat session.                                | FK [chat\_session](./chat-session.mdx)                            |    No    |
| message            | The message.                                                                 | Clob                                                              |    Yes   |
| when\_posted       | When the message was posted (UTC timestamp).                                 | DateTime                                                          |    Yes   |
| special\_type      | Enum indicating if it is a special message, such as an URL redirection, etc. | Enum [ChatMessageSpecialType](./enums/chatmessagespecialtype.mdx) |    Yes   |
| special\_param     | Special parameter for the special\_type.                                     | String(255)                                                       |    Yes   |
| read\_by\_customer | Whether the message has been read by the customer or not.                    | Bool                                                              |    Yes   |
| type               | The type of the message.                                                     | Enum [ChatMessageType](./enums/chatmessagetype.mdx)               |    Yes   |
| author             | The author of the message.                                                   | String(255)                                                       |    Yes   |
| created\_by        | The user agent who wrote the message. -1 if customer                         | FK [ejuser](./ejuser.mdx)                                         |    Yes   |

<img src="https://mintcdn.com/superofficeas-bugfix-ty-screen-designer-paradox/A8Y_bcgEblTh4XOv/media/loc/en/database/tables/chat_message.png?fit=max&auto=format&n=A8Y_bcgEblTh4XOv&q=85&s=f619621d9b6cea30c5a37c8b6cc0a703" alt="chat_message table relationship diagram" width="678" height="59" data-path="media/loc/en/database/tables/chat_message.png" />

## Indexes

| Fields      | Types | Description |
| ----------- | ----- | ----------- |
| session\_id | FK    | Index       |

## Relationships

| Table                           | Description                                              |
| ------------------------------- | -------------------------------------------------------- |
| [chat\_session](./chat-session) | This table contains chat sessions.                       |
| [ejuser](./ejuser)              | This table contains entries for the users of the system. |

## Replication Flags

* None

## Security Flags

* No access control via user's Role.
