Fix a sample code of JSON format output

Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com>