Closed ColeWalker closed 3 years ago
so apparently there is a follow pubsub but i missed it.
example from DomitriusClark
const fetch = require('isomorphic-fetch'); `https://api.twitch.tv/helix/users/follows?to_id=${user.id}&first=1`; await fetch('https://api.twitch.tv/helix/webhooks/hub', { method: 'POST', body: JSON.stringify({ 'hub.callback': `${process.env.CALLBACK_URL}/api/webhooks`, 'hub.mode': 'subscribe', 'hub.topic': followersTopic, 'hub.lease_seconds': 60 * 60 * 4, }), headers: { 'Content-Type': 'application/json', authorization: `Bearer ${process.env.ACCESS_TOKEN}`, 'Client-ID': process.env.CLIENT_ID, }, });
so apparently there is a follow pubsub but i missed it.
example from DomitriusClark