Between 1279 and 1325, King D. Dinis ordered the construction of walls to surround the settlement of Bemposta, which included an area of 352 meters perimeter, using the same methods and strategies employed in Miranda, with two flanked gates and corbels.