azure-webpubsub
azure-webpubsub copied to clipboard
`SendToConnection()`. When `connectionId` is `""`, return `404 not found`. When `connectionId` is a non-existed connection Id, nothing happens.
https://github.com/Azure/azure-webpubsub/issues/33
SendToUser is also the same behavior with empty UserId.
The SDK sends out the request using https://demo-2.webpubsubdev.azure.com/api/hubs/chat/connections//:send?api-version=2020-10-01 as a result 404 returns.
SDK should validate the parameters first when the parameters are in the path.
This should be fixed in the swagger. To fix this apply a minLength attribute to the swagger parameter (e.g. "minLength": 1`)
Updated swagger to include the "minLength": https://github.com/Azure/azure-rest-api-specs-pr/pull/2806/files