Connect-CWC doesn't support subdirectories
Connect-CWC appears to stripping the server down to the base domain, ignoring things like protocol and subdirectories. On my (and I'm sure others) default install, our URL will look like this:
https://automate.mydomain.com/RemoteSupport
Line 16 of Connect-CWC.ps1 has this:
$Server = ($Server -replace("http.*:\/\/",'') -split '/')[0]
I propose changing it to this:
$Server = $Server -replace("http.*:\/\/",'')
This way, you can force HTTPS while keeping the subdirectory intact. In my testing, even if you had a trailing forward slash at the end, though it would end up doubling it up ("RemoteSupport//"), functions continued to work just fine.
The issue has been resolved. Thanks for raising the issue. 93fcc11