add library to handle json encoding. fixes some prior issues with json formatting.