Thanks to Brian Parker, I found my issue. If you're using WASM or InteractiveAuto, make sure to pass in the parameters as a query string and not a header. I did like this:
var url = "";
if (OperatingSystem.IsBrowser())
{
url = string.Format("https://localhost:7000/chatHub?BusinessId={0}", businessId);
}
else
{
url = "https://localhost:7000/chatHub";
}
HubConnection = new HubConnectionBuilder()
.WithUrl(Navigation.ToAbsoluteUri(url), options =>
{
options.Headers.Add("BusinessId", businessId.ToString());
}).AddJsonProtocol(o =>
{
o.PayloadSerializerOptions.PropertyNamingPolicy = null;
}).WithAutomaticReconnect()
.Build();