Barcelona residents had until the end of January to submit suggestions for a plan to redevelop the green spaces of Montjuic, an iconic hill overlooking the Catalan capital.
Few people live on Montjuic itself, which sports a stadium built for the 1992 Olympic Games alongside museums, a castle and recreational areas, but there are dense residential streets at the bottom of the hill.
Inhabitants of those neighbourhoods were given the chance to add their ideas on things like transport and environmental protection - both online and at meetings - to a draft of the city council's action plan for Montjuic.
Barcelona often uses inclusive processes like this to gather citizens' input on municipal projects - a trend that is growing worldwide at municipal and national levels.
Recent surveys in Barcelona, Spain's second-largest city, demonstrate that people want, and are able, to take part in shaping urban development.
But with municipal elections to be held in May, Fernando Pindado, commissioner for democracy and active participation at Barcelona City Council, said working methods needed to be strengthened so they remain consistent, no matter which political party is in charge.
And the city is still looking for the best ways to incorporate the views of a wider range of people, he added.
"Not all citizens are the same - there are lots of foreigners, some have kids, some don't," he said.
"The internet is very useful for extending social debates ... but not everyone has internet access."
Participatory processes are gradually emerging in cities around the world, as digital technology makes them simpler and faster for local authorities to implement.
Getting them to work effectively, however, can be challenging for governments and citizens alike, said Birgit zur Nieden, a commissioner in the Senate of Berlin, which governs the German city.
That was the case when the senate trialled a new way of designing a programme to improve the lives of refugees in the capital, she said.
"In 2015, many such people came - and Berlin failed in some regards to attend to their needs well," she told the Thomson Reuters Foundation.
The process, which lasted about nine months, involved inviting NGOs and other organisations that interact with migrants to take part in working groups on relevant topics.
The goal was to infuse their knowledge and understanding of refugees' needs into the city programme, she explained.
In practice, the design was complex, and the administration and civil society groups did not find it easy to work productively together, she said.
Nonetheless, it was useful to get to know each other and exchange expertise, she added.
Beth Noveck, director of the Governance Lab at New York University, said harnessing new technology to engage the wider public in drafting laws was "a global phenomenon".
But previously authoritarian states like Taiwan and Brazil are experimenting with it the most, she added.
"In countries that have long-established and highly rule-based legislative practices, innovation can be difficult in contrast to countries with younger democratic institutions," she said.
In Taiwan, artificial intelligence and other technology was used to engage 200,000 people in crafting legislation on company shareholder requirements and internet alcohol sales, for instance, Noveck said.
The government uses an open source tool called Polis, which makes it possible to take the pulse of a large group using an algorithm that clusters their responses.
Brazil is using an app called Mudamos to allow ordinary people to digitally sign proposed bills relating to popular issues such as public cleanliness and municipal transport.
Meanwhile, in January, French President Emmanuel Macron launched a two-month "great national debate", in response to ongoing "yellow vest" protests largely rooted in dissatisfaction over growing social inequalities.
Through a series of internet-based consultations, workshops and regional conferences, the government is canvassing citizens' views on key themes including environmental policy, taxation, democracy and public services.
Have you read?
In general, participatory processes are being used more at the local level because party politics are less dominant here, with cities like Reykjavik, Barcelona and Bogota pioneering the use of online engagement, Noveck said.
People also find it easier to spot problems, identify solutions and evaluate legislation that directly affects their daily lives, she noted.
But in Barcelona, for example, there is still a lack of transparency over how the proposals gathered are used, according to a research project into participatory processes called CrowdLaw Catalog, led by the Governance Lab.
In recent years, which ideas made it into the Municipal Action Plan and why has not been clear, the Catalog said, noting a statistical model could be used in future to measure this.
Barcelona City Council's Pindado said the Spanish city had found it useful to set up an independent body to monitor citizen consultations, boosting confidence they would be protected from political interference.
While the level of public interest always depends on the topic, "we're getting to a point where these participatory processes are no longer dependent on the government's will", he added.