botframework-ruby icon indicating copy to clipboard operation
botframework-ruby copied to clipboard

Better way to send messages?

Open davispuh opened this issue 8 years ago • 0 comments

Currently to send messages to Skype or Telegram we have to manually create a Conversation, but it would be nicer if there was some higher level API.

this is example of our current code

SkypeService = 'https://smba.trafficmanager.net/apis/'
TelegramService = 'https://telegram.botframework.com'

to = BotFramework::ChannelAccount.new
to.id = SKYPE_TARGET_GROUP_ID
activity = BotFramework::Activity.new(type: 'message', locale: 'en', text: msg, from: OUR_ACCOUNT, recipient: to)
conv = BotFramework::Conversation.new(SkypeService)
conv.send(to.id, activity)

davispuh avatar Nov 10 '17 14:11 davispuh