Replies: 1 comment
|
Hi, Why would it work ? It's look like python. Whatever the project you should open an issue in the related project :D |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
from kickapi import KickAPI
client = KickAPI(
client_id='',
client_secret=''
)
def get_top_streamers(limit=10):
try:
streams = client.streams.get_live_streams()
sorted_streams = sorted(streams, key=lambda x: x.viewer_count, reverse=True)[:limit]
print(f"Top {limit} live streamers:")
for i, stream in enumerate(sorted_streams, 1):
print(f"{i}. {stream.user_name} - Viewers: {stream.viewer_count}")
if name == "main":
get_top_streamers()
All reactions