/usr/share/otrs/Kernel/Config/GenericAgent.pm.examples is in otrs2 3.3.5-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 | # --
# Kernel/Config/GenericAgent.pm - config file of generic agent
# Copyright (C) 2001-2013 OTRS AG, http://otrs.org/
# --
# This software comes with ABSOLUTELY NO WARRANTY. For details, see
# the enclosed file COPYING for license information (AGPL). If you
# did not receive this file, see http://www.gnu.org/licenses/agpl.txt.
# --
package Kernel::Config::GenericAgent;
use strict;
use warnings;
use utf8;
use vars qw(@ISA @EXPORT %Jobs);
require Exporter;
@ISA = qw(Exporter);
@EXPORT = qw(%Jobs);
# -----------------------------------------------------------------------
# config options
# -----------------------------------------------------------------------
%Jobs = (
# --
# [name of job] -> close all tickets in queue spam
# --
'close spam' => {
# get all tickets with these properties
Queue => 'spam',
States => ['new', 'open'],
Locks => ['unlock'],
# new ticket properties (no option is required,
# use just the options which should be changed!)
New => {
# new queue
Queue => 'spam',
# possible states (closed successful|closed unsuccessful|open|new|removed)
State => 'closed successful',
# new ticket owner (if needed)
Owner => 'root@localhost',
# if you want to add a Note
Note => {
From => 'GenericAgent',
Subject => 'spam!',
Body => 'Closed by otrs.GenericAgent.pl because it is spam!',
},
},
},
# --
# [name of job] -> close and delete all tickets in queue delete
# --
'delete' => {
# get all tickets with these properties
Queue => 'delete',
States => ['new', 'open'],
Locks => ['unlock'],
# tickets older then 60 minutes
TicketCreateTimeOlderMinutes => 60,
# new ticket properties (no option is required,
# use just the options which should be changed!)
New => {
# DELETE!
Delete => 1,
},
},
# --
# [name of job] -> move all tickets from tricky to experts
# --
'move tickets from tricky to experts' => {
# get all tickets with these properties
Queue => ['tricky', 'tricky1'],
States => ['new', 'open'],
Locks => ['unlock'],
# new ticket properties
New => {
Queue => 'experts',
Note => {
From => 'GenericAgent',
Subject => 'Moved!',
Body => 'Moved from "tricky" to "experts" because it was not possible to find a solution!',
ArticleType => 'note-internal', # note-internal|note-external|note-report
},
},
},
# --
# [name of job] -> send escalation notifications
# --
'send escalation notifications' => {
Escalation => 1,
# new ticket properties
New => {
# notify all agents who selected the queue in "my queues/custom queues"
# Module => 'Kernel::System::GenericAgent::NotifyAgentGroupOfCustomQueue',
# notify all agents who can access the ticket with rw permissions
Module => 'Kernel::System::GenericAgent::NotifyAgentGroupWithWritePermission',
},
},
# --
# [name of job] -> move all tickets from xyz to experts
# --
'move escalation ticket to experts and execute CMD' => {
# get all tickets with these properties
Queue => 'xyz',
Escalation => 1,
# new ticket properties
New => {
Queue => 'experts',
# your program (/path/to/your/program) will be executed like
# "/path/to/your/program $TicketNumber $TicketID" ARG[0] will
# be the ticket number and ARG[1] the ticket id
CMD => '/path/to/your/program',
},
},
# --
# [name of job] -> move all tickets from abc to experts and change priority, set dynamic field
# --
'move all priority "3 normal" tickets from abc to experts and set priority to "4 high"' => {
# get all tickets with these properties
Queue => 'abc',
Priorities => ['3 normal'],
# new ticket properties
New => {
Queue => 'experts',
Priority => '4 high',
DynamicField_ProductSkill => 'Expert required',
},
},
# --
# [name of job] -> move specific tickets from abc to experts
# --
'move specific tickets from abc to experts' => {
# only move tickets where:
# Dynamic Field:
# NameX is exactly 123
# NameY is like admin (as admin, administrator or administrators
# Queue is abc
# get all tickets with these properties
Queue => 'abc',
DynamicField_NameX => {
Equals => '123',
},
DynamicField_NameY => {
Like => 'admin*',
},
Priorities => ['3 normal'],
# new ticket properties
New => {
Queue => 'experts',
Priority => '4 high',
DynamicField_ProductSkill => 'Expert required',
},
},
# --
# [name of job] -> delete all tickets with subject 'VIRUS 32' in queue abc
# (take care if you use From, To, Cc, Subject or Body because it takes
# database performance!)
# --
'delete all tickets with subject "VIRUS 32" in queue abc' => {
# get all tickets with these properties
Queue => 'abc',
# From => '%Feedback%',
# To => '%Feedback%',
# Cc => '%Feedback%',
Subject => '%VIRUS%',
# Body => '%installing%',
# DynamicField_ProductSkill => {
# Equals => 'Expert required',
# },
# new ticket properties
New => {
# DELETE!
Delete => 1,
},
},
# --
# [name of job] -> send reminder emails to agents
# --
'send reminder emails to agents' => {
# get all tickets with these properties
States => ['pending reminder'],
TicketPendingTimeOlderMinutes => 10,
# new ticket properties (no option is required,
# use just the options which should be changed!)
New => {
# if you want to add a Note
Note => {
From => 'Reminder Admin',
Subject => 'Reminder Notification',
Body => 'The reminder time of this ticket has been reached!',
},
},
},
# --
);
# -----------------------------------------------------------------------
# end of config options
# -----------------------------------------------------------------------
1;
|