net core web api inject current user code example Example: how get the user show mvc controller core 3.1 public string LoggedInUser => User.Identity.Name;