Skip to content

Controlling what a model serving endpoint is allowed to access

Model serving endpoints run inference code that often needs to call other resources (Unity Catalog tables/functions, vector search indexes, external APIs, MLflow artifacts) on behalf of the deployed model, so Databricks provides mechanisms to securely pass credentials to the endpoint without hardcoding secrets. Access control is managed primarily through Databricks secrets and endpoint-level permissions, ensuring the serving environment can authenticate to dependent resources while following least-privilege principles.

1 · Learn the must-know

  • Model serving endpoints execute in a secure, isolated environment separate from the workspace, so they cannot automatically inherit a user's or notebook's ambient credentials and must be explicitly configured with access.
  • Databricks Secrets (secret scopes) should be used to store API keys, tokens, or credentials needed by the model at inference time rather than embedding them in model code or environment variables in plaintext.
  • Serving endpoints can be granted access to Unity Catalog resources via the endpoint's service principal or the identity under which it runs, and permissions must be explicitly granted on the underlying tables, functions, or indexes.
  • Endpoint permissions (CAN VIEW, CAN QUERY, CAN MANAGE) control who can invoke, view, or modify the serving endpoint itself, and should be scoped to the minimum necessary role for each user or group.
  • When a model needs to call external services (e.g., third-party APIs), credentials should be injected via environment variables backed by secrets at endpoint creation/update time rather than baked into the model artifact.
  • Using a dedicated service principal for the serving endpoint (rather than a personal user identity) is the recommended pattern for production deployments to ensure stable, auditable, and least-privilege access to dependent resources.

2 · Check your understanding

Check this objectiveFree · always available

A Generative AI Engineer is deploying a RAG chatbot as a Mosaic AI Agent Framework serving endpoint. The endpoint calls a third-party embedding API that requires an API key, and the engineer must ensure the key never appears in the logged model artifact, notebook code, or request payloads. Which approach should the engineer use to supply the key to the endpoint at runtime?

Your objective map0 tried · 0 answered correctly · 56 untouched

What you have tried across Databricks GenAI Engineer's objectives, not a readiness score.

Design Applications10.71% of the exam*0 of 6 tried
Data Preparation14.29% of the exam*0 of 8 tried
Application Development23.21% of the exam*0 of 13 tried
Assembling and Deploying Applications26.79% of the exam*0 of 15 tried
Governance7.14% of the exam*0 of 4 tried
Evaluation and Monitoring17.86% of the exam*0 of 10 tried

* Our estimate. Databricks publishes no section weights.

3 · Keep going