I improved the url builder so that it can work with relative / absolute urls for apis.