Platforms and Components: mySociety’s tools for you to re-use

Keen on the idea of setting up a mySociety-style site like FixMyStreet.com or WhatDoTheyKnow.com? Not sure what you need? Then read on.

At mySociety, we’re working really hard to create software tools that are attractive and easy to set up in diverse countries, cities and regions. Now we want to make sure everyone knows what we offer, and how it can be useful. This is a beginners’ guide to what mySociety can offer in the way of software tools.

First up, the basics:

  • All our code is open source.
  • Some of our code is available in simple-to-use packages.
  • There are two types of package. We call them Platforms and Components. This post is about explaining the difference.

Platforms

You can think of Platforms as flat-pack websites – like furniture that arrives in a cardboard box, with all the screws, instructions and tools included. Our Platforms provide everything you need to replicate a site like FixMyStreet.com or WhatDoTheyKnow.com in your own country, city or region, but you need to do a little work to get it up and running.

Platforms are great for people who don’t want to spend a long time reinventing the wheel, and who want to get a basic, functional site up and running as fast as possible.

We provide the software, and you just need to add:

  1. Data to populate it
    For example, if you’re setting up a website using the FixMyStreet platform, you need the names and email addresses of every bit of government that you want to send reports to. (This isn’t as daunting as it might sound – it might just be one authority and one email address! And if not, well, we’ve had lots of success with crowd-sourcing this sort of information).
  2. A server to host it on
    We can help you here, if it’s a problem for you. See step 1 on this page.
  3. Enthusiastic people to run it
    Don’t forget this vital consideration! Computers are great, but they can’t do everything themselves. You will need people – volunteers or paid staff – to promote, improve, and interact with the users of your website.

The following platforms are available to download and install:

  • FixMyStreet
    For reporting common street problems such as potholes or broken streetlights. Creates transparency about local government, at the same time as providing a practical service to users.
  • Alaveteli
    Our Freedom-of-Information Platform. Whether or not your country has a Right to Know law, this Platform lets people ask questions to public authorities, – and it publishes all the conversations online.
Please note, at the moment these Platforms are not easy enough for anyone to install: you will need some technical knowledge. However, we are working all the time to make it easier to set up websites built on these platforms, and we have mailing lists and IRC channels where you can ask for help. These are linked to from the Alaveteli and FixMyStreet Platform homepages.
Components are handy code modules that you can incorporate into any website build, saving yourself an awful lot of time and effort. They’re the result of mySociety’s years of experience in building tools that work (and refining those that didn’t work as well as we wanted them to).
At the moment, we reckon our Components will be of most use to people building Parliamentary Monitoring websites, like our site TheyWorkForYou.com, or the Kenyan site Mzalendo.com.

If Platforms are like a flat-pack piece of furniture, Components are more like the parts of a kitchen. When you have a kitchen built, you get to choose from a number of parts that fit together: cupboards, drawers, shelves, etc. You can ignore things you don’t want, and add in things you do – and you end up with a kitchen that suits your needs.

Components will save you a lot of time because you won’t need to create database structures, APIs, search mechanisms, admin interfaces, and so on. Just slot in a Component – like you might slot in a dishwasher – and it’s all done for you. We’ve done our best to make them easy to deploy, easy to customise, and easy to connect together.

You will definitely need technical skills, although we are working on lowering that barrier. Components cannot run on their own – they need a website to fit into. And just as with our Platforms, you’ll need data. But you don’t need a server – we host the Components ourselves.

Right now we just have one component which is fully documented and ready to use, but we’re working on followups right now. This component is called MapIt.

  • MapIt 
    MapIt is a web service which you can use to work out which boundaries a point or postcode exists within. An essential foundation for geographic lookups of all kinds. You can play with the UK instance here. We use it on:

    • Our parliamentary monitoring website TheyWorkForYou.com. Users are shown their own MP’s data even if they don’t know who that MP is – all they have to do is input their postcode.
    • Our ‘contact your representative’ site WritetoThem.com. Users input their postcode and are shown everyone who represents them, from local to European level.
    • Our street problem-reporting site FixMyStreet.com. It sends problem reports to the relevant local council, based on the co-ordinates of where the problem was reported.

We are also working on a new component for building Parliamentary Monitoring Websites on top of, called PopIt. It isn’t quite ready for prime time yet, but if you join the Poplus email list, you can follow progress.

 

Where can I get these Platforms and Components ?

They’re all on Github, as is all our code (including a lot that we haven’t made easy to re-install yet). As it’s open source code, you can take them for free.

If you want to use MapIt, or learn about our future components, please sign up for the Poplus mailing list at the same time – it can be an invaluable place to get support when you have questions. You can also improve the code – sharing your improvements with us is a great way to say thank you. Plus, if you have ideas for other Components that will work well with ours, we’d love to hear about them.

What next?

We don’t just build this stuff, we also help people install and run it. Keep in touch and let us know how you’re using our code, and what is or is not working. If you hit any problems, there is always someone who can help.