adding JSON metadata output support