In principle, our diplomats have mentioned "respecting the prohibition on the use of force enshrined in international law and the territorial integrity of sovereign states"
using those words as search terms yields:
https://legal.un.org/repertory/art2/english/rep_supp7_vol1_a...
https://legal.un.org/repertory/art2.shtml
In practice, command responsibility is generally upheld against losing commanders: https://en.wikipedia.org/wiki/Superior_orders
but an effective way to avoid being tried, at least in the short term, is to be a winning commander: https://founders.archives.gov/documents/Adams/06-02-02-0072-...
(Alexander the Great, on his deathbed, was asked who would inherit his empire; whether because he was an early "realist" or because he was apathetic or simply narcissistic [or?], he replied: the strongest)
Apart from command responsibility, every combatant has a duty to disobey a manifestly unlawful order; note the restrictive adjective "lawful" in both https://www.govinfo.gov/content/pkg/USCODE-2024-title10/html... and https://www.govinfo.gov/content/pkg/USCODE-2024-title10/html...
Furthermore, even before the purely legal aspects of UCMJ, there's the plain common sense of Adm. Holsley (Ret.): https://www.southcom.mil/MEDIA/NEWS-ARTICLES/Article/4359115...
> "To be a trusted partner, [SOUTHCOM] must be credible..."