A senior CIA official maintained contact with a key aide to fugitive ex-CIA agent Edwin P. Wilson even after the agency learned that Wilson was supplying explosives and training commandos for radical Libyan leader Muammar Qaddafi, the aide has told federal investigators.

The CIA has consistently denied that it in any way condoned or was connected with Wilson's activities in Libya. However, Wilson's former aide, Douglas M. Schlachter, 39, has told federal investigators that until he left Wilson's organization in 1978, he regularly gave Thomas G. Clines, then training supervisor for CIA clandestine services, information on Wilson's activities as well as general intelligence information.

According to Schlachter's attorney, Alvin C. Askew, Schlachter has also told investigators that Clines personally gave him a list of information and material, specifically relating to Soviet military equipment and other technology, that the CIA wanted from Libya. Schlachter has alleged that on at least one occasion he gave Clines a report on his examination of a Soviet-made MIG-23 "Foxbat" fighter plane, Askew said.

Askew said Schlachter has also told federal investigators that he has agency documents and witnesses to back up his assertion that senior officials who solicited his help in gathering intelligence knew about Wilson's activities and about his connection with Wilson.

Clines retired from his CIA post in 1978. He and Theodore G. Shackley, his former CIA supervisor and close associate, now are running a private international consulting firm in Rosslyn. Neither man could be reached for comment yesterday.

Shackley, who retired in 1979 as associate deputy director of CIA operations, has acknowledged that he privately received some intelligence information from former agent Wilson. But Shackley, who had been a longtime social friend of Wilson's, has said he immediately cut off contact with Wilson when he learned in September 1976 about the nature of Wilson's activities in Libya, including a $1 million assassination contract allegedly engineered by Wilson on behalf Qaddafi.

Former Wilson aide Schlachter's allegations were made known by Askew yesterday after a U.S. District Court hearing here in which it was disclosed that Schlachter has agreed to plead guilty to conspiracy and a federal munitions-export violation. The charges stem from his role from 1976 to 1978 in helping Wilson and another ex-CIA operative, Francis E. Terpil, supply explosives and high-technology weapons and support systems and training under an April 1976 contract with the Libyan government.

Wilson and Terpil, both of whom are fugitives, were indicted first in April 1980 and were reindicted, along with Schlachter, last August. Wilson is living in Tripoli and Terpil was last seen in Beirut.

Schlachter voluntarily returned to the United States in November from the central African country of Burundi, where he runs an air freight shipping company. Askew says Schlachter quit working for Wilson in 1978 after Wilson asked him to participate in a "quasimilitary"' operation in another African country that would have included "an act of violence."

Askew said in an interview yesterday that while he was in Libya, Schlachter was convinced that he was working under "deep cover" for the CIA, a belief that Askew says was reinforced by Schlachter's allegedly numerous meetings with Clines. Further, he said Schlachter had met many times with Shackley before Schlachter's departure for Libya in 1976.

"He Schlachter reported to active agents of the CIA and took instructions from them," Askew said yesterday.

"He did what they the government said he did in the indictments ," Askew said. But Schlachter, who began working for Wilson in 1971 when Wilson was employed by a top secret naval intelligence operation, assumed his activities were sanctioned by U.S. intelligence officials, Askew said.

Assistant U.S. Attorney E. Lawrence Barcella Jr. refused yesterday to discuss Askew's disclosures about the statements Schlachter allegedly has made during extensive debriefing sessions with an array of federal investigators, including agents from the FBI and the Treasury Department's Bureau of Alcohol Tobacco and Firearms, which has played a key role in the Wilson-Terpil investigaton.

U.S. Secret Service agents also have questioned Schlachter at length in an effort to gather any information he might have on recent reports that Qaddafi dispatched a "hit team" to assassinate President Reagan and other U.S. officials.

Askew said yesterday that so far Schlachter has refused to submit to questioning from CIA officials. "He's told them all this about Wilson's activities once before and he doesn't want to tell them again," Askew said. "He's mad."

Prosecutor Barcella told U.S. District Judge John H. Pratt yesterday that Schlachter has signed an agreement to cooperate "fully, truthfully and completely" with federal authorities investigating the Wilson-Terpil case. Schlachter is expected to testify before a federal grand jury investigating the case and before the House Intelligence Committee. Pratt placed the plea bargain agreement under court seal yesterday.

Schlachter, who has been under protection by U.S. marshals in an undisclosed location since his arrival, faces up to seven years in prison if convicted of the charges. He is scheduled to formally enter his guilty plea in federal court on Jan. 18.