Forum Discussion
PlanetEstream
Apr 08, 2020Copper Contributor
Messaging Extension (V3 SDK) Settings / Configuration
I've created a messaging extension based on the sample app provided on the Get Started guide for Teams in C#. The extension queries my company's product for data and returns it in a list, from which the user can select a card to insert into the conversation, which contains a link to view that data on our service. This works fine pointing at one of our test sites.
However, my customers have their own instances of the product, so they need to be able to configure the extension to point at their own instance. I'm following the documentation for search based messaging extensions which says I should be able to do this by adding canUpdateConfiguration to my manifest. This brings up a greyed out settings option when right-clicking the extension in Teams.
However it also says I need to use onQuerySettingsUrl and onSettingsUpdate event handlers, but is incredibly vague, and I cannot find further documentation or help on how to actually write/implement either of these things anywhere. It seems like such a simple task and we're so close to having this basic extension finished that it's getting quite frustrating.
Can anyone offer any advice on this? Thanks in advance.
- Trinetra-MSFT
Microsoft
PlanetEstream , This looks like a doc-bug but however there is sample code which shows the implementation for onSettingUpdate & onQuerySettingUrl. take a look at : https://github.com/OfficeDev/microsoft-teams-sample-complete-node/blob/master/src/Bot.ts
- PlanetEstreamCopper Contributor
Trinetra-MSFT Hi, thanks for the response, but this assumes I'm using Node and our app is already written in .NET. I cannot find the relevant .NET documentation anywhere online. Do you know if this exists or how I can implement onSettingUpdate and onQuerySettingURL in .NET?
- Trinetra-MSFT
Microsoft
PlanetEstream , Currently there is no sample code available in C#. I would suggest you to start working with the Bot Builder SDK V4 Sample code, which have more about Message Extension.