> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stackone.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Connect Kustomer with OAuth 2.0 (Multiple Companies) – StackOne Hub

> Link a Kustomer account in the StackOne Hub using OAuth 2.0 (Multiple Companies). End-user guide to authorize the integration and start using Kustomer actions.

> [!WARNING]
>
> You need a Kustomer API key with org.admin.apps and org.permission.apps roles to register an OAuth app.

## Register a Kustomer OAuth App

Register a private app with the Kustomer Apps Platform to obtain OAuth credentials.

**1. Obtain an Admin API Key**

Go to your Kustomer instance at `https://<your-org>.kustomerapp.com`.

<ul>
  <li>Navigate to **Settings > Security > API Keys**.</li>
  <li>Click **Add API Key**.</li>
  <li>Assign the **org.admin.apps** and **org.permission.apps** roles.</li>
  <li>Copy the API key immediately — it is only shown once.</li>
</ul>

**2. Register the App**

Use the API key to register your app via POST request to the Kustomer Apps Platform API.

<ul>
  <li>Send a POST request to `https://api.kustomerapp.com/v1/apps/available` with your app definition JSON.</li>
  <li>Include a unique app identifier and semantic version in the request body.</li>
  <li>Set the redirect URI to `https://api.stackone.com/connect/oauth2/kustomer/callback`.</li>
</ul>

**3. Generate OAuth Credentials**

After registering the app, generate the Client ID and Client Secret.

<ul>
  <li>Send a POST request to `https://api.kustomerapp.com/v1/apps/available/{app}/secret/` to generate credentials.</li>
  <li>Copy the **Client ID** and **Client Secret** — store them securely.</li>
</ul>

## Find Your Organization Name

Your Kustomer organization name is needed for the base URL.

**1. Locate from your browser URL**

After logging in to Kustomer, look at the URL in your browser address bar. It follows the format `https://<org-name>.kustomerapp.com`.

<ul>
  <li>**Organization Name** is the subdomain before `.kustomerapp.com` (e.g., `mycompany`).</li>
</ul>

## Install the App

The OAuth app must be installed in the target organization before authorization can begin.

**1. Install the App**

Install the registered app in the Kustomer organization. Without this step, the OAuth flow will return a 400 'Invalid Client' error.

## Link the Account

**1. Connect**

<ul>
  <li>Click **Connect**.</li>
  <li>If applicable, the provider will redirect you to a sign-in or authorization page. Complete the provider's authorization flow.</li>
  <li>Once authorization is successful, you will see a confirmation popup.</li>
</ul>

**2. Use Actions**

Connect an AI platform to the linked account's actions. See [AI Platforms](https://docs.stackone.com/ai-platforms/overview.md).

Other ways to call actions are listed in [Protocols & SDKs](https://docs.stackone.com/connect/protocols-and-sdks.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.