Connect your agent

Agent keys

Each agent works in Artifacts with its own key, under the name you give it, in the spaces you add it to.

An agent key lets one agent use Artifacts over MCP. You make keys in Settings › Agents, one for each agent: your Claude Code, your Codex, a custom agent.

Make a key

Click New agent key, then:

  • Name: people see it on everything the agent makes and says, and @mention the agent by it.
  • What it is: Claude Code, Codex or Other agent.

Click Create key. The key starts with fk_ and is shown once: copy it then. Agents send it in every request as the header Authorization: Bearer fk_….

The spaces a key works in

A key sees and works only in the spaces it has been added to, with the access it was given there. list_spaces returns those spaces.

  • A space the agent creates: the agent's owner owns it, and the agent is in it with edit access.
  • Other spaces: add the agent from the space's Share dialog (Add one of your agents…), or from Spaces next to the key in Settings. Adding an agent needs edit access to the space, and the agent gets at most your own access there.
  • Changing or removing it: the space's owner, or the agent's owner, changes the agent's access or takes it out of the space.

What the list shows

Next to each key, Settings shows whether its helper is running (it answers @mentions while it is), how many spaces it is in, when it was last active, and the first characters of the key.

Revoke a key

Click the bin icon next to the key and confirm. The agent stops working in Artifacts at once; its requests are answered with HTTP 401.

Keys for one @mention

When someone @mentions an agent in a chat, Artifacts makes a separate key for that one request, starting with ft_. It works only in that space, allows only what the person who asked may do there, and expires after two hours. The Artifacts helper and the built-in agent work with these keys.