From Dawn Like Thunder (Annotated): The Barbary Wars and the Birth of the U.S. Navy, by Glenn Tucker (Corsair Books, 2019), Kindle Loc. ~1150ff:
When Jefferson went to London in company with John Adams to meet the ambassador of Tripoli, Abdurrahman, he found that this least powerful of the Barbary regencies wanted an aggregate of $160,000 from the United States.
The Ambassador thought Tunis would settle for the same tribute.
The cost for all four of the Barbary States probably would be a million dollars, a figure later considerably increased. The ineffectual Congress which operated under the Articles of Confederation had difficulty in raising any kind of money from the states and had no powers of direct taxation.
The request for a million dollars was fantastic. Jefferson was in no temper to pay it even if the money came easily. He rejected it forthwith. What the expected tribute amounted to may be understood better by a comparison with present-day expenditures.
The cost of the federal government for the first ten years under the Constitution, from 1789 to 1800, was roughly $5,775,000 a year. That was the average. The proposed tribute of one million dollars would have aggregated more than one-sixth of the entire federal expenditure.
It would have been tantamount proportionally to fifteen billion dollars of federal expenditures in 1963, at a time when money is much easier to procure by taxation than it was in 1786.