By all odds, it was an extreme long-shot that the day would ever come when an official United States envoy, equipped with all the trappings of a high functionary, would bear the name of Muhammad Ali.

But there he was, operating as President Carter's man in Africa, with a deputy Secretary of State as an escort, a high White House assistant among his attendants and a government jet with copilots awaiting his next takeoff command. The style was Kissinger, reactivated.

Yet, this was the same guy who once defied the whole enforcement power of the United States and his Texas draft board by saying, "I don't have no personal quarrel with those Viet Congs." That was in 1966, and for refusing military service Ali was sentenced to five years in jail and fined $10,000.

There was more. They took away his world heavyweight title. And the State Department sent out its agents to grab up his passport lest he skip the country. Back then the FBI bugged his conversations with Martin Luther King.

Later, the Supreme Court got most people off his back by ruling Ali had a legitimate claim to exemption as a black Muslim minister.

It cleared the record, but by no stretch of the imagination could Ali watchers believe that some day the president of the United States would entrust this man with an important diplomatic mission -- to persuade African countries to put in with the U.S. and defect from the 1980 Olympic Games in Moscow, a boycott in protest of the Soviet invasion of Afghanistan.

Now the results of that diplomatic errand by Ali are in, and it was a clear disaster. He visited five countries, stirred up old animosities, gained no Olympic allies for President Carter and changed the mind of no African nation.

At Ali's first stop, in Tanzania, where the nation's president refused to meet the boxer, he lost his bearings. He pleaded ignorance when questioned closely by Marxist-oriented interviewers who demanded to know why African nations should follow a U.S. boycott of the Moscow Games when in 1976 the U.S. would not back 29 African nations who walked out of Montreal.

They hadn't told him about that, Ali said weakly, and when he was advised how many black African countries owed much to Soviet support, he said, "They didn't tell me about that in America. Maybe I'm being used to do something that ain't right . . . you are making me look at things differently . . . if I find out I'm wrong, I'm going back to America and cancel the whole trip . . . we're all brothers, and I'm closer to you than I am to white Americans, or white Russians . . . I'm learning . . . I'm no traitor to black people . . ."

At the U.S. State Department, one source admitted, "He's giving us heartburn."

Later, in Kenya, Ali said Carter had put him "on the spot," and sent him around the world "to take a whipping" over American policies toward South Africa. Before the trip ended, State Department types got to him, however, and he became more pro-American.

The whole fiasco was not all Ali's fault. Much of the blunder can be traced to the White House, where the president unforgivably overrated Ali as a diplomat. Carter was mistaken in thinking Ali's charm and popularity as an international black personality could be persuasive factors in Africa.

There were culprits, too, in the State Department, where they neglected woefully to provide Ali with a sufficient background in African politics.

They sent the novice Ali out into the real world of African political passions, a babe in the art of international negotiation, and unsurprisingly he was inadequate. He came back sorely tried, badly chafed, with the diplomatic version of diaper rash.

Yet id did not deter the unconquerable Ali from Proclaiming the success of his African visit when, like any important diplomat, he conferred with the president at the White House on his return. "We were 75 percent successful," Ali claimed.

In this, Ali's arithmetic is suspect. Of the five African countries he visited, only two, Kenya and Liberia, joined the U.S. boycott and they had made their position clear long before Ali was dispatched. The others, Nigeria, Senegal and Tanzania, opted for Moscow, not Ali.

Thus Ali did not gain a single new commitment to join the United States in the boycott. His 75 percent success looks, realistically, more like .000. Yet the State Department in some attempt at solace for itself had the chutzpah to say in its best, tired State Department-ese, that "His trip was useful." It can now be said of the State Department, as it used to be said of Ali, they've never lost a decision yet.