The alliance involved the army leaders and advisors of the Habar Gidir and Duduble, a Fiqhi/Qadi of Sheekhaal, and the Imam was reserved for the Mudulood branch who is believed to have been the first born. Once established, the Imamate ruled the territories from the Shabeelle valley, the Benaadir provinces, the Mareeg areas all the way to the arid lands of Mudug, whilst the ancient port of Hobyo emerged as the commercial center and Mogadishu being its capital for the newly established Hiraab Imamate in the late 17th century.