function getSenderDisplayName(sender) {
  try {
    const user = AdminDirectory.Users.get(
      sender.name.replace("users/", ""),
      { projection: 'BASIC', viewType: 'domain_public' });
    return user.name.displayName ?? user.name.fullName;
  } catch (e) {
    console.error("Unable to get display name");
    return "Unknown"
  };
}
Gets the display name from AdminDirectory Services.

@param {!Object} sender 
@return {string} User name on success | 'Unknown' if not.