AnyCap CLI v0.5.0 ships with a built-in MCP server. It exposes 23 typed tools — image generation, video, music, web search, Drive (read), and Page (read) — through the standard stdio protocol that Claude Code, Cursor, Codex, and any other MCP-compatible host already understand.
Note on Drive and Page: The MCP server has read-only access to Drive and Page. That means the agent can list, retrieve, and reference existing Drive files and Pages, but cannot upload new files or publish new Pages through MCP tool calls. For Drive upload and Page publish, use the AnyCap CLI directly.
If you want AnyCap's capabilities available as first-class MCP tools in your agent environment, this guide covers the complete setup.
Before You Start
You need the AnyCap CLI installed and authenticated. If you haven't done that yet:
# Install the CLI
curl -fsSL https://anycap.ai/install.sh | sh
# Authenticate once
anycap login && anycap status
Verify MCP support is available in your version:
anycap mcp --help
If the command is missing, update first:
anycap update
Setup by Host
Claude Code
claude mcp add --scope local anycap -- anycap mcp --allow-root "$PWD"
The --scope local flag scopes the server to your current project. --allow-root "$PWD" grants the MCP server access to local files in the current directory — needed for tools that work with local images, video files, and generated output.
Verify the connection:
claude mcp list
AnyCap should appear in the list. Then open a Claude Code session and ask: "What AnyCap tools do you have available?" — it will list all 23 tools.
Codex
codex mcp add anycap -- anycap mcp
This installs a global server definition without a fixed root. Each session uses the working directory as the default media root.
Cursor
Open .cursor/mcp.json in your project root (create it if it doesn't exist):
{
"mcpServers": {
"anycap": {
"type": "stdio",
"command": "anycap",
"args": ["mcp", "--allow-root", "/absolute/path/to/your/project"]
}
}
}
Replace /absolute/path/to/your/project with the actual path. Restart Cursor after saving. Commit .cursor/mcp.json to your repo so teammates get the same configuration (they'll need the AnyCap CLI installed and authenticated separately).
Windsurf and Generic Stdio Hosts
Any MCP host that supports stdio servers uses the same configuration format:
{
"mcpServers": {
"anycap": {
"type": "stdio",
"command": "anycap",
"args": ["mcp", "--allow-root", "/absolute/path/to/media"]
}
}
}
Check your host's documentation for where to place this configuration. For Windsurf, it goes in Settings → AI Tools.
Authenticating Inside MCP Sessions
The AnyCap MCP server loads your existing CLI credentials automatically at startup. No browser is opened during startup.
If you start a session and find the agent unauthenticated, the MCP server exposes a device-auth flow through tools:
- Call
anycap_auth_status— check current credential state - If unauthenticated, call
anycap_login— returns a verification URL and user code - Complete login in your browser using those credentials
- Call
anycap_login_pollwith the returned session ID to complete the flow - Call
anycap_statusto confirm the server is connected and ready
In practice, if you ran anycap login before starting the MCP session, you're already authenticated and none of these steps are needed.
The 23 AnyCap MCP Tools
Once connected, your agent has access to the full capability stack as typed MCP tools:
Authentication and Status
| Tool | Purpose |
|---|---|
anycap_auth_status |
Check current credential state |
anycap_login |
Start device auth without a browser popup |
anycap_login_poll |
Complete an in-progress login |
anycap_logout |
Clear local credentials |
anycap_status |
Verify server and account status |
anycap_list_models |
Discover available models by capability |
anycap_model_schema |
Get the exact schema for a selected model/operation |
Image Capabilities
| Tool | What it does |
|---|---|
anycap_image_generate |
Text-to-image generation across multiple models (Seedream 5, Nano Banana, Flux, and more) |
anycap_image_edit |
Edit or transform an existing image |
anycap_image_upscale |
Upscale an image to higher resolution |
anycap_image_read |
Understand, describe, or extract information from an image |
Video Capabilities
| Tool | What it does |
|---|---|
anycap_video_generate |
Text-to-video and image-to-video across multiple models (Veo 3.1, Kling 3.0, Seedance, and more) |
anycap_video_read |
Analyze video content, extract details, transcribe |
Music and Audio
| Tool | What it does |
|---|---|
anycap_music_generate |
Generate music from text descriptions |
anycap_audio_read |
Transcribe or analyze audio recordings |
Web Capabilities
| Tool | What it does |
|---|---|
anycap_web_search |
Search the web with grounded results |
anycap_web_crawl |
Crawl and extract content from a URL |
Drive and Page
| Tool | What it does |
|---|---|
anycap_drive_list |
List files in AnyCap Drive (read-only) |
anycap_drive_get |
Retrieve a Drive file by reference (read-only) |
anycap_drive_resolve_path |
Resolve a path to a Drive reference (read-only) |
anycap_page_list |
List published AnyCap Pages (read-only) |
anycap_page_get |
Get a Page by reference (read-only) |
anycap_page_versions |
List versions of a published Page (read-only) |
Local File Access
Several tools accept local file paths in addition to HTTP URLs and AnyCap upload references:
anycap_image_generate,anycap_image_edit,anycap_image_upscale,anycap_image_readanycap_video_generate,anycap_video_readanycap_audio_read
For local files to work, the path must fall within an authorized root. Roots are set via:
--allow-rootflag in the MCP start commandANYCAP_MCP_FILE_ROOTSenvironment variable (colon-separated list of paths)- Roots advertised by the MCP client
- The process working directory (fallback when no other roots are configured)
Practical advice: Use --allow-root "$PWD" or --allow-root "/your/project/path" and keep the root as narrow as possible. The server rejects path traversal and symlink escapes by design.
MCP vs CLI: Which Access Method Should You Use?
AnyCap offers two ways to give your agent capabilities: the CLI (via skills) and the MCP server. Both use the same auth, the same models, and the same capability surface.
| Factor | CLI via Skills | MCP Server |
|---|---|---|
| Setup | npx -y skills add anycap-ai/anycap -a claude-code -y |
claude mcp add --scope local anycap -- anycap mcp --allow-root "$PWD" |
| How the agent calls capabilities | Shell commands (anycap image generate ...) |
Typed MCP tool calls (anycap_image_generate) |
| Token overhead | Low (~2,000 tokens for skill description) | Moderate (23 tool schemas) |
| Best for | Quick setup, natural language agent workflows | Teams standardizing on MCP for tool transport |
| Cross-agent portability | Same skill, different -a flag per agent |
Same JSON config shape across any MCP host |
If you're not sure which to use: AnyCap MCP vs Skills →
Most teams that need both quick onboarding and protocol standardization use both: skills for the first setup, MCP for stable production integration.
Troubleshooting
| Problem | Fix |
|---|---|
anycap mcp --help not found |
Run anycap update to get v0.5.0+ |
| Claude Code doesn't show AnyCap tools | Restart Claude Code after running claude mcp add |
| "File not in allowed root" error | Check that --allow-root points to the right directory |
| Auth fails inside MCP session | Run anycap login in your terminal first, then restart the MCP session |
| Cursor not picking up MCP config | Ensure the path in mcp.json is absolute (not relative) and restart Cursor |
FAQ
Does AnyCap's MCP server replace the CLI?
No. Both access methods are available and use the same underlying capability surface. The CLI is the better path for agents using skills-based onboarding. The MCP server is better for teams standardizing on MCP as a tool transport layer. Many teams use both.
What MCP protocol version does AnyCap support?
AnyCap's MCP server has been verified with MCP protocol version 2025-06-18.
Can I use AnyCap MCP in Windsurf?
Yes. Use the generic stdio configuration in Windsurf's MCP settings. The same anycap mcp command works across any MCP-compatible host.
Do I need separate credentials for MCP vs CLI?
No. AnyCap uses one authentication flow for both access methods. Log in once with anycap login and all tools — CLI commands and MCP tool calls — use the same credentials.
How is token overhead different between CLI and MCP?
The skills-based CLI approach adds approximately 2,000 tokens for the skill description. The MCP server adds more — 23 tool schemas load into the agent's context. For context-sensitive workflows, the CLI path is more token-efficient. For teams that already standardize on MCP, the overhead is acceptable for the protocol consistency it provides.
Read Next
- AnyCap MCP vs Skills: Which Setup Should You Use? — Decision guide for choosing between protocol-based and skills-based AnyCap access.
- What Is Model Context Protocol (MCP)? — Understand the protocol powering AnyCap's MCP server.
- MCP Servers vs Capability Runtimes — How AnyCap fits into the broader MCP ecosystem.
- AnyCap for Claude Code — Start here if you're setting up AnyCap in Claude Code for the first time.