Ozeki 10
SMS Gateway
SMS with Client Software
SMS from/to Database
Autoreply SMS
Built-in SMTP server
SMS from C# API
SMS through Email
SMS from/to File
CSV file format
SMS from/to FTP server
Application starter SMS
SQL Logging
System Database
Robot Controller
Installation guide
Terms and Definitions
Bulk Messenger
Developer tools

Ozeki SMS Gateway
SMS through Email SMS through Email | CSV file format CSV file format

SMS from/to File

Ozeki SMS Gateway's File User is capable to send and receive SMS messages in different file formats. This guide will show you how to install and configure a File User by selecting the file format and the location of the following message boxes: Inbox, Outbox, Sent, Failed, Delivered.

Start the video

Supported file formats:

  • Simple
  • Text
  • Verbose
  • List
  • CSV
  • XML
  • SAP
  • ATF
  • KAL
  • Ozeki SMS Gateway's File User is capable to save SMS messages in the Inbox and send SMS messages from the Outbox. The default folder location for the incoming/outgoing messages are 'C:\smsTemp\smsin' and 'C:\smsTemp\smsout'. The outgoing messages are periodically checked in every 10 seconds as default, but you can always configure it. If you already have a File User installed, please jump to general configuration below.

    In case you do not have a File User, you can easily install one with Ozeki SMS Gateway's browser GUI.

    Installing File User

    Start with installing a File User in Ozeki SMS Gateway by clicking the 'Add' button on the right side panel of the 'Management' page. The button is on the 'Users/Applications' panel (Figure 1).

    Figure 1 - Click 'Add' on the 'Users/Applications' panel to add new users

    On the new page you will see two panels. The left hand panel is called 'Users/Applications'. It contains the list of installed users. Each of them have a unique username and on the bottom of this panel you will see the actual number of users. On the right hand you can see a panel called 'Add user or application'. It contains a list of user and application types that can be installed. You can see a small description after each type in the list.

    Please click the 'install' button next to 'TXT file', which is the File User (Figure 2).

    Figure 2 - Click 'install' next to 'TXT file' to add File User

    On the next page you will need to provide a unique name for your File User and click 'OK'. The name should differ from all user and application names.

    Configuring File User

    You should start with the 'General' tabpage on your File User's 'Configuration' panel (Figure 3). This page comes up directly after providing a unique username.

    On the upper section called 'Settings', please select the file format from the dropdown menu. Our video tutorial explains how to use the Text format, but more file types are discussed below.

    Directly under the dropdown menu, you can set the time period for checking the directory for new messages. This textbox accepts every positive whole number which represents the time period in seconds. It is 10 seconds as default:

    Figure 3 - Set the format of the file and the time period to check the Outbox directory for new messages

    On the lower section you can find 5 sub-tabpages called: Inbox, Outbox, Sent, Failed, Delivered.
    These tabpages contain editable fields with the following default values:
    • Inbox - C:\smsTemp\smsin
    • Outbox - C:\smsTemp\smsout
    • Sent - C:\smsTemp\smssent
    • Failed - C:\smsTemp\smsfailed
    • Delivered - C:\smsTemp\smsdelivered

    The location of the message files determine their status. Each directory represents a specific status. You can always modify these directories (Figure 4)

    Figure 4 - Default directories for Inbox, Outbox, Sent, Failed, Delivered message files

    What does each message folder contain?
    • Inbox: Messages delivered to the File User. This can be set by using Ozeki SMS Gateway's inbound routing.
    • Outbox: Messages to send from the File User. This can be set by using Ozeki SMS Gateway's outbound routing.
    • Sent: Messages that have been accepted for delivery by Ozeki SMS Gateway and the SMS service provider.
    • Failed: Messages that were refused by Ozeki SMS Gateway or the SMS service provider.
    • Delivered: Messages that got a delivery success report from the SMS service provider.

    Sending SMS message from File User

    Both your application and Ozeki SMS Gateway's engine will work on the Outbox folder, which has a default location at C:\smsTemp\smsout Both software shouldn't work simultaneously on the same files. You can append each file with a '.lock' extension, so only your application can modify them while SMS Gateway should not reach them.

    Outgoing messages can be stored in 4 directories:
    (It depends on the message status.)
    Outbox folder - C:\smsTemp\smsout\
    Sent folder - C:\smsTemp\smssent\
    Failed folder - C:\smsTemp\smsfailed\
    Delivered folder - C:\smsTemp\smsdelivered\
    (With FTP, NFS or Samba you can remotely access these directories from your application.)

    Locking Files to avoid conflicts:

    You can easily send SMS messages with your application by creating a locked file in the Outbox directory. It is identified by the '.lock' extension appended to the filename. Ozeki SMS Gateway will not try to read locked files, since they can still be edited by your application. Please delete the locked file when finished.

    See how to use locked files:

    1.) Create: C:\smsTemp\smsout\mysms.sml.lock

    2.) Create: C:\smsTemp\smsout\mysms.sml

    3.) Delete: C:\smsTemp\smsout\mysms.sml.lock

    After your company's application has finally unlocked the file, Ozeki SMS Gateway's SMS engine will read the file and delete it. A new file will be placed in the smssent or smsfailed directory depending on the outcome. In the outcome directories the same locking mechanism works.

    Understand it by examining the following diagram:

    Figure 5 - See how messages flow between your application and the SMS service provider

    Your SMS service provider can send delivery reports of sent, refused and delivered messages to your Ozeki SMS Gateway. If a message file is placed in the 'sent' directory, it means it was sent by the SMS service provider. If it has reached it's final destination, a text file will be created in the 'delivered' folder and the same locking steps apply on it.

    Accepted File formats

    Ozeki SMS Gateway's File User supports useful file formats like simple, text, verbose, list, XML, CSV and more. You can send and receive messages in any available file format. Scroll to the top to see the whole list. You can select the preferred file format from the 'General' tab of the File User's 'Configuration' panel.


    It stores each SMS message in separate files.

    You can select the 'Simple' file format from the dropdown menu as seen on Figure 3. All 'Simple' files have the name of either the sender or recipient. The difference is that both incoming and outgoing messages arrive in a separate folder discussed above. The message content is in the file. For example here is an outgoing message:

    Hello world

    The side effect is hidden in the name convention. No files can be in a single directory with the same name. Which means you can only send one message at a time to a single recipient. To send multiple messages you need to wait Ozeki SMS Gateway to delete the last message before you can insert the new one. Vice versa you can only read and delete one message at a time from the same sender. If Ozeki SMS Gateway receives multiple messages from the same sender then the newest message will count. Since the new message always overwrites the old one. Please take these facts into consideration before selecting the 'Simple' file format from the dropdown menu.

    It can be easily used for position tracking. For example the new coordinates can overwrite the old ones. You can track vehicles that are set to send their coordinates periodically in SMS. In this case the File User of Ozeki SMS Gateway stores the last coordinate in 'Simple' file format.


    It stores every SMS message in a separate file, although they can have unique filenames.

    The Verbose format can store multiple message files from the same sender and multiple message files to the same recipient. These files have an '.sms' file extension and contains more information as the 'Simple' format. The first line in these files consists of the sender's phone number, the second line is the recipient's number while the message text is in the third line. Do not forget that each message is stored in different files.

    This is how a file in 'Verbose' format looks like:

    The message text


    It stores multiple SMS messages in a single file.

    'List' file format enables Ozeki SMS Gateway to comfortably send and receive a massive amount of messages. Multiple SMS messages are stored in a single '.sml' file. As an example it can look the following way:

    +3620454536 This is the first message
    +3620993772 This is the second message
    +3630778972 Use Ozeki SMS Gateway!

    You can see that each line contains a message with the recipient's or sender's phone number, depending on which folder the file is stored in. Each phone number and message pair is separated by a space. If you would like to send SMS messages, please place your file into the Outbox folder.


    Works the same way as the 'List' fileformat. The only difference is that text files have a '.txt' file extension.

    You should place the text files in the output folder for sending as you can see in the video on the top of the page. For example you can save it in the default folder at 'C:\smsTemp\smsout\mysms.txt'.


    'XML' file format is used for sending and receiving SMS messages with Ozeki SMS Gateway.
    These files are saved in '.xml' extension.

    The following XML format is used by Ozeki SMS Gateway:

          <text>Message text</text> 
          <time>2011.08.25. 7:56:31</time> 

    <originator>: These tags surround the sender's phone number.
    <recipient>: These tags surround the recipient's phone number.
    <text>: The text of the message is provided between these tags.
    <time>: Between these tags you can set when the message should be sent.
    <messagetype>: Between these tags you can declare the type of the message.

    Configuring user Log Generation

    Check out the 'Logging' tabpage on the File User's 'Configuration' panel to manage user logs. If you place a tick in both checkboxes (Figure 6), it helps you to debug communication problems. It is capable to log the SMS message flow and low level communication related to the File User.

    Figure 6 - The 'Logging' tabpage. Select what to log and how

    Below the checkbox you can find the 'Log file settings' groupbox with file related settings. The default log directory is C:\Program Files\Ozeki\Ozeki10\Data\NG\Logs, but you can always modify it. The maximum size of each log file and the maximum number of log files can also be set. If a log file gets bigger than the maximum file size, Ozeki SMS Gateway creates a new File. If the maximum number of log files have been reached, the oldest file should be replaced. The textbox to set this is called 'Number of rotated files'.

    'Logging' tabpage's default values:
    • Log sent and received messages in human readable format: Checked
    • Log low level communication: Unchecked
    • Log directory: C:\Program Files\Ozeki\Ozeki10\Data\NG\Logs
    • Maximum log file size: 8000 kB
    • Number of rotated files: 8

    If you like these default values, please do not change the boxes.

    Advanced Settings

    These settings can be reached on the 'Advanced' tabpage (Figure 7). Here you can set the user's login details for Ozeki SMS Gateway, which are the username and password pair. You should also specify the sender's address.

    In the middle section you can change the 'Type of Addressbook' to SQL, LDAP or File then configure it on your left-hand.

    The lower sections contains an 'Allow routing table override' option, which automatically selects the most suitable service provider for each message. You can also 'Enable accounting for this user' which applies the credit limit for this File User. A cost of a single SMS is one credit. You can add credits by clicking 'Settings' on the left hand panel.

    Figure 7 - 'Advanced' tabpage

    SMS Scheduling

    Here you can set the time period for the File User to send messages. The Outbox folder will not be checked by Ozeki SMS Gateway's File User until the start of the schedule. SMS Scheduling is turned off as default (Figure 8).

    Figure 8 - Modifying the configuration of SMS Scheduling

    If you have finished the configuration of your File User, please save it by clicking 'OK'.

    You can always come back to check events or modify configuration. You can do this by selecting your user on the 'Users/Applications' panel and clicking appropriate button on the left hand panel (Figure 9)

    Figure 9 - Modifying File User configuration

    Copyright © 2000- - Ozeki Informatics Ltd. | | Tel: +36 1 371 0150
    Home > Products > Ozeki 10 > Apps > SMS Gateway > Solutions > SMS from/to File
    Page: 5745 | Login