Skip to main content
Version: Next

Universal Tool Calling Protocol (UTCP)

Language Examples

UTCP is available in multiple languages - see Python, TypeScript, Go, and other implementations in the UTCP GitHub organization.

UTCP is a lightweight, secure, and scalable standard that enables AI agents and applications to discover and call tools directly using their native protocols - no wrapper servers required.

Why UTCP?

The Problem with Current Approaches

Most tool integration solutions force you to:

  • Build and maintain wrapper servers for every tool
  • Route all traffic through a middleman protocol
  • Reimplement existing authentication and security
  • Accept additional latency and complexity

The UTCP Solution

UTCP acts as a "manual" that tells agents how to call your tools directly:

Core Philosophy

"If a human can call your API, an AI agent should be able to call it too - with the same security and no additional infrastructure."

OpenAPI Compatibility

UTCP extends OpenAPI for AI agents while maintaining full backward compatibility. Where OpenAPI describes APIs for human developers, UTCP adds agent-focused enhancements: tags for categorization, average_response_size for resource planning, multi-protocol support (HTTP, CLI, gRPC, MCP), and direct execution instructions. Existing OpenAPI specs can be automatically converted to UTCP manuals without requiring API changes or additional infrastructure.

Quick Start (5 Minutes)

1. Install UTCP

# Example installation (Python)
pip install utcp utcp-http

# Example installation (Node.js)
npm install @utcp/core @utcp/http

# See language-specific documentation for other implementations

2. Expose Your First Tool

Option A: Discovery via existing OpenAPI spec

Generate OpenAPI endpoint: GET http://api.github.com/openapi.json

Option B: Add a discovery endpoint to your existing API

Add endpoint: GET /utcp Return your UTCP manual:

{
"manual_version": "1.0.0",
"utcp_version": "1.0.1",
"tools": [{
"name": "get_weather",
"description": "Get current weather for a location",
"inputs": {
"type": "object",
"properties": {"location": {"type": "string"}},
"required": ["location"]
},
"tool_call_template": {
"call_template_type": "http",
"url": "http://localhost:8000/weather",
"http_method": "GET"
}
}],
"auth": {
"auth_type": "api_key",
"api_key": "${WEATHER_API_KEY}",
"var_name": "appid",
"location": "query"
}
}

3. Call Your Tool

Option A: Configure UTCP client:

{
"manual_call_templates": [{
"name": "weather_api",
"call_template_type": "http",
"url": "http://localhost:8000/utcp", // Or http://api.github.com/openapi.json, the openapi spec gets converted automatically
"http_method": "GET"
}]
}

Option B: Convert OpenAPI spec to UTCP manual manually

async def convert_api():
async with aiohttp.ClientSession() as session:
async with session.get("https://api.github.com/openapi.json") as response:
openapi_spec = await response.json()

converter = OpenApiConverter(openapi_spec)
manual = converter.convert()

print(f"Generated {len(manual.tools)} tools from GitHub API!")
return manual

Then save that to a text file and load it with the text configuration:

{
"manual_call_templates": [{
"name": "github_manual",
"call_template_type": "text",
"file_path": "./github_manual.json",
}]
}

Call the tool:

  1. Initialize UTCP client with configuration
  2. Discover tools from weather API
  3. Call get_weather tool with location parameter
  4. Receive weather data response

That's it! Your tool is now discoverable and callable by any UTCP client.

Key Benefits

BenefitDescription
🚀 Zero Latency OverheadDirect tool calls, no proxy servers
🔒 Native SecurityUse your existing authentication and authorization
🌐 Protocol FlexibilityHTTP, MCP, CLI, GraphQL, and more
⚡ Easy IntegrationAdd one endpoint, no infrastructure changes
📈 ScalableLeverage your existing scaling and monitoring

How It Works

  1. Discovery: Agent fetches your UTCP manual
  2. Learning: Agent understands how to call your tools
  3. Direct Calling: Agent calls your API directly using native protocols
  4. Response: Your API responds normally

Supported Protocols

UTCP supports multiple communication protocols through plugins:

ProtocolUse CasePluginStatus
HTTPREST APIs, webhooksutcp-http✅ Stable
CLICommand-line toolsutcp-cli✅ Stable
Server-Sent EventsStreaming datautcp-http✅ Stable
Text FilesFile readingutcp-text✅ Stable
MCPMCP interoperabilityutcp-mcp✅ Stable

View all protocols →

Architecture Overview

UTCP v1.0 features a modular, plugin-based architecture:

Core Components

Plugin System

  • Protocol Plugins: HTTP, MCP, CLI, etc.
  • Custom Protocols: Extend with your own communication methods
  • Tool Repositories: Pluggable storage for tool definitions
  • Search Strategies: Customizable tool discovery algorithms

Learn more about the architecture →

Who Should Use UTCP?

🛠️ Tool Providers

You have APIs, services, or tools that you want AI agents to use:

  • Existing API owners - Expose your REST APIs to AI agents
  • SaaS providers - Make your services AI-accessible
  • Enterprise teams - Enable internal tool usage by AI systems

Get started as a tool provider →

🤖 Tool Consumers

You're building AI agents or applications that need to call external tools:

  • AI agent developers - Give your agents access to external capabilities
  • Application builders - Integrate third-party tools seamlessly
  • Enterprise developers - Connect to internal and external services

Get started as a tool consumer →

UTCP vs Alternatives

FeatureUTCPMCPCustom Wrappers
InfrastructureNone requiredWrapper serversCustom servers
LatencyDirect callsDouble hopVariable
SecurityNativeReimplementedCustom
ProtocolsMultipleHTTP streamingSingle
MaintenanceMinimalHighVery high

Detailed comparison with MCP →

Next Steps

For Tool Providers

  1. Read the provider guide - Learn how to expose your tools
  2. Choose your protocol - Select the right communication method
  3. Implement your manual - Add UTCP to your existing API
  4. Secure your tools - Implement proper authentication

For Tool Consumers

  1. Read the implementation guide - Learn how to build UTCP clients
  2. Explore protocols - Understand available communication options
  3. Check examples - See real-world implementations
  4. Join the community - Get help and share experiences

Migration from Other Systems

Community & Support


Ready to get started? Choose your path: