Today we talk about how in Magento 2 get current admin user detail?. in this tutorial we will cover how to get current admin username and current admin email and other information included as well. So let’s start with our code example.
public function __construct(
$this->authSession = $authSession;
public function getCurrentUser()
Now you have access to current admin information. You can get information with the following code.
$this->getCurrentUser->getEmail(); //get current admin email