switch to async API for validate
doc and clean up