fix uri for api endpoint