Jahangir Alam (22), who had shot at and injured Shahid, and the victim's wife, Farhana, a conspirator in the crime, were arrested on Saturday, they said.
The incident took place on the intervening night of June 3 and 4. The accused were at large and had decided to get married, they said.
Initially, the motive of the crime was not clear, but after officials met the victim, it was learnt that his wife had an affair with his neighbour, said Rajendra Singh Sagar, additional deputy commissioner, Police-1 (Outer).
Police said Alam had hired Shahid's cab to go to Inder Lok from Jahangir Puri, but midway, the accused asked him to stop to pick a friend.
However, after no one turned up, Shahid insisted on returning. They entered into an argument and the accused shot at him, they said.
During interrogation, Alam revealed that he knew Farhana for the last two years and they were in a relationship, they said.
He said they had decided to get married after killing Shahid, police said.
Alam said the woman had told him that her husband suspected that they were in a relationship, they said.
Get the latest election news, live updates and election schedule for Lok Sabha Elections 2019 on ndtv.com/elections. Like us on Facebook or follow us on Twitter and Instagram for updates from each of the 543 parliamentary seats for the 2019 Indian general elections.