Skip to content

Commit

Permalink
Message metadata events
Browse files Browse the repository at this point in the history
  • Loading branch information
soxtoby committed Oct 7, 2023
1 parent ed0eafc commit 781f447
Show file tree
Hide file tree
Showing 3 changed files with 49 additions and 0 deletions.
17 changes: 17 additions & 0 deletions SlackNet/Events/MessageMetadataDeleted.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
namespace SlackNet.Events;

/// <summary>
/// Sent when a message's metadata has been deleted.
/// Within the payload there will be a <see cref="PreviousMetadata"/> property notifying you of what has been deleted.
/// </summary>
public class MessageMetadataDeleted : Event
{
public MessageMetadata PreviousMetadata { get; set; }
public string AppId { get; set; }
public string BotId { get; set; }
public string UserId { get; set; }
public string TeamId { get; set; }
public string ChannelId { get; set; }
public string MessageTs { get; set; }
public string DeletedTs { get; set; }
}
15 changes: 15 additions & 0 deletions SlackNet/Events/MessageMetadataPosted.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
namespace SlackNet.Events;

/// <summary>
/// Sent when a message containing metadata is sent in Slack.
/// </summary>
public class MessageMetadataPosted : Event
{
public MessageMetadata Metadata { get; set; }
public string AppId { get; set; }
public string BotId { get; set; }
public string UserId { get; set; }
public string TeamId { get; set; }
public string ChannelId { get; set; }
public string MessageTs { get; set; }
}
17 changes: 17 additions & 0 deletions SlackNet/Events/MessageMetadataUpdated.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
namespace SlackNet.Events;

/// <summary>
/// Sent when a message's metadata has been updated.
/// Within the payload you'll notice an extra <see cref="PreviousMetadata"/> in addition to the <see cref="Metadata"/> property, notifying you of what was changed.
/// </summary>
public class MessageMetadataUpdated : Event
{
public MessageMetadata PreviousMetadata { get; set; }
public MessageMetadata Metadata { get; set; }
public string AppId { get; set; }
public string BotId { get; set; }
public string UserId { get; set; }
public string TeamId { get; set; }
public string ChannelId { get; set; }
public string MessageTs { get; set; }
}

0 comments on commit 781f447

Please sign in to comment.