Skip to Content
OpenInspect
Integrations

MCP server

Let Claude Code or another MCP client investigate sessions and automation runs, and optionally create and run automations or import skills, through a personal access token.

Last reviewed View as MarkdownEdit on GitHubGive feedback

The OpenInspect MCP server lets an MCP client such as Claude Code read your sessions and automation runs, and optionally create and run automations or import skills, without opening the web UI. It runs on your machine and authenticates with a personal access token.

Set it up

  1. Create a token under Settings › Access tokens. For investigation, select Read-only. Add write permissions only if you want the assistant to make changes; see the table below.

  2. Build the server from a checkout of the repository:

    npm run build -w @open-inspect/shared
    npm run build -w @open-inspect/mcp-server
  3. Register it with your client:

    claude mcp add open-inspect \
      --env OPEN_INSPECT_CONTROL_PLANE_URL=https://<your-control-plane> \
      --env OPEN_INSPECT_TOKEN=oi_pat_... \
      -- node /absolute/path/to/packages/mcp-server/dist/index.js

The control plane URL must use https://; plain http:// is accepted only for a loopback address such as localhost.

What it can do

ToolNeeds the token to hold
list_sessions, get_session_events, get_session_messages, get_session_diff, get_session_diff_fileRead sessions
list_automations, list_automation_invocations, get_automation_runRead automations
list_skillsRead skills
create_automationCreate automations, Create sessions, and use of its targets
trigger_automationRun your automations or Run any automation, Create sessions, and use of its targets
import_skill_from_git, update_skill_from_gitManage skills (administrators), which always comes with Read skills

A token without a tool's permission gets an error, which usually names the missing permission or points to the tool's description, where the needed grant is stated. The token never exceeds your own role or your workspace's token policy, and nothing it does can delete or pause an automation, delete a skill, or reach secrets or workspace settings. A run started with trigger_automation uses only what the token was granted, even where your role allows more.

Keep the assistant in check

Session transcripts and diffs are content the agent and your repositories produced, and they go straight into the assistant's context. Treat them as untrusted. Text in a session can try to persuade the assistant to call a write tool, and that call would act with your authority:

  • An automation runs its instructions later, in a sandbox, as you.
  • A skill assigned globally loads into every later session in the workspace.

A read-only token cannot be talked into writing: the control plane refuses the call whatever the assistant sends. The token's grant is the only limit anything enforces.

The server marks its write tools as not read-only, and many MCP clients ask before running such a tool by default. That marking is a hint, though, and whether you are asked depends on your client's settings: a client set to approve tools automatically runs writes without asking. If you give a token write permissions, check how your client handles write tools, and read what a write is about to create before you approve it.

On this page