[][src]Enum ttv_pubsub::channel_subscriptions::ChannelSubscribeEventsV1Reply

#[non_exhaustive]pub enum ChannelSubscribeEventsV1Reply {
    Sub {
        benefit_end_month: i64,
        channel_id: String,
        channel_name: String,
        cumulative_months: i64,
        is_gift: bool,
        multi_month_duration: i64,
        sub_message: SubMessage,
        sub_plan: SubscriptionTier,
        sub_plan_name: String,
        time: String,
        user_id: String,
        user_name: String,
        display_name: String,
        // some fields omitted
    },
    ReSub {
        benefit_end_month: Option<i64>,
        channel_id: String,
        channel_name: String,
        cumulative_months: i64,
        is_gift: bool,
        streak_months: Option<i64>,
        multi_month_duration: Option<i64>,
        sub_message: SubMessage,
        sub_plan: SubscriptionTier,
        sub_plan_name: String,
        time: String,
        user_id: String,
        user_name: String,
        display_name: String,
        // some fields omitted
    },
    SubGift {
        benefit_end_month: Option<i64>,
        channel_id: String,
        channel_name: String,
        months: i64,
        multi_month_duration: Option<i64>,
        recipient_display_name: String,
        recipient_id: String,
        recipient_user_name: String,
        sub_plan: SubscriptionTier,
        sub_plan_name: String,
        time: String,
        user_id: String,
        user_name: String,
        display_name: String,
        // some fields omitted
    },
}

Variants (Non-exhaustive)

Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Sub

A subscription

Fields of Sub

benefit_end_month: i64

Unknown

channel_id: String

ID of the channel that has been subscribed or subgifted

channel_name: String

Name of the channel that has been subscribed or subgifted

cumulative_months: i64

Cumulative months that user has been subscribed

is_gift: bool

Resubscription is a gift

multi_month_duration: i64

Duration of subscription, e.g 1, 3 or 6

sub_message: SubMessage

Message sent with this subscription

sub_plan: SubscriptionTier

Subscription plan

sub_plan_name: String

Name of subscription plan

time: String

Time when pubsub message was sent

user_id: String

ID of user that subscribed

user_name: String

Username of user that subscribed

display_name: String

Display name of user that subscribed

ReSub

A resubscription

Fields of ReSub

benefit_end_month: Option<i64>

Unknown

channel_id: String

ID of the channel that has been subscribed or subgifted

channel_name: String

Name of the channel that has been subscribed or subgifted

cumulative_months: i64

Cumulative months that user has been subscribed

is_gift: bool

Resubscription is a gift

streak_months: Option<i64>

Months the user has been subscribed for in a row.

multi_month_duration: Option<i64>

Duration of subscription, e.g 1, 3 or 6

sub_message: SubMessage

Message sent with this subscription

sub_plan: SubscriptionTier

Subscription plan

sub_plan_name: String

Name of subscription plan

time: String

Time when pubsub message was sent

user_id: String

ID of user that subscribed

user_name: String

Username of user that subscribed

display_name: String

Display name of user that subscribed

SubGift

A gifted subscription happened

Fields of SubGift

benefit_end_month: Option<i64>

Unknown

channel_id: String

ID of the channel that has been subscribed or subgifted

channel_name: String

Name of the channel that has been subscribed or subgifted

months: i64

Months

multi_month_duration: Option<i64>

Duration of subscription, e.g 1, 3 or 6

recipient_display_name: String

Display name of user that received gifted subscription

recipient_id: String

Username of user that received gifted subscription

recipient_user_name: String

Username of user that received gifted subscription

sub_plan: SubscriptionTier

Subscription plan

sub_plan_name: String

Name of subscription plan

time: String

Time when pubsub message was sent

user_id: String

ID of user that purchased gifted subscription

user_name: String

Username of user that purchased gifted subscription

display_name: String

Display name of user that purchased gifted subscription

Trait Implementations

impl Clone for ChannelSubscribeEventsV1Reply[src]

impl Debug for ChannelSubscribeEventsV1Reply[src]

impl<'de> Deserialize<'de> for ChannelSubscribeEventsV1Reply[src]

impl Eq for ChannelSubscribeEventsV1Reply[src]

impl PartialEq<ChannelSubscribeEventsV1Reply> for ChannelSubscribeEventsV1Reply[src]

impl Serialize for ChannelSubscribeEventsV1Reply[src]

impl StructuralEq for ChannelSubscribeEventsV1Reply[src]

impl StructuralPartialEq for ChannelSubscribeEventsV1Reply[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.