The Generalitat of Catalonia stems from the medieval institution which ruled, in the name of the King of the Crown of Aragon, some aspects of the administration of the Principality of Catalonia. The first Catalan constitution is that of the Corts of Barcelona from 1283.