With the Wix URLs APIs, you can retrieve the relevant URLs to manage redirects to the site editor, the editor preview, and to the published site.
To use Wix URLs, import wixUrlsV2 from the 'wix-urls.v2' module:
wixUrlsV2
'wix-urls.v2'