Initial Queue Detection

Hi all,

We are implementing RT as a customer support application. Many of our
customers send emails to addresses that they believe to be another
company (under a wholesale agreement with them). To support this in RT,
the email addresses for these queues accept and send out using these
specific addresses.

Once a ticket is created in RT, it may need to be escalated to our Tier
2 support, which is a queue in itself. If the user replies back to the
customer once the ticket is in the Tier 2 support queue, it will use the
address on the current queue…which is not a result we can have.

So, I know there are options but ide like to know what you all think is
the most appropriate to implement:

My first choice would be to always reply to the user using the email
address on the queue the ticket was created in:
Assuming this is the method, is there a method call or attribute
that I can grab on the ticket object (via scips or templates) that gives
me access to the queue the ticket was created in. If so, how do I go
about accessing it.

A second option would be to alter the way tickets are escalated to other
queues (or groups), but I do not know how that would work. Without
moving tickets into different queues (where the user does not have
ownership privileges) there is no way to move it back to the new/unowned
tickets query on the homepage of a user in the “escalated to” queue.

Hopefully someone has some insight into this issue.

Thanks,
Anthony Meo

Hi all,

We are implementing RT as a customer support application. Many of our
customers send emails to addresses that they believe to be another
company (under a wholesale agreement with them). To support this in RT,
the email addresses for these queues accept and send out using these
specific addresses.

Once a ticket is created in RT, it may need to be escalated to our Tier
2 support, which is a queue in itself. If the user replies back to the
customer once the ticket is in the Tier 2 support queue, it will use the
address on the current queue…which is not a result we can have.

So, I know there are options but ide like to know what you all think is
the most appropriate to implement:

My first choice would be to always reply to the user using the email
address on the queue the ticket was created in:
Assuming this is the method, is there a method call or attribute
that I can grab on the ticket object (via scips or templates) that gives
me access to the queue the ticket was created in. If so, how do I go
about accessing it.

You could do this by going through the ticket transactions and
finding the OldValue of the first queue change transaction.

A second option would be to alter the way tickets are escalated to other
queues (or groups), but I do not know how that would work. Without
moving tickets into different queues (where the user does not have
ownership privileges) there is no way to move it back to the new/unowned
tickets query on the homepage of a user in the “escalated to” queue.

Hopefully someone has some insight into this issue.

Why can’t they reply to the e-maill address for the first queue? RT
will find the ticket number in the subject and make sure the
correspondence happens in the right place.

-Todd

Hi all,

We are implementing RT as a customer support application. Many of our
customers send emails to addresses that they believe to be another
company (under a wholesale agreement with them). To support this in
RT,
the email addresses for these queues accept and send out using these
specific addresses.

Once a ticket is created in RT, it may need to be escalated to our
Tier
2 support, which is a queue in itself. If the user replies back to
the
customer once the ticket is in the Tier 2 support queue, it will use
the
address on the current queue…which is not a result we can have.

So, I know there are options but ide like to know what you all think
is
the most appropriate to implement:

My first choice would be to always reply to the user using the email
address on the queue the ticket was created in:
Assuming this is the method, is there a method call or attribute
that I can grab on the ticket object (via scips or templates) that
gives
me access to the queue the ticket was created in. If so, how do I go
about accessing it.

You could do this by going through the ticket transactions and
finding the OldValue of the first queue change transaction.

[[Anthony Meo]] Would you happen to have an example of this. I am
currently “trying by dying” on this and making slow progress…though
im sure I will get there.
The perfect method for this would be one that returns the email address
of the original queue if it has been changes, else, it returns the email
address of the current queue (assuming it has not changed queues).

A second option would be to alter the way tickets are escalated to
other
queues (or groups), but I do not know how that would work. Without
moving tickets into different queues (where the user does not have
ownership privileges) there is no way to move it back to the
new/unowned
tickets query on the homepage of a user in the “escalated to” queue.

Hopefully someone has some insight into this issue.

Why can’t they reply to the e-maill address for the first queue? RT
will find the ticket number in the subject and make sure the
correspondence happens in the right place.

[[Anthony Meo]] In this case, they may reply to the original email
address…I have tested this and it works just fine. The only issue is
regarding the person working in RT and sending out the email to the
customer…which is how they will work. Currently, it will take the
email address of the existing queue.

-Todd

[[Anthony Meo]] In this case, they may reply to the original email
address…I have tested this and it works just fine. The only issue is
regarding the person working in RT and sending out the email to the
customer…which is how they will work. Currently, it will take the
email address of the existing queue.

Again, why can’t the address change?

[[Anthony Meo]] In this case, they may reply to the original email
address…I have tested this and it works just fine. The only issue
is
regarding the person working in RT and sending out the email to the
customer…which is how they will work. Currently, it will take the
email address of the existing queue.

Again, why can’t the address change?

[[Anthony Meo]] Here is an example. We have a wholesale agreement with
company X. This company sends in emails for support using an email
address called helpdesk@X.com. As far as they know, our company does
not exist. The customer support rep working with the customer would
send responses to the customer from within the queue. As long as the
ticket stays in the original queue, emails will always be sent using
helpdesk@X.com to the requestor.

Now, the ticket might get to a point where the customer service rep
cannot help anymore due to lack of knowledge. This ticket must be
escalated, so the customer service rep moves the ticket to the “Tier 2
Support Queue”. This queue has an email address of tac@ourcompany.com.
If the tier 2 support rep needs to ask the customer a question the email
will be sent using tac@ourcompany.com. This is not the desired affect
(unless the ticket was created in that queue).

The desired affect would be that the tier 2 tech support rep would send
the customer a question and the email address "from address’ would be
helpdesk@X.com.

Thanks,
-Anthony

This ticket must be
escalated, so the customer service rep moves the ticket to the “Tier 2
Support Queue”. This queue has an email address of tac@ourcompany.com.
If the tier 2 support rep needs to ask the customer a question the email
will be sent using tac@ourcompany.com. This is not the desired affect

You are using the wrong model. If the ticket is escalated, then the
customer service rep makes the Tier 2 Support (T2S) person the owner of
the ticket so that it shows up in the T2S person’s MyTickets. All of
company X’s tickets must remain in company X’s queue.

Russell Mosemann, Ph.D. * Computing Services * Concordia University, Nebraska
"Confucious say: Mind like parachute. Only function when open."

This ticket must be
escalated, so the customer service rep moves the ticket to the “Tier 2
Support Queue”. This queue has an email address of
tac@ourcompany.com.
If the tier 2 support rep needs to ask the customer a question the
email
will be sent using tac@ourcompany.com. This is not the desired affect

You are using the wrong model. If the ticket is escalated, then the
customer service rep makes the Tier 2 Support (T2S) person the owner of
the ticket so that it shows up in the T2S person’s MyTickets. All of
company X’s tickets must remain in company X’s queue.

Or you could make a ticket escalation queue for each company. So
there’s an X queue and an X2 queue. Each of those queues would be set
to use the same e-mail address.

Simon

This ticket must be
escalated, so the customer service rep moves the ticket to the “Tier 2
Support Queue”. This queue has an email address of
tac@ourcompany.com.
If the tier 2 support rep needs to ask the customer a question the
email
will be sent using tac@ourcompany.com. This is not the desired affect

You are using the wrong model. If the ticket is escalated, then the
customer service rep makes the Tier 2 Support (T2S) person the owner of
the ticket so that it shows up in the T2S person’s MyTickets. All of
company X’s tickets must remain in company X’s queue.

[[Anthony Meo]] If we go with this model how can we take care of the
following: The current owner does not know who to escalate the ticket
to. The tier 2 support group consists of about 50 people. The owner
does not have insight, nor authority to assign anything to a specific
person.

Given that, is there a way to make the ticket visible to the whole group
(meaning the group of people with “Show Ticket” privileges on the tier 2
support queue? Within tier 2, It may be escalated again to a higher
more specific queue i.e Network Support, PC Support, etc… where a
higher level person has to perform work.

Actually, I would prefer to keep the tickets in the queue specific to
that customer. So if this can be accommodated, that would be great.

-Anthony

This ticket must be
escalated, so the customer service rep moves the ticket to the "Tier
2

Support Queue". This queue has an email address of
tac@ourcompany.com.
If the tier 2 support rep needs to ask the customer a question the
email
will be sent using tac@ourcompany.com. This is not the desired affect

You are using the wrong model. If the ticket is escalated, then the
customer service rep makes the Tier 2 Support (T2S) person the owner
of
the ticket so that it shows up in the T2S person’s MyTickets. All of
company X’s tickets must remain in company X’s queue.

Or you could make a ticket escalation queue for each company. So
there’s an X queue and an X2 queue. Each of those queues would be set
to use the same e-mail address.

[[Anthony Meo]] Certainly an option, but if there are 50 customers with
2 or 3 or 4 escalation levels, this would become a management nightmare.

An email address is associated with a queue. If you want a reply or
comment to have a specific email address, the ticket needs to reside in
the queue with that address.

What you want is for a specific email address to be associated with a
ticket, no matter what queue it is in. That’s not how this works. You
might be able to cobble together a template that looks to see what queues
a ticket has visited and specify an address based on that, but that
sounds a little complicated. If you are up to it, go for it.

[[Anthony Meo]] If we go with this model how can we take care of the
following: The current owner does not know who to escalate the ticket
to. The tier 2 support group consists of about 50 people. The owner
does not have insight, nor authority to assign anything to a specific
person.

The owner doesn’t need to have insight. He just needs to know someone in
the next tier. That person can reassign the ticket to someone else, if
necessary. In fact, it could be that person’s responsibility to
disseminate escalated tickets.

Given that, is there a way to make the ticket visible to the whole group
(meaning the group of people with “Show Ticket” privileges on the tier 2
support queue? Within tier 2, It may be escalated again to a higher
more specific queue i.e Network Support, PC Support, etc… where a
higher level person has to perform work.

You could make tickets in all of the queues visible to everyone in tier 2
and above, but I doubt you want to do that, because they normally would
not deal with the majority of the tickets.

Russell Mosemann, Ph.D. * Computing Services * Concordia University, Nebraska
"Confucious say: Man who throw dirt lose ground."

An email address is associated with a queue. If you want a reply or
comment to have a specific email address, the ticket needs to reside in
the queue with that address.

That’s not necessarily true. Adding From: and Reply-To: headers to your
templates should override the queue-default headers. You could then use
a ticket custom field to hold the ticket’s “address” or even do a
dynamic lookup.

An email address is associated with a queue. If you want a reply or
comment to have a specific email address, the ticket needs to reside in
the queue with that address.

[[Anthony Meo]] Regardless of the email address you send to (as long as
it goes to RT) the ticket will be updated as long as the ticket number
is in the subject. I have tested this extensively.

What you want is for a specific email address to be associated with a
ticket, no matter what queue it is in. That’s not how this works. You
might be able to cobble together a template that looks to see what
queues
a ticket has visited and specify an address based on that, but that
sounds a little complicated. If you are up to it, go for it.

[[Anthony Meo]] The logic seems feasible, could do it in the send email
action. Before sending the email out of RT, if the ticket originated in
another queue, use that address, else use the current queue address.On Mon, 4 Apr 2005, Meo, Anthony wrote:

[[Anthony Meo]] If we go with this model how can we take care of the
following: The current owner does not know who to escalate the ticket
to. The tier 2 support group consists of about 50 people. The owner
does not have insight, nor authority to assign anything to a specific
person.

The owner doesn’t need to have insight. He just needs to know someone
in
the next tier. That person can reassign the ticket to someone else, if
necessary. In fact, it could be that person’s responsibility to
disseminate escalated tickets.

[[Anthony Meo]] This is a good point, sort of like a triage person. The
only issue is if he/she is out…I don’t think this will pass because
RT is being implemented to remove the reliance on single people.

Now I understand. I’ll try to help but I’m not in a position
to test my suggestions right now so you’ll have to test them
and get back to me.

First, I think we can change the From address for all emails
by adding a From header to each template.

Go to: Configuration->Global->Templates

and add a From line to the top of each template, like this example:

==== Template Correspondence =======From: makeupsomeaddress@yourcompany.com
RT-Attach-Message: yes

{$Transaction->Content()}

==== END of Template =====

The blank line between the headers is important. Now send
and e-mail by replying to a ticket and make sure the From
address is the one you added and not the one for the
queue.

Next, we want to write a function that gets the correspond
address of a ticket based on the first queue.

==== File /opt/rt3/local/lib/RT/Ticket_Local.pm ====
use strict;
no warnings qw(redefine);

sub FirstQueueEmail {

my $self = shift;
my $email = $self->QueueObj->CorrespondAddress;

my $transactions = $self->Transactions;
$transactions->Limit( FIELD => 'Type', VALUE => 'Set' );
$transactions->Limit( FIELD => 'Field', VALUE => 'Queue' );
if ( $transactions->Count ) {
    my $queue_id = $transactions->First->OldValue;
    my $queue = RT::Queue->new( $RT::SystemUser );
    my ($rv, $msg) = $queue->Load($queue_id);
    $email = $queue->CorrespondAddress if $rv;
}

return $email;

}

1;
==== END File ====

Finally, if the header tests in the rist step worked, change the
from line to:

From: { $Ticket->FirstQueueEmail }

Let me know if you have problems.

-Todd

Now I understand. I’ll try to help but I’m not in a position
to test my suggestions right now so you’ll have to test them
and get back to me.

First, I think we can change the From address for all emails
by adding a From header to each template.

Go to: Configuration->Global->Templates

and add a From line to the top of each template, like this example:

==== Template Correspondence =======From: makeupsomeaddress@yourcompany.com
RT-Attach-Message: yes

{$Transaction->Content()}

==== END of Template =====

The blank line between the headers is important. Now send
and e-mail by replying to a ticket and make sure the From
address is the one you added and not the one for the
queue.

Next, we want to write a function that gets the correspond
address of a ticket based on the first queue.

==== File /opt/rt3/local/lib/RT/Ticket_Local.pm ====
use strict;
no warnings qw(redefine);

sub FirstQueueEmail {

my $self = shift;
my $email = $self->QueueObj->CorrespondAddress;

my $transactions = $self->Transactions;
$transactions->Limit( FIELD => 'Type', VALUE => 'Set' );
$transactions->Limit( FIELD => 'Field', VALUE => 'Queue' );
if ( $transactions->Count ) {
    my $queue_id = $transactions->First->OldValue;
    my $queue = RT::Queue->new( $RT::SystemUser );
    my ($rv, $msg) = $queue->Load($queue_id);
    $email = $queue->CorrespondAddress if $rv;
}

return $email;

}

1;
==== END File ====

Finally, if the header tests in the rist step worked, change the
from line to:

From: { $Ticket->FirstQueueEmail }

Let me know if you have problems.

-Todd
[[Anthony Meo]]

This sounds like a viable option I will use your code a start for this
and then provide some feedback on this all as to how it works out and
any other mods I make.

If anyone has any thoughts on the idea of making this into a “Branding
Engine” of sorts, please keep this discussion going. Whatever the final
method of implementation is, I will be creating configuration pages (if
necessary to get this to be fully usable in a production environment.

Best,
-Anthony

I tested briefly and the email address is changed appropriately. More
configuration etc…tomorrow, when I’m not falling asleep.

Thanks very much for the help, this has been a great push in the right
direction (if not half the solution altogether.)

Cheers!
-Anthony

Now I understand. I’ll try to help but I’m not in a position
to test my suggestions right now so you’ll have to test them
and get back to me.

First, I think we can change the From address for all emails
by adding a From header to each template.

Go to: Configuration->Global->Templates

and add a From line to the top of each template, like this example:

==== Template Correspondence =======From: makeupsomeaddress@yourcompany.com
RT-Attach-Message: yes

{$Transaction->Content()}

==== END of Template =====

The blank line between the headers is important. Now send
and e-mail by replying to a ticket and make sure the From
address is the one you added and not the one for the
queue.

Next, we want to write a function that gets the correspond
address of a ticket based on the first queue.

==== File /opt/rt3/local/lib/RT/Ticket_Local.pm ====
use strict;
no warnings qw(redefine);

sub FirstQueueEmail {

my $self = shift;
my $email = $self->QueueObj->CorrespondAddress;

my $transactions = $self->Transactions;
$transactions->Limit( FIELD => 'Type', VALUE => 'Set' );
$transactions->Limit( FIELD => 'Field', VALUE => 'Queue' );
if ( $transactions->Count ) {
    my $queue_id = $transactions->First->OldValue;
    my $queue = RT::Queue->new( $RT::SystemUser );
    my ($rv, $msg) = $queue->Load($queue_id);
    $email = $queue->CorrespondAddress if $rv;
}

return $email;

}

1;
==== END File ====

Finally, if the header tests in the rist step worked, change the
from line to:

From: { $Ticket->FirstQueueEmail }

Let me know if you have problems.

-Todd