Model
TokenUserContext
Magento\Webapi\Model\Authorization\TokenUserContext
What it does
This class determines the user context (user ID and type) for web API requests by validating Bearer tokens from the Authorization header.
Developers use this to identify whether the API request is from a customer, admin user, or integration, enabling proper authentication and authorization in Magento's REST/SOAP APIs.
Public Methods
- getUserId()
- getUserType()
- _resetState()