Fork me on GitHub

2014-01-31

Sojolicious

A toolkit for the Federated Social Web

Sojolicious is a toolkit for the federated social web, containing plugins for the powerful web framework Mojolicious written in Perl.

Synopsis

  use Mojolicious::Lite;

  # Load Plugins
  plugin 'WebFinger';
  plugin 'PubSubHubbub';
  plugin 'Salmon';

  # Establish Salmon Endpoints:
  group {
    under '/salmon';
    any('/:acct/mentioned')->salmon('mentioned');
    any('/:acct/all-replies')->salmon('all-replies');
    any('/signer')->salmon('signer');
  };

  # Add PubSubHubbub callback url
  any('/pubsub')->pubsub;

  # Hooks for incoming notifications
  hook on_salmon_follow => sub {
    # ... You receive a follow request
  };

  hook on_pubsub_content => sub {
    my ($c, $type, $dom) = @_;
    # ... You receive feed information you subscribed to
  };

  app->start;

Goal

Sojolicious mainly focus on support for the OStatus meta protocol and aims for a straight forward implementation of all surrounding specifications.

The design goal is to make all plugins useful on their own, as separated building blocks of OStatus, while playing well with each other. All plugins are application (despite the fact that they are Mojolicious plugins) and storage agnostic, providing event driven hooks for usage.

Some plugins will become separated distributions, in case this is useful.

For the moment the following plugins were already seperated:

Sojolicious is work in progress. There are missing parts currently developed and existing parts reworked. Don't use it in its current status! However, you can try out all separated distributions published on CPAN.

Plugins for ...

  • ActivityStreams, developed by Martin Atkins, Will Norris, Chris Messina, Monica Wilkinson, and Rob Dolin.
  • Atom, developed by Mark Nottingham and Robert Sayre.
  • Atom-Threading-Extension, developed by James M. Snell.
  • HostMeta, developed by Eran Hammer-Lahav and Blaine Cook.
  • MagicSignatures, developed by John Panzer, Ben Laurie, and Dirk Balfanz.
  • OStatus, developed by Evan Prodromou, Brion Vibber, James Walker, and Zach Copley.
  • PortableContacts, developed by Joseph Smarr.
  • PubSubHubbub, developed by Brad Fitzpatrick, Brett Slatkin, and Martin Atkins.
  • Salmon, developed by John Panzer.
  • WebFinger, developed by Brad Fitzpatrick, Eran Hammer-Lahav, Blaine Cook, John Panzer, and Joe Gregorio.
  • XRD, developed by Eran Hammer-Lahav and Will Norris.

There are plans to expand the scope to other social protocols later, for example OExchange. Beside Federated Social Web awareness, there are plans to use these building blogs for indieweb concepts, like WebMentions.

Acknowledgement

Mojolicious is written by Sebastian Riedel.

I want to thank all persons responsible for maintaining code and specifications in this realm. Thanks to all contributors of these projects as well!

And thanks to all implementors of the specifications for inspiring code (which is referenced in the sourcecode).

Participation on conferences was supported by the BMBF-project Linguistic Networks.

Where to learn more?

mojolicio.us, OStatus.