# Subscribe to Projects

## Subscribe to a project

1. Click <i class="fa-database">:database:</i> **Data** in the navigation menu and then select **Projects**.
2. Click **Join Project** from either the all projects view or the project overview tab, which can be accessed by clicking on the project.
3. Click **Join** to confirm you want to join the project.
4. After you have been granted access to the project, go to the project and click **I Agree** to acknowledge that you will only use the project for its specified purposes.

## Change project contexts

### Switch projects in the Immuta UI

1. Click the **Project dropdown menu** in the menu bar. If no project is currently selected, it is **No Current Project**.
2. Select a **project**. Once selected, the current project will display at all times in the menu bar.

If you unsubscribe from the project, this display will default to **No Current Project**.

### Switch projects using UDFs in Databricks

1. View your available projects by running the following query in Spark: **select \* from immuta.list\_projects**. In the resulting table, note the values listed in the **id column**; this value will be used as the parameter in the following step.
2. Run **select immuta.set\_current\_project(`<id>`)**. This UDF must be called in its own notebook cell to ensure the changes take effect.

Your project context will be switched, and that project's data sources and workspaces will now be visible. To set your project context to None, run `select immuta.set_current_project()` with no parameters.

*Note: Since the UDFs are not actually registered with the FunctionRegistry, if you call `DESCRIBE FUNCTION immuta.set_current_project`, you won't get back the documentation for the UDF.* For a complete list of functions, see the [Project UDFs](https://documentation.immuta.com/saas/govern/secure-your-data/projects-and-purpose-based-access-control/write-index/reference-guides/project-udfs) reference guide.

## Create a project-based API key

Any project member can create project-based API keys, which are used for authenticating external tools with Immuta.

1. Navigate to the **Project Overview** tab.
2. Click **Get API Key** in the project information section.
3. A window will display with the API key. Store this key somewhere secure. If you misplace it, you will have to generate a new one and re-authenticate all services connected to Immuta via this key.
4. Click **Close**.

## Leave a project

1. Navigate to the **Project Overview** tab.
2. Click the **Leave Project** button, and then click **Confirm**.

## Manage project data sources

### Add data sources to a project

Any project member can add data sources to a project, unless the [project equalization](https://documentation.immuta.com/saas/govern/secure-your-data/projects-and-purpose-based-access-control/equalized-access) or [allow masked joins](https://documentation.immuta.com/saas/govern/secure-your-data/projects-and-purpose-based-access-control/masked-joins) features are enabled; in those cases only project owners can add data sources to the project.

1. Select the project, and then navigate to the **Project Overview** tab.
2. Click the **Add Data Sources** button in the **Data Sources** section in the center pane.
3. Start typing the name of a data source you'd like to include in the project.
4. Select the **data source** from the list of auto-completed options in the dropdown menu.
5. Repeat this process to add additional data sources to the list. Click **Remove** to remove them.
6. When complete, click the **Add** button.

### Add data sources by purpose

You can automatically add all data sources to a project that contain a **Limit usage to purpose** policy that matches the purpose of that project.

1. Select a **Project**, and click the **Add Data Sources** button on the **Data Sources** tab.
2. Click **Add By Purpose** in the dialog.
3. All data sources matching the project's purpose(s) will populate. Review this list, and then click **Save**.

### Remove data sources from a project

As a project member, you can only delete data sources you've added to the project.

1. Select a project, and then click the **Data Sources** tab.
2. Click the **Remove Data Source** icon in the **Actions** column of the data source you want to remove.
3. Click **Confirm** in the window that appears.

## Search for projects

Immuta's UI provides a list of all projects, excluding those that have been set to private. Users can search for projects by keyword, tag, or connection string.

* To access a list of all projects, click the **Projects** icon in the navigation menu.
* To search for projects by keyword, type a keyword into the **search box**, and hit enter. If the list of results is empty, then no projects with names matching that keyword currently exist.
* To search for projects by tag or connection string, type the relevant name into the **search box** and select the **tag** or **connection string** from the list of auto-completed results. If a list does not display, then no results matching that search criteria currently exist.

### Create a project search filter

Project search filters allow users to codify complex, recurring search criteria into a shared asset that can be used by any other user. This eliminates the need for team members to repeatedly reconstruct identical search queries for frequent tasks inside Immuta.

To create a new project search filter,

1. Type your search criteria into the **Global Search** bar and hit enter.
2. Review and refine the resulting list of projects from your search, and then click **Save Search Filter**.
3. In the dialog box, type in a **Name** for your search filter and then confirm by clicking **Save**.

To view existing project search filters,

1. Click into the **Global Search** bar.
2. Any available search filters will be displayed in the dropdown.

To delete a project search filter,

1. Click into the **Global Search** bar.
2. Any search filters that the current user is allowed to delete will be displayed with an :heavy\_multiplication\_x: in the dropdown. Click :heavy\_multiplication\_x: next to the search filter you want to delete.
3. Click **Confirm**.

{% hint style="info" %}
Users with APPLICATION\_ADMIN or USER\_ADMIN global permission can delete search filters created by any user. All other users can only delete search filters that they originally created.
{% endhint %}
