Model
GetLoggedAsCustomerCustomerId
Magento\LoginAsCustomer\Model\GetLoggedAsCustomerCustomerId
What it does
This class retrieves the customer ID of the customer that an admin user is currently logged in as.
Developers use this when they need to identify which customer account is being accessed through Magento's 'Login as Customer' feature, typically for auditing, logging, or conditional logic purposes.
Public Methods
- execute()