An unarmed man fatally shot by a Bay Area Rapid Transit officer on New Year’s Day contributed to the incident by hitting one of the two officers who initially detained him, according to court documents filed by the agency Friday.

BART filed a legal response in federal court to a $50 million wrongful death lawsuit filed by the family of 22-year-old Oscar Grant who was fatally shot at an Oakland transit station.

Dale Allen, an attorney representing BART, said Grant’s shooting death by former officer Johannes Mehserle, 27, was “a tragic accident.”

Last month, Grant’s family sued BART, Mehserle, BART police chief Gary Gee, and officers Tony Pirone and Marysol Domenici.

The lawsuit says Pirone threatened to use his Taser on Grant and his friends if they did not comply with his orders. Pirone’s attorney, Bill Rapoport, has said that Grant provoked Pirone’s blow by trying to knee Pirone at least twice.

“It is our position that there was a provocation and assault on Mr. Pirone based upon a video that shows Mr. Grant apparently hitting Mr. Pirone with his knee,” Allen said.

Domenici is accused of repeatedly pointing her Taser and threatening to stun them in the face.

However, Friday’s filing by BART said the officers were just defending themselves.

“Oscar Grant willfully, wrongfully, and unlawfully made an assault upon defendants and would have beaten, bruised, and ill-treated them if defendants had not immediately defended themselves,” the response said. “(The) defendants necessarily and unavoidably came in contact with decedent Oscar Grant and threatened him, but no more than was necessary for said defense.”

Meanwhile, Grant family attorney John Burris on Friday maintains the shooting was intentional and called the filing, “legal mumbo jumbo.”

Mehserle has pleaded not guilty to murder and is free on $3 million bail. He has a preliminary hearing May 18. Mehserle’s attorney, Michael Rains, has previously said his client had meant to fire his Taser when he fired a single shot with his pistol.

The shooting — which grabbed national attention after cell phone videos of the incident began circulating on the Internet and television — continues to cause community outrage and has led to numerous protests and arrests.

Allen said in a phone interview Friday that BART acknowledges Grant was shot in the back but denies Pirone and Domenici were unprovoked when they tried to detain Grant.

He said the officers were justified in pulling Grant and his friends from a train because witnesses had identified them as being involved in an earlier fight. Allen also believes the officers used reasonable force to detain Grant because he was resisting arrest.

However, Allen said there was no reason for Mehserle to shoot Grant, adding that the officer “made a horrible, terrible mistake,” firing his gun instead of his Taser while trying to subdue Grant. Allen said he’s hoping that the lawsuit can be settled through mediation.

Burris said the filing has no impact on his assessment of the case. He has said Grant was unlawfully detained, arrested and deprived of urgent medical care after being shot.