Skip to main content

AI SDK

The AI SDK gives you programmatic access to OpenMetadata’s MCP tools — use them to build custom AI applications with any LLM by connecting to your metadata catalog. Available across Python, TypeScript, and Java.
Using Collate? You also get access to AI Studio Agents — ready-to-use AI assistants that you can create, manage, and invoke programmatically. See the Collate AI SDK documentation for the full agent capabilities.
You can find the source code for the AI SDK in the GitHub repository. Contributions are always welcome!

Available SDKs

Prerequisites

You need:
  1. An OpenMetadata instance (self-hosted or Collate)
  2. A Bot JWT token for API authentication
To get a JWT token, go to Settings > Bots in your OpenMetadata instance, select your bot, and copy the token.

Configuration

Set the following environment variables:
All environment variables:

Client Initialization


MCP Tools

OpenMetadata exposes an MCP server that turns your metadata into a set of tools any LLM can use. Unlike generic MCP connectors that only read raw database schemas, OpenMetadata’s MCP tools give your AI access to the full context of your data platform — descriptions, owners, lineage, glossary terms, tags, and data quality results. The MCP endpoint is available at POST /mcp using the JSON-RPC 2.0 protocol.

Available Tools

Using MCP Tools Directly

You can call MCP tools directly through the SDK client:

LangChain Integration

Convert OpenMetadata’s MCP tools to LangChain format with a single method call. This lets you use your metadata as tools in any LangChain agent.

Tool Filtering

Control which tools are exposed to your LLM by including or excluding specific tools. This is useful for restricting agents to read-only operations or limiting scope.

Multi-Agent Orchestrator

Build a multi-agent system where specialist agents each get focused MCP tools:

OpenAI Integration

Convert MCP tools to OpenAI function calling format: