Press "Enter" to skip to content

Protocols, APIs, and conventions | InfoWorld

The fediverso is connected by protocols like ActivityPub and WebFinger that I know very little about at this time. This is because the Steampipe plugin, which is compatible with the boards I’ve been creating and describing in this series, doesn’t require you to understand or use those protocols.

However, it requires you to understand and use the Mastodon API. I mostly use that API via the Go SDK for Mastodon (thanks mattn!), sometimes I make REST calls directly. Either way, my read-only boards use a fairly small subset of the Mastodon API. The full API is quite broad and deep; allows API clients to read and write to Mastodon servers in many ways. These are the chapters of the Mastodon API book: applications, accounts, administration, instance, search, states, timelines, notifications, oembed. These chapters define what is common to all Mastodon clients, including web apps, phone apps, native OS apps, and Steampipe dashboards.

So far, I’ve ignored protocol-enabled interop to focus on API-enabled interop. I am aware that the fediverse includes much more than just Mastodon. I intend to explore BookWrym, Friendica, Funkwhale, Lemmy, takahe, PeerTube, Pixelfed, PeerTube and others in due course. But right now, the Mastodon ecosystem is enough to try to figure it out.

For example, there is a new web client for Mastodon: With the recent addition of list support, it has become my favorite way to interact in the Mastodon space. So naturally I wanted to be able to click from panels from Steampipe to Elk, and use it as an alternative to the Mastodon web app with batteries included.

It was easy to enable that integration. Not thanks to ActivityPub, and not even thanks to the API. It works because of a third level of interop at play: common patterns for account URLs and toot URLs.

This is the URL of Ward Cunningham’s account, who posts his tile at But as we saw in instance-qualified Mastodon URLs, if you visit that URL directly, and if it’s not your main server, you can’t follow Ward there or add him to a list. You’ll need to copy that URL, paste it into your home server’s search box, run the search, and arrive at an instance-qualified URL where you can follow or add to a list: . If your home is, this would be

Similarly, here is one of Ward’s touches on If you want to reply, boost, or bookmark, you can’t do it there. The URL you need is again one that is routed through your home server: Note that the IDs for the same toot differ! That difference surprised me and a few others, and is a topic for another episode. I’ll just point out here that these two patterns govern how we interact when we cross server boundaries in the Mastodon space using the standard web client.

Also Read:  Making a new business case for cloud computing

When I started using Elk, another pattern layer emerged. Here are those same URLs in Elk:

Turns out I just needed to make two of the Steampipe plugin’s transform functions prepend to the instance-qualified URLs, then make the prefix a configuration option. Now when I visit the Mastodon links from the dashboards, to reply, boost, follow or sign up, I land on the Elk experience I prefer.

ActivityPub and WebFinger are formal standards. I would describe the Mastodon API as a de facto standard. But this prefix maneuver is just a convention. It is not guaranteed to work with any other web client, and is not even guaranteed to work on all URLs presented by the standard Mastodon client. That’s fine by me. Conventions are incredibly useful. The Twitter hashtag is just a convention, after all, itself inspired by an IRC convention.

We are in one of those times of rapid innovation on the Internet, when new conventions can unlock emerging behaviors. It hadn’t even occurred to me that Steampipe boards might support Elk. A few hours after I thought they might do it, they did. I’ve seen this sort of thing before, perhaps most notably when the blogosphere embraced <link rel="alternate" type="application/rss+xml" href="{feedUrl}"> to allow browsers to automatically discover RSS feeds. That happened about 20 years ago, and suddenly, when a handful of leading blogging tools adopted the convention in a matter of days. It was a lot of fun living that time. If you missed it, please enjoy the sequel that is in development now!

These series:

  1. Autonomy, pack size, friction, fanout and speed
  2. Create a Mastodon panel with Steampipe
  3. Navigating the fediverse
  4. A Bloomberg terminal for Mastodon
  5. Create your own Mastodon UX
  6. Lists and people on Mastodon
  7. How many people on my Mastodon feed also tweeted today?
  8. Qualified Mastodon URLs per instance
  9. Mastodon Ratio Charts
  10. Working with Mastodon lists
  11. Images considered harmful (sometimes)
  12. Mapping the broader fediverse
  13. Protocols, APIs and conventions

Copyright © 2023 IDG Communications, Inc.

Be First to Comment

Leave a Reply

Your email address will not be published. Required fields are marked *