BEIRUT, Lebanon — Dozens of Syrians choked to death after a suspected chemical attack struck the rebel-held suburb of Douma, east of Damascus, with aid groups on Sunday blaming President Bashar al-Assad’s government for the assault and Western governments expressing outrage.

Rescue workers in Syria reported finding at least 42 people dead in their homes from apparent suffocation, and antigovernment activists circulated videos of lifeless men, women and children sprawled out on floors and in stairwells, many with white foam coming from their mouths and nostrils.

A stream of patients with burning eyes and breathing problems were rushed to clinics after the attack at dusk on Saturday, medical and rescue groups said.

The attack appeared to break the will of Douma’s rebels, who agreed on Sunday to a deal with the government to hand the area over and be bused to another area outside government control in the country’s north. Thousands of fighters and tens of thousands of their relatives are expected to leave soon.

The latest atrocity in Syria’s agonizing seven-year civil war drew immediate condemnation from the United States and the European Union, but Mr. Assad’s allies in Moscow and Tehran dismissed allegations of a chemical attack as “bogus.”

The British Foreign Office called for an urgent investigation and said that if the use of chemical weapons proved to be true, “it is further proof of Assad’s brutality.”

The United States government said it was working to verify whether chemical weapons had been used. A new, confirmed chemical attack in Syria would pose a dilemma for President Trump, who ordered military strikes on a Syrian air base after a chemical attack last year to punish Mr. Assad but has more recently said he wanted to get the United States out of Syria.

In posts on Twitter on Sunday, Mr. Trump condemned the attack, blaming Iran and President Vladimir V. Putin of Russia for supporting the Syrian government and warning of consequences. White House officials did not rule out a military response.