finish JSON conversion