@Bhupesh_Gupta have a look here for initial block parsing:
extracting the different blocks can help to pull out the different portions needed in output 4