In what appears to be the most substantive outcome of the state visit to Washington to Mexican President Jose Lopez Portillo, Mexico has agreed to implement a new program aimed at insuring the safety of American tourists.

American Automobile Association President J.B. Creal said that Lopez Portillo, during a Wednesday night meeting at Blair House, had agreed to begin within two weeks the program, which includes establishment of a high-level tourist aid office, a tourist telephone hotline and stiff penalties for Mexican police and officials who ask for and accept bribes to handle tourist problems.

The tourist agreement may be the most definitive result of Lopez Portillo's four-day visit this week, during which he met with President Carter, addressed the House of Representatives and met with high-level U.S. officials. As one senior State Department official said of the government talks, "There were no agreements on anything. Nothing was signed . . . no important decisions were made."

The meeting between Lopez Portillo and Carter were characterized as "get acquainted" sessions in which both governments defined their problems with each other and Lopez Portillo's had a chance to welcome good relations with the United States.

Those good relations, at least in the minds of many of the more than 3 million Americans who visit Mexico each year, have been strained by widespread reports, over the past several months, of attacks on tourists by highway "bandidos."

Nearly two months ago, AAA advised its 18.5 million members to stay out of certain parts of the country. At the same time, the State Department issued a danger "warning" on Mexico for American citizens.

American tourism supplies approximately 46 per cent of Mexico's dollar earnings, so the official safety warnings were a further blow to the tourist industry, which hopes this year to come out of a serious two-year slump.

According to AAA spokesmen, previous appeals to Lopez Portillo to establish new tourist safeguards had gone unanswered since his Dec. 1 inauguration.

The AAA said the new agreement was a combination of AAA recommendations and suggestions by Mexico's tourism ministry.