WHEN THE SENATE voted to prohibit import fees on oil, it apparently had only one simple purpose in mind. The senators wanted to avoid an increase in gasoline prices in an election year. Unfortunately, that vote has much longer implications. President Carter is going to Bonn in mid-July for a meeting with the heads of the governments of six other leading nations. They are going to ask Mr. Carter what he expects to do about the tremendous volumes of American oil imports.

Earlier in the year, the Carter administration had been answering that kind of question with assurances that the energy bill would shortly be passed. Those assurances have become less persuasive over the months, as the questions got more urgent. In the past few weeks there have been hints that the president was preparing to say at Bonn that, if Congress didn't act on the bill by the end of this session, he would invoke his emergency powers to put a stiff tax on imports. That's why the Senate moved.

In Japan and, especially, in Europe the Bonn meeting has taken on tremendous significance. The oil-import issue has become, abroad, a symbolic test of American willingness to act on a matter of worldwide concern. American oil consumption this spring rose at a dismaying rate. American oil imports are currently down - very temporarily - because the Alaskan pipeline has come into operation. But once it reaches full capacity, the imports will start upward again. The other industrial nations fear that inordinate American demand will tighten markets for OPEC's oil and send prices soaring again. It's not an idle anxiety. U.S. energy officials have repeatedly predicted that the cost of crude oil will double by the mid-1980s.

At Bonn, Mr Carter will ask the Europeans and Japanese to do a number of things that are costly and politically painful for them. He wants the Germans to risk a higher inflation rate, to make their economy grow faster. He wants the French to open European markets to more American farm exports. He wants the Japanese to buy more American manufactured goods. But if he can't do anything about American oil imports, he can't offer them much of a bargain.

The administration is increasingly concerned about this country's gigantic and unprecedented deficits in foreign trade. It made much of the point that the May deficit, announced Tuesday, was the smallest in some months. But it was still very large, and the underlying pattern is not healthy. A large foreign-trade deficit tends to pull the economy toward a recession.

The best cure for a trade deficit is to expand exports. But if the United States can't lift its exports faster, the deficits will persist and the value of the dollar will continue to fall against the Japanese yen and the German mark. That in turn frightens the Japanese and Germans, who correctly see it as a threat to their own export industries and domestic employment.

For the rest of the world, the question is whether the United States is going to put together any energy policy at all, beyond the present instable and dangerous status quo. Last year the Senate declared that it didn't like the Carter energy plan, but it hasn't been able to get a clear majority for any alternative. Most senators will agree, at least in private, that the present American oil exports are too high and need to be restrained. But they won't vote for a tax on oil to discourage consumption. Now they have voted to prevent the president from using his own emergency powers to impose a next-best remedy, a tax on imports. Having been confronted with a series of hard choices on oil and the world economy, the Senate has answered: None of the above.