started implementing normalization of endpoint using js-url, bug found in the library