Maryland-based U.S. District Judge Peter Messitte previous year allowed the lawsuit to proceed - a ruling that Trump appealed to the 4th Circuit.
The state of Maryland and the District of Columbia sued in 2017, claiming Trump has violated the emoluments clause of the Constitution by accepting profits through foreign and domestic officials who stay at his Washington hotel. The complaint also alleges that the U.S. government has "promoted the Mar-a-Lago Club ... and that "federal, state, and local governments or their instrumentalities have made and will continue to make payments for the use of the facilities owned or operated" by Trump.
The case extends beyond the D.C. hotel and is based on a different theory of standing.
President Trump broke precedence by not divesting fully from his business interests. The provisions are called emoluments clauses.
If they intend on continuing their case, the attorneys could petition the court for an en banc (full court) review or appeal to the Supreme Court. As such, the court rejected their standing.
The lawsuit brought by the state attorneys general was one of several emoluments cases that accuse Trump of benefitting from foreign government business in violation of a constitutional prohibition on the receipt of things of value from foreign states.
Judge Paul Niemeyer wrote in the 36-page opinion that the arguments put forth by Washington and Maryland are "so attenuated and abstract that their prosecution of this case readily provokes the question of whether this action against the president is an appropriate use of the courts".
They added that it is equally plausible that Trump's ties to the Trump International Hotel has diverted business away from it, and towards other competing properties in the area.
Actually, the reason there hasn't been litigation on the Emoluments Clauses is because Trump's extensive (alleged) violations of them are unprecedented.
The court ruled there was no legal standing to even bring this frivolous lawsuit against President Trump.
After all, as the court wrote, "there is a distinct possibility" that "certain government officials might avoid patronizing the Hotel because of the President's association with it".
The Justice Department, which is evidently displeased with the diktat and is looking at whether to appeal to a higher court said: "President Trump's decision to block users from his personal Twitter account does not violate the First Amendment".
Despite the legal challenges his company faces, to this point Trump has been able to prevent the release of any private business information to the courts, leaving Democrats to wonder if Trump will be affected by any of the inquiries before he faces re-election next year.
Washington DC's Trump International Hotel - as it is formally known - was opened in September 2016 - just months before Mr Trump won the presidential election.
Kelly Laco, a Justice Department spokeswoman, said the department was pleased that the appeals court unanimously dismissed "this extraordinarily flawed case".
There are now two other emoluments lawsuits playing out in federal court against the president, neither of which has yet gone to discovery. Trump has asked another appeals court to step in to determine whether lawmakers have a sufficient basis for suing him.