append JSON data to document