# Hex MCP Server: Governed AI Access

Hex's MCP server includes 4 different actions available to any connected model or AI agent. When registered with Barndoor, you can ensure centralized governance, visibility, and control across every AI agent your team uses.

## Tools **4**

**Capabilities** [Create](/content/integration-capability/create/index.html), [Read](/content/integration-capability/read/index.html), [Update](/content/integration-capability/update/index.html)

**Category** [Data, Analytics & Code Quality](/content/integration-category/data-analytics-code-quality/index.html)

**Type** Official Remote

## What can AI agents do with the Hex MCP server?

### Tools Available

- **create_thread**  
  Start a new Hex Thread to run data analysis for a user prompt.

- **search_projects**  
  Search published and unpublished Hex projects in the authenticated workspace.

- **get_thread**  
  Poll thread status and fetch messages, charts, and tables from a Hex Thread.

- **continue_thread**  
  Continue an existing Hex Thread with a follow-up analysis prompt.

## Use cases for Hex

### Data Analysis
- Start AI-powered analysis threads
- Iterate on analyses with follow-up prompts
- Retrieve results with charts and tables

### Project Discovery
- Search published and unpublished projects
- Discover analytics projects across workspace
- Access project outputs and metadata

### Thread Management
- Create new analysis threads
- Monitor thread progress and status
- Poll for completed results

### Collaborative Exploration
- Explore data interactively with AI
- Continue threaded analysis conversations
- Fetch analysis conversation history

## What are the risks of using the Hex MCP without an AI gateway?

- **Uncontrolled reads** — AI agents can pull data out of Hex with no visibility into what was accessed.
- **Ungoverned writes** — agents can create or modify records in Hex with no approval step.
- **Destructive actions** — agents can delete or overwrite Hex data with no approval gate or audit trail.
- **Native OAuth is all-or-nothing** — connecting directly grants an agent everything your user account can do in Hex, with no per-tool scoping.

## Why connect Hex with the Barndoor AI gateway?

### Barndoor MCP Governance is the gateway between your AI agents and the tools they use.

| At a glance                                                  | Available?   |
|------------------------------------------------------------|--------------|
| Fine-grained access controls policies per agent, team, role, user, MCP server and tool call | Yes          |
| Approval required before write/destructive actions          | Yes (configurable per role) |
| Full audit log (reads and writes)                          | Yes          |
| Sensitive data detection before it reaches a model or agent| Yes          |
| Instant access revocation                                   | Yes          |
| SOC 2 Type II compliant                                     | Yes          |

### Benefits of Barndoor MCP Governance
- Centralized MCP management — One place to manage and control every MCP server across the organization.
- Universal connection — One universal URL works across every AI provider your team uses.
- Fine-grained access controls — Set access policies for how AI is connecting with Hex.
- Protect sensitive data — Keeps sensitive data from reaching a model or AI agent.
- Observability — Real-time reporting and dashboards for visibility.
- Enterprise-grade security — Stay compliant with audit trails and logging.

## Works with every AI client

[ChatGPT](/content/integrations/chatgpt/index.html)  
 [Claude Code](/content/integrations/claude-code/index.html)  
 [Claude Desktop](/content/integrations/claude-desktop/index.html)  
 [Codex](/content/integrations/codex/index.html)  
 [CrewAI](/content/integrations/crewai/index.html)  
 [Cursor](/content/integrations/cursor/index.html)  
 [Gemini CLI](/content/integrations/gemini-cli/index.html)  
 [GitHub Copilot](/content/integrations/github-copilot/index.html)  
 [Google ADK](/content/integrations/google-adk/index.html)  
 [LangChain](/content/integrations/langchain/index.html)  
 [Microsoft Copilot](/content/integrations/microsoft-copilot/index.html)  
 [OpenClaw](/content/integrations/openclaw/index.html)

## Getting started with Hex in Barndoor

1. Connect the Hex MCP server once
2. Define your policies
3. Go live across every AI client

## Frequently asked questions

### What is MCP?
MCP (Model Context Protocol) is the open standard that lets AI models and agents connect to external tools and data sources through a common interface.

### Is Barndoor secure?
Yes. Barndoor is SOC 2 Type II compliant.

### How are Hex schema changes handled?
Barndoor tracks tool and schema changes on Hex.

### Do you integrate with my identity provider?
Barndoor authenticates admins and policy managers through your OIDC or SAML 2.0 identity provider.

### Can I deploy custom-built MCP servers?
Yes. Barndoor supports customer-built MCPs.

### Can I set and audit tool-level access across teams?
Yes. Barndoor's access control is fine-grained.

### How can I get started with Hex and Barndoor?
Connect Hex once, define your access policies, and go live across every AI client your team uses.
