# LAP MCP Connection Guide for ChatGPT

This guide walks staff through connecting the **LAP MCP server** in both:

- ChatGPT online (web)
- ChatGPT Desktop

Use this when you need ChatGPT to call LAP tools (case search, case details, updates, documents, and appointments).

---

## Before You Start

1. Confirm you have a valid LAP login account.
2. Confirm your LAP MCP endpoint URL is available from your admin or deployment notes (example: `https://mcp.kinghornja.com`).
3. Keep your OAuth-enabled account ready so you can sign in during the connection flow.

---

## Connect LAP MCP in ChatGPT Online (Web)

### Step 1: Open Plugins in Settings

1. Sign in to ChatGPT in your browser.
2. Open **Settings**.
3. Select **Plugins** in the left menu.
4. Confirm you can see **Developer mode** as a menu item.

![Open Plugins in settings](/mcp-docs/chatgpt-web-1.png)

### Step 2: Enable Developer Mode

1. Open **Security and login** in settings.
2. Find the **Developer mode** section.
3. Turn **Developer mode** ON.

![Enable developer mode](/mcp-docs/chatgpt-web-2.png)

### Step 3: Start Adding a Custom Plugin/MCP

1. Return to **Plugins**.
2. Click the **+** button in the top-right.
3. Start creating a new connector.

![Click plus to add new plugin](/mcp-docs/chatgpt-web-3.png)

### Step 4: Fill the New Plugin Form

1. Set **Name** to `Legal Assist` (or your preferred LAP name).
2. Keep connection type on **Server URL**.
3. Set URL to your LAP MCP endpoint (example: `https://mcp.kinghornja.com/`).
4. Set **Authentication** to **OAuth**.
5. Tick the risk acknowledgement checkbox.
6. Click **Create**.

![Create plugin with server URL and OAuth](/mcp-docs/chatgpt-web-4.png)

### Step 5: Click Sign in with Legal Assist

1. In the connector pop-up, click **Sign in with Legal Assist**.
2. Continue to the LAP sign-in page.

![Sign in with Legal Assist prompt](/mcp-docs/chatgpt-web-5.png)

### Step 6: Log in to LAP

1. Enter your LAP username/email.
2. Enter your LAP password.
3. Click **Log in**.

![LAP login page](/mcp-docs/chatgpt-web-6.png)

### Step 7: Authorize ChatGPT

1. Review the authorization request.
2. Click **Authorize** to grant access.
3. Wait for redirect back to ChatGPT.

![Authorize application page](/mcp-docs/chatgpt-web-7.png)

### Step 8: Run a Quick MCP Test Prompt

1. Start a new chat.
2. Ask for a safe read-only request, for example:
   - "Connect to Legal Assist and search clients by name 'Test'."
3. Approve tool usage when prompted.

---

## Connect LAP MCP in ChatGPT Desktop

### Step 1: Add MCP Server in Desktop Settings

1. Open the ChatGPT Desktop app.
2. Go to **Settings**.
3. Open **Plugins**, then select the **MCPs** tab.
4. Click **Add** → **Add MCP server**.
5. Fill the form:
   - **Name**: `Legal Assist`
   - **Type**: `Streamable HTTP`
   - **URL**: your LAP MCP endpoint (example: `https://mcp.kinghornja.com`)
6. Save/create the MCP connection.

![Open connector settings in desktop](/mcp-docs/chatgpt-desktop-1.png)

### Step 2: Test and Approve Tool Access

1. Open a new Desktop chat.
2. Ask ChatGPT to run a LAP tool (for example, client search).
3. When prompted, click **Allow once** (or your preferred allow option).
4. Confirm tool-backed response is returned.

![Test MCP tool approval in desktop](/mcp-docs/chatgpt-desktop-2.png)

---

## Quick Troubleshooting

1. **Connection fails**: re-check the MCP URL and network access.
2. **Auth loops**: sign out and sign in again, then reconnect.
3. **No tools listed**: reconnect and confirm account permissions.
4. **Unexpected errors**: capture screenshot + timestamp and send to IT.
