How to send chat messages from a TXT file

Whether you're running marketing campaigns, sending notifications, or managing transactional messages, the ability to automate message delivery from a simple .txt file can bring efficiency to your communication processes. Imagine creating a file once and having the Ozeki Chat Gateway handle all the rest. In this step-by-step guide, we’ll walk you through the entire process, making it easy for you to set up and implement message delivery from .txt files in just a few minutes. Let’s get started!

What is a TXT file?

A TXT file is a plain text file that contains unformatted text and is typically used for storing simple data or notes. It can be opened and edited by basic text editors like Notepad or TextEdit, and is often used for straightforward data storage and transfer.

How to send chat messages from a TXT file (Quick steps)

To send chat messages from a TXT file

  1. Open your Ozeki Chat Gateway account
  2. Add Chat Account
  3. Set up account details
  4. Install TXT file application
  5. Configure TXT file application
  6. Define message routes
  7. Create message file
  8. Move file
  9. Queue the message for delivery
  10. Log in to MyOzeki Chat
  11. View message chat history
  12. View inbox folder in the local disk
  13. Respond to the received message

Send chat messages from a TXT file (Video tutotial)

In this tutorial, you'll learn how to send chat messages directly from a .txt file. This method is ideal for situations where you have message data stored in text files and want to automate sending them through the Ozeki Chat Gateway. We’ll walk you through setting up a new chat account, and configuring the .txt file application. You’ll learn to manage .txt files, set up message routes, and handle file placement for efficient message delivery. Follow the given instructions and learn to send messages from a .txt file easily.

Step 1 - Open Your Ozeki Chat Gateway Account

Start by logging into your Ozeki Chat Gateway account. If you don’t have an account yet, you can download the Ozeki Chat Gateway from https://ozeki.chat/. After installing the application, create your Ozeki account. Once you've logged in with your credentials, you'll be directed to the Ozeki Chat Gateway home screen. From there, navigate to the main interface and choose the option to add a new chat account.

Add new chat account
Figure 1 - Add new chat account

Step 2 - Add Chat Account

To connect to the Ozeki server and enable sending chat messages and push notifications, go to the connections panel and install the Ozeki Chat Account. This connection allows mobile clients with the Ozeki App to send and receive messages for free. Click the installation link to begin the setup process.

Install Ozeki Chat account
Figure 2 - Install Ozeki Chat account

Next, enter a workspace name, which will serve as the hostname for the chat server. Then, create a username and password to connect to the chat network. The username should be in the format of user@domain, ensuring a unique identity that allows you to send and receive messages without conflicts. After entering these details, click "Ok" to save the settings.

Provide account details
Figure 3 - Provide account details

Once you've confirmed the account details, the system will verify the connection. If the authentication is successful, your Ozeki Chat Gateway will be linked to the chat network. To activate communication between your Ozeki Chat Gateway and mobile clients, toggle the slider button to green. You’ll receive a notification in the events tab confirming the connection.

Account connected
Figure 4 - Account connected

Step 3 - Install TXT File Application

After the chat account is successfully connected, return to the Ozeki Chat Gateway main interface. Go to the "Add new application or chatbot" panel, where you can integrate new apps or chatbots into your Ozeki Chat Gateway system.

Add new application
Figure 5 - Add new application

Install the TXT file application form the connections panel. The text file managing configuration makes it easy to send and receive messages using text files. When an incoming message arrives Ozeki creates a text file for the message in your incoming directory on your hard disk. If you would like to send a message all you have to do is place a text file into the outgoing directory.

Install TXT file application
Figure 6 - Install TXT file application

Now, setup the directories and the file format to use for .txt file messaging. Specify a unique name to the connection. Choose the file format, configure the message folders that are saved into the directory. Add inbox, outbox, sent, not sent and delivered directory locations. After that, click on the "Ok" button to save these settings.

Setup TXT file application
Figure 7 - Setup TXT file application

Once you have entered and confirmed the details, the system will verify the connection. If the authentication is successful, your Ozeki Chat Gateway will be linked to the selected chat network. To activate communication between your Ozeki Chat Gateway and mobile clients, toggle the slider to green. A confirmation message will then appear in the events tab, indicating the connection was successful.

Enable TXT file appilcation
Figure 8 - Enable TXT file appilcation

Step 4 - Define Message Routes

Now, head back to the main interface, and choose "Add new route" option. This route will define how incoming messages are handled and directed within your system.

Add new icoming route
Figure 9 - Add new incoming route

Next, you need to configure the incoming route. This setup will control how messages and calls are transferred between connections. Start by giving this route a unique name, then proceed with the necessary settings. Define the message route by specifying the sender and receiver addresses. Once everything is configured, click "Ok" to save the route settings.

Configure incoming route
Figure 10 - Configure incoming route

To add a new outgoing route, click on the "Add new route" option. This configuration will dictate how outgoing messages are processed and delivered to their recipients. Be sure to fill in all necessary details, such as routing criteria and destination settings, to finalize the setup.

Add new outgoing route
Figure 11 - Add new outgoing route

Set up the outgoing route to control how messages and calls are routed between connections. Begin by assigning a unique name to the route, then adjust the required settings. Specify the sender and receiver addresses to define the message path. After configuring all the details, click "Ok" to save the route.

Configure outgoing route
Figure 12 - Configure outgoing route

Step 5 - Create Message File

Create a new folder at your local disk, named messages. Open your notes and create the message in the .txt document. Enter the message recipient's email address, then the message text. Save the file, then close the document.

Create mesage file
Figure 13 - Create message file

Step 6 - Queue the message for Delivery

Move the previous .txt document—containing the message text—to the designated Ozeki's TXT_file folder. Specifically, place this document into the "out" folder within that directory. This step is crucial as it indicates that the message is ready to be processed.

Move file to out foldet
Figure 14 - Move file to "out" folder

By moving the file into the "out" folder, you are initiating the processing of the message. The Ozeki system will automatically detect the file in this folder and begin processing it according to the predefined settings. This ensures that the message will be queued for delivery and managed efficiently.

Message file processed
Figure 15 - Message file processed

After the message has been sent, open the MyOzeki Chat website in your browser. Log in to your MyOzeki account and navigate to the chats page. If the message was successfully delivered, it will appear alongside the recipient's details. To view the full conversation, click on the chat icon, and the complete chat history with that contact will be displayed.

Chat message received
Figure 16 - Chat message received

As the recipient, you can reply to the message directly through the MyOzeki Chat interface. To continue the conversation, type your response in the input box and press Send to deliver your message immediately. The chat interface supports real-time communication, ensuring smooth and continuous interactions between users.

Send chat message
Figure 17 - Send chat message

When the reply has been sent, it will appear in the events tab. When you open the Ozeki's TXT_file folder at your local disk, you will recognize that the incoming message has been placed into the "in" folder. This folder is specifically designated for incoming messages, ensuring that they are organized and easily accessible for further action.

Inbox file
Figure 18 - Inbox file

Right click on the .txt file and choose to open the document in notes. You will see the message's content. Once you open the file, you will see the content of the message clearly displayed. This allows you to review the reply and ensure that the information is accurate and as expected.

Message in inbox file
Figure 19 - Message in inbox file

Conclusion

In this guide, we’ve walked you through the process of sending chat messages directly from .txt files using the Ozeki Chat Gateway. By leveraging the simplicity of text files, you can streamline your messaging operations, whether for marketing campaigns, notifications, or transactional communications.

By following the provided instructions, you can automate message delivery and manage communications with ease. If you encounter any issues or need further assistance, refer to our additional resources or contact support.

FAQs

What is a TXT file and how is it used in Ozeki Chat?

A TXT file is a plain text file used for storing simple, unformatted text. In Ozeki Chat, TXT files are used to automate message sending and receiving by placing them in designated directories.

How do I create a TXT file for sending messages?

Create a TXT file using any basic text editor (e.g., Notepad). Enter the recipient’s email address followed by the message text, then save the file.

What should I do if my messages are not being sent?

Ensure that your TXT file is correctly formatted and placed in the "out" folder. Check your Ozeki Chat Gateway settings and routes to confirm they are properly configured.

Can I send messages to multiple recipients using a TXT file?

Yes, you can send messages to multiple recipients by creating separate TXT files for each recipient and placing them in the "out" folder. Each file should contain the recipient’s email address and the respective message text.

More information