The Government of the Islamic Republic of Afghanistan (GoIRA) was established under the 2004 Constitution, which defined the powers and functions of the executive, judiciary, and legislative branches.