reworking api routes and result