The following scope of judicial review of agency action is set forth in the APA (Administrative Procedure Act), 5 U.S.C. §§ 551–706:
To the extent necessary to decision and when presented, the reviewing court shall decide all relevant questions of law, interpret constitutional and statutory provisions, and determine the meaning or applicability of the terms of an agency action. The reviewing court shall—
(1) compel agency action unlawfully withheld or unreasonably delayed; and
(2) hold unlawful and set aside agency action, findings, and conclusions found to be—
(A) arbitrary, capricious, an abuse of discretion, or otherwise not in accordance with law;
(B) contrary to constitutional right, power, privilege, or immunity;
(C) in excess of statutory...