Adding util method for fetchign json.