Indonesian police shot dead four suspected militants who were part of a bomb and gun attack in the capital, Jakarta, on Thursday and the area is being secured, a police spokesman said.