Development Seed Blog

Playing with FeedAPI and Notifications

A More Efficient Way of Keeping People Posted

A More Efficient Way of Keeping People Posted

As we have these two powerful frameworks, FeedAPI and the new Notifications framework I talked about  in my last post, I was thinking it would be cool to have them work together. Users already had the option to stay subscribed (i.e. to all nodes created of a given type), but this didn't seem like a very efficient way of getting notifications for all updated feed items. 

So I’ve implemented this new notifications plug-in that allows you to subscribe to a feed and then get lists of new/updated items. To see it working please take a look at the notifications_feed.module in the notifications package.

The resulting email notification looks like this:

This simple module takes advantage of the existing Notifications and Messaging frameworks to implement - with just a few lines of code - a new event type (Feed update) and a new subscription type (Subscribe to feed) with all the features, such as configurable sending methods, queueing, and custom message templates.

The idea, in short, is that we can now easily create any custom plug-in to keep users posted about anything with just a few lines of code, while having all the gory details like message templating and delivery, user subscriptions,  notifications queueing for large sites, etc. automatically handled by these modules. 

And you don't need to create any new table or field for managing all this data!

The notifications_feed.module is already part of the Notifications Framework.

Comments
great work.

We're interested to dig into these modules deeper, and help test and develop.

Hey Jose, Just had a look at

Hey Jose,

Just had a look at the code. This looks great. Need to test drive soon.

Alex

notifications and og

Hi,

This looks like the right way to go, we are building up a bunch of tools for organic groups, does the notification framework work with OG.

We're interested to dig into these modules deeper, and help test and develop.

Great work! -M

Post new comment
The content of this field is kept private and will not be shown publicly.