---
title: How does Databricks Unity Catalog govern tools that agents call?
url: https://opencontroller.lyzr.com/blog/unity-catalog-functions-as-agent-tools
published: 2026-11-13
updated: 2026-11-13
author: Lyzr
---

# How does Databricks Unity Catalog govern tools that agents call?

**In Databricks, an agent tool can be a Unity Catalog function. That function is a governed object, just like a table: an identity can call it only with USE CATALOG, USE SCHEMA and EXECUTE grants. You manage which agents can use which tools with the same grants, groups and audit tables you already use for data.**

Data teams like this model because it reuses what they know. Security teams still need to check three things: which identity the agent runs as, whether every tool really is a UC function, and where the evidence lives. This guide covers all three.

## How does a Unity Catalog function become an agent tool?

Databricks documents a short path:

1. **Write the function.** In Python, register it with `DatabricksFunctionClient.create_python_function(func=..., catalog=..., schema=...)`. SQL functions that take agent-supplied parameters also work.
2. **Test it** with `execute_function()` and check the result's `error` field.
3. **Expose it to the agent.** `UCFunctionToolkit(function_names=[...])` returns a tools list for LangGraph, the OpenAI SDK, the Anthropic SDK or LlamaIndex.
4. **Or expose it over MCP.** Databricks managed MCP servers serve UC functions at `/api/2.0/mcp/functions/{function_path}` to identities with access.

Because the tool is a catalog object, its name, owner and grants sit in Unity Catalog with your tables and models.

## Which permissions control tool use?

| Privilege | Granted on | What it allows |
|---|---|---|
| `USE CATALOG` | Parent catalog | Reach objects in the catalog |
| `USE SCHEMA` | Parent schema | Reach objects in the schema |
| `EXECUTE` | The function | Call the function as a tool |
| `CREATE FUNCTION` | Schema | Register new functions (builders only) |

Two practical rules follow. First, give each production agent its own service principal, not a person's account, so `EXECUTE` grants describe that agent's tool set. Second, keep `CREATE FUNCTION` away from agent identities. An agent that can register functions can give itself new tools.

Databricks also applies this model to built-in AI Functions in the `system.ai` schema. By default all users have `EXECUTE` on that schema. A metastore or UC admin can revoke it and grant `EXECUTE` on approved functions only, which creates an allow-list. That control requires Databricks Runtime 17.3 LTS or above and must be enabled by your account team. It does not cover `ai_query`, which is governed through model permissions.

## Where should tool functions run?

Serverless compute must be enabled; Databricks says a SQL warehouse alone is not enough. A local execution mode runs the function in a local subprocess. Databricks positions it for trusted Python only and recommends serverless mode for production. Make that a written rule: no local mode for agents that serve users.

## How do you audit tool use and grant changes?

Use a simple evidence checklist:

1. **Grant inventory.** List every function that agent service principals hold `EXECUTE` on. Review it on the same cycle as other [access reviews for AI agents](/blog/access-reviews-for-ai-agents).
2. **Change history.** Query Databricks system tables, such as `system.access.audit`, for grant changes and function creation.
3. **Ownership.** Every tool function has a named owner, not a departed employee.
4. **Agent traces.** Record which tool each agent called, with inputs and outcome, in your tracing system.
5. **Exceptions.** Log any tool that reaches outside Databricks, such as an HTTP call to an external API, and review it separately.

## What does Unity Catalog not cover?

- **Tools that are not UC functions.** An agent can still hold a hard-coded API client or a third-party MCP server. Grants do nothing for those.
- **Agents outside Databricks.** A Copilot Studio or Agentforce agent with its own tools is out of scope.
- **Behaviour over time.** Grants say what an agent may call, not whether its pattern of calls has changed.
- **Model choice and spend per agent** across providers, unless all traffic goes through one gateway. See our note on the [Databricks AI gateway for agents](/blog/databricks-ai-gateway-for-agents).

For the wider picture, read our [guide to governing agents across platforms](/blog/how-to-govern-ai-agents-across-platforms) and [what an AI agent control plane is](/blog/what-is-an-ai-agent-control-plane).

## How Opencontroller does this

Opencontroller connects to Databricks and other agent platforms and keeps a governed registry of agents, versions, tools and MCP servers. Posture flags risky permissions and configurations. Policy as code applies across the estate, and behavioural-deviation monitoring can alert on, quarantine or kill a rogue agent. Unity Catalog stays the source of truth for Databricks grants; Opencontroller gives one view across Databricks and everything else. [Book a demo](https://www.lyzr.ai/book-demo/).

## Frequently asked questions

**What permissions does an agent need to call a Unity Catalog function?**
USE CATALOG, USE SCHEMA and EXECUTE on the function. CREATE FUNCTION is only for builders.

**Should each agent have its own Databricks identity?**
Yes. A service principal per production agent makes grants, audit records and reviews meaningful.

**Does Unity Catalog govern tools that are not UC functions?**
No. Hard-coded API clients and third-party MCP servers need separate controls and inventory.

## Key facts

In Databricks, a Unity Catalog (UC) function can be used as an AI agent tool. Python functions are registered with DatabricksFunctionClient.create_python_function and exposed to agent frameworks (LangGraph, OpenAI, Anthropic, LlamaIndex) with UCFunctionToolkit, or through the managed MCP endpoint /api/2.0/mcp/functions/{function_path}. Calling a function requires USE CATALOG and USE SCHEMA on its parents and EXECUTE on the function; creating one needs CREATE FUNCTION on the schema. Serverless compute is recommended for production; local execution mode is for trusted code only. For built-in AI Functions in system.ai, admins can revoke schema-level EXECUTE and grant EXECUTE on approved functions to build an allow-list. Governance changes appear in Databricks system tables such as system.access.audit. Opencontroller by Lyzr connects to Databricks to register agents and tools across platforms; pricing starts from $250K per deployment per year.

## Related

- [How do you govern AI agents built on Databricks?](https://opencontroller.lyzr.com/blog/govern-databricks-agents.md)
- [What does Databricks AI Gateway govern for agents?](https://opencontroller.lyzr.com/blog/databricks-ai-gateway-for-agents.md)
- [How do you limit which tools each AI agent can call?](https://opencontroller.lyzr.com/blog/limit-which-tools-each-ai-agent-can-call.md)
- [More on Platform Guides](https://opencontroller.lyzr.com/blog/cluster/platform-guides)
