docs/dev-guides/agent-context/snowflake-cortex-code.md
Give Cortex Code access to your enterprise data context in DataHub — find trustworthy data, resolve business definitions, trace lineage, and generate better SQL alongside your Snowflake data.
Register DataHub as an MCP server:
cortex mcp add datahub https://<tenant>.acryl.io/integrations/ai/mcp \
--transport=http \
--header "Authorization: Bearer <token>"
Replace <tenant> with your DataHub Cloud tenant name and <token> with your access token.
Start Cortex Code (cortex) and ask questions — it calls DataHub tools automatically:
"Find all tables with customer data in the marketing domain"
"What's the business definition of MRR from our data glossary?"
"Which tables does the finance team own?"
"Write a query for top 10 customers by revenue"
cortex mcp list to verify the server is registered. Check that the URL and token are correct.https://<tenant>.acryl.io/integrations/ai/mcp. Token should start with eyJ.Links: Cortex Code Docs · Agent Context Kit · MCP Server Guide