Model

SetLoggedAsCustomerAdminId

Magento\LoginAsCustomer\Model\SetLoggedAsCustomerAdminId

What it does

This class sets the admin user ID in the customer session when an administrator logs in as a customer.

Developers use this when implementing or extending the Login as Customer feature to track which admin is impersonating a customer for security and audit purposes.

Public Methods

  • execute()