---
updatedAt: 2025-06-16T23:15:08.000Z
agentTools:
  projectIndex: https://developers.directscale.com/llms.txt
---

# Custom Page/Widget to External App

Use the [Razor `GetSsoUrl` method](https://developers.directscale.com/docs/razor-syntax-integration) to link to an external app from a Custom Page or Widget. You can use the following areas of **Web Office Admin** to do this:

* [**Custom Office Widgets**](https://developers.directscale.com/docs/custom-widgets)
* [**Custom Office Pages**](https://developers.directscale.com/docs/custom-pages)
* [**Custom Admin Pages**](https://developers.directscale.com/docs/custom-admin-pages)

Like the [Web Office to External App](https://developers.directscale.com/docs/outbound-sso-web-office-to-an-external-app) process, you can add an SSO link to custom pages/widgets. This method accepts the redirect URL as an argument parameter.

```html
<a href='@GetSsoUrl("http://mysite.com?token={DirectScale:Token}")'>Click to go to my site</a> 
```

The SSO URL generates to DirectScale’s redirect handler. The handler replaces `{DirectScale:Token}` with a temporary SSO token. Then it redirects the browser to the given URL.

> ⚠️Important
>
> The token remains valid for **ONE MINUTE**.

***

***

# Sign-in Process

A logged-in **Web Office** user clicks the SSO link, which calls the DirectScale server, and generates a link to the external application with a short-lived token substituted in the URL. The browser then redirects to the external application with the DirectScale token added to the URL. The external application calls the DirectScale API to get the user information from the token. The Public API endpoint it uses is `https://dsapi.directscale.com/v1/sso/?token={token}`

The external application returns its page to the Associate with the session established.