}) => (
+
+ {configs.map(({ key, supportsAdvancedSearch }) => (
+
+ {key}
+
+ ))}
+
+ ),
+}));
+
+vi.mock("src/components/SearchBar", () => ({
+ SearchBar: () => null,
+}));
+
+vi.mock("src/queries/useConfig", () => ({
+ useConfig: (key: string) => (key === "fallback_page_limit" ? 50 : false),
+}));
+
+const { useAssetServiceGetAssetsUi } = await import("openapi/queries");
+
+const lastAssetsCall = () => vi.mocked(useAssetServiceGetAssetsUi).mock.calls.at(-1)?.[0];
+
+describe("AssetsList filters", () => {
+ beforeEach(() => {
+ mockSearchParams = new URLSearchParams();
+ vi.mocked(useAssetServiceGetAssetsUi).mockReturnValue({
+ data: { assets: [], total_entries: 0 },
+ error: null,
+ isLoading: false,
+ } as ReturnType);
+ });
+
+ it("offers an exact-match Dag ID filter", () => {
+ render(, { wrapper: Wrapper });
+
+ expect(screen.getByTestId("asset-filter-dag_id")).toHaveAttribute("data-advanced-search", "false");
+ });
+
+ it("passes the selected Dag ID to the Assets API and omits it after clearing", () => {
+ mockSearchParams = new URLSearchParams("dag_id=consumer_dag");
+
+ const { rerender } = render(, { wrapper: Wrapper });
+
+ expect(lastAssetsCall()?.dagIds).toEqual(["consumer_dag"]);
+
+ mockSearchParams = new URLSearchParams("dag_id=");
+ rerender();
+
+ expect(lastAssetsCall()?.dagIds).toBeUndefined();
+ });
+});
diff --git a/airflow-core/src/airflow/ui/src/pages/AssetsList/AssetsList.tsx b/airflow-core/src/airflow/ui/src/pages/AssetsList/AssetsList.tsx
index 3351810523112..b3bd5038ee298 100644
--- a/airflow-core/src/airflow/ui/src/pages/AssetsList/AssetsList.tsx
+++ b/airflow-core/src/airflow/ui/src/pages/AssetsList/AssetsList.tsx
@@ -38,6 +38,7 @@ import { useDocumentTitle, useFiltersHandler, type FilterableSearchParamsKeys }
import { DependencyPopover } from "./DependencyPopover";
const assetsFilterKeys: Array = [
+ SearchParamsKeys.DAG_ID,
SearchParamsKeys.GROUP_PATTERN,
SearchParamsKeys.LAST_ASSET_EVENT_TIMESTAMP_RANGE,
];
@@ -98,7 +99,7 @@ const createColumns = (translate: (key: string) => string): Array {
const { t: translate } = useTranslation(["assets", "common"]);
@@ -107,6 +108,7 @@ export const AssetsList = () => {
const [searchParams, setSearchParams] = useSearchParams();
+ const dagId = searchParams.get(DAG_ID);
const namePattern = searchParams.get(NAME_PATTERN) ?? "";
const advancedSearch = useAdvancedSearch("assets");
@@ -116,6 +118,9 @@ export const AssetsList = () => {
const orderBy = sort ? [`${sort.desc ? "-" : ""}${sort.id}`] : ["-last_asset_event_timestamp"];
const { filterConfigs, handleFiltersChange, initialValues } = useFiltersHandler(assetsFilterKeys);
+ const assetsFilterConfigs = filterConfigs.map((config) =>
+ config.key === DAG_ID ? { ...config, supportsAdvancedSearch: false } : config,
+ );
const lastAssetEventTimestampGte = searchParams.get(SearchParamsKeys.LAST_ASSET_EVENT_TIMESTAMP_GTE);
const lastAssetEventTimestampLte = searchParams.get(SearchParamsKeys.LAST_ASSET_EVENT_TIMESTAMP_LTE);
@@ -128,6 +133,7 @@ export const AssetsList = () => {
const { data, error, isLoading } = useAssetServiceGetAssetsUi({
...groupArg,
+ dagIds: dagId === null || dagId === "" ? undefined : [dagId],
lastAssetEventTimestampGte: lastAssetEventTimestampGte ?? undefined,
lastAssetEventTimestampLte: lastAssetEventTimestampLte ?? undefined,
limit: pagination.pageSize,
@@ -164,7 +170,7 @@ export const AssetsList = () => {
/>
From 5c62bdf0bfdb9b70d158296bb8a25294b4d0571d Mon Sep 17 00:00:00 2001
From: Shivam <6463385+shivaam@users.noreply.github.com>
Date: Sun, 2 Aug 2026 23:50:42 -0700
Subject: [PATCH 2/2] Document Assets Dag ID filtering
---
airflow-core/newsfragments/70971.feature.rst | 1 +
1 file changed, 1 insertion(+)
create mode 100644 airflow-core/newsfragments/70971.feature.rst
diff --git a/airflow-core/newsfragments/70971.feature.rst b/airflow-core/newsfragments/70971.feature.rst
new file mode 100644
index 0000000000000..338ebc9cf4ccb
--- /dev/null
+++ b/airflow-core/newsfragments/70971.feature.rst
@@ -0,0 +1 @@
+Add a Dag ID filter to the Assets search page.