Support documents with a +json media type

This addresses #261.