add has key and making result generation cleaner for insert_one