intagrated json data extract , simplified the code