I'm trying to trigger an Azure Function when a Web PubSub message is published.
According to the example in this article, I should be able to use the following to trigger a function when a new message is sent to a specific hub...
{
"disabled": false,
"bindings": [
{
"type": "webPubSubTrigger",
"direction": "in",
"name": "data",
"hub": "ABC",
"eventName": "message",
"eventType": "user"
}
],
"scriptFile": "../dist/WebPubSubTrigger/index.js"
}
However, I keep getting this error whenever I initialise the function app...
The 'WebPubSubTrigger' function is in error: The binding type(s) 'webPubSubTrigger' were not found in the configured extension bundle. Please ensure the type is correct and the correct version of extension bundle is configured.
Here's my extensionBundle config in host.json...
"extensionBundle": {
"id": "Microsoft.Azure.Functions.ExtensionBundle",
"version": "[2.*, 3.0.0)"
}
But this article does not have it listed as a supported binding type so I'm a little puzzled to say the least!
Can anyone point me in the right direction please?
I'm running my Functions in a NodeJS environment but that shouldn't make a difference I don think.