Cosmography with cluster strong lenses: the influence of substructure and line-of-sight haloes