# Egnyte

![Egnyte_Logo.svg](https://assets.relyanceuat.xyz/images/docs/12673536904589/12673114235021.svg)
Egnyte is a cloud-based content security, compliance, and collaboration platform for businesses. It provides the ability for IT admins to automatically classify and manage metadata through document type identification, which allows them to turn their unstructured data to structured data.

In order to integrate Egnyte with Relyance AI you will need a **Subdomain, Client ID, Client Secret, Path of Folders**, and follow an OAuth2 flow.

#### In Egnyte:

1. Login to your Egnyte account.
2. The Egnyte **Subdomain** will be the subdomain found in your Egnyte URL.

![Egnyte-3.png](https://assets.relyanceuat.xyz/images/docs/12673536904589/12792139148045.png)

3. On the main page, click on **Files** in the left-hand navigation.
4. Choose which **Path of Folders** you would like to scan using the path found above the folder files.

![Egnyte-7.png](https://assets.relyanceuat.xyz/images/docs/12673536904589/12795737777037.png)

From this screenshot, the folder path would be '**Shared/Documents/Folder Test**'.
5. To get the **Client ID** and **Client Secret**, you will need to have an associated Egnyte developer account. Go here to sign in to your developer account (or register for a new one).
6. Once signed in, click on **Get API Key** in the page header.

![Egnyte-6.png](https://assets.relyanceuat.xyz/images/docs/12673536904589/12794671370509.png)

7. Click on the **APPLICATIONS** tab on the page.
8. Click the **CREATE A NEW APPLICATION** button.
9. Fill out the **REGISTER YOUR NEW APPLICATION** form with the following values:

**Name**: Provide a meaningful name (e.g. Relyance Scan) **Type**: Publically Available Application
**Current User Base**: New App
**Platform**: Web App
**Egnyte domain you will use for testing**: This will by your Egnyte full domain (i.e. boutique.egnyte.com). Do not include 'http' / 'https'.
**Registered OAuth Redirect URI**: https://root.relyance.ai/api/oauth2
**Issue a new key for Egnyte Connect API**: Checked **Terms of Service**: Checked

![Egnyte-4.png](https://assets.relyanceuat.xyz/images/docs/12673536904589/12794701680909.png)

10. Click the **REGISTER APPLICATION** button.
11. Return to the **GET API Key** developer page and copy the **Key** (this will be your **Client ID**) and **Secret** (this will be your **Client Secret**).

#### In the Relyance AI application:

1. Login to your Relyance account.
2. Navigate to the **Settings** Menu in the bottom left-hand side.
3. Select **Integrations**.
4. Click on the **Vendor Integration** tab.
5. Find the **Egnyte** integration card and click it to open its connections.
6. Under **Authentication Method**, choose **Oauth2 / App Token**.
8. Paste the **Subdomain, Client ID, Client Secret, Path of Folders** into their respective fields.

![Egnyte-1.png](https://assets.relyanceuat.xyz/images/docs/12673536904589/12673374243085.png)

9. Click **Authenticate**.
10. At this point, you should see the following result on the **Vendor** Integrations page:

![Egnyte-2.png](https://assets.relyanceuat.xyz/images/docs/12673536904589/12673436814989.png)

11. Congratulations, you are now connected to **Egnyte**.

<!-- failure-modes:begin (generated from the integration catalog; do not hand-edit) -->

## If the connection reports Connected but returns nothing

These are the ways this integration comes back empty without reporting an error. Generated from the integration catalog, so it tracks what the connection actually asks for.

1. **Authorised, then empty.** The connection carries an authorisation, not a password: it stops returning data if the account that granted it loses access, its own permissions narrow, or the grant is revoked at the vendor. None of that reports an error here -- the connection keeps its last status until the next scan.
2. **A credential rotated at the vendor is not picked up here.** **Client Secret** is stored when you save the connection, so regenerating the value at the vendor breaks the next scan until it is re-pasted here. Recording the expiry on the connection means Relyance warns you before it lapses.
3. **Check the address fields before suspecting the credentials.** **Subdomain** identifies which tenant, region or host to talk to. A wrong value there fails authentication and looks exactly like a bad secret.

<!-- failure-modes:end -->

<!-- auth-methods:begin (generated from the integration catalog; do not hand-edit) -->

## Authentication methods and fields

Pick one of these under **Authentication Method** on the connection wizard's **Authentication** step. This table is generated from the integration catalog, so it always matches what the form actually asks for.

| Method | Required | Optional |
| --- | --- | --- |
| **Oauth2 / App Token** | `Subdomain`, `Client ID`, `Client Secret` (secret), `Path of the folders containing contracts delimited by ;` | — |

<!-- auth-methods:end -->

<!-- terraform-examples:begin (generated from the integration catalog; do not hand-edit) -->

## Manage this integration with Terraform

Connections for this integration can be managed as code with the [Relyance Terraform provider](https://registry.terraform.io/providers/Relyance/relyance/latest). Non-secret fields go in `auth.params`; secret fields go in `auth.secrets_wo`, which is write-only — never stored in Terraform state. Rotate secrets by bumping `auth.secrets_wo_version`.

The **OAuth (browser authorization)** method uses a browser authorization flow, so the connection is created in the Relyance app. Manage it in Terraform afterwards by importing it (`terraform import relyance_integration_connection.example egnyte/<connection_id>`) or reading it with the `relyance_integration_connection` data source.

<!-- terraform-examples:end -->
