raise 404 unless json in request