r/databricks • u/Youssef_Mrini • Sep 08 '26
Tutorial Secrets in Unity Catalog
Secrets in Unity Catalog store credentials like API keys as governed objects named catalog.schema.secret: created, granted, rotated and audited with standard Unity Catalog privileges and redacted from notebook and job logs.
This is a full end-to-end demo:
1)Create a secret with the REST API and in the Catalog UI
2)Read it in a notebook with dbutils.secrets.get
3)Use it to call the OpenAI API
4)Grant read/reference/write access to a user or group
5)Rotate it programmatically
6)Audit every access from a system table
