Building Decidim, an open-source participatory democracy platform
At Codegram we've been working for well over two years now on Decidim, an open-source participatory democracy platform for cities and organizations. The project is leaded by Barcelona's Town Hall, together with ALabs, Universitat Oberta de Catalunya and Localret.
After two years of work, Decidim has become a massive project with lots of abstractions, some arguably better than others. We are writing a series of posts explaining the development of this platform, explaining some decisions we took and analyzing the outcomes.
So, what's Decidim?
Decidim is a platform that allows any organization to empower their users so that they can take part in important decisions. Cities and democratic governments mostly use it, but we've seen cooperatives or cultural associations using Decidim too.
To understand how Decidim works, first we need to define some keywords:
- Organizations : where participation is scoped to. It can represent a government, a town hall, an association or a cooperative, for example. An organization can have multiple participatory spaces of any kind.
- Participatory spaces : the frameworks that specify how participation is carried out. Participatory processes, assemblies, initiatives, and consultations are Decidim’s official participatory spaces.
- Participatory components : these are the mechanisms through which the participation is carried out. Proposals, meetings, debates or surveys are examples of participatory components. A single participatory space can have many components. Two spaces of the same kind might have a different list of components.
For example, consider a local government wants to create a participatory budget so the citizens can decide what should the budget be spent on. That is done via a participatory process (the space), which might have a list of components:
- proposals made by the citizens,
- meetings and online debates to discuss general issues
- a budget where the users can choose what to spend the budget on
You can find a complete list of features, with more detailed definitions, at the official docs.
Any feature developed in Decidim has to agree to its social contract. Most importantly, it has to ensure data confidentiality and integrity, since the platform aims to ensure democratic fairness. This means Decidim does not use, by default, any provider that tampers with this kind of data, so developers must find a way to create internal APIs, and then create API providers for each kind of service we might want to integrate.
Decidim is a multi-tenant platform. This means that a single installation can handle the data for many organizations. Any new feature developed has to keep this in mind. It's also extendable by the community with a modules system.
Project overview and organization
In this post series, we will not focus on Decidim's features, but in its development. Decidim started as a fork of Madrid's Consul, but we ended up with a full rewrite of the software. Consul is a full Rails app tailored to Madrid’s needs and has to be forked per installation, so any particular changes for your app need to be synced every time you update from the official fork. In the end, forks tend to diverge too much for this to be easy, so we rewrote the entire app using Rails engines instead. Rails engines can be delivered via gems, so updates are more manageable. We’ll review Decidim’s architecture in later posts.
Development involves teams from 3 different companies, together with community contributions. Codegram handles the repository management and deals with the core changes.
This post series
This post is the starting point for a series of post that will take us through the whole project. In upcoming posts, we'll analyze specific parts of the project, such as the testing environment setup, the permissions system or the different abstractions we used so that the community can extend Decidim.
We'll be updating this post with a list of each post in the series so that they're easy to find. Keep updated!
Posts published so far: