U.S. and Mexican officials are working to defuse a confrontation over Mexico's antinarcotics campaign that some fear could disrupt diplomatic relations and jeopardize future drug-control efforts.

In a meeting last night with President Miguel de la Madrid, U.S. Ambassador to Mexico John Gavin said that President Reagan had "authorized" new U.S. Attorney General Edwin Meese III to meet with his Mexican counterpart, Sergio Garcia Ramirez, to "analyze" anti-drug cooperation, a statement released by de la Madrid's office said.

The issue is expected to be a principal topic in meetings between Mexican Foreign Minister Bernardo Sepulveda and Secretary of State George P. Shultz that the Mexican Foreign Ministry last night said would take place March 11 in Washington.

But despite obvious diplomatic attempts on both sides to tone down both the rhetoric and the image of growing bilateral problems, each day over the past two weeks seems to have added new fuel to the fire.

Mexican officials pronounce themselves "confused" by unilateral U.S. actions such as last week's border inspection of all incoming Mexican border traffic and public U.S. airing of charges that Mexican police have been derelict in their duties if not actually complicitous in allowing suspects in drug and kidnaping cases to flee. They note repeatedly that until recently the United States had pointed to Mexico as a model for international drug-control programs.

In a news conference here today, Gavin said that during their meeting last night de la Madrid had expressed "his concern about the climate that has been created" by official U.S. criticism of Mexico's handling of the investigation into the Feb. 7 abduction of U.S. Drug Enforcement Administration agent Enrique Camarena Salazar.

De la Madrid said he hoped Mexico and the United States could establish a "more correct climate" for the resolution of the drug problem, Gavin reported.

In Guadalajara, meanwhile, police released for "lack of evidence" a former police agent that DEA chief Francis Mullen had suspected of involvement in the abduction. Two other detainees were reported to be released, and U.S. officials said Mexican authorities are not now detaining any suspects in the case.

While Gavin defended the border searches, saying they came at a point "at which certain of our agencies were desperate" for progress in the search for Camarena, the ambassador conceded that the search had produced "no leads, no information, no clues."

"Certain individuals and agencies in our government are distressed and disappointed by the lack of vigor and attention" given to the Camarena case, he said, although in recent days "we have certainly seen an improvement in the vigor with which this investigation is being conducted."

Gavin echoed DEA complaints, however, that some Mexican law enforcement authorities have allowed principal suspects in the case to escape "scot-free," mentioning a Feb. 9 incident in which known Guadalajara drug trafficker Rafael Caro Quintero was allowed by police and armed federal security guards to fly from a local airport after the United States formally sought his detention. Caro Quintero is now believed by U.S. officials to have fled the country.

Jose Ramon Mata Ballesteros, a Mexico-based Honduran said to serve as link with Colombian and Italian underworld groups and also a prime suspect in the Camarena case, allegedly was allowed to escape Mexico City two days after his presence here had been discovered by DEA agents. Francis Mullen charged that Mata's departure was arranged with the complicity of Mexican Federal Judicial Police Chief Manuel Ibarra Herrera, who until recently was singled out by DEA agents stationed here as one of the most "determined" and "effective" of the officials leading Mexico's drug-eradication program.

By subjecting high-ranking Mexican police officers to such damaging criticism, U.S. officials are eroding the present administration's carefully maintained image as a government opposed to corruption, Mexican analysts say.

Yet U.S. diplomats still profess to view the current group of top Mexican law enforcement officials as a group far preferable, professionally and ethically, to their predecessors from Mexico's past government. Among the latter is the notorious Arturo "Negro" Durazo, the former Mexico City police chief said by acquaintances to be a heavy cocaine user and at least occasional smuggler. Durazo is now in Los Angeles awaiting extradition on charges of embezzlement and illegal arms possession.

Another area of government sensitivity is the domestic political perception that Mexico is being forced to focus police resources on one kidnaped U.S. narcotics agent at a time when scores of Mexican law enforcement officers have been killed in confrontations with drug gangs.

In a telephone conversation with Reagan Friday, de la Madrid said, he "lamented the disappearance" of Camarena. But he pointedly noted that "many" Mexican police agents have also lost their lives in the antinarcotics campaign.

In the military alone, Defense Minister Gen. Juan Arevalao Gardoqui reported yesterday, 315 soldiers and officers working in drug eradication have died since the present government assumed office in December 1982.

Another concern expressed by informed Mexican observers is that the overt U.S. pressure could prove counterproductive, as an accelerated antinarcotics drive might now appear like a politically dangerous demonstration of acquiescence to Washington.

Before the Camarena incident, neither Mexican authorities nor U.S. diplomats would publicly discuss the activities of the 30 to 50 DEA agents stationed here out of concern for Mexican sensibilities. "It came as news to a lot of the public that U.S. police agents are allowed by the government operate openly here," one Mexican journalist remarked.

Some Mexicans view the controversy as a symptom of the broader deterioration in U.S.-Mexican relations prompted by the paralysis of the Contadora peace negotiations in Central America. "This has been a difficult time for bilateral relations in general," one foreign ministry official remarked. "You can't look at this in isolation."

At the attorney general's office, responsible for coordinating Mexico's antinarcotics campaign, authorities at first interpreted the U.S. response as primarily one of "frustration, a comprehensible human reaction" to the slowness of the investigation into the Camarena kidnaping, as Garcia Ramirez said Friday.

But officials were stung by subsequent public accusations from Mullen and other U.S. sources that seemed to imply widespread collusion between drug traffickers and Mexican law enforcement agencies.

Since the new government took power two years ago, DEA agents here have expressed satisfaction at the personnel changes and administrative changes instituted in the drug control program, privately comparing the "seriousness and commitment" of the present administration with the "lack of interest" and "corruption" of its predecessor.

Mexican officials were taken aback, therefore, at recent U.S. assertions that corruption in the drug control program has worsened since de la Madrid took office. "There are strong signs that the Mexican program has been less effective over the past two years and that corruption is playing an important part in this decline," the State Department said this month, according to a Spanish translation of its 1984 world narcotics production report released by the U.S. embassy here.

Such commentary contradicts the privately and publicly expressed viewpoints of U.S. diplomats and narcotics agents here, leading some Mexican observers to suspect that the document was partially drafted by State Department opponents of Mexico's foreign policy stance.

Other Mexican officials, however, believe the report -- issued shortly after the Camarena abduction -- reflects U.S. annoyance at Mexico's failures to resolve a series of disappearances of U.S. citizens in Guadalajara, of which the Camarena case was the seventh in less than three months.

"In all those incidents," an embassy official commented, "there was one common denominator -- the inactivity and lack of cooperation of the Mexican police."