MSTeams - Link Unfurling. Handle "Action.Submit" action of Adaptive Card from User-to-User chat.

Brass Contributor

Hi.

Link Unfurling ... C# (NET Core 3.1)

I added "Link Unfurling" functionality to my application (& Bot). Than I can select any chat ("My User"-"User1"), insert link and send Adaptive Card. The Adaptive Card contains "Add" ("type": "Action.Submit") button.

"User1" can see the Adaptive Card and can press the button but He recieves "Something went wrong. Make sure you've successfully added the app." message. He installed the Application seccessfully and can use the button from his "Bot-User" chat (Card that was addressed for him) but can't use it if a different user sent the card (the same story with copy/paste the card to "User1") .

I can click the "Add" button in "My User-User1" chat and the action handles seccessfully but "User1" can't do it.

Bot:

"scopes": ["personal"]

How we (Bot) can handle the action?

11 Replies
Paul_By - As per my understanding, you are sending a card with one action button and it's working fine for you from a other person's chat where you send the card but it's not working for other user correct?
If yes, it should handle the request for other user as well.
We will also check it from our and let you know.

Right. ... Or ... What kind of handler should I add?

"My User" sent a card using link Unfurling functionality to "User1" ("My User-User1" chat)
"My User-User1" chat, link Unfurling, Adaptive Card, Button Action ("type": "Action.Submit"): It works for me. Bot handles the action.
"My User-User1", link Unfurling, Adaptive Card, Button Action ("type": "Action.Submit"): "User1" can't use the button of Adaptive Card: "Something went wrong. Make sure you've successfully added the app." On Bot side I can't see any activity,

@Paul_By 

Could you please share the sample which you are referring to so that we can repro at our end?

 

@Nivedipa-MSFT 

55.teams-link-unfurling.zip

Link for query: https://you_domain/item/index?id=190237271

"User1" receives the following : User1View.png

But bot handles my action.

@Nivedipa-MSFT 

I updated APP manifest a little bit

Link unfurling: https://linkunfurlingsite.com/item/index?id=4

@Paul_By

Thanks for sharing the details.We are checking on it.We will update you.

@Paul_By 

We have tried the sample.You have not added the permissions in manifest file.After adding the permissions we following result when user1 click the action.submit.

 

NivedipaMSFT_0-1635944173069.png

and user1 also use the button now.

 

Thanks, 

Nivedipa

------------------------------------------------------------------------------------------------------------------------ 

If the response is helpful, please click "**Mark as Best Response**" and like it. You can share your feedback via Microsoft Teams Developer Feedback link. Click here to escalate.

 

I can't see any requests like yours.
What kind of changes should I do? Project (manifect or bot) side or client side (MS Teams client) or Azure (administrative) side?

@Paul_By 

Could you please add permissions block in project manifest file.

 

"permissions": [
"identity",
"messageTeamMembers"
]

 

Thanks, 

Nivedipa

------------------------------------------------------------------------------------------------------------------------ 

If the response is helpful, please click "**Mark as Best Response**" and like it. You can share your feedback via Microsoft Teams Developer Feedback link. Click here to escalate. 

 

@Paul_By 

Is your issue resolved with above suggestion? Or still you need any help.