The NYPD says a man was shot by police in Midtown Thursday afternoon after he attacked an officer with a meat cleaver.

First responders were called to West 32nd Street and Broadway just before 5 p.m. for reports of a shooting.

Chief of Department James O'Neill says two uniformed officers from the Midtown South precinct responded to a call at West 31st Street and Broadway and encountered the suspect, identified as 32-year-old Akram Joudeh, trying to remove a parking boot from a car (seen at left).

According to O'Neill, Joudeh pulled out an 11-inch meat cleaver and fled westbound.

Several other officers from the Midtown South precinct, as well as officers from the Transit Bureau, joined the two original officers in the foot pursuit, according to O'Neill.

O'Neill says an on-duty sergeant tried to taser the suspect on West 32nd Street, but it had no effect.

According to O'Neill, Joudeh then jumped on top of the front of a police car on West 32nd Street between Sixth and Seventh avenues. According to O'Neill, an off-duty detective in plainclothes then tried to subdue the suspect and was struck in the head by the meat cleaver, causing a six-inch gash from his temple to his jaw.

O'Neill says police officers then fired at the suspect, striking him several times. Police Commissioner William Bratton said three officers fired approximately 18 times at the suspect.

The detective who was struck by the meat cleaver was transported to Bellevue Hospital, as was the suspect. The detective is in serious condition. The suspect is in critical but stable condition.

O'Neill said two other officers suffered non-life-threatening injuries in the incident. It is unclear how those injuries were sustained.

Mayor Bill de Blasio visited the wounded detective and the two other officers that suffered minor injuries.

O'Neill said the suspect has "a number of arrests," but did not get into specifics.

Police recovered a cleaver at the scene. It can be seen at left.

Back in 2014, a group of officers were attacked by a man wielding a hatchet in Queens. 

Officer Kenneth Healey was hit in the head, but survived. 

Another officer and a bystander were also injured.