From left, Staff Sgt. Jeremiah Johnson, Staff Sgt. Bryan Black and Staff Sgt. Dustin Wright. The body of a fourth US soldier, Sgt. La David T. Johnson, has also been recovered.

Four elite soldiers in the US Army Special Forces, known as Green Berets, were killed this week when they were ambushed by armed militants during a joint mission with Nigerien forces.

Staff Sgt. Bryan C. Black, 25, Staff Sgt. Jeremiah W. Johnson, 39, and Staff Sgt. Dustin M. Wright, 29, were on a reconnaissance patrol Wednesday in Niger when they came under hostile fire, according to a statement from the Department of Defense.

"The body of another U.S. service member has been recovered from the area of the attack, bringing the number of U.S. service members killed in this attack to four," Col. Rob Manning, Pentagon spokesperson, said in a statement Friday.

On Saturday, the Pentagon identified Sgt. La David T. Johnson, 25, of Miami Gardens, as the fourth casualty in the ambush. His body was recovered Friday by Nigerien security forces.

Multiple news outlets, including CNN, and Fox News, reported the soldiers were ambushed by about 50 militant fighters who may be affiliated with ISIS.

Five Nigerien soldiers were also killed, according to CNN.

Pentagon officials have released little information about how the Green Beret soldiers were killed and said the incident is now under investigation. The four deaths are the first known casualties of American forces in Niger, where the US is conducting train and assist operations.

Military officials said the mission involving the four soldiers was not intended to encounter enemy forces.

"It was meant to establish relations with the local leaders and the threat at the time was deemed to be unlikely," Army Col. Mark R. Cheadle told reporters at the Pentagon. "So there was no overhead armed air cover during the engagement."

French Super Puma helicopters provided some cover to soldiers while it evacuated those wounded in the attack, according to CNN.

As of Friday afternoon, President Trump had not issued a statement or tweet about the incident.

In a letter sent by Trump to House Speaker Paul Ryan in June, Trump said there were about 645 US personnel deployed in Niger to support counterterrorism operations.

On Thursday, however, Defense officials estimated there were about 800 troops in the country. The US is also looking to build a $100 million base for surveillance drones in Agadez, suggesting the US is looking to remain in the region for some time.

Black was identified as a native of Puyallup, Washington, who enlisted in Oct. 2009. Jeremiah W. Johnson enlisted in Oct. 2007 and was a native of Springboro, Ohio. Wright was a native of Lyons, Georgia, and joined the Army in July 2012.

All four were assigned to Fort Bragg in North Carolina.

Vera Bergengruen contributed to this report.

Salvador Hernandez is a reporter for BuzzFeed News and is based in Los Angeles.