When the knock came at the door of his apartment in a Bonn residential area at 6:32 on the morning of April 24, 1974, and he was told that a group of nine West German security officers had arrived to arrest him, Guenther Guillaume finally dropped the cover that had made him East Germany's master spy.

"I am an officer of the National People's Army of (East Germany) and an employee of the Ministry for State Security," he stated. "I ask you to respect my officer's honor."

With that, the unassuming refugee who had come with his wife from East Germany two decades earlier and who had risen through the ranks of the West German Social Democrats to serve as an aide to Chancellor Willy Brandt, volunteered nothing more. Two weeks later, in the wake of the espionage disclosure, Brandt himself resigned.

Today, the story of the highest-placed East German spy to be unmasked in the West came to a close as East Germany handed over to West Germany about 30 political prisoners and proceeded to grant exit visas to 3,000 East Germans in return for Guillaume's release.

Guillaume was whisked out of West Germany last night into East Germany, passing through the East-West border checkpoint at Herleshausen in the southeast, riding in a camper van that was trailed by a Mercedes.

The completion of the swap left Bonn officials relieved but also frustrated that leaks to the press a week ago had foiled prospects of a grander international espionage trade arrangement.

As originally reported, Denmark, France and South Africa were to give up jailed East German or Soviet agents as part of the deal. But the West German news leaks reportedly angered the other Western governments and may have scuttled what were still delicate negotiations. In the end, the trade remained solely a German affair.

"Negotiations of this kind gain nothing from publicity," Bonn government spokesman Kurt Becker told reporters. He said that the final scope of the deal did not meet "the satisfaction of the federal government."

The official disappointment in Bonn that more West Germans could have been freed was echoed by Egon Franke, West German minister for inner-German affairs, who said, "Some people will regrettably have to remain longer in East German custody because of these indiscretions, because of these boastful disclosures."

Franke reported that among those released by East Germany were three persons who were serving life sentences, one of whom had already spent 13 years in jail. Several others had faced sentences of 10 to 15 years.

In addition to Guillaume, West Germany handed over three other agents, including a former Bonn ministry secretary, Renate Lutze, who had been sentenced to six years in 1979 for spying. The identities of the other two involved were not disclosed.

Such spy exchanges belong to the discreet deals of politics, and there is a history of more than a half-dozen known trades between the two Germanys stretching back over several decades. The names, dates and exact terms involved in a number of other spy swaps have gone undisclosed. But today's arrangement unquestionably ranks as the largest.

Guillaume's wife, Christel, who had received an eight-year sentence in 1975 for her ancillary role in West Germany's most extraordinary spy scandal, was freed last March in exchange for several West Germans held in East German jails. But the Bonn government had long declined to consider releasing the 54-year-old Guillaume, who was serving a 13-year term for his treason conviction at Rheinbach Prison near Bonn.

What appears to have prompted the swap now was Guillaume's poor health -- he has suffered from a kidney ailment -- and Bonn's concern that he would lose his attraction as a bargaining chip. "If we had waited any longer," said Uwe Ronneburger, chairman of the Bonn parliament's Inner-German Committee, in a television interview, "the market value of this spy would have dropped."

It was not brilliance or daring that made the squat, bespectacled Guillaume the master "mole" he turned out to be, but rather the diligence and dullness he displayed. He was the classic "sleeper," a long-term agent who is not expected to produce much for years after his infiltration.

Arriving in Frankfurt with his wife in 1956, Guillaume got a job as a photographer and joined the Social Democratic Party. He was made party secretary in a subdistrict in Frankfurt in 1964, then elected to the Frankfurt city parliament in 1968. In 1970, he moved to Bonn with new party duties and with references from politicians and trade union leaders, some of whom are still in office today. In late 1972, Guillaume became Brandt's party liaison aide.

How could Guillaume have gotten so far without detection? The question, of course, was asked for months after his arrest, and the answer included a combination of oversights and fumbling by intelligence agents as well as a reluctance on Brandt's part and others to see Guillaume as a spy when suspicions about him surfaced in 1973.

Even after Brandt was informed by Bonn Foreign Minister Hans-Dietrich Genscher, then the interior minister, in May 1973, that there were questions about Guillaume's background, Guillaume was allowed to accompany Brandt on vacation for a month in Norway. During that time, it is thought, the spy saw and forwarded to East Berlin copies of two highly sensitive telegrams that reached Brandt -- a NATO nuclear planning document and a letter from then president Richard Nixon about alliance problems.

While in jail, Guillaume was visited regularly by members of the East German mission in Bonn. From them he is said to have learned that in his absence he had been advanced from the rank of captain in the East German Army through major to colonel.