> ## Documentation Index
> Fetch the complete documentation index at: https://stackone-hub-docs-confluence-api-token-update.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Databricks (OAuth)

> Follow these steps to connect Databricks via the StackOne Hub successfully.

<Warning>
  Ensure that your Databricks account has Account Admin privileges.
</Warning>

If you've been directed to StackOne to integrate with Databricks, the following steps will help you understand the process and any necessary actions to configure a successful integration.

This integration will connect with Databricks at the *Account* level, which can contain multiple *Workspaces*. See Databricks [Accounts and workspaces](https://docs.databricks.com/en/getting-started/concepts.html#accounts-and-workspaces) for more information.

## Log in to Databricks

Log in to your Databricks account console.

* AWS hosted: [https://accounts.cloud.databricks.com](https://accounts.cloud.databricks.com)
* Azure hosted: [https://accounts.azuredatabricks.net](https://accounts.azuredatabricks.net)

<Frame>
  <img className="rounded-md" style={{ margin: '0 auto', border: '1px solid #efefef' }} alt="Log in" src="https://mintcdn.com/stackone-hub-docs-confluence-api-token-update/YuiSn9_H_qPKyg_D/images/databricks/image1.png?fit=max&auto=format&n=YuiSn9_H_qPKyg_D&q=85&s=5c1eb0837fd4bde3f2b50ea8ab23e549" width="439" height="387" data-path="images/databricks/image1.png" />
</Frame>

## Obtain your Account ID

Click the down arrow next to your username in the top-right corner. In the drop-down menu, copy your displayed **Account ID** to be used in a later step.

<Frame>
  <img className="rounded-md" style={{ margin: '0 auto', border: '1px solid #efefef' }} alt="Obtain your Account ID" src="https://mintcdn.com/stackone-hub-docs-confluence-api-token-update/YuiSn9_H_qPKyg_D/images/databricks/image2.png?fit=max&auto=format&n=YuiSn9_H_qPKyg_D&q=85&s=31da3d25aa5cf4f3614bf64c2d283987" width="400" height="232" data-path="images/databricks/image2.png" />
</Frame>

## Create New OAuth Application Credentials

This connection will authenticate on behalf of a registered OAuth Application in Databricks.

<Info>
  The following Databricks interfaces are only available to Databricks Account Administrators.
</Info>

<Steps>
  <Step title="Navigate to App Connections">
    In your Databricks Account console, click **Settings** in the left navigation. Then click the **App Connections** tab.

    <Frame>
      <img className="rounded-md" style={{ margin: '0 auto', border: '1px solid #efefef' }} alt="Navigate to App Connections" src="https://mintcdn.com/stackone-hub-docs-confluence-api-token-update/YuiSn9_H_qPKyg_D/images/databricks/image3.png?fit=max&auto=format&n=YuiSn9_H_qPKyg_D&q=85&s=39b4798c5333ff900089ad83a744ff5c" width="1590" height="872" data-path="images/databricks/image3.png" />
    </Frame>
  </Step>

  <Step title="Add connection">
    Click the **Add connection** button on the right.

    <Frame>
      <img className="rounded-md" style={{ margin: '0 auto', border: '1px solid #efefef' }} alt="Add connection" src="https://mintcdn.com/stackone-hub-docs-confluence-api-token-update/YuiSn9_H_qPKyg_D/images/databricks/image4.png?fit=max&auto=format&n=YuiSn9_H_qPKyg_D&q=85&s=6b36eb358aa09cde0241d0e3da4499a4" width="2200" height="870" data-path="images/databricks/image4.png" />
    </Frame>
  </Step>

  <Step title="Enter connection details">
    Under *Add connection*, enter the following required information:

    * Application Name: (Appropriate name for this application)
    * Redirect URLs:

    ```
    https://api.stackone.com/connect/oauth2/databricks_iam/callback
    ```

    * Access scopes: Select **All APIs**
    * Client secret: Select **Generate a client secret**
    * Access token TTL: 30 (recommended minimum)
    * Refresh token TTL: **129,600** (strongly recommended)

    <Warning>
      When the Databricks refresh token expires, a manual re-authorization is required to re-establish the connection.

      Therefore, we strongly recommend setting the refresh token TTL to the maximum allowed value of 129,600 minutes (90 days).
    </Warning>

    <Frame>
      <img className="rounded-md" style={{ margin: '0 auto', border: '1px solid #efefef' }} alt="Enter connection details" src="https://mintcdn.com/stackone-hub-docs-confluence-api-token-update/YuiSn9_H_qPKyg_D/images/databricks/image5.png?fit=max&auto=format&n=YuiSn9_H_qPKyg_D&q=85&s=9bb653eeb0746cd43cb47c729e589fa5" width="1346" height="1670" data-path="images/databricks/image5.png" />
    </Frame>

    Once completed, click the **Add** button at the bottom.
  </Step>

  <Step title="Copy new credentials">
    Copy your displayed **Client ID** and **Client Secret** and store them safely to be used in a later step.

    <Frame>
      <img className="rounded-md" style={{ margin: '0 auto', border: '1px solid #efefef' }} alt="Add connection" src="https://mintcdn.com/stackone-hub-docs-confluence-api-token-update/YuiSn9_H_qPKyg_D/images/databricks/image6.png?fit=max&auto=format&n=YuiSn9_H_qPKyg_D&q=85&s=e99c7312054336a24590bb008fa9e902" width="1440" height="924" data-path="images/databricks/image6.png" />
    </Frame>
  </Step>
</Steps>

## Connecting with StackOne

Upon reaching the Link Account page, enter the credentials from the previous steps:

* **Cloud Provider**: Select your Databricks cloud host (AWS or Azure)
* **Account ID**
* **Client ID**
* **Client Secret**

Proceed by clicking the Connect button.

You may be prompted to log in to your Databricks account to authorize the connection. If so, follow the login prompt.

<Frame>
  <img className="rounded-md" style={{ margin: '0 auto', border: '1px solid #efefef' }} alt="Connecting with StackOne" src="https://mintcdn.com/stackone-hub-docs-confluence-api-token-update/YuiSn9_H_qPKyg_D/images/databricks/image7.png?fit=max&auto=format&n=YuiSn9_H_qPKyg_D&q=85&s=1b96e980c9c4005538cd68edc95416cb" width="964" height="1518" data-path="images/databricks/image7.png" />
</Frame>

<br />

Congratulations, you're all set! If you face any issues with the steps mentioned above,
please contact us by emailing [integrations@stackone.com](mailto:integrations@stackone.com). We're always here to assist you!

## Available data

This integration has the following [IAM Resources](https://docs.stackone.com/reference/getting-started-with-your-api) available from the provider:

<ul>
  <li>Users</li>
  <li>Groups</li>
</ul>
