Fargo, North Dakota, police bodycam footage of a deadly assault on officers July 14 was released Thursday, which showed the tense situation one officer endured before fatally shooting the suspect.

North Dakota Attorney General Drew Wrigley and Fargo Police Department Chief David Zibolski held a news conference Thursday to go over surveillance and body camera video evidence of the police-involved shooting in Fargo.

That day, 37-year-old Mohamad Barakat shot and killed Fargo Police Officer Jake Wallin and wounded three other people, including officers Andrew Dotas and Tyler Hawes, who were responding to a traffic crash.

GUNMAN KILLS OFFICER, INJURES 2 OTHERS IN FARGO SHOOTING; MOTIVE UNKNOWN

Fargo Police body camera footage

Bodycam footage of a fatal shooting in Fargo, North Dakota, on July 14, 2023, was released Thursday, showing the moment officers who responded to a traffic crash were ambushed by Mohamad Barakat. (Fargo Police Department Facebook Live)

Also injured at the scene was Karlee Koswick, a bystander who attempted to flee the scene.

Officer Zach Robinson was also at the scene when gunfire began and is credited with stopping a much bigger attack by shooting and killing Barakat.

In the bodycam footage from Robinson’s perspective, police were seen responding to a traffic crash. About 38 seconds into the video, rapid fire was heard while several people were seen running for cover.

SECOND FARGO OFFICER WOUNDED IN DEADLY SHOOTING SET TO LEAVE HOSPITAL

Zach Robinson

Fargo Police Officer Zach Robinson. (The City of Fargo via AP)

Robinson was heard saying, "We got shots fired," as he ducked behind a vehicle. He then peaked out from behind the vehicle and fired off four rounds toward Barakat, who was next to a vehicle in a parking lot.

"Central, we got a man with an AK-47 shooting at us," Robinson reported, when more shots are fired by Barakat.

"Central, shots fired, shots fired," Robinson said. "We got three officers down, three officers down."

FUNERAL SERVICES SET FOR SLAIN NORTH DAKOTA POLICE OFFICER WHO WAS KILLED IN SHOOTING

Police officers Andrew Dotas, Tyler Hawes, Zach Robinson

Police officers Andrew Dotas, left, and Tyler Hawes were both injured in the shooting. Police officer Zach Robinson, right, shot and killed the gunman. (The City of Fargo)

The officer then moved toward the gray vehicle, where legs were seen protruding from the front of the vehicle on the passenger side, horizontally.

Barakat was seen moving and reaching for something when Robinson ordered him to stop moving and to put his hands up, six times.

As Barakat continued to roll on his back, a rifle was seen close to his body.

NORTH DAKOTA GUNMAN HAD 1,800 ROUNDS OF AMMO, HOMEMADE GRENADE WHEN LAUNCHING ATTACK ON OFFICERS: POLICE

weapons and ammunition

This photo released by the North Dakota Bureau of Criminal Investigation on Wednesday, July 19, 2023, shows the cache of weapons and ammunition that authorities recovered from the car of a man who opened fire on Fargo, North Dakota, police officers on Friday, July 14. (North Dakota Bureau of Criminal Investigation via AP)

Robinson moved into position and fired three shots at Barakat, then reloaded his magazine

Barakat then appeared to have a handgun, and Robinson told him to drop the gun and fired his pistol eight times. Stepping back then checking on Barakat again, Robinson told him six more times to drop the gun, maneuvering to the rear of the vehicle.

Once on the passenger side, Barakat was seen moving while on his back, with a headshot in plain sight. Robinson then fireed his gun five more times, at which point Barakat’s head was blurred out.

Robinson moved to the front of the vehicle and another officer was seen walking toward the back of the automobile with his weapon drawn.

STANDOFF AT INDIANA APARTMENT COMPLEX ENDS IN FATAL POLICE SHOOTING OF 65-YEAR-OLD MAN

Memorial

A memorial in Fargo, North Dakota, where one police officer was fatally shot, and two others were critically wounded. (AP Photo/Ann Arbor Miller, File)

Wrigley said Robinson was "the last man standing between what was coming next, and you can see this assailant was armed for."

The attorney general also said Robinson’s use of deadly force was reasonable, necessary, justified and lawful.

Investigators searched Barakat’s vehicle after the shooting and found numerous guns, 1,800 rounds of ammunition, a homemade grenade and explosives.

MURDER SUSPECT CAUGHT AT TOPGOLF AFTER ALLEGEDLY KILLING GIRLFRIEND IN APARTMENT

His internet queries over the last five years included things like "kill fast," "explosive ammo," "incendiary rounds," "mass shooting events" and one for "area events where there are crowds."

Fargo, N.D., police officers

Official portraits of Fargo, North Dakota, police officers who were involved in a deadly shooting are seen during a press conference at Fargo City Hall. (AP Photo/Ann Arbor Miller, File)

Authorities said the latter query brought up a news article with the headline, "Thousands enjoy first day of Downtown Fargo Street Fair," a day before the shooting.

In recent years, police had visited the suspect’s home at least twice out of concerns related to his guns, which authorities said he appeared to acquire legally.

CLICK HERE TO GET THE FOX NEWS APP

Barakat came to the U.S. in 2012 as a Syrian national on an asylum request. In 2019, he became a U.S. citizen, Wrigley has said.

Earlier this month, Hawes and Dotas were discharged from the hospital and Koswick left the hospital nearly a month ago.

The Associated Press contributed to this report.