Hi,
I am an RT newbie and need assistance. For every ticket created, I would like to notify the requestor by SMS. I have created a Mobile Number field for each user and would like to extract the number and use it in my custom scrip. Please assist.
Hi,
I am an RT newbie and need assistance. For every ticket created, I would like to notify the requestor by SMS. I have created a Mobile Number field for each user and would like to extract the number and use it in my custom scrip. Please assist.
One way would be to make a Perl template for this that can be run from the On Correspondence action. This template will get the $Ticket
variable pre-filled with the RT::Ticket
object for the ticket in question. You can then use this object to find the group users who are requestors for the ticket using something like:
my $users = $Ticket->Requestor()->UserMembersObj();
The $users
variable is then an RT::Users
object that you can iterate through to get individual RT::User
objects for each requestor:
while(my $user = $users->Next) {
# Do something to send the SMS here
}
The contents of this loop will need to be able to extract the SMS number from the Mobile Number field you created for the user and then talk to whatever service API/device you have for sending SMS messages.
At the end of your template just return the empty string so that RT doesn’t try to send an email.
You can checkout this as well:
Hi guys,
Thanks for the assistance. I managed by referencing the below thread: