transfer-ai-mcp
Provides tools for text generation and image generation via OpenAI-compatible API endpoints, allowing AI agents to generate text and images using configured models.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@transfer-ai-mcpGenerate an image of a futuristic city"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
transfer-ai-mcp
transfer-ai-mcp is a small MCP server for relay or proxy AI endpoints. It reads configuration from environment variables and exposes tools for text generation and image generation.
Features
Supports
openai-style andgemini-style HTTP APIsConfigurable
url,key, andmodelthrough environment variablesSaves generated images locally and returns file paths (no base64 in MCP response)
Packaged as a standalone Node library for reuse on other machines
Related MCP server: gemini-image-mcp
Changelog
v0.2.0
Fix:
generate_imageno longer returns base64 image data in MCP response. This fixes a crash in MCP clients (e.g. Kiro) that occurred when processing large image payloads in subsequent turns. Images are saved to disk and only file paths are returned.Change: Default
TRANSFER_AI_API_FORMATchanged fromopenaitogemini.Response now includes file size info for each saved image.
v0.1.0
Initial release.
Install
npm installFor a global install:
npm install -g .Then run:
transfer-ai-mcpEnvironment variables
Required:
TRANSFER_AI_API_KEYTRANSFER_AI_BASE_URLunless you useTRANSFER_AI_TEXT_URLandTRANSFER_AI_IMAGE_URLTRANSFER_AI_MODELunless you set bothTRANSFER_AI_TEXT_MODELandTRANSFER_AI_IMAGE_MODEL
Optional:
TRANSFER_AI_API_FORMATopenaiorgeminidefault:
gemini
TRANSFER_AI_AUTH_MODEbearer,query,x-goog-api-key, ornonedefault:
bearer
TRANSFER_AI_TEXT_MODELTRANSFER_AI_IMAGE_MODELTRANSFER_AI_TEXT_URLTRANSFER_AI_IMAGE_URLTRANSFER_AI_TEXT_PATHTRANSFER_AI_IMAGE_PATHTRANSFER_AI_OUTPUT_DIR
Default endpoint behavior
If TRANSFER_AI_API_FORMAT=openai:
text requests default to
/v1/chat/completionsimage requests default to
/v1/chat/completions
If TRANSFER_AI_API_FORMAT=gemini:
text requests default to
/v1beta/models/{model}:generateContentimage requests default to
/v1beta/models/{model}:generateContent
Override any of these with TRANSFER_AI_TEXT_URL, TRANSFER_AI_IMAGE_URL, TRANSFER_AI_TEXT_PATH, or TRANSFER_AI_IMAGE_PATH.
Tools
get_configuration_statusgenerate_textgenerate_imageget_last_image_info
generate_text arguments:
promptsystemPromptmodeltemperaturemaxTokensextraBody
generate_image arguments:
promptsystemPromptmodelaspectRatioimageSizeoutputPathextraBody
Kiro / VS Code MCP example
{
"mcpServers": {
"transfer-ai": {
"command": "node",
"args": ["/path/to/transfer-ai-mcp/dist/index.js"],
"env": {
"TRANSFER_AI_API_FORMAT": "gemini",
"TRANSFER_AI_AUTH_MODE": "bearer",
"TRANSFER_AI_API_KEY": "your-api-key",
"TRANSFER_AI_BASE_URL": "https://your-endpoint.example.com",
"TRANSFER_AI_MODEL": "gemini-2.0-flash-preview-image-generation",
"TRANSFER_AI_OUTPUT_DIR": "/path/to/output/images"
},
"disabled": false,
"autoApprove": ["generate_image", "get_configuration_status"]
}
}
}Codex MCP example
This server cannot be deployed
Maintenance
Related MCP Connectors
MCP server for AI dialogue using various LLM models via AceDataCloud
MCP server for Qwen Image 3 AI image generation
Focused MCP server for OpenAI image/audio generation (v2.0.0). Wraps endpoints via HAPI CLI.
- ArcjetOAuthcom.arcjet
An MCP server for Arcjet - the runtime security platform that ships with your AI code.
Related MCP Servers
- AlicenseAqualityDmaintenanceAn MCP server that enables AI applications to access 20+ model providers (including OpenAI, Anthropic, Google) through a unified interface for text and image generation.230MIT
- AlicenseBqualityCmaintenanceAn MCP server for image generation using the Gemini API.133 npm2MIT
- FlicenseAqualityDmaintenanceMCP server that generates images using Gemini models via an OpenAI-compatible gateway.19-
- AlicenseAqualityDmaintenanceA multi-provider MCP server that enables AI agents to generate and edit images across OpenAI, Google Gemini, Azure, Vertex, and OpenRouter with a unified API.317Apache 2.0