api route fixes