add pagetype property to document json