This code gets all peers from mastodon.social. Goal is to collect maximum number of alive fediverse's servers and then query their API to obtain their registered users (if their API provide such information). At the end it post the results to host server bot account.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Anar al arxiu
quimnuss 799f3bd2b1
first red test working
3 weeks ago
config first red test working 3 weeks ago
federation make federation a package 3 weeks ago
scripts forgotten some moves 3 weeks ago
tests first red test working 3 weeks ago
.gitignore add gitignore to ignore config and byte compiled 3 weeks ago
LICENSE Add LICENSE 2 years ago
README.md Save MAU to database 3 weeks ago
requirements-dev.txt add tests and req-dev.txt 3 weeks ago
requirements.txt Recoded uptime.py and removed unneeded uptime_setup.py 3 weeks ago

README.md

Fediverse Stats

This code gets all peers from mastodon.social. Goal is to collect maximum number of alive fediverse's servers and then query their API to obtain their registered users (if their API provide such information). At the end it post the results to host server bot account.

Dependencies

  • Python 3
  • Postgresql server
  • Mastodon running server.

Usage:

Within Python Virtual Environment:

  1. Run pip install -r requirements.txt to install needed libraries.

  2. Run python fetchservers.py to add servers to alive servers database.

  3. Run python fediverse.py to query world alive servers API. It gets data from server's nodeinfo.

  4. Use your favourite scheduling method to set python fediverse.py to run twice daily, python fetchservers.py one time daily, python fediquery.py to run every minute and `python uptime.py' every minute to publish best fediverse uptime.

18.2.2021 - New feature! Added Lemmy project
12.5.2021 - New feature! Added Wordpress support. The code can now detect Wordpress instances with ActivityPub enabled plugin.
12.5.2021 - New feature! New shinny creation of servers and users graphs.
21.8.2021 - New feature! Added Best Fediverse's servers Uptime publishing bot.
22.10.2021 - New feature! Added Funkwhale support.
26.10.2021 - New feature! Added Socialhome support.
2.3.2022 - Improved server nodeinfo detection.
4.1.2023 - Refactored.
4.1.2023 - Now peers are obtained from mastodon.social's peers list.
5.1.2023 - Added fediquery.py. Allow ask the main bot fediverse about soft and server and it replies to the asking user with its data if any.
7.1.2023 - When querying a not found server, we will be added to database if it's alive.
8.1.2023 - Save MAU to database.