import { queryOptions } from '@tanstack/react-query'; import type { BusterDashboardListItem, BusterDashboardResponse } from '@/api/asset_interfaces/dashboard'; import { dashboardsGetList } from '../buster_rest/dashboards'; const dashboardGetList = ( filters: Omit[0], 'page_token' | 'page_size'> ) => queryOptions({ queryKey: ['dashboard', 'list', filters] as const, initialData: [], staleTime: 60 * 1000, initialDataUpdatedAt: 0 }); const dashboardGetDashboard = (dashboardId: string, version_number?: number) => queryOptions({ queryKey: ['dashboard', 'get', dashboardId, version_number] as const, staleTime: 10 * 1000 }); export const dashboardQueryKeys = { dashboardGetDashboard, dashboardGetList };