# OpenAI

Connect your OpenAI workspace to Teleskope to catalog and classify conversations, messages, and files for data security and data loss prevention.

## Prerequisites

* A ChatGPT for Enterprise or OpenAI organization and workspace
* Admin or equivalent access to workspace settings and API key management

## Where to find your OpenAI credentials

Before enrolling in Teleskope, gather the **Workspace ID**, **Organization ID**, **Workspace Name** (optional display label), and an **API key**. Use the steps below to find or create each one.

### Get Workspace ID and Organization ID (ChatGPT for Enterprise)

1. Open your ChatGPT for Enterprise account and go to **Settings & permissions**: <https://chatgpt.com/admin/settings>.
2. In **Workspace details**, note the **Organization ID** and **Workspace ID**. You will enter these in Teleskope during enrollment.
3. The workspace name you see there can be used as **Workspace Name** in Teleskope (a display label for the data catalog).

### Confirm organization and create an API key (OpenAI Platform)

1. Open the OpenAI Platform **Organization settings** and ensure the correct organization is selected: <https://platform.openai.com/settings/organization/general>. The **Organization ID** on this page should match the one from ChatGPT for Enterprise.
2. Go to **API keys**: <https://platform.openai.com/settings/organization/api-keys>.
3. Click **Create new secret key**, give it a name, and assign the permissions your integration requires (e.g. **All** or the scopes needed for reading workspace data). Click **Create secret key**.
4. Copy and store the secret key in a secure place immediately. The full key is shown only once. Optionally note the key name and who created it; some workflows (e.g. requesting compliance scopes) may require this.

{% hint style="warning" %}
The API secret is displayed only once. Save it securely before closing the dialog.
{% endhint %}

### Request Compliance API Scopes

OpenAI requires that your API key have Compliance API scopes for Teleskope’s DLP functionality to work with ChatGPT for Enterprise. You must request these scopes from OpenAI Support before enrolling. Email **<support@openai.com>** with the key name, the name of the user or service that created the key, the last four characters of the API key, and the requested scope: **Read** for scanning and cataloging only, or **Read & Delete** if you will use Teleskope for redaction/deletion. After verification, OpenAI will grant the scopes and typically send a confirmation email. See [OpenAI's admin API documentation](https://chatgpt.com/admin/api-reference) for current requirements.

## Enroll the OpenAI Connector

{% stepper %}
{% step %}
**Open OpenAI settings**

1. In Teleskope, go to **Settings → Connectors.**
2. Select **OpenAI** from the connectors list.
3. Click **Enroll**.
   {% endstep %}

{% step %}
**Enter workspace credentials**

On the enrollment page, fill in:

1. **Workspace ID** — The OpenAI workspace ID.
2. **Workspace Name** — A display name for the workspace (e.g., for use in the data catalog).
3. **Organization ID** — Your OpenAI organization ID.
4. **API Key** — Your OpenAI API key. This is stored securely and used to access workspace data.

Click **Enroll** to complete enrollment. On success, you are returned to the OpenAI connector page and the workspace appears in the enrolled list.
{% endstep %}
{% endstepper %}

{% hint style="info" %}
Keep your API key secure. Do not share it or commit it to version control. You can create and manage API keys in your OpenAI organization settings.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.teleskope.ai/connectors/saas/openai.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
