I believe you need to modify the core code to do that, i'd suggest making the mail call here https://github.com/osTicket/osTicket/blob/develop/include/class.ticket.php#L1212 and you can get some pointers from here https://github.com/osTicket/osTicket/blob/develop/include/class.ticket.php#L2524