# Inside ChatGPT and Claude

> Let a person open your app's home screen inside ChatGPT and Claude, with one line.

Source: https://docs.coline.app/sdk/chat

A person who connected Coline to ChatGPT or Claude can say "open my standup tracker" and get your app's own screen in the chat, working. Turn it on for a React home screen:

```ts title="app.config.ts"
export default defineApp({
  key: "standup",
  name: "Standup",
  permissions: ["storage.app", "tasks.read"],
  surfaces: { home: { tier: "react", entry: "./home.tsx", chat: true } },
});
```

Nothing else in your code changes. `chat` is off by default and only a `react` home screen can turn it on.

## How it runs

The chat loads a small page from Coline. Your screen runs in a sandboxed frame inside it, the same sandbox it has in Coline: no network of its own, no cookies, no storage, and one way out, the `coline.*` bridge. Every call goes to Coline and is checked there against the permissions the install was granted, as it is in Coline. Your code never sees the person's connection to Coline.

A chat that doesn't allow a frame inside its page shows your app's name, its description and "Open in Coline" instead.

## What works

* Every `coline.*` call: storage and collections, tools, actions, integrations, tasks, calendar, messages, references, file reads, search, notifications, jobs, AI and `net.fetch`.
* `pickers.confirm` and toasts, drawn by Coline.
* Light and dark, and the chat's own neutral colors and font, through the theme your screen already reads.
* `coline.context.publish`: the chat's assistant sees what you publish, marked as your app's text.
* `navigation.*` opens the Coline page in a new tab.

A reply over 100 KB is refused: ask for less at a time (a page of records, not all of them).

## What doesn't

There is no live connection in a chat. `realtime.subscribe` succeeds and delivers nothing; live collections read again on an interval and after each write, so lists stay current.

These answer the error code `not_in_chat` with a message like "Open this app in Coline to pick a file." Show it, or hide the control:

* file, member and destination pickers, and `files.saveAs`
* uploads (`files.upload`, `files.createUpload`)
* `connections.connect`

File editors open only in Coline. In a chat, it's the home screen.

## Consent

The install screen says "Can open its screen inside ChatGPT and Claude". Turning `chat` on in a new version asks the people who installed your app again, so an update never puts it in a chat on its own.

## For the person

Connect Coline in ChatGPT or Claude, then ask for the app by name. The assistant calls `open_app` with its key (`list_apps` lists them). The app opens with the install you'd get in Coline: your own before the workspace's.
