UserId Parameter (Connect-Exchange Cmdlet)
Specifies the user account to impersonate when accessing Outlook resources using the client credentials flow.
Syntax
Connect-Exchange -UserId string
Data Type
cstr
Default Value
""
Remarks
Set this property to the identifier of the user whose Outlook mailbox or calendar data you want to access. The value should be the user's unique identifier, typically in the form of a UPN ([email protected]) or Azure AD object ID.
This property is useful for service applications using client credentials to operate on behalf of a specific user without interactive login.