BEIRUT, JAN. 27 -- Gunmen seized a West German citizen at gunpoint today in the heart of Syrian-controlled west Beirut in a kidnaping that reportedly was linked to the current trial in Duesseldorf of a leading Lebanese terrorist suspect.

Ralph Schray, 30, who holds a West German passport but is half Lebanese and a lifelong resident of Beirut, was grabbed by three carloads of gunmen as he chatted with a friend on a street near his home in the vicinity of the Bristol Hotel.

No claims of responsibility had been made by late today, but a relative of Schray told journalists he had been told by a senior Shiite official that the kidnaping was ordered by Abdel Hadi Hamadei to put pressure on West Germany to release two brothers of Hamadei it is holding on terrorism charges.

One brother, Ali Abbas Hamadei, is being tried in Duesseldorf on charges of involvement in the kidnaping of two West Germans here in a bid to free the other brother, Mohammed Hamadei, who also is being held by West Germany and is a suspect in the 1985 TWA hijacking during which a U.S. Navy diver was shot and killed.

In Duesseldorf, the judge presiding over the trial warned that "it will make matters worse" for the Hamadeis if they turned out to be involved in the latest kidnaping, news services reported. There had been suggestions earlier that West Germany might expel the two after convicting and sentencing them.

Abdel Hadi Hamadei is security chief of Hezbollah, a militant pro-Iranian Shiite faction, but analysts said it appeared likely that if he was behind today's kidnaping, he was acting on family instinct and not on behalf of Iran.

A Syrian security officer was overheard telling Schray's family today: "This is a challenge to Syrian authority, and we will spare no effort" to find Schray. If Hamadei does not have Iranian cover, a Shiite militia official predicted, the Syrians, who have 7,000 troops in the area, will attempt to find the kidnapers.

Shortly after Schray was seized, witnesses said they spotted him, in blood-stained clothes, being transferred to another car at gunpoint in Zukak Blat, a slum near the Green Line, which separates Moslem west Beirut and Christian east Beirut.

Security sources said Syrian soldiers stormed a Hezbollah hideout in Zukak Blat and detained three suspects for questioning. But the sources said Schray had already been taken to the southern suburbs, a Hezbollah stronghold not policed by Syrian troops.

Schray's mother is a Lebanese Palestinian, according to his wife, Rana, and his father is West German. She said Schray had never seen his father, who divorced his mother before their son was born. Schray, who reportedly speaks little German, taught at Beirut University College but now is an industrial engineer at Issaco, a contracting firm.

About two dozen foreigners kidnaped in Beirut in recent years are being held hostage, including eight Americans and another West German, Rudolf Cordes, one of two seized a year ago, allegedly by Ali Abbas Hamadei and others. The second, Alfred Schmidt, was released last September, reportedly in return for a large ransom.

West German's ambassador to Beirut, Wolfgang Goettelmann, said in a telephone interview: "It is extremely dangerous for West Germans in west Beirut." Western European diplomats said that even he is no longer allowed to go there.

Shiite security sources in west Beirut have said that most of the foreign hostages are now in the custody of Iranian Revolutionary Guards, to make sure Iran can control any possible transaction.