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

# Bulk Import Test Cases

> Learn to bulk import data quality test cases in Collate using CSV files, at the table, test suite, or platform-wide scope.

# Bulk Import Test Cases

Importing test cases from a CSV file lets you create or update several test cases at once, instead of adding them one at a time through the UI. You can import test cases for a single table, for a test suite, or across your entire platform.

For more information about what each column in the file means, see the [CSV Field Reference](/how-to-guides/data-quality-observability/quality/import-export-test-cases).

## Bulk Import Test Cases for a Table

To import test cases scoped to a single table:

1. In the left navigation menu, click **Explore**, and select the table whose test cases you want to import.
2. Navigate to the **Data Observability** tab.
3. In the **Data Quality** tab, click **Test Cases** if not selected.
   <img src="https://mintcdn.com/collatedocs/pegD9dAsgJRGdvkc/public/images/how-to-guides/data-quality-observability/quality/table-test-cases.png?fit=max&auto=format&n=pegD9dAsgJRGdvkc&q=85&s=a113c3751899693747c905d214b7da24" alt="Access Table Test Cases" width="2528" height="1390" data-path="public/images/how-to-guides/data-quality-observability/quality/table-test-cases.png" />
4. Click the **⋮** icon and click **Import**.
   <img src="https://mintcdn.com/collatedocs/pegD9dAsgJRGdvkc/public/images/how-to-guides/data-quality-observability/quality/select-import-table.png?fit=max&auto=format&n=pegD9dAsgJRGdvkc&q=85&s=69633c76ce8de4417b69a816f1a05dfd" alt="Import test cases for a single table" width="2448" height="646" data-path="public/images/how-to-guides/data-quality-observability/quality/select-import-table.png" />
5. Upload or drop the CSV file.
   <img src="https://mintcdn.com/collatedocs/pegD9dAsgJRGdvkc/public/images/how-to-guides/data-quality-observability/quality/upload-test-cases.png?fit=max&auto=format&n=pegD9dAsgJRGdvkc&q=85&s=61b177664d5dd0cfb06890d11533da58" alt="Upload the test case CSV file" width="2510" height="788" data-path="public/images/how-to-guides/data-quality-observability/quality/upload-test-cases.png" />
6. Preview the uploaded file and add or modify rows using the inline editor.
   <img src="https://mintcdn.com/collatedocs/pegD9dAsgJRGdvkc/public/images/how-to-guides/data-quality-observability/quality/preview-edit-import.png?fit=max&auto=format&n=pegD9dAsgJRGdvkc&q=85&s=0023a1ff179d2d49f060dd6eabd663a6" alt="Preview of the test case CSV file" width="2420" height="1476" data-path="public/images/how-to-guides/data-quality-observability/quality/preview-edit-import.png" />
7. Validate your changes. A green or red tick in the **Status** column displays the success or failure of the test cases.
   <img src="https://mintcdn.com/collatedocs/pegD9dAsgJRGdvkc/public/images/how-to-guides/data-quality-observability/quality/validate-import-test-cases.png?fit=max&auto=format&n=pegD9dAsgJRGdvkc&q=85&s=d8d3c6f1c5fa0239674480466e90ba5a" alt="Validate the test case CSV file" width="2460" height="678" data-path="public/images/how-to-guides/data-quality-observability/quality/validate-import-test-cases.png" />
8. Click **Update** to apply the changes.

## Bulk Import Test Cases in a Suite

To import test cases scoped to a single test suite:

1. Navigate to **Data Observability** > **Data Quality**.
2. Click the **Test Suites** tab and switch to **Bundle Suites**.
   <img src="https://mintcdn.com/collatedocs/pegD9dAsgJRGdvkc/public/images/how-to-guides/data-quality-observability/quality/test-suites-test-cases.png?fit=max&auto=format&n=pegD9dAsgJRGdvkc&q=85&s=1455cebdbfd855f0f387d03f556886f6" alt="Select a bundle test suite" width="2996" height="1426" data-path="public/images/how-to-guides/data-quality-observability/quality/test-suites-test-cases.png" />
3. Search and select the bundle suite whose test cases you want to import.
4. Click the **⋮** icon and click **Import**.
   <img src="https://mintcdn.com/collatedocs/pegD9dAsgJRGdvkc/public/images/how-to-guides/data-quality-observability/quality/select-import-suite.png?fit=max&auto=format&n=pegD9dAsgJRGdvkc&q=85&s=033a07b825b6585b758991f1774e94f1" alt="Import test cases for a test suite" width="2472" height="1066" data-path="public/images/how-to-guides/data-quality-observability/quality/select-import-suite.png" />
5. Repeat steps 5 to 8 from [Bulk Import Test Cases for a Table](#bulk-import-test-cases-for-a-table).

## Bulk Import All Test Cases

To import test cases across your entire Collate instance:

1. Navigate to **Data Observability** > **Data Quality**, and click **Test Cases**.
   <img src="https://mintcdn.com/collatedocs/pegD9dAsgJRGdvkc/public/images/how-to-guides/data-quality-observability/quality/test-cases-tab.png?fit=max&auto=format&n=pegD9dAsgJRGdvkc&q=85&s=becbe01284ae7b76dc829b5f84c06c3a" alt="Test Cases Tab" width="2986" height="1382" data-path="public/images/how-to-guides/data-quality-observability/quality/test-cases-tab.png" />
2. Click the **⋮** icon and select **Import**.
   <img src="https://mintcdn.com/collatedocs/pegD9dAsgJRGdvkc/public/images/how-to-guides/data-quality-observability/quality/select-import-test-cases.png?fit=max&auto=format&n=pegD9dAsgJRGdvkc&q=85&s=7684beed6a5be64084dbbba09dca7630" alt="Import test cases platform-wide" width="2534" height="1302" data-path="public/images/how-to-guides/data-quality-observability/quality/select-import-test-cases.png" />
3. Repeat steps 5 to 8 from [Bulk Import Test Cases for a Table](#bulk-import-test-cases-for-a-table).

## Import Using API

You can also import test cases using the API with the following endpoints:

`PUT /api/v1/dataQuality/testCases/name/{name}/import`

`PUT /api/v1/dataQuality/testCases/name/{name}/importAsync`

Replace `{name}` with the Fully Qualified Name (FQN) of the entity you're importing into, or with `*` for a platform-wide import. What `{name}` actually scopes depends on `targetEntityType`:

* When `targetEntityType=testSuite`, `{name}` is the FQN of the bundle test suite, and the import is scoped to that suite.
* For any other `targetEntityType` (including table-scoped and platform-wide imports), `{name}` does not restrict which entity each row applies to. The target for every test case is determined by that row's `entityFQN` column in the CSV instead.

Both endpoints take the CSV file as the raw request body and support two query parameters:

* **dryRun**: `true` or `false` (default `true`). Validates the file without making changes, matching the preview step in the UI.
* **targetEntityType**: The entity type the test cases are being added to, for example `table` or `testSuite`.

<Warning>
  Outside of a test-suite-scoped import, `{name}` in the URL doesn't limit which entities are affected — double-check the `entityFQN` column in your CSV before importing to avoid updating the wrong table or column.
</Warning>

The `importAsync` endpoint runs the import as a background job and is what the UI uses. The `import` endpoint returns the result synchronously.
