The foreign policy of the United States of America is laid by POTUS and the Legislative Branch (US Congress). US Congress has the power of influencing US foreign policy as granted by the United States Constitution in Article 1, Section 8
...To declare War, grant Letters of Marque and Reprisal, and
make Rules concerning Captures on Land and Water;
To raise and support Armies, but no Appropriation of
Money to that Use shall be for a longer Term than two
Years;
To provide and maintain a Navy;
To make Rules for the Government and Regulation of the
land and naval Forces;
To provide for calling forth the Militia to execute the Laws
of the Union, suppress Insurrections and repel Invasions
To provide for organizing, arming, and disciplining, the
Militia, and for governing such Part of them as may be
employed in the Service of the United States, reserving to
the States respectively, the Appointment of the Officers,
and the Authority of training the Militia according to the
discipline prescribed by Congress;
Take for example at the time Woodrow Wilsen wanted to create the League of Nations after World War I which was revoked by Congress shows how powerful Congress is on matters about domestic and foreign policy. The Judicial Branch (SCOTUS) of the United States is rather powerless in dealing with "constitutional disputes" on foreign policy
The judicial branch is limited in how much it can arbitrate constitutional disputes over foreign policy, and it is often reluctant to.
POTUS has also the power granted by the US Constitution to ordain foreign policy as declared in Article 2, Section 2 of US constitutional law such as creating treaties, power of naming reluctant offices important to foreign policy... Take, for example, Mark Esper, United States secretary of Defense chief, who was fired by POTUS... Although the Senate has the power to decide ambassadors
The President shall be Commander in Chief of the Army
and Navy of the United States, and of the Militia of the
several States, when called into the actual Service of the
United States; he may require the Opinion, in writing, of
the principal Officer in each of the executive Departments,
upon any Subject relating to the Duties of their respective
Offices and he shall have the Power to grant Reprieves and
Pardons for Offenses against the United States, except in
Cases of Impeachment.
He shall have Power, by and with the Advice and Consent
of the Senate, to make Treaties, provided two-thirds of the
Senators present concur, and he shall nominate, and by and
with the Advice and Consent of the Senate, shall appoint
Ambassadors, other public Ministers, and Consuls, Judges
of the Supreme Court, and all other Officers of the United
States, whose Appointments are not herein otherwise
provided for, and which shall be established by Law: but
the Congress may by Law vest the Appointment of such inferior Officers, as they think proper, in the President alone,
in the Courts of Law, or in the Heads of Departments.
The President shall have the Power to fill up all Vacancies
that may happen during the Recess of the Senate, by
granting Commissions which shall expire at the End of
their next Session.
https://constitutioncenter.org/media/files/constitution.pdf
https://www.cfr.org/backgrounder/us-foreign-policy-powers-congress-and-president
https://www.nytimes.com/2020/11/09/us/politics/esper-defense-secretary.html