Changed api, call genRequest to generate handler