universal-tool-calling-protocol/python-utcp

Official python implementation of UTCP. UTCP is an open standard that lets AI agents call any API directly, without extra middleware.

What it solves

UTCP provides a standardized, secure, and scalable way to define and interact with tools across different communication protocols. It eliminates the need to write custom integration code for every new tool or service, allowing AI agents and applications to interact with a wide variety of external APIs, CLI tools, and other protocols using a single, unified interface.

How it works

UTCP uses a modular architecture consisting of a core library and a set of pluggable protocol plugins. The core library handles the high-level logic of tool discovery, interaction, and search, while the plugins implement the specific communication details for different protocols.

  • Core Package: Manages data models (using Pydantic), the UtcpClient for tool interaction, and the plugin system.
  • Protocol Plugins: Implement specific communication methods, such as HTTP/REST, SSE, CLI, MCP (Model Context Protocol), and local text files.
  • Call Templates: Tools are defined using "call templates" that specify how to reach the tool (e.g., URL, HTTP method, CLI command) and how to authenticate.
  • UtcpManual: A discovery document that describes the available tools, their inputs, and outputs, allowing clients to discover tools dynamically.

Who it’s for

Developers building AI agents, LLM-powered applications, and systems that require a scalable way to integrate multiple external tools and services across diverse communication protocols.

Highlights

  • Multi-Protocol Support: Out-of-the-box support for HTTP, SSE, CLI, and MCP, with planned support for TCP/UDP and GraphQL.
  • Pluggable Architecture: Easily add new communication protocols, tool storage, and search strategies without modifying the core library.
  • Symmetric Discovery: Tools can be provided via a UtcpManual for automatic discovery by the UtcpClient.
  • Secure by Default: Includes protocol restrictions to prevent dangerous protocol escalation (e.g., preventing an HTTP-based manual from calling CLI tools).
  • Flexible Authentication: Supports various authentication methods including API keys, Basic Auth, and OAuth2.

Related

  • Project
  • Project
  • Project
  • Project