Nice 502 from API on connection problems