• Register

Embedded UI API

The Navigate API (formerly the Embedded UI API) allows you to start an Egnyte Web UI session in the web browser with a public API token. To use this API your authentication token must have been requested with the Egnyte.launchwebsession scope.

Version 1 (Deprecated)

This endpoint is used to allow users to access files and folders from within other browser pages besides the Egnyte Web UI.


Request Parameters

Parameter DescriptionRequiredPossible Values
scope State the scope of the resources that you want to utilize. Yes home, folder/.*

Method-specific Response Codes

Error Code Error Message HTTP Code Troubleshooting
Unauthorized This request is unauthenticated. Please provide credentials and try again. 401 Check that your token has Egnyte.launch websession scope.

Request Examples

POST /pubapi/v1/navigate/embedded/folder/Shared/test HTTP/1.1
          Host: apidemo.egnyte.com
          Authorization: Bearer 68zc95e3xv954u6k3hbnma3q
curl -v -X POST -H "Authorization: Bearer 68zc95e3xv954u6k3hbnma3q" https://apidemo.egnyte.com/pubapi/v1/navigate/embedded/folder/Shared/test

Expected Response

The response is a HTTP 303 Code that redirects the user to a temporary link. The temporary link includes a one-time token. Loading the link in a browser will initialize a regular web session without requiring the user to log into the web interface.

HTTP/1.1 303 See Other
    Location: https://apidemo.egnyte.com/navigate/temp/15f221dc-5405-4988-9f47-f480dbb0b285
    Content-Type: application/vnd.egnyte.error+json;v=1;charset=UTF-8
TIP: Handling the response

Unlike other Egnyte APIs, this API does not return data as a JSON object. The response to a successful call uses an HTTP 303 response. The URL that can be used to open the embedded UI is returned in the "Location" response header. When calling this API, be sure to configure your HTTP client to not follow redirects. If a redirect is followed it will return the actual HTML content of the embedded UI.

This API cannot be used directly in the browser with JavaScript because web browsers automatically follow redirects. You need to call this API with server-side code.

User Redirected to Egnyte Session

When the user navigates to the temporary url that was generated in the previous step, he gets redirected to the active Egnyte session at the specified path. If the folder path provided is invalid, the user will see an error message in the UI.