code for lpc to parse json