-
Notifications
You must be signed in to change notification settings - Fork 298
Closed
Description
Hey,
I'm using botbuilder version 4.0.0a6 and I have a struggle with quick replies.
Quick replies are displayed in the emulator but not in any other Skype Client.
Here is the code I used :
def handle_request(self, request, channel_model):
data = request.data
activity = Activity.deserialize(data)
if not self.__handle_authentication__(request, channel_model):
return
if activity.type == ActivityTypes.message.value:
resp_activity = Activity(
type=ActivityTypes.message,
channel_id=activity.channel_id,
conversation=activity.conversation,
from_property=activity.recipient,
recipient=activity.from_property,
service_url=activity.service_url
)
replies = [
{
"title": "Test1",
"type": ActionTypes.im_back,
"value": "Test1",
},
{
"title": "Test2",
"type": ActionTypes.im_back,
"value": "Test2",
}
]
resp_activity.text = "My text"
resp_activity.suggested_actions = SuggestedActions(actions=replies, to=[activity.from_property.id])
credentials = MicrosoftAppCredentials(channel_model.settings["app_id"], channel_model.settings["app_password"])
try:
connector = ConnectorClient(credentials, response_activity.service_url)
connector.conversations.send_to_conversation(resp_activity.conversation.id, response_activity)
except Exception as e:
print("An error happened ! ")
traceback.print_tb(e.__traceback__)
else:
return
Any help is really appreciated
Metadata
Metadata
Assignees
Labels
No labels