Robert Heinlein's book Space Cadet featured a setting where the Earth is still politically divided into different nation-states (one is named as the 'North American Union'), but all space travel is overseen by a single body, the "Interplanetary Patrol", which also has a monopoly on atomic weapons and enforces peace on Earth with the threat to drop atomic bombs on any nation that launches war on its neighbors (they also have 'space marines' to deal with other types of crises where atomic bombs would be overkill). As one character says, "your purpose is not to fight, but to prevent fighting, by every possible means. The Patrol is not a fighting organization; it is the repository of weapons too dangerous to entrust to military men."
We don't learn a lot about the history of how the Patrol developed beyond the stories of some key people that played a role early on (see this question for two quotes), along with a comment by one character that "It hasn’t been necessary for the Patrol actually to use a bomb since they got it rolling right", and a comment elsewhere about "the past hundred years of Patrol-enforced peace". But we do learn that the Patrol draws people from many nations--in an opening speech to new recruits, they are told that "You come from many lands, some from other planets. You are of various colors and creeds. Yet you must and shall become a band of brothers." They also seem to oversee other forms of space travel that aren't part of the Patrol, like the "merchant service"--at one point in the book, a member of the merchant service is arrested by a Space Cadet for violation of "colonial codes" after using illegal force against some intelligent natives of Venus.
So I was curious about the earliest story that featured a political setup somewhat like this--not necessarily the part about threatening the nations of Earth with destruction to keep the peace, but at least the idea that all space travel is regulated by a single independent organization not under the control of any of the nations on Earth. I'd also want to include the idea that the Earth nations and the space organization co-exist peacefully for the most part (as opposed to a story about a war between Earth and a space power), that this organization is at least primarily human rather than being governed/founded by aliens or A.I.s (and I'd also like to rule out organizations founded by advanced lost civilizations like Atlantis). I'm sure there are plenty of older stories with a single "space navy" type organization controlled by a united Earth government, but I wonder if this sort of variation was already a common trope when Heinlein wrote his book. I have found one pre-Space Cadet story along these lines, I'll add it as an answer it if no one else finds anything earlier.