Chapter 1. Getting Started

Table of Contents

Development Environment
Framework checkout
Useful Tools
Linking Expansion Modules
Architecture Overview
Core Modules
Frontend Handle
Frontend Modules
CMD Frontend
Generic Interface Modules
Generic Interface Invoker Modules
Generic Interface Mapping Modules
Generic Interface Operation Modules
Generic Interface Transport Modules
Scheduler Task Handler Modules


OTRS is a multi-platform web application framework which was originally developed for a trouble ticket system. It supports different web servers and databases.

This manual shows how to develop your own OTRS modules and applications based on the OTRS styleguides.

Development Environment

To facilitate the writing of OTRS expansion modules, the creation of a development environment is necessary. The source code of OTRS and additional public modules can be found on github.

Framework checkout

First of all a directory must be created in which the modules can be stored. Then switch to the new directory using the command line and check them out by using the following command:

# for git master
shell> git clone -b master
# for a specific branch like OTRS 3.3
shell> git clone -b rel-3_3

Check out the module-tools module (from github) too, for your development environment. It contains a number of useful tools:

shell> git clone

Please configure the OTRS system according to the installation instructions in the admin manual.

Useful Tools

There are two modules that are highly recommended for OTRS development: OTRSCodePolicy and Fred.

OTRSCodePolicy is a code quality checker that enforces the use of common coding standards also for the OTRS development team. It is highly recommended to use it if you plan to make contributions. You can use it as a standalone test script or even register it as a git commit hook that runs every time that you create a commit. Please see the module documentation for details.

Fred is a little development helper module that you can actually install or link (as described below) into your development system. It features several helpful modules that you can activate, such as an SQL logger or an STDERR console. You can find some more details in its module documentation.

By the way, these tools are also open source, and we will be happy about any improvements that you can contribute.

Linking Expansion Modules

A clear separation between OTRS and the modules is necessary for proper developing. Particularly when using a git clone, a clear separation is crucial. In order to facilitate the OTRS access the files, links must be created. This is done by a script in the directory module tools repository. Example: Linking the Calendar Module:

shell> ~/src/module-tools/ ~/src/Calendar/ ~/src/otrs/

Whenever new files are added, they must be linked as described above.

As soon as the linking is completed, the SysConfig must be rebuilt to register the module in OTRS. Additional SQL or Perl code from the module must also be executed. Example:

shell> ~/src/otrs/bin/ Maint::Config::Rebuild
shell> ~/src/module-tools/ -m Calendar.sopm -a install
shell> ~/src/module-tools/ -m Calendar.sopm -a install

To remove links from OTRS enter the following command:

shell> ~/src/module-tools/ ~/src/otrs/