The Bashorun was the leader of the 7-person council of Oyo called the Ọ̀yọ́ Mèsi and his position was essentially that of a Prime Minister or Chancellor, which he is often referred to as.
[1][2][3] In times without an Aláàfin, the Bashorun would rule as regent.
It was his duty to protect the unwritten constitution and counter the Aláàfin when he becomes unfit to rule, either through disability or by becoming tyrannical.
They are also known as "the king maker" because they play the biggest role in chosing the next Aláàfin.
The office greatly lost significance after a Bashorun, Gáà, overthrew the Aláàfin in 1754.