> ## Documentation Index
> Fetch the complete documentation index at: https://docs.open-metadata.org/llms.txt
> Use this file to discover all available pages before exploring further.

# Building Blocks of Authorization - Rules, Policies, and Roles

> Understand authorization policies to manage read, write, and discover permissions for users and service accounts.

# Building Blocks of Authorization: Rules, Policies, and Roles

OpenMetadata controls access through three building blocks: rules define what is allowed or denied, policies group rules together and apply them to teams, and roles bundle policies into job-function templates you can assign to users. Every access decision OpenMetadata makes comes down to three questions: who is the user, what are they trying to access, and what do they want to do with it?

## Rules

A rule in a policy is the building block of authorization. It contains the following:

* **Name**: A unique name for the rule.
* **Description**: A description of the rule.
* **Resources**: The resources to which the rule applies. Select a specific resource, such as `Table`, or select `All` to apply the rule to every resource.
* **Operations**: The operations to which the rule applies. Select a specific operation, such as `EditOwners`, or select `All` to apply the rule to every operation.
* **Effect**: Determines whether the rule allows or denies the selected operations.
* **Condition**: An expression that uses policy functions and evaluates to true or false.

![Building Blocks of Authorization: Rules](https://mintcdn.com/openmetadata/hh5nHFImSbxUEO9H/public/images/how-to-guides/roles-policies/rules3.png?fit=max\&auto=format\&n=hh5nHFImSbxUEO9H\&q=85\&s=faf31bfa425eaeecaab15495d1dce426)

### Operations

When you build a rule, you pick one or more operations to cover. Each operation
controls a specific action – for example, `ViewAll`, `EditTags`, or `Delete`.
Operations vary in risk level, from low-risk viewing permissions to critical
admin-only actions like `Impersonate`, `EditPolicy`, `EditRole`, and `GenerateToken`.

For a reference for common operations, risk levels, and recommended role assignments, see
[Resource scope and operations reference](https://docs.open-metadata.org/v2.1.x/how-to-guides/admin-guide/roles-policies/resource-scope.md).

> [!WARNING]
>
> **Important**: `EditAll` overrides every other edit permission. Only use it when full editing access is intentional – otherwise assign the specific edit operations you need.

`EditDomains` controls changing the domains of an asset. A rule that allows `EditAll` also allows `EditDomains`, so existing policies keep working. To stop a role from reassigning domains, add a Deny rule with `EditDomains`.

### Condition

Conditions let you make a rule apply only when certain things are true about the asset being accessed. For example, you can write a rule that only applies to assets tagged as `PII.Sensitive`, or only to assets that don't have an owner yet.

OpenMetadata uses SpEL-based expressions for conditions. For more information about SpEL expressions, see [Spring Expression Language (SpEL)](https://docs.spring.io/spring-framework/docs/3.0.x/reference/expressions.html).

Following are some examples of conditions:

| Condition | Applies when… |
| - | - |
| `noOwner()` | The asset has no assigned owner |
| `isOwner()` | The person accessing it is the owner |
| `matchAllTags(tagFqn, ...)` | The asset carries all of the tags listed |
| `matchAnyTag(tagFqn, ...)` | The asset carries at least one of the tags listed |
| `matchTeam()` | The user belongs to the team that owns the asset |
| `hasDomain()` | The asset has no domain, or the requesting user or bot shares a domain (or a sub-domain of one) with it |

#### Use `hasDomain()` With Bots

`hasDomain()` evaluates the domains on the requesting principal. For a bot request, the principal is the user account associated with that bot. Assigning a domain only to the asset does not give the bot access.

For example, a bot with a policy that allows `ViewBasic` only when `hasDomain()` is true receives a `403 [ViewBasic] not allowed` response when the asset belongs to **Finance** but the bot user does not. To resolve the error:

1. Open **Settings** > **Bots**, select the bot, and identify its associated bot user.
2. In **Settings** > **Members** > **Users**, open the bot user's profile.
3. Add the asset's domain in the **Domains** card. An administrator must make this change.
4. Retry the request after the domain assignment is saved.

If the bot must read assets across domains, use a separate policy without the `hasDomain()` condition. Limit its resources and operations to the minimum required. Removing the condition allows the rule to match resources outside the bot's domains.

RBAC Search supports only some of these conditions. It evaluates `noOwner()`, `isOwner()`, `matchAllTags()`, `matchAnyTag()`, `hasDomain()`, and `inAnyTeam()`, and it ignores `matchTeam()` when it filters search results. Access to the asset itself still honors `matchTeam()`.

To limit search results by team, use `isOwner()`. In search, it also matches assets owned by any team the user belongs to. The `inAnyTeam('<team>')` condition checks only the user's team membership: if the user is in that team, it matches every asset.

Use conditions to assess data assets like Tables, Topics, and Dashboards for specific attributes.

Example: Consider the noOwner() condition when applied to the table **fact\_orders**. If this table lacks an assigned owner, then the condition returns **true**. However, if an owner is present, it returns **false**.

Another instance: The ***matchAnyTag('PII.Sensitive')*** condition, when applied to the **dim\_address** table that carries the PII.Sensitive tag, will yield **true**. But, without this specific tag, the outcome is **false**.

You can combine conditions with `&&` (both must be true) or `||` (either can be true). For example:

```
noOwner() && matchAllTags('PersonalData.Personal', 'Tier.Tier1')
```

This condition is true only if the asset has no owner and carries both of the listed tags.

#### Control Domain Changes

When a policy uses `hasDomain()`, adding or moving an asset into a domain also requires the caller to hold that target domain. OpenMetadata checks each domain you add on its own. Holding domain A does not allow adding domain B next to it. Adding a sub-domain of a held domain is allowed.

The check runs on every write path: PATCH, PUT, bulk PUT, test case PATCH, and CSV import. A CSV dry run reports the rows the import will refuse. A change that moves an asset into a domain the caller does not hold returns `403`, including a PATCH that updates the whole document. OpenMetadata does not turn the refused change into a change request under an approval workflow.

Administrators are never refused. A policy without a domain condition allows the change for any target domain.

> [!WARNING]
>
> **Important**: These domain checks change how existing `hasDomain()` policies behave. A rule that allows `EditAll` or `EditDomains` when `hasDomain()` is true no longer lets a user assign any domain they choose. OpenMetadata also checks the target domain against the domains the user holds. After you add or edit a `hasDomain()` rule, test it with a non-admin user who tries to add or move an asset into a domain they do not hold, and expect a `403` response.

The error names the refused domain: `Principal: CatalogPrincipal{name='<user>'} does not belong to domains [<domain>] to perform the [EditDomains] operations.`

### Use Service Attributes in Policy Conditions

Every service can store three deployment attributes.

| Attribute | Supported value | Policy support |
| - | - | - |
| **Environment** | `Development`, `Staging`, `QA`, `UAT`, `Production`, `Sandbox`, or `Other` | Use `matchAnyServiceEnvironment(...)`. |
| **Region** | Free text, such as `us-east-1` | Display only. It is not available as a policy condition. |
| **Deployment** | Free text, such as `prod-cluster-01` | Display only. It is not available as a policy condition. |

#### Set Service Attributes

You need permission to edit the service.

1. Go to **Connections**.

2. Select the service type, then open the service you want to configure.

3. Click the **Connection** tab.

   ![Connection tab on a service page](https://mintcdn.com/openmetadata/3HCwU9B2XSlH-J12/public/images/how-to-guides/roles-policies/service-connection-tab.png?fit=max\&auto=format\&n=3HCwU9B2XSlH-J12\&q=85\&s=c21ba358fe26b5ad9615f3196ddb0788)

4. In the **Service Attributes** section, click **Edit**.

   ![Service Attributes section with the Edit button highlighted](https://mintcdn.com/openmetadata/3HCwU9B2XSlH-J12/public/images/how-to-guides/roles-policies/service-attributes-edit.png?fit=max\&auto=format\&n=3HCwU9B2XSlH-J12\&q=85\&s=7bee8d583aa248ded296bd11c19d2fc3)

5. Complete the following steps:

   * Select an **Environment**.
   * Optional: Enter the **Region** and **Deployment** identifier.

   ![Service Attributes configured with an environment, region, and deployment](https://mintcdn.com/openmetadata/3HCwU9B2XSlH-J12/public/images/how-to-guides/roles-policies/service-attributes.png?fit=max\&auto=format\&n=3HCwU9B2XSlH-J12\&q=85\&s=49e1d554425c40d6bea014fe395dd61e)

6. Click **Save**.

The attributes apply to the service. You do not need to add them separately to every asset ingested from that service.

Service-aware conditions let one rule cover the service and the assets it ingests:

| Condition | Returns true when |
| - | - |
| `matchAnyServiceTag('Environment.Development')` | The service has any listed tag or glossary term. |
| `matchAnyServiceType('Snowflake', 'BigQuery')` | The service has any listed connector type. Matching is case-insensitive. |
| `matchAnyServiceName('snowflake-sandbox')` | The asset belongs to any listed service name. Use the service name, not its fully qualified name. |
| `matchAnyServiceEnvironment('Development', 'Sandbox')` | The service has any listed environment. Matching is case-insensitive. |

The referenced value must exist when you save the policy. These conditions return false for resources that do not belong to a service. Examples include glossary terms and users.

For example, the following condition can be used in a `Deny` rule to prevent access to assets from development services:

```
matchAnyServiceEnvironment('Development')
```

Apply the rule to the required resources and operations. A service is treated as its own service, so a matching `Deny` rule can hide both the service and its assets.

#### Create a Service-Scoped Policy Rule

Test the rule in an unassigned policy before applying it to users or teams.

1. Go to **Settings** > **Access Control** > **Policies**.
2. Create a policy or open an existing policy.
3. Click **Add Rule**.
4. Complete the following steps:

   * Enter the **Rule Name**.
   * Optional: Enter a **Description**.
   * Select the required **Resources** and **Operations**. For example, select **All** and `ViewAll` to evaluate view access across service-backed resources.
   * Set **Effect** to `Deny` or `Allow`. When rules conflict, `Deny` takes precedence.
   * In **Condition**, enter a service-aware expression. For example:

     ```text theme={null}
     matchAnyServiceEnvironment('Development', 'Sandbox')
     ```

     Confirm that the editor reports **Valid condition**.

   ![Policy rule with a valid service environment condition](https://mintcdn.com/openmetadata/3HCwU9B2XSlH-J12/public/images/how-to-guides/roles-policies/service-environment-policy-condition.png?fit=max\&auto=format\&n=3HCwU9B2XSlH-J12\&q=85\&s=f8d7416832552bb19e08504f3e83f5a8)
5. Select **Create**.

Review the policy with the Permission Debugger before assigning it to a production team.

> [!WARNING]
>
> Service-aware conditions apply to search-backed results, direct entity requests, and create operations. A plain entity list API, such as `GET /v1/tables`, does not resolve an individual entity for its authorization check and cannot evaluate these conditions per result. Do not use an unfiltered list endpoint as a security boundary for a service-scoped policy.

### Understand Inherited Service Tags

Tags now pass down automatically through the service hierarchy. For example, a tag on a database service is inherited by its databases, database schemas, and tables.

* OpenMetadata marks inherited tags as `Derived`.
* Inherited tags are merged with the tags assigned directly to the child asset.
* If the child asset already has the same tag assigned directly, the child's tag takes precedence.

You cannot remove a derived tag from a child asset. To remove it, go to the parent where the tag was assigned and remove it there.

Policy conditions such as `matchAnyTag(...)` also evaluate inherited tags.

> [!NOTE]
>
> After you upgrade, reindex OpenMetadata so existing assets receive their inherited tags in search. Until reindexing finishes, an asset's own page can show inherited tags before they appear in Explore.

### Restrict Requests Made Through Bots

Use impersonation conditions in `Deny` rules to restrict actions attributed to a bot acting on a person's behalf. This includes requests that use the `X-Impersonate-User` header and Model Context Protocol (MCP) or artificial intelligence (AI) tool calls. An impersonated session can't use the identity endpoints, such as generating or revoking tokens, changing a password, or signing out.

| Condition | Returns true when |
| - | - |
| `isImpersonated()` | The request is attributed to any bot. |
| `impersonatedBy('McpApplicationBot')` | The request is attributed to any named bot. Bot-name matching is case-insensitive. |

Use this condition to match every request attributed to a bot:

```
isImpersonated()
```

To restrict a specific bot, use its existing bot name:

```
impersonatedBy('McpApplicationBot')
```

You can combine `isImpersonated()` with `matchAnyTag(...)` to protect tagged assets. The tag's fully qualified name must already exist in OpenMetadata or the condition will be invalid. Put `isImpersonated()` before the tag condition so ordinary requests can stop evaluation before OpenMetadata loads the tags. When you use `impersonatedBy(...)`, the supplied name must resolve to a bot or to its bot user.

#### Create a Bot Attribution Rule

Create the rule in an unassigned test policy first. A broad impersonation `Deny` rule can block MCP and AI tool access to matching resources.

1. Go to **Settings** > **Access Control** > **Policies**.

2. Create a policy or open an existing policy.

3. Click **Add Rule**.

4. Complete the following steps:

   * Enter the **Rule Name**.
   * Optional: Enter a **Description**.
   * Select the required **Resources** and **Operations**.
   * Set **Effect** to `Deny`.
   * In **Condition**, enter `isImpersonated()` or `impersonatedBy('<existing-bot-name>')`. Confirm that the editor reports **Valid condition**.

   ![Deny rule with a valid impersonatedBy condition for McpApplicationBot](https://mintcdn.com/openmetadata/3HCwU9B2XSlH-J12/public/images/how-to-guides/roles-policies/impersonated-by-policy-condition.png?fit=max\&auto=format\&n=3HCwU9B2XSlH-J12\&q=85\&s=ead5b05f1f1b1824ef27836fea2cf7d7)

5. Select **Create**.

Use the Permission Debugger to verify the expected result before assigning the policy.

> [!WARNING]
>
> These functions report bot attribution. They do not verify that an impersonation grant was authorized. Use them in `Deny` rules. They apply when OpenMetadata performs a per-entity authorization check, but they do not filter results returned directly by `search_metadata`, `semantic_search`, or `nlq_search`.

### Default Rules

To see the three rules that come built in and apply to everyone in your organization, follow these steps:

1. Click the **Profile** icon and go to **Settings** > **Access Control** > **Policies**.

   ![Access Control settings page with the Policies card highlighted](https://mintcdn.com/openmetadata/l7UFUTVmoMyeg70G/public/images/how-to-guides/roles-policies/access-control-policies.png?fit=max\&auto=format\&n=l7UFUTVmoMyeg70G\&q=85\&s=6bfbc2062a217c5dea6dad74823fede4)

2. Select **Organization Policy**.

   ![Policies list with Organization Policy highlighted](https://mintcdn.com/openmetadata/l7UFUTVmoMyeg70G/public/images/how-to-guides/roles-policies/policies-organization-policy.png?fit=max\&auto=format\&n=l7UFUTVmoMyeg70G\&q=85\&s=b68f393a1b9f2892b44f33c4653d87ab)

The Organization Policy includes the following default rules:

* **OrganizationPolicy-NoOwner-Rule**

  This rule lets any user assign ownership to an asset that doesn't have an owner yet. Once an owner is assigned, the rule no longer applies to that asset.

  For example, if a user accesses fact\_table and finds that it is unowned, then they can modify the ownership field to establish a new owner. However, for a table like dim\_address that already has an assigned owner, any attempt to change the ownership will be restricted.

* **OrganizationPolicy-Owner-Rule**

  This rule gives the owner of an asset – or any member of the owning team – full access to edit and view all its details.

  When a user, who either personally owns a table or is part of the team owning that table logs in, they're granted extensive rights. They can modify all properties of that data asset and access complete information about it.

* **OrganizationPolicy-ViewAll-Rule**

  This rule lets every user view every asset. It has no condition, so it applies to all users and all assets, whether or not they own the asset or belong to its team.

  This is why everyone can find and open any asset in Explore by default. With RBAC Search turned on, this rule still applies. See [Roles Based Access Controls (RBAC) Search](#roles-based-access-controls-rbac-search).

By setting up such default rules, the organization ensures clarity in access control based on ownership status and user roles.

## Policies

A policy is a named group of rules. When you access a resource in OpenMetadata, it checks all the rules in all the policies that apply to your account and decides whether to allow or deny the action.

### How Policies Work

**When rules conflict**

If two rules in the same policy disagree – for example, one allows `EditDescription` and another denies it – the `Deny` always wins.

**How policies combine**

OpenMetadata doesn't stop at the first policy that matches. A user's policies come from several places:

* The roles assigned to the user.
* The roles and policies of the user's teams, including parent teams.
* The Organization Policy.

OpenMetadata collects all of them and then checks:

1. Every `Deny` rule in every policy. If one matches the action, the action is denied.
2. If no `Deny` rule matches, every `Allow` rule in every policy. If one matches, the action is allowed.
3. If no rule matches, the action is denied.

This means a `Deny` rule always wins, even when it sits in a different policy than the `Allow` rule. For example, `OrganizationPolicy-Owner-Rule` allows owners to edit their assets. A `Deny` rule for `EditCertification` in another policy still blocks owners from changing certification.

**How policies are assigned**

Policies are assigned to teams, not to individual users. When you're added to a team, you automatically inherit all the policies assigned to that team.

**Inheritance and Application**

![Inheritance and Application](https://mintcdn.com/openmetadata/hh5nHFImSbxUEO9H/public/images/how-to-guides/roles-policies/inheritance.png?fit=max\&auto=format\&n=hh5nHFImSbxUEO9H\&q=85\&s=70643fd13ae427e5878f34ff3d8eb0ac)

Any user positioned within a team structure inherently adopts its policies. For instance, if the **"Organization-NoOwner-Policy"** is instituted at the organization's apex, all its internal members will be governed by this policy and the rules therein.

Similarly, if a policy is assigned to "Division1" such as "Division Policy", every member – whether "Department", "Team1", "Team2", or individual users in these groups – falls under its scope.

However, if you create a policy specifically for "Team1", only its members are affected.

**Policy Design Principles**

This architecture sets broad rules at the organizational level, with more lenient defaults at the top. Teams can then define stricter, more tailored policies as you move down the hierarchy. For example, a policy can say: 'Deny access to everyone outside of Team 1.' This gives you flexibility at the top and precision where it matters most.

When designing policies for sensitive processes, it's also worth thinking
about who should hold which permissions – not just what the permissions are.

A rule that you remove from a policy takes effect on the next authorization decision on the server that processed the update. On deployments with several servers connected through Redis, the change reaches the other servers asynchronously. Requests that were already authorized are not cancelled.

### Separation of Duties

For teams with compliance or regulatory requirements, it's good practice to make sure no single person can complete a sensitive process from start to finish on their own. Split the steps across two roles so each one requires a different person.

| Process | First role | Second role | Why it's split |
| - | - | - | - |
| Pipeline deployment | Data engineer (`Create`, `EditAll`) | Pipeline approver (`Deploy`) | Stops unreviewed pipelines reaching production |
| PII labelling | Data steward (`EditTags`) | Compliance officer (review via `AuditLogs`) | Makes sure PII labels are independently checked |
| User provisioning | HR system via SCIM (`CreateScim`) | Admin (`EditRole` assignment) | Prevents someone granting themselves elevated access |
| Glossary publishing | Business analyst (create term) | Data steward (`EditCertification`) | Requires a steward to sign off before a term goes live |

## Roles

A role is a ready-made bundle of policies that matches a job function. Instead of assigning individual policies to every user, you assign them a role and they get all the right policies in one step.

![Building Blocks of Authorization: Roles](https://mintcdn.com/openmetadata/3HCwU9B2XSlH-J12/public/images/how-to-guides/roles-policies/roles-list.png?fit=max\&auto=format\&n=3HCwU9B2XSlH-J12\&q=85\&s=62bb2ee280f598312ff8de302b54458b)

Roles can be assigned to individual users or to entire teams. When a role is assigned to a team, every member of that team gets it automatically – which makes onboarding and offboarding much simpler.

Some common examples of how roles map to job functions:

* **Data engineers** build and maintain data assets – they need `Create`, `Deploy`, and `Trigger`
* **Analysts** explore and use data – they need `ViewAll`, `ViewUsage`, and `ViewQueries`
* **Data stewards** manage governance – they need `EditTags`, `EditGlossaryTerms`, and `EditCertification`

A role bundles multiple policies that match a specific job function. For example, a "Data Consumer" role includes a "Data Consumer Policy." Anyone assigned that role – whether an individual or a team – automatically gets all the permissions defined in those policies.

### Common Mistakes to Avoid

| Mistake | Why it's a problem | What to do instead |
| - | - | - |
| Assigning `EditAll` when only `EditDescription` is needed | The user ends up with access to change lineage, ownership, and tags – not just descriptions | Assign only `EditDescription` and `EditDisplayName` for documentation roles |
| Giving `ViewSampleData` to all analysts | Exposes production row-level data broadly across the team | Create a separate role for sample data access and require approval to join it |
| Using `Delete` outside admin roles | Risks accidental or unauthorised deletion of assets | Keep `Delete` for admins only |
| Granting `EditPolicy` without regular audit reviews | A user could change their own permissions without anyone noticing | Only admins get `EditPolicy` – review the audit log weekly for policy changes |
| Using one global role for everyone | Gives people access to assets in domains that have nothing to do with their work | Scope roles to specific domains or resource types where possible |
| Overlooking Bot and MCP resources | Automated integrations can access or move data if over-permissioned | Treat bot and MCP permissions with the same care as human user permissions |
| Leaving out `Ingestion Runner` in pipeline roles | Engineers can create pipelines but can't run them | Always pair `Ingestion Pipeline` (`Create`) with `Ingestion Runner` (`Trigger`) |

> [!WARNING]
>
> **Important**: This has been enforced since OpenMetadata 1.12.9. Triggering an ingestion pipeline through the API (`POST /v1/services/ingestionPipelines/trigger/{id}`) now requires the `Trigger` operation to be explicitly granted — `EditAll` no longer covers it. The upgrade automatically added `Trigger` to the default bot policies (`Ingestion`, `Lineage`, `Profiler`, `Quality`, `Usage`) and the default Data Steward role.
>
> If you have a custom role or policy that grants `EditAll` on `Ingestion Pipeline` without an explicit `Trigger` grant, add `Trigger` to it after upgrading — otherwise pipeline triggers will start failing silently for anyone assigned that role. Scheduled runs are unaffected. This only applies to manually or programmatically triggered runs.

## Permissions for Related Endpoints

Several endpoints that return part of an asset check the same permission the asset itself requires.

| Endpoint | Permission required |
| - | - |
| System profile of a table | `ViewDataProfile` on the table |
| Entity relationships of a table or schema | `ViewBasic` on the table or schema |
| KPI results | `ViewBasic` on the KPI |
| Pipeline status history | `ViewAll` on the ingestion pipeline |
| Data contract validation | `ViewBasic` on the entity the contract is for |
| Intake form for an entity type | `ViewBasic` on the intake form |
| Lineage edge | `ViewBasic` on both the source and the target |
| Lineage graph, export, and scene | `ViewBasic` on the root entity |
| Vote on an asset, follow an asset, or stop following it | `ViewBasic` on the asset |
| Trigger, redeploy, suspend, or resume a governance workflow | `EditAll` on the workflow definition |
| Add or remove users, or bulk add or remove assets, on a team | `EditUsers` on the team |
| Read an announcement on an asset, or its versions | `ViewBasic` on the asset the announcement is linked to |

Adding or removing a follower other than yourself requires an administrator.

The automations workflow trigger for **Test connection** requires `EditAll` on the service in the request, or `Create` on ingestion pipelines. Without a service in the request, it requires `Create` on ingestion pipelines.

## CSV Import and Export

CSV import and export check permissions for each row, not only for the asset you start from. This applies to every entity that supports CSV, such as services, databases, schemas, tables, glossaries, teams, users, and test cases.

* **Import**: OpenMetadata authorizes each row as the matching write that the importing user could make through the API. A row that updates an existing entity needs `EditAll` on that entity, even when the row changes nothing. A row that creates an entity needs `Create`, checked against the entity's parent. A row for a table's columns is checked as an update to the table.
* **New parents in the same file**: A row can create an entity under a parent that an earlier row in the same file created. OpenMetadata checks it against that parent, and the parent counts only after its own row succeeds.
* **Refused rows**: A refused row is reported as failed and the other rows continue, in a dry run as well as in a real import. An explicit deny on any operation the row needs refuses the row.
* **Administrators**: Administrators skip these per-row checks.
* **Export**: An export includes only the rows the caller can view (`ViewAll`). When a container is left out, its children are left out with it, for example the schemas and tables under a database. A restricted user can therefore get a shorter file than an administrator, and importing that file does not change the rows that were left out.

> [!NOTE]
>
> A CSV dry run reports the rows that the import will refuse. Use it to check your permissions before you run the import.

## Filtered Lists and Responses

OpenMetadata filters these responses to what the caller can view:

* **Asset lists**: The assets of a domain, data product, glossary term, tag, team, or user.
* **Asset counts**: The counts of domains, data products, and teams. A user restricted to a domain sees counts for that domain and its sub-domains only.
* **Mixed responses**: Activity feeds, lineage neighbors, column search and export, and the `semantic_search` MCP tool. Administrators skip this filtering in activity feeds and lineage.
* **Announcements**: A list of announcements leaves out the announcements on assets that the caller cannot view, and the total counts only the announcements the caller can view. System announcements, which are not linked to an asset, are not affected. An announcement on an asset that has no link recorded can be read by administrators only.
* **CSV exports**: An export includes only the rows the caller can view. See [CSV Import and Export](#csv-import-and-export).

## Administrator and Bot Endpoints

OpenMetadata restricts these endpoints to administrators, or to administrators and bots.

| Access | Endpoints |
| - | - |
| Administrator or bot | `GET /v1/events`, system entity and service counts, `GET /v1/system/status`, `GET /v1/analytics/web/events/collect` (raw events), search document by ID |
| Administrator only | Reset an email template, list search reindex failures (up to 1,000 per page, default 50) |

Recording a page view (`PUT /v1/analytics/web/events/collect`) stays open to all users, and OpenMetadata always records the page view for the caller. A caller who is not an administrator sees a generic message when the pipeline service is unavailable: "The pipeline service is not available. Ask an administrator to check its status."

## Roles Based Access Controls (RBAC) Search

By default, every user can search for and find any data asset in OpenMetadata, regardless of whether they have permission to access it. If you want search results to reflect each user's permissions, turn on RBAC Search. Search then shows only the assets that the user's policies allow them to see. The built-in Organization Policy allows everyone to see every asset, so this takes effect only after you change that. For more information, see [How Search Combines Your Policies](#how-search-combines-your-policies).

To enable or disable this, go to **Settings** > **Preferences** > **Search**.

![Roles Based Access Controls (RBAC) Search Option](https://mintcdn.com/openmetadata/3HCwU9B2XSlH-J12/public/images/how-to-guides/roles-policies/rbac-search-setting.png?fit=max\&auto=format\&n=3HCwU9B2XSlH-J12\&q=85\&s=1f0352a077892f73b726da0bda3fb15e)

### What Changes When You Turn It On

**Search results are filtered by permission** – users only see assets their
role gives them access to, which helps with data security and compliance.

**Permissions apply at the point of discovery** – users can't find or browse
assets they're not allowed to access, even through search.

### How Search Combines Your Policies

RBAC Search combines the rules from all of a user's policies, including the Organization Policy. An asset shows up in search if at least one allow rule lets the user see it, unless a deny rule blocks it.

Search only looks at rules that grant `ViewBasic`, `ViewAll`, or `All`. It skips every other rule.

The Organization Policy includes `OrganizationPolicy-ViewAll-Rule`, which grants `ViewAll` on all resources with no condition. Because of this rule, every user sees every asset in search, even with RBAC Search turned on. A role that grants `ViewAll` only under `isOwner()` doesn't change this. The unconditional rule still shows non-owned assets. Any other policy with an unconditional rule that grants `ViewBasic`, `ViewAll`, or `All` has the same effect. Examples are the policy of the Data Consumer role and a read-only viewer policy that grants `ViewBasic` on tables.

For strict isolation, make sure no policy that applies to the user grants `ViewBasic`, `ViewAll`, or `All` without a condition. To change the Organization Policy, go to **Settings** > **Policies** > **Organization Policy**, and either delete `OrganizationPolicy-ViewAll-Rule` or add a condition such as `isOwner()` to it. OpenMetadata doesn't restore the built-in rules when the server restarts. Owners and owning teams keep access through `OrganizationPolicy-Owner-Rule`.

> [!WARNING]
>
> `ViewAll` also lets users view an asset's details, not only find it in search. After you remove an unconditional `ViewAll` rule, users can open only the assets that another rule gives them access to.

The search aggregation endpoint (`/v1/search/aggregate`, GET and POST) also applies your policy conditions. With RBAC Search turned on, the counts and top hits for a non-admin user cover only the assets their policies allow. If the policies produce no usable query, the aggregation returns no results. Results are unchanged for administrators and when RBAC Search is off. Bots are not exempt: OpenMetadata evaluates their policies like any other user's.

### Before You Turn It On

**Check your roles and policies are fully configured** – make sure every user and team has the right permissions for the assets they need. Incomplete configuration can cause users to lose visibility of assets they should see.

**Check for unconditional `ViewBasic`, `ViewAll`, and `All` rules**: if you need users to see only some assets, review every policy that applies to them.

**Test with real users after enabling** – ask someone from each role to run searches and confirm they're seeing the right results.

For a full guide on setting up roles and policies, see [Roles and Policies](https://docs.open-metadata.org/v2.1.x/how-to-guides/admin-guide/roles-policies.md). Enabling RBAC Search makes sure OpenMetadata's search aligns with your organization's data governance and access requirements.

> [card] [Use Cases: Creating Roles & Policies in OpenMetadata](https://docs.open-metadata.org/v2.1.x/how-to-guides/admin-guide/roles-policies/use-cases.md)
>
> Tailor your policies to meet your organizational and team needs.

### Troubleshooting: Queries Tab Is Empty for Non-Admin Users

If a table has queries and an admin can see them, but a non-admin user sees an empty Queries tab, check the following in order:

1. **RBAC Search**: Go to **Settings** > **Preferences** > **Search** and check whether RBAC Search is on. When it is on, policies filter the Queries list, so continue to step 2. When it is off, search results aren't filtered by policies, so go to step 3.
2. **Query resource rule**: Confirm that one of the user's policies has an Allow rule on the `Query` resource with `ViewAll` (or `All`) and no `isOwner()` condition. Table-level `ViewAll` or `ViewQueries` doesn't control this tab. Owning the table doesn't help either, because `isOwner()` in search matches the owners of the query.
3. **Query ingestion**: Confirm that query ingestion has run for the service. An admin should see the queries on the table.
4. **Permission Debugger**: Use the [Permission Debugger](https://docs.open-metadata.org/v2.1.x/how-to-guides/admin-guide/permission-debugger.md) to evaluate `ViewAll` on the `Query` resource for the affected user.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.