Connect GthonrAgents through MCP
GthonrAgents’s local MCP server lets Claude Code, Codex, Cursor, and other compatible hosts discover tools for image and video generation, media understanding, and web research. The host launches gthonragents mcp as a local process and communicates over stdio; media and web requests run through the GthonrAgents service.
The server runs inside the CLI binary and shares its login and model discovery. Install the CLI first, then configure a host below. The MCP tool reference describes the tool surface and read/write boundaries.
Verify support
Section titled “Verify support”gthonragents mcp --helpIf the command is missing, run gthonragents update.
Configure a host
Section titled “Configure a host”Store the machine-specific absolute root in Claude’s local project scope:
claude mcp add --scope local gthonragents -- gthonragents mcp --allow-root "$PWD"The Codex CLI command installs a global server definition. Omit a fixed root and let each project session advertise its root or use the server working directory fallback:
codex mcp add gthonragents -- gthonragents mcp{ "mcpServers": { "gthonragents": { "type": "stdio", "command": "gthonragents", "args": ["mcp", "--allow-root", "/absolute/path/to/media"] } }}Authenticate inside MCP
Section titled “Authenticate inside MCP”MCP startup never opens a browser. Existing CLI login is loaded automatically and credentials are refreshed on every tool call.
- Call
gthonragents_auth_status. - If unauthenticated, call
gthonragents_loginand show its verification URL and user code. - After the human completes login, call
gthonragents_login_pollwith the returned session ID. - Call
gthonragents_statusto verify the server and account.
Authorize local files
Section titled “Authorize local files”Effective local file access is the union of:
- repeatable
--allow-rootflags - the platform path list in
GTHONRAGENTS_MCP_FILE_ROOTS - roots advertised by the MCP client
- the process working directory when no other roots are configured
Canonical checks reject path traversal, sibling-prefix confusion, and symlink escape. Keep roots as narrow as possible. HTTP(S) URLs and existing GthonrAgents upload references do not require local access.
Explore the tools
Section titled “Explore the tools”After authentication, ask the host to list the available image models with gthonragents_list_models, then inspect a selected model with gthonragents_model_schema. This verifies discovery and shows the inputs before you request generation.
For a first task, ask: “Use GthonrAgents to generate a product image. Check the current image models and the selected model’s schema first.” The host can then use gthonragents_image_generate. For a local reference image, authorize its directory before asking the host to read or edit it.
See the MCP tool reference for individual tools. Use the CLI reference for operations that the MCP surface does not expose, such as Drive uploads and Page deployments.
Troubleshoot the connection
Section titled “Troubleshoot the connection”| Symptom | What to check |
|---|---|
The host cannot start gthonragents |
Run gthonragents --version in a terminal. If that works, use the executable’s absolute path in the host configuration or restart the host after updating PATH. |
mcp is an unknown command |
Run gthonragents update, then verify gthonragents mcp --help again. |
| Tools are present but authentication fails | Call gthonragents_auth_status and complete the login sequence above. A running server does not by itself confirm account access. |
| A local image or video is rejected | Check that its resolved path is inside an authorized root, including where a symlink points. See local file security. |
| A wrapper breaks the stdio connection | Keep stdout reserved for MCP protocol messages. Send wrapper logs to stderr. |
