I am facing issue were long urls are not getting shortened on page. we have used page.getPath method to place page url in href. But it is showing entire path starting from /content intead of short urls.
Can you make changes like below:
Above will remove /content/we-retail from all links which starts with /content/we-retail
In your config it seems you did reverse mapping if there is a link like <a href="https://forums.adobe.com/content/we-retail/">Link</a> will be render like <a href="https://forums.adobe.com/">Link</a>