AS THE IRAN-CONTRA affair moves onto the dusty library shelf of history, one of its most troubling stories remains untold. To a degree little understood even by the congressional investigating committees, the Reagan administration attempted to manipulate American views of the war in Nicaragua through an unprecedented, covert propaganda bureaucracy.

The apparatus was coordinated by the National Security Council staff, used CIA experts and Army psychological-warfare specialists and worked to intimidate or discredit those who stood in the way of military aid for the contras. Ultimately, the campaign came to resemble the sort of covert political operation the CIA runs against hostile forces overseas but is outlawed from conducting at home.

The Iran-contra committee unearthed hundreds of pages of documents about the domestic propaganda operation and took depositions from many of the principals. House investigators even drafted a chapter about the domestic side of the scandal for the Iran-contra report. But Senate members of the panel blocked its inclusion in the final report, arguing that the issue fell outside the committee's mandate.

The explosive conclusion of that draft chapter was that the administration's covert propaganda operation had used "one of the CIA's most senior specialists, sent to the NSC by Bill Casey, to create and coordinate an inter-agency public-diplomacy mechanism. {This network} did what a covert CIA operation in a foreign country might do -- {it} attempted to manipulate the media, the Congress and public opinion to support the Reagan administration's policies."

The troubling aspects of the domestic propaganda operation include:

A CIA link. Iran-contra documents show that the propaganda campaign's chief architects were the late CIA director William J. Casey and Walter Raymond Jr., a veteran of CIA clandestine media operations overseas. In 1982, Casey detailed Raymond to the NSC staff where he set up the "public-diplomacy" machinery. One U.S. official described Raymond in an interview as the CIA's leading propaganda expert; Raymond told congressional investigators he was recommended for the NSC staff by another CIA veteran, Donald Gregg, national security adviser to Vice President George Bush.

One senior NSC official acknowledged in an interview that the public-diplomacy apparatus was modeled after CIA covert operations overseas. "They were trying to manipulate {U.S.} public opinion . . . using the tools of Walt Raymond's tradecraft which he learned from his career in the CIA covert-operation shop," the official said. To sidestep legal bars on CIA domestic activities, Raymond retired from the CIA in April 1983 so that, as he said in his deposition for the Iran-contra committee, "there would be no contamination of this."

Psy-war specialists. To staff the State Department public-diplomacy office on Central America, the administration recruited Defense Department personnel with propaganda training. One high-level operative, Lt. Col. Daniel "Jake" Jacobowitz, had a "background in psychological warfare," a senior public-diplomacy official, Jonathan Miller, told the Iran-contra committee. The office drew five other psy-war specialists from the 4th Psychological Operations Group at Fort Bragg, N.C. One was assigned to find "exploitable themes and trends," Jacobowitz wrote in a May 30, 1985 internal memo. The military men worked in the State Department office for stints ranging from several months to about a year.

According to military doctrine, psychological operations identify cultural and political weaknesses in a target country that can be exploited to induce the population to comply, whether consciously or not, with those carrying out the psy-op.

Both Raymond and the man he picked to run the State Department public-diplomacy office, Otto Reich, have denied any impropriety in the operation of the public-diplomacy campaign, calling it a legitimate means to inform the American public about the conflict in Central America.

Casey's role. Despite bars on CIA domestic operations, Casey appears to have been the guiding hand behind the propaganda campaign, as he was behind the contra war and North's secret contra-resupply network. As the public-diplomacy apparatus took shape in August 1983, Casey summoned advertising specialists to the Old Executive Office Building to brainstorm about how "to sell a 'new product' -- Central America -- by generating interest across-the-spectrum," according to an NSC summary of the meeting. Sensitive to the bars on executive-branch propaganda and Casey's participation, Raymond noted in one August 1983 memo that "the work done within the administration has to, by definition, be at arms length." Raymond added that he hoped "to get {Casey} out of the loop." Yet Casey remained active through 1986.

North's role. The ubiquitous Oliver North served Casey and Raymond as a chief operational officer for propaganda while he was also running the secret contra resupply. North's calendars show some 70 public-diplomacy strategy sessions scheduled with Raymond between 1984 and 1986 -- although Raymond insists that North was "not a regular attendee" at those meetings.

In a 14-page memo dated March 20, 1985, North informed then national security adviser Robert C. McFarlane about more than 80 planned publicity events to influence public and congressional opinion for the upcoming contra-aid vote. North then said that "other activities in the region continue as planned -- including military operations and political action. Like the chronology, these events are also timed to influence the vote {such as} special-operations attacks against highly visible targets in Nicaragua . . . . You should also be aware that Director Casey has sent a personal note to {then White House chief of staff} Don Regan on the timing matter {of the vote}."

North's hand also appeared in some of the more dramatic White House publicity stunts to promote the contra cause. In 1984, for instance, North oversaw a "sting" operation that involved flying a shipment of cocaine into Nicaragua, photographing a little-known Sandinista official with the drugs and then transporting the load to Florida. Although Reagan seized on the case as proof the Sandinistas were poisoning America's youth, DEA officials later acknowledged that they had no evidence of drug-running by any other Nicaraguan government official.

Ex-Panamanian consul Jose Blandon testified before a Senate Foreign Relations panel that in 1986 Panama's Gen. Manuel Antonio Noriega said he had planned with North to plant a shipment of East-bloc weapons in El Salvador, where it was to be intercepted as the long-missing proof of Sandinista gunrunning to the Salvadoran guerrillas. The "proof" was to be discovered right before a key congressional vote resuming contra military aid. But Blandon said the plan went awry when the general, angered by U.S. press disclosures about his drug trafficking, seized the ship carrying the weapons.

Although other administrations have routinely attempted, in former secretary of state Dean Acheson's words, to "spin a story clearer than truth," President Reagan created an unusually aggressive peacetime propaganda campaign. By running the operation from the NSC -- as would later be the case with North's contra resupply efforts -- the administration was able to employ CIA specialists while sidestepping restrictions on the CIA. Reagan's own Executive Order 12333 bars the CIA from activities "intended to influence United States political processes, public opinion . . . or media."

The "public-diplomacy" bureaucracy took shape in secret in early 1983, as the White House sought a means to amplify its foreign-policy themes. Reagan formally authorized its creation in January 1983 by signing National Security Decision Directive 77, entitled "Management of Public Diplomacy Relative to National Security." A special planning group was created within the NSC to direct public-diplomacy campaigns at home and abroad.

In a Jan. 25, 1983 planning memo to then national security adviser William Clark, Raymond expounded on the need for this "new art form" in foreign policy. "It is essential that a serious and deep commitment of talent and time be dedicated to this," he argued. "Programs such as Central America, European strategic debate, Yellow Rain and even Afghanistan have foundered by a failure to orchestrate sufficient resources and forces {for} these efforts."

The propaganda operation's goal for Central America was to paint the contras -- in Reagan's famous phrases -- as "the moral equivalent of the Founding Fathers" and Sandinista-ruled Nicaragua as "a totalitarian dungeon." This did not merely reflect Reagan's fondness for simplistic explanations; it was an explicit propaganda strategy. In a July 1986 memo that could be a summary for the entire campaign, Raymond said, "in the specific case of Nica{ragua}, concentrate on gluing black hats on the Sandinistas and white hats on UNO {the contras' United Nicaraguan Opposition}."

In a war fought on both sides by "gray hats," the strategy meant distorting the factual record by exaggerating Sandinista offenses while concealing those of the contras. Journalists, human-rights investigators, law-enforcement officials and members of Congress who uncovered the facts thus threatened the desired public relations image.

The administration's penchant for exaggerating and distorting the factual case in Central America dates back to its earliest days. In February 1981, it issued a "white paper" describing the leftist Salvadoran insurgency as a "textbook case of indirect armed aggression by communist powers through Cuba." Only later, after journalists examined the supporting documents, did the public find out how flimsy the administration's evidence was. In a Wall Street Journal interview, the report's author conceded that the white paper had included "guesses" and "extrapolation" and that critical parts were "misleading" and "overembellished."

As the administration's focus shifted to Nicaragua, so did the pattern of distortion, sometimes using carefully calibrated campaigns to exploit the fears of everyday Americans.

In one case in 1983, former contra director Edgar Chamorro said CIA officers targeted the American Jewish community by fashioning a propaganda drive accusing the Sandinistas of anti-Semitism because much of the small Jewish community had fled Nicaragua after the 1979 revolution. Reagan and other senior officials often have repeated this allegation since then, despite a July 28, 1983 classified cable from the U.S. embassy in Managua reporting that there was "no verifiable ground" to make the anti-Semitism charge. The Nicaraguan Jews who left had been associated personally with the ousted dictator Anastasio Somoza Debayle, according to the cable.

When the administration found through pollster Richard Wirthlin's opinion surveys in 1983 that Americans feared an influx of Latin American refugees, it argued that only by crushing leftist movements could such a flood be stopped. Reagan promptly raised the issue in a June 1983 speech, warning that unless a tough stand was taken, a "tidal wave" of "feetpeople" would be "swarming into our country."

The administration became so obsessed with manipulating public and congressional opinion that the contra war itself became part of the propaganda game. To conceal the contras' military ineffectiveness in 1983 and early 1984, Casey ordered a series of CIA-run coastal attacks on Nicaragua, including mining its harbors. According to Chamorro, the CIA then instructed contra leaders to claim credit for the raids. Back in Washington, the public-diplomacy apparatus informed reporters that the attacks proved that the contras were capable of mounting sophisticated military operations, thus justifying continued CIA support.

The most visible arm of the propaganda machinery was the Office of Public Diplomacy for Latin America and the Caribbean, known by the initials S/LPD. The office was directed initially by Raymond's choice, Reich. It was housed at the State Department but actually reported to the National Security Council, Raymond said in an Aug. 7, 1986 memo for Casey. (Reich and Raymond have since denied that the office "reported" to the NSC. But files obtained by the General Accounting Office show that Reich provided activity reports directly to the president's national-security adviser, his budgets were cleared by the NSC and Raymond arranged personnel for Reich's office.)

The office's principal activity was to produce and disseminate one-sided publications on Nicaragua and El Salvador, while pressuring the press into conformity with administration arguments. But it also planted stories in newspapers while concealing government sponsorship -- an intelligence tactic called "white propaganda" -- and relied on the skills of Army psychological-warfare specialists to manage the perceptions of the American public, according to a GAO legal opinion.

Called Reich's "A-Team," the psy-ops experts were used to "prepare a daily summary of exploitable information for S/LPD use, analyze media trends and highlight areas of possible S/LPD concern, as well as suggest themes and media for use in the S/LPD mission," according to a March 1985 memo.

S/LPD aggressively monitored American reporting on the region. As Reich reported to Raymond in March 1986, public diplomacy officials took "a very aggressive posture vis-a-vis a sometimes hostile press" and "generally did not give the critics of the policy any quarter in the debate." S/LPD report cards boast of having "killed" purportedly "erroneous news stories." And when stories aired that did not conform with administration views, Reich often met personally with editors and reporters to press for more sympathetic coverage.

After National Public Radio upset S/LPD with a report on a contra attack, Reich informed NPR editors that he had "a special-consultant service listening to all NPR programs" on Central America and that he considered NPR's reporting to be biased against U.S. policy, according to NPR's Bill Buzenberg.

Reich made a similar visit to CBS in April 1984 after Reagan became upset with the network's news coverage of Central America. In a memo, Secretary of State George Shultz told the president that Reich had spent one hour complaining to the correspondent and two more hours with the Washington bureau chief "to point out flaws in the information." This was but one example of "what the Office of Public Diplomacy has been doing to help improve the quality of information the American people are receiving," Shultz told the president. "It has been repeated dozens of times over the past few months."

The office also sought to discredit journalists who didn't toe the propaganda line. In July 1985, Reich's office helped spread a scurrilous story from a Sandinista defector that suggested that some American reporters received sexual favors from Sandinista prostitutes in return for favorable reporting. "It isn't only women," Reich asserted in an article in the July 29, 1985 issue of New York magazine. For gay journalists, Reich contended, the Nicaraguans provided men.

Late last year, Congress quietly shut down S/LPD, making it the only governmental body scrapped in the Iran-contra scandal. Rep. Jack Brooks (D-Tex.) denounced the office as "an important cog in the administration's effort to manipulate public opinion and congressional action." But as one senior public-diplomacy official noted wryly at the time, "they can shut down the public-diplomacy office, but they can't shut down public diplomacy." Robert Parry is a correspondent for Newsweek. Peter Kornbluh is a foreign-policy analyst and co-editor of "Low-Intensity Warfare." This article is adapted from a version that will appear in Foreign Policy.