Throwing exceptions when incorrectly constructing a request.