Code to contact external json endpoint added