clean up json/binary post