Soviet leader Mikhail Gorbachev today told two ranking members of the House Foreign Affairs Committee he is confident he will meet President Reagan at a second summit, the congressmen reported.

After a meeting of two hours and 40 minutes in the Kremlin, Rep. Dante B. Fascell (D-Fla.) and Rep. William S. Broomfield (R-Mich.) described Gorbachev as "basically optimistic" about the U.S.-Soviet relationship in spite of recent difficulties.

The Soviet news agency Tass said that at the meeting the "conviction was expressed that the summit dialogue started in Geneva should be carried on."

The congressmen said Gorbachev set no preconditions for the next summit. "He said that he was still interested, that he wants to go, that he feels confident that we can get there," said Fascell, chairman of the Foreign Affairs Committee.

"He absolutely reaffirmed his position on the desirability of a summit," said Fascell, adding, however, that the Soviet leader gave no firm dates for his Washington visit.

The congressmen said that Soviet Ambassador to Washington Anatoliy Dobrynin, on his way back to the United States to make his farewell rounds, is expected to convey a message about the summit.

Fascell also said it was his impression that a meeting between Soviet Foreign Minister Eduard Shevardnadze and Secretary of State George P. Shultz is "about to take place." U.S. Ambassador Arthur Hartman met today with Shevardnadze.

The second summit is due to take place in the United States this year, according to the schedule agreed upon in Geneva last fall when Reagan and Gorbachev met for the first time. A third is scheduled for 1987, when Reagan is to come to Moscow.

The United States has suggested that Gorbachev come in June, but so far the Soviets have not delivered an official answer, pressing for assurances that the next summit will produce a "substantive agreement."

In his speech to the 27th congress of the Soviet Communist Party, Gorbachev last month listed two areas where an agreement would be possible -- a ban on nuclear testing and the abolition of U.S. and Soviet medium-range weapons in Europe.

Last Saturday, Gorbachev invited Reagan to a separate meeting in Europe as soon as possible to discuss a treaty banning nuclear testing. Reagan did not accept.

Today, Fascell noted that Gorbachev reiterated the Soviet wish for substantive results from the next summit, but said the Soviet leader did not specify in what areas. "The question is, what is this substantive agreement?" said Fascell. "It is not clear to me what it is."

Tass said the continuing dialogue should be "effective" and provide for "concrete steps to end the arms race and eliminate the danger of a nuclear catastrophe."

Tass quoted Gorbachev as saying the Soviet Union is prepared to reach agreement "on an equal footing, without detriment to anybody, on any problems and expects the same preparedness from the United States."

"There are no preconditions with respect to the summit," Fascell said, adding that the test ban was not "directly characterized as the substantive agreement" sought by the Soviets. Reagan's Strategic Defense Initiative -- for two years the central issue in the Soviet campaign for arms control -- was "not a major focal point of the discussion," the congressman said.

Fascell said Gorbachev placed "great stock" in his offer on the moratorium. But, the congressmen's statement said, "We explained that we are not ready to jump on that, and that it would be better to move on."

Broomfield, the ranking Republican member of the committee, said the conversation had touched on a wide range of issues, including charges of human rights violations in the Soviet Union.