If Im understanding you correctly, and you just want to make sure the Suggested Username is not taken....here's something that will search your Service Desk environment to see if a particular instance of an object exists. (my username format was first letter of given name + last name.
import System
static def GetAttributeValue(Activity):
Value = 'found nothing for = ' + Activity._EmployeeFirstName.Substring(0,1)+ Activity._EmployeeLastName
user = Activity.GetObjectByAttribute("System.User","Name", Activity._EmployeeFirstName.Substring(0,1)+ Activity._EmployeeLastName)
if user != null:
Value = 'found =' + user.Title
return Value