# Use Dvina from other apps with MCP

> Connect an MCP client like Claude Code, ChatGPT or Cursor to Dvina, sign in, and let it read and add to your Dvina with your approval.

Dvina has its own MCP server. Connect an MCP client, like Claude Code, ChatGPT or Cursor, and that app can search your Dvina, read your documents and memory, and add notes, tasks and reminders, as you.

## Before you start

You need the server's address:

```text
https://api.dvina.ai/mcp
```

If your company runs Dvina on its own servers, use your company's own Dvina API address with `/mcp` at the end. Ask your admin for it.

The server uses Streamable HTTP. In a client that asks for a transport, choose HTTP.

## Connect a client

::: tabs

=== Claude Code

1. In your terminal, run:

    ```sh
    claude mcp add --transport http dvina https://api.dvina.ai/mcp
    ```

2. Start Claude Code, run `/mcp`, choose **dvina**, and sign in to Dvina.

=== ChatGPT

1. Open the place where ChatGPT lets you add an MCP server.
2. Enter `https://api.dvina.ai/mcp` as the server's address, and choose OAuth if it asks how to sign in.
3. Sign in to Dvina when ChatGPT asks.

=== Cursor

1. Open the place where Cursor lets you add an MCP server.
2. Add a server named `dvina` with the address `https://api.dvina.ai/mcp`.
3. Sign in to Dvina when Cursor asks.

:::

You don't need a client ID or secret. The client registers itself with Dvina the first time it connects.

## Sign in

Dvina's MCP server signs you in with OAuth, in your browser:

1. Sign in to Dvina as you usually do.
2. If you belong to more than one workspace, choose one under **Select workspace**, then choose **Continue**. The client works in that workspace only.
3. Under **Authorize access**, check the app's name, then choose **Allow access**. Choose **Deny** if you don't recognize it.

The client stays connected, so you don't sign in every time.

## What a client can do

The client sees Dvina's tools and uses them when your request calls for them:

| Area                   | What the client can do                                                                                                                       |
| ---------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
| **Search**             | Search your chats, documents, memory and world at once.                                                                                      |
| **Memory**             | List and read your memory files, add a new one, or change one.                                                                               |
| **World**              | List your topics, show what Dvina knows about a topic or anything else, and list your Feed.                                                  |
| **Documents**          | List, read and search your Library, create notes and folders, upload files, and replace, move or rename a document, or move it to the trash. |
| **Canvas**             | List and read your canvases, create a canvas, or rewrite a page.                                                                             |
| **Tasks and goals**    | List your tasks and read what they did, start a task or a task that works toward a goal, send a task more to do, or stop one.                |
| **Scheduled messages** | List them, schedule a message or reminder, once or repeating, or cancel one.                                                                 |
| **Agents and skills**  | List and read your agents and skills, create an agent, add a skill, or change either.                                                        |
| **Projects**           | List your projects and show a project's folder and recent tasks.                                                                             |
| **Sharing**            | See who has access to an item and what others shared with you, or give or remove someone's access.                                           |
| **Settings**           | Show your preferences, or turn memory on or off.                                                                                             |

The client can't delete anything for good, open public links, connect or disconnect apps, or change admin or billing settings.

## Approve changes

What the client does follows the same rules as everywhere in Dvina:

- Reading runs without asking.
- Adding something new, like a note, a memory file or a task, runs without asking. It never changes what's already there.
- Changing or removing something, like moving a document to the trash, rewriting a canvas page, stopping a task or sharing an item, asks you first. The client shows Dvina's own summary of the change, and you approve it or decline it. When you decline, nothing changes.

> [!NOTE]
> If a client can't ask you to confirm, Dvina doesn't make the change from it. Make the change in the Dvina app instead, or use a client that can ask.

## Your access and your company's rules

The client works as you, with what you can see and do in Dvina:

- It works only while you're still a member of the workspace, and only with what your role allows.
- If your admin turns a feature off, like file uploads, the client can't use it either.
- What the client adds or changes goes through your company's data protection rules, as in the app.
- What it adds or changes is recorded in your [audit log](/docs/teams/audit-log) as the assistant's, for you, with the client it came from.
- What it does counts toward your usage, within your usual limits.

## Connect with an API key instead of OAuth

On the Enterprise plan, a client can connect with a personal access token instead of signing in. Use this for a client that can't sign in with OAuth, or for a script.

1. Open Settings and choose **API Access**.
2. Under **Personal Access Tokens**, choose **Create Token**.
3. Enter a **Name**, choose the **Access** and when it **Expires**, then choose **Create Token**.
4. Under **Copy Your Token**, copy the token. This is the only time it's shown.

Choose the access the client needs:

- **Read only:** the client sees only the tools that read. It can search and read your Dvina, but can't add or change anything.
- **Read and write:** the client sees every tool, and changes still ask for your approval, as with OAuth.

Send the token in the `Authorization` header, after `Bearer`. In Claude Code, for example:

```sh
claude mcp add --transport http dvina https://api.dvina.ai/mcp --header "Authorization: Bearer <your token>"
```

In another client, add the same header where it lets you set headers for an MCP server.

The token works as you, in the workspace you made it in, with your role there now. To replace it, open it under **Personal Access Tokens** and choose **Rotate…**: a new token replaces it, and the old one stops working at once. To stop it, choose **Revoke…**: anything that uses it stops working at once.

For more about tokens, see [API access](/docs/connectors/api-access).

## Related

- [Custom apps and MCP servers](/docs/connectors/custom-apps)
- [API access](/docs/connectors/api-access)
- [Use the dvina command](/docs/connectors/dvina-cli)
- [Teams overview](/docs/teams/overview)
