This is quite a complex question. In the USA, the Constitution is not precise about the scope of powers and duties of the different layers and branches of government. It was not until the tenure of John James Marshall, a Federalist judge who served at the SCOTUS between 1801 and 1835, that this complex legal question was clarified during the Marbury v. Madison case.
This case established the principle of Judicial Review, by which the judiciary, one of the three branches of government reviews the actions and/or laws or decrees passed by the other two powers. This means that in terms of Constitutionality, the courts have jurisdiction over the other two branches of government. This is part of the system of Checks and Balances.