Python UTCP
Official python implementation of UTCP. UTCP is an open standard that lets AI agents call any API directly, without extra middleware.
What is Python UTCP?
Python UTCP is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to official python implementation of utcp. utcp is an open standard that lets ai agents call any api directly, without extra middleware.
Official python implementation of UTCP. UTCP is an open standard that lets AI agents call any API directly, without extra middleware.
This server falls under the APIs category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- Official python implementation of UTCP. UTCP is an open stan
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx python-utcpConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Python UTCP
Python UTCP is the official Python implementation of the Universal Tool Calling Protocol (UTCP), an open standard that lets AI agents call any API directly without extra middleware or custom server wrappers. It supports HTTP/REST (with automatic OpenAPI 2.0/3.0 ingestion), CLI commands, WebSocket, MCP, and text-based tool definitions through a unified plugin architecture. Developers use it to connect AI agents to real-world APIs in a standardized way, eliminating the need to write bespoke adapters for every integration.
Prerequisites
- Python 3.9+ installed
- pip for installing packages (utcp core and desired protocol plugins)
- API credentials for the external services you plan to call (e.g., API keys)
- An MCP client such as Claude Desktop, Cursor, or Claude Code to consume the server
Install the UTCP core and HTTP plugin
Install the utcp core package plus the communication-protocol plugin(s) you need. The HTTP plugin is the most common choice for REST APIs and includes automatic OpenAPI ingestion.
pip install utcp utcp-httpInstall additional protocol plugins as needed
Install optional plugins for CLI commands, WebSocket, or MCP bridging depending on the APIs you want to expose to your AI agent.
pip install utcp-cli utcp-mcp utcp-text utcp-websocketCreate a UTCP client configuration
Define your API endpoints in a configuration object. Use the call_template_type field to select the protocol and authenticate via api_key, bearer, basic, or oauth2 auth types. Environment variables are substituted using ${VARIABLE_NAME} syntax.
from utcp.utcp_client import UtcpClient
import asyncio
async def main():
client = await UtcpClient.create(config={
"manual_call_templates": [{
"name": "my_api",
"call_template_type": "http",
"url": "https://api.example.com/utcp",
"auth": {
"auth_type": "api_key",
"api_key": "Bearer ${API_KEY}",
"var_name": "Authorization",
"location": "header"
}
}],
"load_variables_from": [{
"variable_loader_type": "dotenv",
"env_file_path": ".env"
}]
})
result = await client.call_tool("my_api.tool_name", {"param": "value"})
print(result)
asyncio.run(main())Ingest an OpenAPI spec automatically
Use the built-in OpenAPI converter to automatically turn any OpenAPI 2.0 or 3.0 specification into UTCP tools without modifying the target server.
from utcp_http.openapi_converter import OpenApiConverter
import json
with open("openapi.json") as f:
openapi_spec = json.load(f)
converter = OpenApiConverter(openapi_spec)
manual = converter.convert()
# Pass `manual` into UtcpClient config as a manual_call_templateExpose tools to an MCP client
Install the utcp-mcp plugin and configure your MCP client to launch the UTCP bridge. The bridge translates MCP tool-call requests into UTCP calls and returns results in MCP format.
pip install utcp-mcpConfigure your MCP client
Add the UTCP MCP bridge to your MCP client configuration file, pointing it at your UTCP config and the API key environment variable.
Python UTCP Examples
Client configuration
Add the UTCP MCP bridge to Claude Desktop or another MCP client so AI agents can call APIs via UTCP.
{
"mcpServers": {
"utcp": {
"command": "python",
"args": ["-m", "utcp_mcp.server", "--config", "/path/to/utcp_config.json"],
"env": {
"API_KEY": "your-api-key-here"
}
}
}
}Prompts to try
Example prompts to use once UTCP is connected to your MCP client and pointed at a real API.
- "List all available tools from the connected API"
- "Call the search tool on my API with the query 'machine learning'"
- "Fetch the weather for New York using the weather API tool"
- "Use the REST API to create a new record with these fields: name=Test, status=active"Troubleshooting Python UTCP
Variable substitution fails with KeyError for ${MY_VAR}
Ensure the .env file path in load_variables_from is correct and the variable name matches exactly (case-sensitive). Variables in named templates are namespaced as manual__name_VARIABLE_NAME with a double underscore.
Protocol restriction error when calling a tool from a different protocol type
By default a manual can only call tools of its own protocol type. Add the allowed_communication_protocols field to your config: {"allowed_communication_protocols": ["http", "cli", "mcp"]}.
OpenAPI ingestion skips some endpoints
Verify the spec is valid OpenAPI 2.0 or 3.0 JSON/YAML. The converter does not support OpenAPI 3.1 or custom extensions. Check that endpoint paths have operationId fields defined.
Frequently Asked Questions about Python UTCP
What is Python UTCP?
Python UTCP is a Model Context Protocol (MCP) server that official python implementation of utcp. utcp is an open standard that lets ai agents call any api directly, without extra middleware. It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Python UTCP?
Follow the installation instructions on the Python UTCP GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with Python UTCP?
Python UTCP works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Python UTCP free to use?
Yes, Python UTCP is open source and available under the MPL-2.0 license. You can use it freely in both personal and commercial projects.
Python UTCP Alternatives โ Similar APIs Servers
Looking for alternatives to Python UTCP? Here are other popular apis servers you can use with Claude, Cursor, and VS Code.
Kong
โ 43.4k๐ฆ The API and AI Gateway
API Mega List
โ 5.4kThis GitHub repo is a powerhouse collection of APIs you can start using immediately to build everything from simple automations to full-scale applications. One of the most valuable API lists on GitHubโperiod. ๐ช
Fetch
โ 5.4kFetch web content and convert to markdown for AI consumption
Fusio
โ 2.1kSelf-Hosted API Management for Builders
Korean Law
โ 1.8k๊ตญ๊ฐ๋ฒ๋ น์ ๋ณดMCP v4.0 | ๋ฒ์ ์ฒ 41๊ฐ API โ 17๊ฐ MCP ๋๊ตฌ. ๋ฒ๋ นยทํ๋กยท์กฐ๋ก ๊ฒ์ + LLM ํ๊ฐ ๋ฐฉ์ง ์ธ์ฉ๊ฒ์ฆ + ์กฐ๋ฌธ ์ํฅ ๊ทธ๋ํ(impact_map) + ์์ ๋น๊ต ์๋ diff(time_travel) + ์๋ฏผ 5๋จ๊ณ ์คํ ๊ฐ์ด๋(action_plan) | 41 Korean legal APIs โ 17 MCP tools
RuleGo
โ 1.5kโ๏ธRuleGo is a lightweight, high-performance, embedded, next-generation component orchestration rule engine framework for Go.
Browse More APIs MCP Servers
Explore all apis servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Python UTCP in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use Python UTCP?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.