add validation for couchdb import