WASHINGTON — President Trump abruptly issued an executive order on Thursday demanding an evaluation of the Postal Service’s finances, asserting the power of his office weeks after accusing Amazon, the online retail giant, of not paying its fair share in postage.

In the executive order, issued just before 9 p.m., Mr. Trump created a task force to examine the service’s “unsustainable financial path” and directed the new panel to “conduct a thorough evaluation of the operations and finances of the U.S.P.S.”

The president does not mention Amazon in the order, but it is clear that he intends for the panel to substantiate his repeated claim that the financial arrangement between the Postal Service and Amazon, its biggest shipper of packages, is a money loser.

In December, Mr. Trump railed against the service on Twitter for being “dumber and poorer” by losing billions of dollars and not “charging MUCH MORE” to Amazon and other shippers. His Twitter attacks date back as far as 2013, when he scoffed at the service for planning to eliminate Saturday mail delivery — “our poor, poor Country,” he wrote — and raising the cost of stamps.