IActivity.cs
1 using System;
2 using System.Linq;
3 
4 namespace Microsoft.Bot.Connector
5 {
9  public interface IActivity
10  {
14  string Type { get; set; }
15 
19  string Id { get; set; }
20 
24  string ServiceUrl { get; set; }
25 
29  DateTime? Timestamp { get; set; }
30 
34  DateTimeOffset? LocalTimestamp { get; set; }
35 
39  string ChannelId { get; set; }
40 
44  ChannelAccount From { get; set; }
45 
49  ConversationAccount Conversation { get; set; }
50 
54  ChannelAccount Recipient { get; set; }
55 
59  string ReplyToId { get; set; }
60 
77  dynamic ChannelData { get; set; }
78 
82  IMessageActivity AsMessageActivity();
83 
87  IContactRelationUpdateActivity AsContactRelationUpdateActivity();
88 
92  IInstallationUpdateActivity AsInstallationUpdateActivity();
93 
97  IConversationUpdateActivity AsConversationUpdateActivity();
98 
102  ITypingActivity AsTypingActivity();
103 
107  IEndOfConversationActivity AsEndOfConversationActivity();
108 
112  IEventActivity AsEventActivity();
113 
117  IInvokeActivity AsInvokeActivity();
118  }
119 }
Synchronous request to invoke an operation
A user has added a bot to their contact list, removed the bot from their contact list, or otherwise changed the relationship between user and bot
Channel account information for a conversation
A bot was installed or removed from a channel
The referenced conversation has been updated
Asynchronous external event
Shared properties for all activities
Definition: IActivity.cs:9
Conversation is ending, or a request to end the conversation
Channel account information needed to route a message