Skip to content

new props, fixed typos, removed default values from nullable props #42

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -61,39 +61,47 @@ public sealed class ChannelChatMessage
/// </summary>
public ChatCheer? Cheer { get; set; }

/// <summary>Metadata if this message is a reply.</summary>
/// <summary>
/// Metadata if this message is a reply.
/// </summary>
public ChatReply? Reply { get; set; }

/// <summary>
/// Optional. The ID of a channel points custom reward that was redeemed.
/// </summary>
public string? ChannelPointsCustomRewardId { get; set; } = string.Empty;
public string? ChannelPointsCustomRewardId { get; set; }

/// <summary>
/// Optional. The broadcaster user ID of the channel the message was sent from.
/// </summary>
public string? SourceBroadcasterUserId { get; set; } = string.Empty;
public string? SourceBroadcasterUserId { get; set; }

/// <summary>
/// Optional. The user name of the broadcaster of the channel the message was sent from.
/// </summary>
public string? SourceBroadcasterUserName { get; set; } = string.Empty;
public string? SourceBroadcasterUserName { get; set; }

/// <summary>
/// Optional. The login of the broadcaster of the channel the message was sent from.
/// </summary>
public string? SourceBroadcasterUserLogin { get; set; } = string.Empty;
public string? SourceBroadcasterUserLogin { get; set; }

/// <summary>
/// Optional. The UUID that identifies the source message from the channel the message was sent from.
/// </summary>
public string? SourceMessageId { get; set; } = string.Empty;
public string? SourceMessageId { get; set; }

/// <summary>
/// Optional. The list of chat badges for the chatter in the channel the message was sent from.
/// </summary>
public ChatBadge[]? SourceBadges { get; set; } = [];
public ChatBadge[]? SourceBadges { get; set; }

/// <summary>
/// Optional. Determines if a message delivered during a shared chat session is only sent to the source channel.
/// Has no effect if the message is not sent during a shared chat session.
/// </summary>
public bool? IsSourceOnly { get; set; }

/// <summary>
/// Returns true if viewer is a subscriber
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using TwitchLib.EventSub.Core.Models.Shoutouts;
using System;
using TwitchLib.EventSub.Core.Models.Shoutouts;

namespace TwitchLib.EventSub.Core.SubscriptionTypes.Channel;

Expand All @@ -12,13 +13,28 @@ public sealed class ChannelShoutoutReceive : ShoutoutBase
/// <summary>
/// An ID that identifies the broadcaster that received the Shoutout.
/// </summary>
[Obsolete("This property is a typo, please use: FromBroadcasterUserId")]
public string ToBroadcasterUserId { get; set; } = string.Empty;
/// <summary>
/// The receiving broadcaster’s display name.
/// </summary>
[Obsolete("This property is a typo, please use: FromBroadcasterUserName")]
public string ToBroadcasterUserName { get; set; } = string.Empty;
/// <summary>
/// The receiving broadcaster’s login name.
/// </summary>
[Obsolete("This property is a typo, please use: FromBroadcasterUserLogin")]
public string ToBroadcasterUserLogin { get; set; } = string.Empty;
/// <summary>
/// An ID that identifies the broadcaster that sent the Shoutout.
/// </summary>
public string FromBroadcasterUserId { get; set; } = string.Empty;
/// <summary>
/// The broadcaster’s display name.
/// </summary>
public string FromBroadcasterUserName { get; set; } = string.Empty;
/// <summary>
/// The broadcaster’s login name.
/// </summary>
public string FromBroadcasterUserLogin { get; set; } = string.Empty;
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
namespace TwitchLib.EventSub.Core.SubscriptionTypes.Channel;
using System;

namespace TwitchLib.EventSub.Core.SubscriptionTypes.Channel;

/// <summary>
/// Channel Update subscription type model
Expand Down Expand Up @@ -38,5 +40,11 @@ public sealed class ChannelUpdate
/// <summary>
/// A boolean identifying whether the channel is flagged as mature.
/// </summary>
[Obsolete("Removed 2023‑06‑29, please use: ContentClassificationLabels")]
public bool IsMature { get; set; }
/// <summary>
/// Array of content classification label IDs currently applied on the Channel.
/// To retrieve a list of all possible IDs, use the <see href="https://dev.twitch.tv/docs/api/reference/#get-content-classification-labels">Get Content Classification Labels</see> API endpoint.
/// </summary>
public string[] ContentClassificationLabels { get; set; } = [];
}
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ public sealed class ChannelWarningSend
/// <summary>
/// Optional. The reason given for the warning.
/// </summary>
public string Reason { get; set; } = string.Empty;
public string? Reason { get; set; }
/// <summary>
/// Optional. The chat rules cited for the warning.
/// </summary>
public string[] ChatRulesCited { get; set; } = [string.Empty];
}
public string[]? ChatRulesCited { get; set; }
}
Loading