Federal powers in foreign affairs are different than domestic affairs.
Foreign policy is an inherently federal topic, and the States have never had any power regarding foreign policy; thus, the federal government is not bound to the States' enumerated powers—while they would be for domestic affairs.
The President is the sole organ of the United States in its external, foreign relations.
To fulfill this role, he must be free from legislative restrictions that apply to internal affairs.
The President must comply with the Constitution.
But he must be afforded a degree of deference/latitude in foreign affairs.
From this case: The President entered into a joint resolution that prohibited the sale of arms to countries involved in the Chaco border dispute.