mauricew / twitch-graphql-api

Undocumented, uncorroborated, but certainly not unPoggers.
121 stars 4 forks source link

User follows #2

Closed spirit1337 closed 10 months ago

spirit1337 commented 10 months ago

Hello @mauricew

I managed to check who follows a user but I just can't seem to get who a user follows to work.

According to page doc:

query { user(login: "Amouranth") { follows(first: 25) { totalCount edges { followedAt node { login } } } } }

Getting the following error when trying to fetch:

{"errors":[{"message":"service error","path":["user","follows"]}],"data":{"user":{"follows":null}},"extensions":{"durationMilliseconds":21,"requestID":""}}

Can anyone confirm if this method is still working?

mauricew commented 10 months ago

If this isn't a server hiccup then it's more likely tied to Get User Follows being removed from Helix in September (https://discuss.dev.twitch.com/t/legacy-follows-api-and-eventsub-shutdown-timeline-updated/46769). There is a replacement Get Followed Channels which could indicate that the same authentication & permission requirements to use that are also required when making this call.

spirit1337 commented 10 months ago

That's what I thought but there appears to be a way to get around the public API change and to check follows without the user needing to be a mod for the channel.

For example this site operates like before the API change. It's behind a paywall but I can confirm it works. I thought it uses the GQL API. Any idea how this is possible?

mauricew commented 10 months ago

Can't say for sure, does that site require logging in via OAuth? The only method I know of is the one where you access Settings > Notifications and the list that gets generated in the "Per channel" section, but that's only for the logged-in user. I'm sure if the call was known or heavily used it would be patched out quicker, hence the reason why that feature is paywalled.

spirit1337 commented 10 months ago

No authentication needed and it works for every user. The only solution I can think of is to scrape the followers of every channel - save it to a database and fetch the data from there but that seems inefficient.