this post was submitted on 01 Oct 2025
11 points (100.0% liked)

Python

7494 readers
1 users here now

Welcome to the Python community on the programming.dev Lemmy instance!

๐Ÿ“… Events

PastNovember 2023

October 2023

July 2023

August 2023

September 2023

๐Ÿ Python project:
๐Ÿ’“ Python Community:
โœจ Python Ecosystem:
๐ŸŒŒ Fediverse
Communities
Projects
Feeds

founded 2 years ago
MODERATORS
 

I'm working on a Python script to find a snappy Lemmy instance, as the one I was using (not dbzer0) has recently slowed down to about 5 seconds per page load. I have a rough version of the script, but I need to fetch a list of available Lemmy instances through their API.

Could anyone guide me on how to access the Lemmy API to retrieve a list of instances?

you are viewing a single comment's thread
view the rest of the comments
[โ€“] tal@olio.cafe 2 points 3 days ago* (last edited 3 days ago)

Not what you're asking, but I can probably do better.

I'd give decent odds that the issue you're hitting is the thing that many Fediverse instances are hitting. There have been a lot of badly-written and very aggressive scraper-bots hammering servers all over (the Web, not just the Threadiverse) to try to find text to train AI models. If you've seen discussion on Anubis recently, that was aimed at trying to mitigate the load from that.

Many instances dealt with this by disallowing anonymous access. This sucks, because it'd be nice to let people use an instance without logging in, but it did apparently drastically reduce the bot load.

You can probably just pick an instance that doesn't provide for anonymous access.