# API keys

> Create, limit and revoke workspace API keys for the TalkDemo CLI, the MCP server and the TalkDemo Recorder, which propose draft flows for review.

Source: https://talkdemo.com/help/team-and-settings/api-keys · Updated 2026-11-20

## Key takeaways

- An API key lets your own tools read an agent's flow setup, add draft flows and update drafts they pulled. It never activates, deletes or changes an active flow and never sees the demo login.
- Each key shows when it was last used and how many requests it has made, so you can spot unused keys and revoke them.
- Only a workspace admin creates and revokes keys in Settings, API keys. The key is shown once; TalkDemo keeps only a keyed hash.
- Keys expire after 30 to 365 days, and stop working at once when revoked or when the person who made them leaves the workspace or becomes a viewer.
- Pairing the TalkDemo Recorder creates its own key, limited to one agent and draft flows, for 30 days.

API keys connect your own tools to TalkDemo: the TalkDemo CLI and MCP server, so Claude Code or another coding agent can write flows from your codebase, and the TalkDemo Recorder extension. A key can read an agent's flow setup and add **draft** flows. Someone on your team reviews every draft before the agent uses it.

**Who can do this:** Admin creates and revokes keys. Everyone can see the list.

## Create a key

1. Open **Settings → API keys**.
2. Under **New key**, give it a **Name** that says what it is for, such as "Claude Code on the web app repo".
3. Choose the **Agent**. Limit the key to one agent when you can.
4. Choose **Permissions**: **Read flows and context** is always on; **Propose draft flows** lets it add drafts.
5. Choose when it **Expires after**: 30, 90, 180 or 365 days.
6. Click **Create key** and copy it right away. It starts with `tdk_live_` and is shown only once.

Keep the key in your terminal (`export TALKDEMO_API_KEY=…`) or your MCP settings, never in a file you commit.

## See how a key is used

Each key in the list shows who made it and when, when it was **last used** and how many **requests** it has made. A key that hasn't been used for a long time is a good one to revoke. The count includes every request the key made that TalkDemo accepted, from the CLI, the MCP server or the Recorder. Requests with a revoked, expired or wrong key aren't counted.

If you ask TalkDemo support about a key, they can see the same list for your workspace (name, first characters, created, last used, requests and whether it's revoked). Nobody can see the key itself, and only your workspace's admins can revoke keys.

## Revoke a key

Click **Revoke** next to the key and confirm. Anything using it stops working straight away. Flows it already added stay where they are.

A key can also revoke itself, so the person using it doesn't need an admin:

- **TalkDemo CLI:** run `talkdemo logout`. It revokes the key in `TALKDEMO_API_KEY` for the CLI, the MCP server and anything else using it. Then remove the key from your shell profile and MCP settings.
- **TalkDemo Recorder:** click **Disconnect** in the extension. It revokes its key, then forgets it. If TalkDemo can't be reached at that moment, the extension says so and an admin can revoke the key here.

The key then shows as revoked in this list, and the activity log records that the key revoked itself.

## When a key stops working

- It expires or is revoked.
- The person who created it leaves the workspace or becomes a **Viewer**.
- The workspace is suspended or closed.

Ask an admin for a new key in each case.

## The TalkDemo Recorder

On an agent's **Flows** tab, **Connect the TalkDemo Recorder** shows an 8-character code that works once, for 10 minutes. Typing it into the extension creates a key named "Recorder (your name)", limited to that agent and to draft flows, for 30 days. It appears here with a **Recorder** label, and an admin can revoke it like any other key. See [Teach a flow by clicking](/help/product-and-flows/teach-a-flow-by-clicking).

## Frequently asked questions

### What does TalkDemo store?
A keyed hash of the key and its first characters, so the list can name it. The key itself can't be shown again.

### Can a key read leads, sessions or recordings?
No. Keys only reach an agent's flow setup and flows.
