Twitch dev

Added sub points / total to GetBroadcasterSubscriptions()

The api.twitch.tv/helix/subscriptions endpoint now supports total subscribers and subscriber point which is added to the Twitch API lib. Requires BlushyFace.Twitch.API; How to use var subscribers = await _twitchAPI.Helix.Subscriptions.GetBroadcasterSubscriptionsAsync(broadcasterId: “…”); //get total broadcaster subscribers and subscriber points and write it to...

Show channel view count in overlay

A code snippet that can be used as a browser source overlay (for example OBS) to show viewer count on the stream that updates every minute. <!DOCTYPE html> <html> <head> <meta content=”text/html;charset=utf-8″ http-equiv=”Content-Type” /> <title>Blushyface.com</title> </head> <body> <p id=”viewers”></p> <script>...

September 30, 2021
More

Twitch auth example

[Update] Added support for optional states that is managed inside BlushyFace.Twitch.Authentication and renamed some methods so it’s more clear what they do but it is not updated in the [original] post below.   [Original] BlushyFace.Twitch.Authentication is a lightweight C# .NET...

Connect to Twitch chat

Started rewriting BlushyFace.Twitch.Chat into BlushyFace.Twitch.Chat.V2 because while v1 is a rewrite ported from my .NET FX version I wasn’t totally happy with it and decided to just rewrite it in it’s entirely. This is a work in progress but the...

Generate Twitch auth tokens

An example how to generate Twitch access tokens with custom scopes. The example requires BlushyFace.Twitch.Authentication and BlushyFace.Common.HTTP to run a local HTTP server. using System.Collections.Specialized; using BlushyFace.Common.HTTP; using BlushyFace.Config; using BlushyFace.Twitch.API.Auth; using BlushyFace.Twitch.API.Auth.ResponseObjects; using Newtonsoft.Json; namespace BlushyFace.Examples { public static...

Send a whisper to a user

Requires – BlushyFace.Twitch.Chat.V2.Chat   In this example we are sending a whisper from BlushyFace to BlushyFaceBot. Note that sending whispers to another user requires an authenticated user login with the following scope: whispers:edit var client = new Client(userName: “blushyface”, token:...