West Yorkshire Police said three men and a woman were detained in connection with the “firearms discharge”, which happened in the Stanacre Place area of Undercliffe yesterday afternoon.
A police spokesman said enquiries at the scene had also led to the recovery of a gun and some ammunition.
No one is reported to have been injured in the incident, which is now under investigation by the West Yorkshire force’s Homicide and Major Enquiries Team.
Det Chief Chris Gibson said: “Our enquiries are continuing into this incident and we would like to hear from anyone who saw any suspicious activity in the Stanacre Place area shortly before the discharge occurred.
“We are treating this as a targeted incident and patrols of the area have been increased, although we do not believe there is a wider threat to the community at this time.”
Anyone with information is asked to ring West Yorkshire Police on 101 or Crimestoppers anonymously on 0800 555111.