As revealed in these exclusive photographs by Iwan Baan, the pavilion constructed at the Louisiana Museum of Modern Art by José Selgas and Lucía Cano, with architecture studio Helloeverything, has been rebuilt in Kibera, part of the Kenyan capital Nairobi.
In its new role as a school, it is intended to demonstrate how architecture can make a big difference to the world's poorest communities.
"Architecture and design isn't just about looking nice, it is about making a difference to people's lives," said Second Home co-founder Rohan Silva, one of the partners in the project.
"It can change people's behaviour, it can support development, it can help the poorest," he told Dezeen.
"As depressing as the world can be sometimes, it can be shaped by good architecture and good design. I think that is really life-affirming."
The project came about after Baan visited the old Kibera Hamlets School, which had no drainage, toilets, electricity or adequate roof to keep out the frequent rain. It was also surrounded by pile of garbage.
The photographer approached Selgas and Cano, who has already been commissioned to design the Louisiana Museum's 2016 summer pavilion. They then teamed up with Second Home, as well as architects Helloeverything and AbdulFatah Adam to plan a more socially minded second life for the pavilion.
One the summer season was over, the structure – which is made from chipboard, sheets of polycarbonate plastic and scaffolding – was dismantled and packed up into shipping containers for transport.
But on the way to Kenya, the project hit a major hurdle – it was impounded at customs, and the team was forced to make an "official government payment" to get it released.
"It was a real reminder of how difficult it is, sadly, for many countries to do trade," said Silva.
After a six week delay, the containers finally arrived at its destination. SelgasCano then led the building's reconstruction, with help from a team of 20 local labourers.
Now complete, the building has become a landmark for the local community, according to Silva.
As well as creating a school that children love, it has become a venue for evening and weekend events, as well as a focal points for donors and charities.
"We rightly celebrate buildings like the David Chipperfield gallery in Wakefield or the Sage in Gateshead, because we think that great design and architecture will encourage people to go the area, spend money and invest. And it's exactly the same here," said Silva.
"That feedback loop is clearly happening in Kibera and the headmaster is so happy about that," he added.
"His challenge is to get enough money each month to keep the school alive. This new building means they are talking to a lot more donors, and that is a really nice thing."
Madrid-based Selgascano are best known for creating the colourful plastic Serpentine Pavilion in 2015, as well as Second Home's creative workspace in London.
But the pair have also worked on several socially focused projects, ranging from a street sports facility in Spain to a vaccination clinic elsewhere in Kenya.
"Selgascano, as a practice, are really hands on," added Silva, who also commissioned the duo to design a concept bookstore.
"They never wanted to have and never will have more than 20 employees because they always want to be hands on with projects. Being part of that very physical process of building is very important to them."
The architects ranked at 110 in the Dezeen Hot List, a guide to the key players, newsmakers and the emerging talents in the design world.