API to get per-user information about streamer support (gifts and bits)
I'd like to see an API endpoint that gives me information about the level of support for a given channel/streamer and user/viewer combination.
On one hand, I as a viewer want to have a way of getting my total numbers raised in support of a given streamer (that is, user BhaaLseN on $channel).
On the other hand, I as a streamer want to have a way of getting total numbers raised by a particular viewer of mine (that is, user $viewer on BhaaLseN).
The former is meant for viewers and addons like FFZ/BTTV that display numbers: amount of subs gifted (which is already shown in the "Gift a Sub" popup), amount of bits cheered (which is somewhat reflected in the Cheer popup and the bit badge, but doesn't appear as an actual number I think), plus perhaps even a culmination of the Wallet subpage (that could equate the number of subs/bits into actual money spent).
This should be available to the user themselves, regardless of channel, and only return their own level of support (or value if you like).
It could look like a simple GET request to /helix/channel_support/$channel to retrieve my own data for $channel.
The latter is meant for both streamers and perhaps their editors/moderators (but at least channel bots) to allow them to get data on their loyal viewers that provide support over extended periods of time, and might be eligible for a little extra. Many streamers reward milestones with special giveaways and other personal goodies for those particular individuals. Most go by gift count (which can be viewed when gifting or using the gift badge), amount bits cheered (which is again from the cheer badge) or any combination thereof.
This obviously shouldn't be available to just anyone except for the streamer, and maybe even to a trusted group of individuals per channel (editors, moderators and/or bots) to keep track of how much viewers spend on their channel, and also verify that what they claim is true.
It could look like a simple GET request to /helix/channel_support/$channel/$viewer to retrieve data for $viewer on $channel, assuming that the current user has a minimum access level on $channel (such as moderator or editor). In case this remains limited to the channel owner themselves, the endpoint could obviously drop the $channel segment, but I'm also considering scenarios where roles other than the broadcaster may want (or need) access to this.
The data should be there (after all, the former is somewhat available for viewers already using the Wallet page for both subscriptions and bits), it's just that there is no API available for it (aside from GQL I suppose, which developers may not use).
-
SaishoNoOokami commented
Great idea! I really want this so I can easily visualize how many gift subs I have given to which channel.