CmdID / PowerShell / Cmdlets / Invoke
Invoke-RDUserLogoff
Ends a user session and closes all running applications. Windows Server PowerShell reference
From the Windows Server PowerShell reference 3 parameters Its page in the reference
Parameters
-ForceForces the command to run without asking for user confirmation.-HostServerSpecifies the name of the server that hosts the session.-UnifiedSessionIDSpecifies a unique session ID on the host.