awslabs / awslabs/agentcore-samples
[Sample request] Databricks Genie via Amazon Bedrock AgentCore Gateway (MCP)
- Dominant language
- Python
- Stars
- 3.4k
- Forks
- 1.3k
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 30
Description
# [Sample request] Databricks Genie via Amazon Bedrock AgentCore Gateway (MCP)
## Description
I'd like to contribute a new integration sample that exposes a **Databricks Genie** space as a governed MCP tool to Amazon Bedrock agents through **Amazon Bedrock AgentCore Gateway**.
The sample complements the two existing Databricks integrations in `03-integrations/data-platforms/`:
- [`databricks-dbsql-agentcore-gateway`](https://github.com/awslabs/agentcore-samples/tree/main/03-integrations/data-platforms/databricks-dbsql-agentcore-gateway) — Databricks SQL MCP via Gateway with M2M auth
- [`databricks-dbsql-per-user-delegation`](https://github.com/awslabs/agentcore-samples/tree/main/03-integrations/data-platforms/databricks-dbsql-per-user-delegation) — Per-user delegation via RFC 8693 token exchange
The new sample adds the **Genie** surface — Databricks' natural-language analytics layer grounded in Unity Catalog Trusted Assets — so Bedrock agents can ask plain-English business questions and get governed, lakehouse-native SQL answers without a custom NL-to-SQL chain.
## Proposed location
`03-integrations/data-platforms/databricks-genie-agentcore-mcp/`
## What the sample demonstrates
- Register the [Databricks-managed Genie MCP endpoint](https://docs.databricks.com/en/generative-ai/mcp/managed-mcp.html) (`/api/2.0/mcp/genie/{space_id}`) as a target in AgentCore Gateway
- AWS Secrets Manager stores Databricks OAuth M2M credentials; AgentCore Gateway fetches them at tool-invocation time
- IAM role for the gateway target (Terraform-provisioned)
- Optional local MCP proxy (FastAPI) for development
- Sample prompts a Bedrock agent can ask Genie (aggregate, trend, cohort, comparative, metric lookup)
- Unity Catalog governance + CloudWatch trace validation steps
- Clean-up steps to tear down provisioned resources
## Why this matters
The two existing Databricks samples target `databricks-dbsql` (raw SQL execution). Genie sits one layer above — it converts natural-language questions into governed SQL using curated Trusted Assets. That makes it the more natural surface for agentic use cases where the agent's caller is a business user rather than a developer.
## Deliverable structure (follows the existing Databricks sample pattern)
```
03-integrations/data-platforms/databricks-genie-agentcore-mcp/
├── README.md
├── databricks_genie_agentcore_mcp.ipynb
└── images/
└── architecture.png
```
## Checklist
- [x] Reviewed CONTRIBUTING.md and the required PR template sections (Introduction, Architecture Diagram, Prerequisites, Usage, Sample Prompts, Clean Up)
- [x] Will add my name to CONTRIBUTORS.md in the PR
- [x] Sample is self-contained — no external dependencies beyond the documented AWS + Databricks accounts
- [x] No proprietary information; all configuration values are placeholders
I'll open the PR shortly and attach the `review ready` label once CI is green.
Contributor guide
Research direction
Start by reading CONTRIBUTING.md and the two existing Databricks samples in 03-integrations/data-platforms/. Use their README files and notebooks as the pattern for the proposed databricks-genie-agentcore-mcp/README.md and databricks_genie_agentcore_mcp.ipynb, including the listed architecture, prerequisites, usage, prompts, and cleanup. Done means the self-contained sample and images/architecture.png are added with documented AWS and Databricks configuration.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, fastapi, python, terraform
- Domain
- api, cloud, documentation, infrastructure
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100