# Claude Code + VidMachine MCP

> Register the server once, then run the whole loop from your terminal.

Claude Code speaks Streamable HTTP and accepts a custom header, so the API key stays in your shell — the config only names the variable. Register VidMachine once and every Claude session on the machine can list projects, edit scenes, and schedule posts.

Page: https://vidmachine.ai/claude

## Connect

Create an API key under [API & MCP](https://vidmachine.ai/api-keys), then register the server. The single quotes stop your shell from expanding the variable, so the key is not written to the config in plaintext.

```bash
export VIDMACHINE_API_KEY=vidm_...
claude mcp add --transport http vidmachine \
  https://vidmachine.ai/api/mcp \
  --header 'Authorization: Bearer ${VIDMACHINE_API_KEY}'
```

Run `claude mcp list` to confirm it connected.

- The same key works for the [REST API](https://vidmachine.ai/docs/api.md).
- The agent gets 28 tools in five groups: find, build, render, post, brand.

## The loop: find, inspect, make, schedule

### 1. Find — find out what's already there

Ask for a project or a video in plain language. The read tools answer with real IDs, statuses, and the first missing stage — and cost nothing.

Tools: `search_documentation`, `get_documentation`, `list_projects`, `list_videos`

### 2. Inspect — inspect before spending credits

Read the script, scenes, and cover, then quote the credits the remaining stages will cost and check the balance. Every paid step is priced before it runs.

Tools: `get_video_content`, `estimate_video_cost`, `get_credit_balance`

### 3. Make — make your version

Rewrite a scene, regenerate just that scene's media, and resume the pipeline. Work that already exists is reused, so a one-scene change does not redo the video.

Tools: `update_scene`, `generate_scene_media`, `generate_video`, `export_video`

### 4. Schedule — schedule it and get the link

Set the post time and status, then have the final URL handed back to you. The scheduler publishes it with the same rules as the dashboard.

Tools: `update_video`, `export_video`

## Three prompts to try

1. Show me the Fast Brain project and what's left to render.
2. Rewrite scene 3 with a tighter hook, then regenerate that scene.
3. Move Thursday's post to Friday 9:00 and send me the final URL.

## Full tool list

Every tool, input schema, protocol version, and header rule: [MCP server docs](https://vidmachine.ai/docs/mcp.md).

Other guides: [ChatGPT](https://vidmachine.ai/chatgpt) · [Cursor](https://vidmachine.ai/cursor) · [Codex](https://vidmachine.ai/codex)
