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

# Looker

> Learn how to connect Opal to Looker to manage group membership and review who holds each role.

With the Looker integration, you can manage access to your Looker instance from Opal:

* Allow users to request membership of a Looker group from the web and Slack
* Automatically remove group members when a time-bound grant expires
* Review who holds each Looker role, directly or through a group
* Include Looker access in access reviews

Opal connects to one Looker (Google Cloud core) instance through an API client ID and secret. To manage several instances, add a Looker app in Opal for each one.

## Supported resources

| Resource | Read | Grant and revoke access | Notes |
| - | - | - | - |
| Looker Group | ✔️ | ✔️ | Membership. Also shows the groups nested in it and the roles it holds. |
| Looker Role | ✔️ | | Shows users who hold the role directly and groups that hold it, at one **Assigned** level. |

Opal syncs your Looker users as accounts and links them to Opal users by email.

### How Looker access maps to Opal

* **Groups**: each group appears in Opal as a **Looker Group**. Granting membership adds the user to the group, and revoking it removes them. A group nested inside another group shows as a member of it, and its members inherit the parent group's access.
* **Roles**: each role appears in Opal as a **Looker Role**. A user who holds a role only through a group shows on the role through that group, not as a direct holder.

### Limitations

* Opal can't assign or remove Looker roles. Looker replaces a user's or role's whole list of roles at once, so roles are read only. Give a group the role in Looker, then grant membership of that group in Opal.
* Opal doesn't sync Looker folders or folder access.
* Only Looker (Google Cloud core) instances at `<instance>.looker.app` are supported. Legacy Looker-hosted instances at `<instance>.cloud.looker.com` aren't.

## Requirements

Before you begin, you must:

* Be an Opal Admin
* Be a Looker admin who can create API keys for a user
* Be on version `1.1262.0` or later, if you self-host Opal

## Configuration steps

### 1. Create a Looker API client ID and secret

1. In Looker, go to **Admin** > **Users** and select the user Opal should act as. Use a dedicated user for Opal, so access keeps working when people leave.
2. Give the user the **Admin** role, or a role whose permission set includes the permissions below.
3. Select **Edit Keys**, then create a new API key. Copy the client ID and the client secret.

| Permission | Needed to |
| - | - |
| `see_users` | Sync users |
| `see_groups` | Sync groups and their members |
| `see_roles` | Sync roles and who holds them |
| `manage_groups` | Add and remove group members |

### 2. Create the Looker app in Opal

In Opal, go to **Inventory** > **+ App** and select **Looker**. Fill in the following fields:

| Field | Value |
| - | - |
| App name | A name for the Looker app in Opal, for example `Looker`. |
| App admin | The owner who administers the app in Opal. |
| Description | A short description that helps requesters understand what this app is. |
| Instance name | The first part of your Looker URL. For `https://acme.looker.app`, the instance name is `acme`. |
| API client ID | The client ID from step 1. |
| API client secret | The client secret from step 1. |

Opal checks the credentials when you save the app. The app's **Setup** tab shows whether the credentials can read users, groups, and roles.

### 3. Import assets

After you save the app, import the items you want to manage: on the app's **Assets** tab, select **Import assets** and choose the groups and roles. Opal pulls access only for imported items, so members appear after the next sync.

## Troubleshooting

| Error or symptom | Fix |
| - | - |
| Saving the app fails | Check that **Instance name** matches your Looker URL, and that the client ID and secret come from the same API key. |
| A **Read** check fails on the **Setup** tab | Give the user the matching permission: `see_users`, `see_groups`, or `see_roles`. |
| Adding or removing a group member fails | Give the user the `manage_groups` permission. |


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