A web designer threatened to beat up a Scotland Yard commander during a verbal tirade and later stabbed him in the stomach with the mouthpiece of a sheesha pipe, a court heard today .

Metropolitan police commander, Ali Dizaei, 47, who is on trial accused of "fitting up" the web designer today testified in his own defence, saying he was the victim of abuse and assault.

The prosecution alleges that on the evening of 18 July 2008, Waad al-Baghdadi and Dizaei clashed over a website Baghdadi designed for him. Baghdadi claims he was owed £600, and when he raised that, Dizaei falsely arrested and detained him.

Dizaei told the trial at Southwark crown court that he was sitting in a car with his wife outside a London restaurant, talking through an open window to the establishment's owner, Sohrab Eshrag, when Baghdadi approached the vehicle.

Dizaei said Baghdadi started a verbal tirade. "He started swearing, he was swearing in Farsi … 'who the fuck do you think you are?'" Dizaei said he told the web designer to calm down. He said his wife was "caught in the crossfire", between himself and Baghdadi who continued his verbal tirade, and at one stage put his head through the car window.

Dizaei said that he got out of the car and approached Baghdadi: "I was firm, I said to him 'look, stop behaving in this manner, there are laws in this country, you can't go around behaving in this way. You are frightening me, you are frightening my wife, you are causing a disturbance.'"

The jury heard that Baghdadi, 24, then threatened the commander. Dizaei said: "He used a very strange Farsi quote … 'I will take the money out of your throat'."

In his evidence Baghdadi claimed Dizaei gestured to him and said words he took to mean were a challenge to go round the corner and have a fight. Dizaei told the jury: "It's just complete utter nonsense."

The row went on. Baghdadi went into the restaurant and was asked to leave. When he went out he phoned the police.

Dizaei, who claimed Baghdadi was repeatedly raising his middle finger at him, leaving his wife petrified, said he had wanted to drive away but could not because of his duty as a police officer: "I'm an operational police officer being asked by a member of the public, don't go away because I'm frightened of this guy. If I did drive away I probably would not be sitting in the dock today." During the arrest, Dizaei claims, Baghdadi pushed him and poked him in the stomach with an object that caused a sharp pain.

The jury have heard that a doctor who examined Dizaei after the incident believed his stomach wounds might have been self inflicted. "I just find the whole accusation very, very, outrageous," Dizaei told the jury. Before the jury he raised his vest to show the abdomen area where he claims to have been injured.

Peter Wright, QC for the crown, accused Dizaei of framing Baghdadi, angered by his "temerity" at approaching him on the street. Wright said: "You decided to fit him up, didn't you?" Dizaei replied: "That is not true, not at all."

Dizaei's cross-examination by the crown continues tomorrow. He denies misconduct in public office and acts intended to pervert the course of justice.