UPDATE 7th Nov 2019: snarfed‘s (author of granary) preference is for people to use a different of his tools, https://twitter-atom.appspot.com/, for this use case.  (see the discussion here).  Various reasons to do so, but chief of which I would say is that using twitter-atom you use your own app key, versus everyone piling on to granary and risking it getting in to trouble with Twitter.  I’ll keep this post here, but please use that tool instead!


My online social experience is mostly through the indieweb. For following people and blogs, I use Aperture, a Microsub server, to subscribe to various social feeds. And then I read and interact with those feeds in various clients – e.g. Indigenous on Android, and Monocle on the web.

Although I don’t use Twitter anymore, lots of people I find interesting still do. So I want a way of following their posts from within my Indieweb readers.

I use granary.io to follow Twitter people in my indieweb reader. What it does is convert a Twitter feed into a feed in a format that I can subscribe to via Microsub.

I do it on a person by person basis. I could just convert the list of all people that I’m following in Twitter into one big feed and subscribe to that – but I kind of want to only think of Twitter as a place where certain people that I like happen to have a feed of their posts. It’s where they choose to post their content, and that’s fine. I personally don’t want to use it, so I don’t want it to be my place where I curate the list of people that I follow – I want my indiereader to be that.

IMPORTANT UPDATE: snarfed (author of granary) pointed out that subscribing individually to many feeds makes for a heavier load on both granary and your Microsub server – so it’s better to manage your subscriptions in Twitter.  You can create multiple lists in Twitter and follow and match those to your channels in Microsub, so it’s not just one huge firehose of everything from Twitter.

getting your feeds from granary

OK – so how to get a feed from granary?

Go to granary.io and click on the Twitter button.

Twitter in Granary

You’ll then have to authenticate in to Twitter – so you still do need a Twitter account in order to pull back the info you want to see.

Once authenticated, you should see a form for crafting a Twitter request.

Granary Twitter request builder

(access_token_key and access_token_secret should have been auto-filled in with your own credentials at this point.)

Now, fill in the username with the twitter handle of the user you want to follow. Don’t include the @.

Change @all to @self.

And you can change the format to either atom or html – your Microsub server should recognise both of them. The html rendering is marked up with microformats, so most Microsub servers should understand it (Aperture, does at least.) I’m not sure which one makes more sense to use semantically. Arguably, as atom is purely for use as a feed, and html+microformats could also be used for visual rendering, you could say that atom is the more sensible choice of format, but honestly in terms of verbosity there seems to be little difference. I started using Atom but lately I’ve been using html as I like microformats.

UPDATE: actually, posts show up with much nicer rendering in Indigenous (possibly other readers) if you use the html+microformats format.

If you then hit GET, you should see an example of the content that the request will return:

Granary Twitter results

You can then subscribe to the feed in your Microsub server by copying the URL that granary has generated and subscribing to it. e.g., in Aperture:

Aperture add source

And the Twitter feed should now start showing up in whichever indiereader client you point at your Microsub server. Awesome!

Following Twitter peeps in an indiereader with granary.io and Microsub

Leave a Reply

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