**#ActivityPub support in #Madblog**
-
#ActivityPub support in #Madblog
I am glad to announce that Madblog has now officially joined the #Fediverse family.
Madblog has already supported #Webmentions for the past couple of weeks, allowing your blog posts to be mentioned by other sites with Webmentions support (WordPress, Lemmy, HackerNews...) and get those mentions directly rendered on your page.
It now adds ActivityPub support too, using #Pubby, another little Python library that I've put together myself (just like Webmentions) as a mean to quickly plug ActivityPub support to any Python Web app.
Webmentions and Pubby follow similar principles and implement a similar API, and you can easily use them to add federation support to your existing Web applications - a single
bind_webmentionsorbind_activitypubcall to your existing Flask/FastAPI/Tornado application should suffice for most of the cases.Madblog may have now become the easiest way to publish a federated blog - and perhaps the only way that doesn't require a database, everything is based on plain Markdown files.
If you have a registered domain and a certificate, then hosting your federated blog is now just a matter of:
mkdir -p ~/madblog/markdown cat <<EOF > ~/madblog/markdown/hello-world.md This is my first post on [Madblog](https://git.fabiomanganiello.com/madblog)! EOF docker run -it \ -p 8000:8000 \ -v "$HOME/madblog:/data" \ quay.io/blacklight/madblogAnd Markdown files can be hosted wherever you like - a Git folder, an Obsidian Vault, a Nextcloud Notes installation, a folder on your phone synchronized over SyncThing...
Federation support is also at a quite advanced state compared to e.g. #WriteFreely. It currently supports:
-
Interactions rendered on the articles: if you like, boost, quote or reply to an article, all interactions are rendered directly at the bottom of the article (interactions with WriteFreely through federated accounts were kind of lost in the void instead)
-
Guestbook support (optional): mentions to the federated Madblog handle that are not in response to articles are now rendered on a separate
/guestbookroute -
Email notifications: all interactions can have email notifications
-
Support for quotes, also on Mastodon
-
Support for mentions, just drop a
@joe@example.comin your Markdown file and Joe will get a notification -
Support for hashtag federation
-
Support for split-domain configurations, you can host your blog on
blog.example.combut have a Fediverse handle like@blog@example.com. Search by direct post URL on Mastodon will work with both cases -
Support for custom profile fields, all rendered on Mastodon, with verification support
-
Support for moderation, either through blocklist or allowlist, with support for rules on handles/usernames, URLs, domains or regular expressions
-
A partial (but comprehensive for the provided features) implementation of the Mastodon API
If you want you can follow both the profiles of my blogs - they are now both federated:
-
My personal blog: @fabio@manganiello.blog (it used to run WriteFreely before, so if you followed it you may need to unfollow it and re-follow it)
-
The #Platypush blog: @blog@platypush.tech
https://blog.fabiomanganiello.com/article/Madblog-federated-blogging-from-markdown
@fabio I really, really love it!! I wanted to do the same for quite a long time - but I didn't; and now maybe I can eventually steal your code and RIIR in glorious AGPL!
That said, unfortunately at the moment it's not working for me, I can't open it either in my client, or through my instance's search
FWIW, through my instance I'm seeing some "503 Remote SSL certificate could not be verified", while the client just spins a throbber endlessly. No idea where the fault lies, but I do remember reading many times that Mastodon is a flustercluck and a fishy citizen in ActivityPub
...Anyway, huge applause from me regardless, and hopefully one day I can get to fave the actual post on the blog!
-
-
#ActivityPub support in #Madblog
I am glad to announce that Madblog has now officially joined the #Fediverse family.
Madblog has already supported #Webmentions for the past couple of weeks, allowing your blog posts to be mentioned by other sites with Webmentions support (WordPress, Lemmy, HackerNews...) and get those mentions directly rendered on your page.
It now adds ActivityPub support too, using #Pubby, another little Python library that I've put together myself (just like Webmentions) as a mean to quickly plug ActivityPub support to any Python Web app.
Webmentions and Pubby follow similar principles and implement a similar API, and you can easily use them to add federation support to your existing Web applications - a single
bind_webmentionsorbind_activitypubcall to your existing Flask/FastAPI/Tornado application should suffice for most of the cases.Madblog may have now become the easiest way to publish a federated blog - and perhaps the only way that doesn't require a database, everything is based on plain Markdown files.
If you have a registered domain and a certificate, then hosting your federated blog is now just a matter of:
mkdir -p ~/madblog/markdown cat <<EOF > ~/madblog/markdown/hello-world.md This is my first post on [Madblog](https://git.fabiomanganiello.com/madblog)! EOF docker run -it \ -p 8000:8000 \ -v "$HOME/madblog:/data" \ quay.io/blacklight/madblogAnd Markdown files can be hosted wherever you like - a Git folder, an Obsidian Vault, a Nextcloud Notes installation, a folder on your phone synchronized over SyncThing...
Federation support is also at a quite advanced state compared to e.g. #WriteFreely. It currently supports:
-
Interactions rendered on the articles: if you like, boost, quote or reply to an article, all interactions are rendered directly at the bottom of the article (interactions with WriteFreely through federated accounts were kind of lost in the void instead)
-
Guestbook support (optional): mentions to the federated Madblog handle that are not in response to articles are now rendered on a separate
/guestbookroute -
Email notifications: all interactions can have email notifications
-
Support for quotes, also on Mastodon
-
Support for mentions, just drop a
@joe@example.comin your Markdown file and Joe will get a notification -
Support for hashtag federation
-
Support for split-domain configurations, you can host your blog on
blog.example.combut have a Fediverse handle like@blog@example.com. Search by direct post URL on Mastodon will work with both cases -
Support for custom profile fields, all rendered on Mastodon, with verification support
-
Support for moderation, either through blocklist or allowlist, with support for rules on handles/usernames, URLs, domains or regular expressions
-
A partial (but comprehensive for the provided features) implementation of the Mastodon API
If you want you can follow both the profiles of my blogs - they are now both federated:
-
My personal blog: @fabio@manganiello.blog (it used to run WriteFreely before, so if you followed it you may need to unfollow it and re-follow it)
-
The #Platypush blog: @blog@platypush.tech
https://blog.fabiomanganiello.com/article/Madblog-federated-blogging-from-markdown
@fabio@manganiello.eu @fabio@manganiello.blog @blog omg thank you for the python lib. i was getting ready to write one but extremely good to see i can draw from (credit/depend on/etc.) prior art. adding to the inspo docs!!!
-
-
@julian Yes, to backfill a profile. It is a manual action.
I don't know who else does that, but @jonny is working on adding automatic profile backfill to Mastodon: https://github.com/mastodon/mastodon/pull/34597
@silverpill @julian @general Collections are one of the best parts of activitypub/streams and i have no idea why nobody uses them or works on them. like if we embraced the underlying graph structure of the data and used the canonicalization algos that have been developed in the meantime we get all the good parts of atproto (mostly efficient updating the pds system) basically for free
-
@silverpill @julian @general Collections are one of the best parts of activitypub/streams and i have no idea why nobody uses them or works on them. like if we embraced the underlying graph structure of the data and used the canonicalization algos that have been developed in the meantime we get all the good parts of atproto (mostly efficient updating the pds system) basically for free
@silverpill @julian @general account backfilling is issue number THIRTY FOUR in mastodon and has >700 thumbs, >200 comments hemming and hawing about how possible it would be for TEN YEARS.
the solution is just "enumerate the outbox" and it's 200 lines.
like we already have a mechanism for reply controls: the reply collection.
for fine-grained post visibility: access control on the outbox collection.
broadcasting feeds and posts between instances: collections
migrations: collections
store and forward, offline-focused AP: collectionsand so on.
-
@julian @silverpill ActivityPub API clients dont need their server to backfill thanks to proxyURL, but Actors will look like they havenβt posted

-
@julian @silverpill ActivityPub API clients dont need their server to backfill thanks to proxyURL, but Actors will look like they havenβt posted

@django@social.coop sounds like I'll have to implement it sooner rather than later!
-
@silverpill @julian @general account backfilling is issue number THIRTY FOUR in mastodon and has >700 thumbs, >200 comments hemming and hawing about how possible it would be for TEN YEARS.
the solution is just "enumerate the outbox" and it's 200 lines.
like we already have a mechanism for reply controls: the reply collection.
for fine-grained post visibility: access control on the outbox collection.
broadcasting feeds and posts between instances: collections
migrations: collections
store and forward, offline-focused AP: collectionsand so on.
i have no idea why nobody uses them or works on them
There is a FEP in the works:
https://codeberg.org/silverpill/feps/src/branch/main/9f9f/fep-9f9f.md
-
@fabio I really, really love it!! I wanted to do the same for quite a long time - but I didn't; and now maybe I can eventually steal your code and RIIR in glorious AGPL!
That said, unfortunately at the moment it's not working for me, I can't open it either in my client, or through my instance's search
FWIW, through my instance I'm seeing some "503 Remote SSL certificate could not be verified", while the client just spins a throbber endlessly. No idea where the fault lies, but I do remember reading many times that Mastodon is a flustercluck and a fishy citizen in ActivityPub
...Anyway, huge applause from me regardless, and hopefully one day I can get to fave the actual post on the blog!
@akavel@merveilles.town thanks for your response

Did you manage to get to the bottom of it? From the description of the error it sounds like your certificate may be broken? Can you access the blog index from a normal browser? Do you perhaps have a split-domain situation (
link!=activitypub_link) but the certificate only applies to one? -
@julian@fietkau.social @liaizon@wake.st it's all live, let me know if it works

-
@julian@fietkau.social @liaizon@wake.st it's all live, let me know if it works

-
@silverpill@mitra.social @django@social.coop @hongminhee@hollo.social Okay, I implemented user outboxes for posts, votes, and shares (post edits are a little harder
)https://activitypub.space/uid/1/outbox
Hopefully I did it ok, had to re-invent some collection logic because I couldn't re-use the helper I wrote before, as that relies on a pagination cursor, which, long story short, is not at all scalable when navigating through a user inbox.
Group outboxes to follow, but just hoping for a sanity check for now.
-
@julian I can read the outbox and activities

There is a minor problem with
Likeactivities, which don't have atofield (this means nobody should be able to see them).And while we're at it: when NodeBB sends a signed GET request, does it add a
Digestheader? I see warnings in my log due to invalid header value.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better π
Register Login