Professional Documents
Culture Documents
Developer Overview
Tom Jebo
Agenda
What is Microsoft Teams?
Tab Overview
Design & Config
API
Bot Overview
Design
Build
Conversation
Events
Actionable Messages
Activity Feed
Compose Extensions
Apps and Side Load
Office Store
Resources
Chat-based workspace in Office 365
Build apps with a rich set of capabilities to enable these higher-performing teams
Extension Points in Teams
Reach your users in their chats, channels, notifications, and personal workspace
Microsoft Teams Extension Points
Available now
Reach your users in their chats, channels, notifications, and personal workspace
Demo
Configurable vs Static
Configuration(required), reconfiguration, removal
Content – HTML based, hosted
Manifest – JSON based
Package – manifest.json + 2 icons
Tab Content
Requirements:
- Secure https endpoint
- Allow iframe
- https://statics.teams.microsoft.com/sdk/v1.0/js/MicrosoftTeams.min.js
- call microsoftTeams.initialize();
Demo
Authentication
1. Silent – existing Azure AD token
2. Pop-up – non-AAD
- microsoftTeams.authentication.Authenticate()
- microsoftTeams.authentication.Success/Failure()
Deep Linking
• Generation https://teams.microsoft.com/l/entity/<appId>/
<entityId>?webUrl=<entityWebUrl>&label=<en
tityLabel>&context=<context>
• Share
microsoftTeams.shareDeepLink()
Example Deep Link
appId
https://teams.microsoft.com/l/entity/
fe4a8eba-2a31-4737-8e33-e5fae6fee194/ entityWebUrl
tasklist123?webUrl=https://tasklist.example.com/123
&context={"canvasUrl": "https://tab.tasklist.example.com/123","channelId":
"19:cbe3683f25094106b826c9cada3afbe0@thread.skype"}
Teams js API
microsoftTeams microsoftTeams.settings
getContext getSettings
initialize registerOnRemoveHandler
navigateCrossDomain registerOnSaveHandler
registerOnThemeChangeHandler setSettings
shareDeepLink setValidityState
microsoftTeams.authentication
authenticate https://msdn.microsoft.com/en-us/microsoft-teams/jslibrary
notifyFailure
notifySuccess https://statics.teams.microsoft.com/sdk/v1.0/js/MicrosoftTeams.min.js
Bots
Bot Demo
Bot Design
Intelligent vs CLI
Drive users as much as possible
Bot Demo
Microsoft Teams
Bot Conversations Basics
Receiving: Activity object (type message)
text = “hello”
channelId (always “msteams”)
from.id – unique to user
channelData.tenant.id – AAD
channelData.channel.id & name*
conversationData.id and isGroup*
entities*
TeamsChannelData channelData = activity.GetChannelData<TeamsChannelData>(); string
tenantId = channelData.Tenant.Id;
Bot Conversation Creation
Add vs @mention – provides id’s for creating conversations
and other operations
Channel – enumerate team roster.
Conversations created with unique user/tenant ID
bot.beginDialog() / CreateConversation()
Id of the Channel
Id of the Conversation
Bot Conversations Basics
Sending/Reply:
await connector.Conversations.SendToConversationAsync((Activity)newMessage);
/v3/conversations/<conversationId>/activities/<activityId>/
Example reply with
@mention
Bot Conversations Basics
NEW! Message Update:
origAttachment.content.subtitle = 'Assigned to Tom Jebo’;
var updatedMsg = new builder.Message()
.address(address) Update method or
.textFormat(builder.TextFormat.markdown) REST endpoint
.addAttachment(origAttachment)
.toMessage();
session.connector.update(updatedMsg, function(err, addresses)
{ if (err) { console.log(`Could not update the message`); }
/v3/conversations/<conversationId>/activities/<activityId>/
Events for Bots
Team member or Bot addition/removed
- to a team
- for personal context
Channel updates
Team name updates
Example:
Bot added for personal context
- conversationUpdate
- membersAdded
- no channelData.team property
Possible action:
Welcome message for user
vs. team…
Send Cards
Property Type Description
Reach your users in their chats, channels, notifications, and personal workspace
Connectors with Actionable Messages
12 message
response
Connector or message
send card
Bot
Connector Service
1 event
Data,
Service,
Etc… Microsoft Teams
Connector/Actionable Message Architecture
12
Connector or send http postcard
update
Bot
Connector Service
Data,
Service,
Etc… Microsoft Teams
Demo
1 send request
2 Query
Data,
Service, Microsoft Teams
Compose Extension Design
• composeExtension object
• composeExtension.type (“result”)
• composeExtension.attachmentLayout (“list” or “grid”)
• composeExtension.attachments
Cards:
Thumbnail
Hero
O365 connector
Authentication
Apps in Teams
Office Store
Create a developer account
https://msdn.microsoft.com/en-us/microsoft-teams/submission
New Features Summary
Actionable Messages on Connector cards
User Notifications (Activity Feed)
Compose Extensions
Office Store
App Platform
Wrap-up
All these features and more in Developer Preview
Submit your app: aka.ms/SubmitTeamsApp
Resources
https://dev.office.com/microsoft-teams/explore-microsoft-teams
https://dev.office.com/microsoft-teams/ + tabs | bots | composeextenstions | activityfeed | connectors
https://msdn.microsoft.com/en-us/microsoft-teams/samples https://aka.ms/bf-createsdkbot
https://dev.botframework.com/
https://docs.microsoft.com/en-us/bot-framework/azure/azure-bot-service-quickstart
Suggestions:
mailto://microsoftteamsdev@microsoft.com
Problems:
StackOverflow "microsoft-teams“
https://aka.ms/microsoftteamsplatformsuggestions
Thank You!
Questions?