Were Hiroshima and Nagasaki war crimes?
No. While there were laws in place to protect civilians for attack, specifically from artillery, there we no protections from aerial assaults under the existing Hague Conventions of 1899 and 1907. Arguments linking radioactive fallout, which is poisonous, to a ban on chemical weapons was rejected by the International Court of Justice in 1996. Other rules or laws governing "unnecessary suffering" were deemed non-applicable to nuclear weapons.
About the only convention that could have been violated where statutes on targeting industrial centers. Hiroshima did not have a major industrial zone within its city limits, but it did have HQs of several Japanese army units and up to 40,000 troops stationed in the city, so again, these could also be argued as legitimate targets.
There are no international treaties or law banning the use of nuclear weapons. Such treaties have been voted on, but where never passed or ratified by nuclear powers.
US committed a war crime.
Maybe. I can be argued that Soleimani was a legitimate target because he was a party to combatant forces targeting the Americans in Iraq and supporting combatant activities around the region which do engage in conflict or hostile actions. There is no declared war between Iran and the United States, but that doesn't mean any strike is a crime or the killing of a commander is illegal, just undeclared.
International laws do allow of the killing of enemy combatants during non-war times if there is sufficient cause. There doesn't have to be a declared war for a war crime to take place. Any crime committed against combatants outside of a declared war isn't automatically a war crime. Any action needs to be measured against existing, ratified and party-to conventions and statutes.
the US is not a party to the International Criminal Court and does not accept its jurisdiction over American troops or actions.
The IRGC is not a military force, it is an official part of the Iranian military, but from a legal perspective it's a paramilitary outfit and is thus not subjected to the same laws or rules or protections afforded to militaries. Under international laws they would be considered "Unlawful combatants" with the same protections as militants the US fought during the Iraqi insurgency or during its campaign against ISIS... or India in Kashmir. They would be governed by the relevant national law of the combatant power.
American contractors are of the same category. Combatants or support elements, but not soldiers in the eyes of the law.
Same with Russia's current crop of PMCs like the Wagner Group.
If captured, they are to be treated as armed civilians and are subjected to each governments laws, not international treaties.