diff --git a/airflow/api_fastapi/core_api/datamodels/assets.py b/airflow/api_fastapi/core_api/datamodels/assets.py index 942b0294e5fd0..c7b7bec034c06 100644 --- a/airflow/api_fastapi/core_api/datamodels/assets.py +++ b/airflow/api_fastapi/core_api/datamodels/assets.py @@ -103,6 +103,8 @@ class AssetEventResponse(BaseModel): id: int asset_id: int uri: str | None = Field(alias="uri", default=None) + name: str | None = Field(alias="name", default=None) + group: str | None = Field(alias="group", default=None) extra: dict | None = None source_task_id: str | None = None source_dag_id: str | None = None diff --git a/airflow/api_fastapi/core_api/openapi/v1-generated.yaml b/airflow/api_fastapi/core_api/openapi/v1-generated.yaml index cdf70d9413b8c..e30a8637f2ca0 100644 --- a/airflow/api_fastapi/core_api/openapi/v1-generated.yaml +++ b/airflow/api_fastapi/core_api/openapi/v1-generated.yaml @@ -6311,6 +6311,16 @@ components: - type: string - type: 'null' title: Uri + name: + anyOf: + - type: string + - type: 'null' + title: Name + group: + anyOf: + - type: string + - type: 'null' + title: Group extra: anyOf: - type: object diff --git a/airflow/models/asset.py b/airflow/models/asset.py index 1ac14fb6ec2f2..212a0b3a84c6c 100644 --- a/airflow/models/asset.py +++ b/airflow/models/asset.py @@ -714,6 +714,14 @@ class AssetEvent(Base): def uri(self): return self.asset.uri + @property + def group(self): + return self.asset.group + + @property + def name(self): + return self.asset.name + def __repr__(self) -> str: args = [] for attr in [ diff --git a/airflow/ui/openapi-gen/queries/common.ts b/airflow/ui/openapi-gen/queries/common.ts index 02e0910aae2d9..ec71219dfd3c6 100644 --- a/airflow/ui/openapi-gen/queries/common.ts +++ b/airflow/ui/openapi-gen/queries/common.ts @@ -1,1674 +1,611 @@ -// generated with @7nohe/openapi-react-query-codegen@1.6.0 -import { UseQueryResult } from "@tanstack/react-query"; +// generated with @7nohe/openapi-react-query-codegen@1.6.0 -import { - AssetService, - BackfillService, - ConfigService, - ConnectionService, - DagParsingService, - DagRunService, - DagService, - DagSourceService, - DagStatsService, - DagWarningService, - DagsService, - DashboardService, - EventLogService, - ExtraLinksService, - GridService, - ImportErrorService, - JobService, - MonitorService, - PluginService, - PoolService, - ProviderService, - StructureService, - TaskInstanceService, - TaskService, - VariableService, - VersionService, - XcomService, -} from "../requests/services.gen"; +import { UseQueryResult } from "@tanstack/react-query"; +import { AssetService, BackfillService, ConfigService, ConnectionService, DagParsingService, DagRunService, DagService, DagSourceService, DagStatsService, DagWarningService, DagsService, DashboardService, EventLogService, ExtraLinksService, GridService, ImportErrorService, JobService, MonitorService, PluginService, PoolService, ProviderService, StructureService, TaskInstanceService, TaskService, VariableService, VersionService, XcomService } from "../requests/services.gen"; import { DagRunState, DagWarningType } from "../requests/types.gen"; - export type AssetServiceNextRunAssetsDefaultResponse = Awaited>; -export type AssetServiceNextRunAssetsQueryResult< - TData = AssetServiceNextRunAssetsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type AssetServiceNextRunAssetsQueryResult = UseQueryResult; export const useAssetServiceNextRunAssetsKey = "AssetServiceNextRunAssets"; -export const UseAssetServiceNextRunAssetsKeyFn = ( - { - dagId, - }: { - dagId: string; - }, - queryKey?: Array, -) => [useAssetServiceNextRunAssetsKey, ...(queryKey ?? [{ dagId }])]; +export const UseAssetServiceNextRunAssetsKeyFn = ({ dagId }: { + dagId: string; +}, queryKey?: Array) => [useAssetServiceNextRunAssetsKey, ...(queryKey ?? [{ dagId }])]; export type AssetServiceGetAssetsDefaultResponse = Awaited>; -export type AssetServiceGetAssetsQueryResult< - TData = AssetServiceGetAssetsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type AssetServiceGetAssetsQueryResult = UseQueryResult; export const useAssetServiceGetAssetsKey = "AssetServiceGetAssets"; -export const UseAssetServiceGetAssetsKeyFn = ( - { - dagIds, - limit, - namePattern, - offset, - orderBy, - uriPattern, - }: { - dagIds?: string[]; - limit?: number; - namePattern?: string; - offset?: number; - orderBy?: string; - uriPattern?: string; - } = {}, - queryKey?: Array, -) => [ - useAssetServiceGetAssetsKey, - ...(queryKey ?? [{ dagIds, limit, namePattern, offset, orderBy, uriPattern }]), -]; -export type AssetServiceGetAssetAliasesDefaultResponse = Awaited< - ReturnType ->; -export type AssetServiceGetAssetAliasesQueryResult< - TData = AssetServiceGetAssetAliasesDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseAssetServiceGetAssetsKeyFn = ({ dagIds, limit, namePattern, offset, orderBy, uriPattern }: { + dagIds?: string[]; + limit?: number; + namePattern?: string; + offset?: number; + orderBy?: string; + uriPattern?: string; +} = {}, queryKey?: Array) => [useAssetServiceGetAssetsKey, ...(queryKey ?? [{ dagIds, limit, namePattern, offset, orderBy, uriPattern }])]; +export type AssetServiceGetAssetAliasesDefaultResponse = Awaited>; +export type AssetServiceGetAssetAliasesQueryResult = UseQueryResult; export const useAssetServiceGetAssetAliasesKey = "AssetServiceGetAssetAliases"; -export const UseAssetServiceGetAssetAliasesKeyFn = ( - { - limit, - namePattern, - offset, - orderBy, - }: { - limit?: number; - namePattern?: string; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: Array, -) => [useAssetServiceGetAssetAliasesKey, ...(queryKey ?? [{ limit, namePattern, offset, orderBy }])]; +export const UseAssetServiceGetAssetAliasesKeyFn = ({ limit, namePattern, offset, orderBy }: { + limit?: number; + namePattern?: string; + offset?: number; + orderBy?: string; +} = {}, queryKey?: Array) => [useAssetServiceGetAssetAliasesKey, ...(queryKey ?? [{ limit, namePattern, offset, orderBy }])]; export type AssetServiceGetAssetAliasDefaultResponse = Awaited>; -export type AssetServiceGetAssetAliasQueryResult< - TData = AssetServiceGetAssetAliasDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type AssetServiceGetAssetAliasQueryResult = UseQueryResult; export const useAssetServiceGetAssetAliasKey = "AssetServiceGetAssetAlias"; -export const UseAssetServiceGetAssetAliasKeyFn = ( - { - assetAliasId, - }: { - assetAliasId: number; - }, - queryKey?: Array, -) => [useAssetServiceGetAssetAliasKey, ...(queryKey ?? [{ assetAliasId }])]; -export type AssetServiceGetAssetEventsDefaultResponse = Awaited< - ReturnType ->; -export type AssetServiceGetAssetEventsQueryResult< - TData = AssetServiceGetAssetEventsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseAssetServiceGetAssetAliasKeyFn = ({ assetAliasId }: { + assetAliasId: number; +}, queryKey?: Array) => [useAssetServiceGetAssetAliasKey, ...(queryKey ?? [{ assetAliasId }])]; +export type AssetServiceGetAssetEventsDefaultResponse = Awaited>; +export type AssetServiceGetAssetEventsQueryResult = UseQueryResult; export const useAssetServiceGetAssetEventsKey = "AssetServiceGetAssetEvents"; -export const UseAssetServiceGetAssetEventsKeyFn = ( - { - assetId, - limit, - offset, - orderBy, - sourceDagId, - sourceMapIndex, - sourceRunId, - sourceTaskId, - timestampGte, - timestampLte, - }: { - assetId?: number; - limit?: number; - offset?: number; - orderBy?: string; - sourceDagId?: string; - sourceMapIndex?: number; - sourceRunId?: string; - sourceTaskId?: string; - timestampGte?: string; - timestampLte?: string; - } = {}, - queryKey?: Array, -) => [ - useAssetServiceGetAssetEventsKey, - ...(queryKey ?? [ - { - assetId, - limit, - offset, - orderBy, - sourceDagId, - sourceMapIndex, - sourceRunId, - sourceTaskId, - timestampGte, - timestampLte, - }, - ]), -]; -export type AssetServiceGetAssetQueuedEventsDefaultResponse = Awaited< - ReturnType ->; -export type AssetServiceGetAssetQueuedEventsQueryResult< - TData = AssetServiceGetAssetQueuedEventsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseAssetServiceGetAssetEventsKeyFn = ({ assetId, limit, offset, orderBy, sourceDagId, sourceMapIndex, sourceRunId, sourceTaskId, timestampGte, timestampLte }: { + assetId?: number; + limit?: number; + offset?: number; + orderBy?: string; + sourceDagId?: string; + sourceMapIndex?: number; + sourceRunId?: string; + sourceTaskId?: string; + timestampGte?: string; + timestampLte?: string; +} = {}, queryKey?: Array) => [useAssetServiceGetAssetEventsKey, ...(queryKey ?? [{ assetId, limit, offset, orderBy, sourceDagId, sourceMapIndex, sourceRunId, sourceTaskId, timestampGte, timestampLte }])]; +export type AssetServiceGetAssetQueuedEventsDefaultResponse = Awaited>; +export type AssetServiceGetAssetQueuedEventsQueryResult = UseQueryResult; export const useAssetServiceGetAssetQueuedEventsKey = "AssetServiceGetAssetQueuedEvents"; -export const UseAssetServiceGetAssetQueuedEventsKeyFn = ( - { - assetId, - before, - }: { - assetId: number; - before?: string; - }, - queryKey?: Array, -) => [useAssetServiceGetAssetQueuedEventsKey, ...(queryKey ?? [{ assetId, before }])]; +export const UseAssetServiceGetAssetQueuedEventsKeyFn = ({ assetId, before }: { + assetId: number; + before?: string; +}, queryKey?: Array) => [useAssetServiceGetAssetQueuedEventsKey, ...(queryKey ?? [{ assetId, before }])]; export type AssetServiceGetAssetDefaultResponse = Awaited>; -export type AssetServiceGetAssetQueryResult< - TData = AssetServiceGetAssetDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type AssetServiceGetAssetQueryResult = UseQueryResult; export const useAssetServiceGetAssetKey = "AssetServiceGetAsset"; -export const UseAssetServiceGetAssetKeyFn = ( - { - assetId, - }: { - assetId: number; - }, - queryKey?: Array, -) => [useAssetServiceGetAssetKey, ...(queryKey ?? [{ assetId }])]; -export type AssetServiceGetDagAssetQueuedEventsDefaultResponse = Awaited< - ReturnType ->; -export type AssetServiceGetDagAssetQueuedEventsQueryResult< - TData = AssetServiceGetDagAssetQueuedEventsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseAssetServiceGetAssetKeyFn = ({ assetId }: { + assetId: number; +}, queryKey?: Array) => [useAssetServiceGetAssetKey, ...(queryKey ?? [{ assetId }])]; +export type AssetServiceGetDagAssetQueuedEventsDefaultResponse = Awaited>; +export type AssetServiceGetDagAssetQueuedEventsQueryResult = UseQueryResult; export const useAssetServiceGetDagAssetQueuedEventsKey = "AssetServiceGetDagAssetQueuedEvents"; -export const UseAssetServiceGetDagAssetQueuedEventsKeyFn = ( - { - before, - dagId, - }: { - before?: string; - dagId: string; - }, - queryKey?: Array, -) => [useAssetServiceGetDagAssetQueuedEventsKey, ...(queryKey ?? [{ before, dagId }])]; -export type AssetServiceGetDagAssetQueuedEventDefaultResponse = Awaited< - ReturnType ->; -export type AssetServiceGetDagAssetQueuedEventQueryResult< - TData = AssetServiceGetDagAssetQueuedEventDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseAssetServiceGetDagAssetQueuedEventsKeyFn = ({ before, dagId }: { + before?: string; + dagId: string; +}, queryKey?: Array) => [useAssetServiceGetDagAssetQueuedEventsKey, ...(queryKey ?? [{ before, dagId }])]; +export type AssetServiceGetDagAssetQueuedEventDefaultResponse = Awaited>; +export type AssetServiceGetDagAssetQueuedEventQueryResult = UseQueryResult; export const useAssetServiceGetDagAssetQueuedEventKey = "AssetServiceGetDagAssetQueuedEvent"; -export const UseAssetServiceGetDagAssetQueuedEventKeyFn = ( - { - assetId, - before, - dagId, - }: { - assetId: number; - before?: string; - dagId: string; - }, - queryKey?: Array, -) => [useAssetServiceGetDagAssetQueuedEventKey, ...(queryKey ?? [{ assetId, before, dagId }])]; +export const UseAssetServiceGetDagAssetQueuedEventKeyFn = ({ assetId, before, dagId }: { + assetId: number; + before?: string; + dagId: string; +}, queryKey?: Array) => [useAssetServiceGetDagAssetQueuedEventKey, ...(queryKey ?? [{ assetId, before, dagId }])]; export type ConfigServiceGetConfigsDefaultResponse = Awaited>; -export type ConfigServiceGetConfigsQueryResult< - TData = ConfigServiceGetConfigsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type ConfigServiceGetConfigsQueryResult = UseQueryResult; export const useConfigServiceGetConfigsKey = "ConfigServiceGetConfigs"; -export const UseConfigServiceGetConfigsKeyFn = (queryKey?: Array) => [ - useConfigServiceGetConfigsKey, - ...(queryKey ?? []), -]; +export const UseConfigServiceGetConfigsKeyFn = (queryKey?: Array) => [useConfigServiceGetConfigsKey, ...(queryKey ?? [])]; export type ConfigServiceGetConfigDefaultResponse = Awaited>; -export type ConfigServiceGetConfigQueryResult< - TData = ConfigServiceGetConfigDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type ConfigServiceGetConfigQueryResult = UseQueryResult; export const useConfigServiceGetConfigKey = "ConfigServiceGetConfig"; -export const UseConfigServiceGetConfigKeyFn = ( - { - accept, - section, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - section?: string; - } = {}, - queryKey?: Array, -) => [useConfigServiceGetConfigKey, ...(queryKey ?? [{ accept, section }])]; -export type ConfigServiceGetConfigValueDefaultResponse = Awaited< - ReturnType ->; -export type ConfigServiceGetConfigValueQueryResult< - TData = ConfigServiceGetConfigValueDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseConfigServiceGetConfigKeyFn = ({ accept, section }: { + accept?: "application/json" | "text/plain" | "*/*"; + section?: string; +} = {}, queryKey?: Array) => [useConfigServiceGetConfigKey, ...(queryKey ?? [{ accept, section }])]; +export type ConfigServiceGetConfigValueDefaultResponse = Awaited>; +export type ConfigServiceGetConfigValueQueryResult = UseQueryResult; export const useConfigServiceGetConfigValueKey = "ConfigServiceGetConfigValue"; -export const UseConfigServiceGetConfigValueKeyFn = ( - { - accept, - option, - section, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - option: string; - section: string; - }, - queryKey?: Array, -) => [useConfigServiceGetConfigValueKey, ...(queryKey ?? [{ accept, option, section }])]; +export const UseConfigServiceGetConfigValueKeyFn = ({ accept, option, section }: { + accept?: "application/json" | "text/plain" | "*/*"; + option: string; + section: string; +}, queryKey?: Array) => [useConfigServiceGetConfigValueKey, ...(queryKey ?? [{ accept, option, section }])]; export type DagsServiceRecentDagRunsDefaultResponse = Awaited>; -export type DagsServiceRecentDagRunsQueryResult< - TData = DagsServiceRecentDagRunsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type DagsServiceRecentDagRunsQueryResult = UseQueryResult; export const useDagsServiceRecentDagRunsKey = "DagsServiceRecentDagRuns"; -export const UseDagsServiceRecentDagRunsKeyFn = ( - { - dagDisplayNamePattern, - dagIdPattern, - dagIds, - dagRunsLimit, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - tags, - }: { - dagDisplayNamePattern?: string; - dagIdPattern?: string; - dagIds?: string[]; - dagRunsLimit?: number; - lastDagRunState?: DagRunState; - limit?: number; - offset?: number; - onlyActive?: boolean; - owners?: string[]; - paused?: boolean; - tags?: string[]; - } = {}, - queryKey?: Array, -) => [ - useDagsServiceRecentDagRunsKey, - ...(queryKey ?? [ - { - dagDisplayNamePattern, - dagIdPattern, - dagIds, - dagRunsLimit, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - tags, - }, - ]), -]; -export type DashboardServiceHistoricalMetricsDefaultResponse = Awaited< - ReturnType ->; -export type DashboardServiceHistoricalMetricsQueryResult< - TData = DashboardServiceHistoricalMetricsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseDagsServiceRecentDagRunsKeyFn = ({ dagDisplayNamePattern, dagIdPattern, dagIds, dagRunsLimit, lastDagRunState, limit, offset, onlyActive, owners, paused, tags }: { + dagDisplayNamePattern?: string; + dagIdPattern?: string; + dagIds?: string[]; + dagRunsLimit?: number; + lastDagRunState?: DagRunState; + limit?: number; + offset?: number; + onlyActive?: boolean; + owners?: string[]; + paused?: boolean; + tags?: string[]; +} = {}, queryKey?: Array) => [useDagsServiceRecentDagRunsKey, ...(queryKey ?? [{ dagDisplayNamePattern, dagIdPattern, dagIds, dagRunsLimit, lastDagRunState, limit, offset, onlyActive, owners, paused, tags }])]; +export type DashboardServiceHistoricalMetricsDefaultResponse = Awaited>; +export type DashboardServiceHistoricalMetricsQueryResult = UseQueryResult; export const useDashboardServiceHistoricalMetricsKey = "DashboardServiceHistoricalMetrics"; -export const UseDashboardServiceHistoricalMetricsKeyFn = ( - { - endDate, - startDate, - }: { - endDate?: string; - startDate: string; - }, - queryKey?: Array, -) => [useDashboardServiceHistoricalMetricsKey, ...(queryKey ?? [{ endDate, startDate }])]; -export type StructureServiceStructureDataDefaultResponse = Awaited< - ReturnType ->; -export type StructureServiceStructureDataQueryResult< - TData = StructureServiceStructureDataDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseDashboardServiceHistoricalMetricsKeyFn = ({ endDate, startDate }: { + endDate?: string; + startDate: string; +}, queryKey?: Array) => [useDashboardServiceHistoricalMetricsKey, ...(queryKey ?? [{ endDate, startDate }])]; +export type StructureServiceStructureDataDefaultResponse = Awaited>; +export type StructureServiceStructureDataQueryResult = UseQueryResult; export const useStructureServiceStructureDataKey = "StructureServiceStructureData"; -export const UseStructureServiceStructureDataKeyFn = ( - { - dagId, - externalDependencies, - includeDownstream, - includeUpstream, - root, - }: { - dagId: string; - externalDependencies?: boolean; - includeDownstream?: boolean; - includeUpstream?: boolean; - root?: string; - }, - queryKey?: Array, -) => [ - useStructureServiceStructureDataKey, - ...(queryKey ?? [{ dagId, externalDependencies, includeDownstream, includeUpstream, root }]), -]; -export type BackfillServiceListBackfillsDefaultResponse = Awaited< - ReturnType ->; -export type BackfillServiceListBackfillsQueryResult< - TData = BackfillServiceListBackfillsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseStructureServiceStructureDataKeyFn = ({ dagId, externalDependencies, includeDownstream, includeUpstream, root }: { + dagId: string; + externalDependencies?: boolean; + includeDownstream?: boolean; + includeUpstream?: boolean; + root?: string; +}, queryKey?: Array) => [useStructureServiceStructureDataKey, ...(queryKey ?? [{ dagId, externalDependencies, includeDownstream, includeUpstream, root }])]; +export type BackfillServiceListBackfillsDefaultResponse = Awaited>; +export type BackfillServiceListBackfillsQueryResult = UseQueryResult; export const useBackfillServiceListBackfillsKey = "BackfillServiceListBackfills"; -export const UseBackfillServiceListBackfillsKeyFn = ( - { - active, - dagId, - limit, - offset, - orderBy, - }: { - active?: boolean; - dagId?: string; - limit?: number; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: Array, -) => [useBackfillServiceListBackfillsKey, ...(queryKey ?? [{ active, dagId, limit, offset, orderBy }])]; -export type BackfillServiceListBackfills1DefaultResponse = Awaited< - ReturnType ->; -export type BackfillServiceListBackfills1QueryResult< - TData = BackfillServiceListBackfills1DefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseBackfillServiceListBackfillsKeyFn = ({ active, dagId, limit, offset, orderBy }: { + active?: boolean; + dagId?: string; + limit?: number; + offset?: number; + orderBy?: string; +} = {}, queryKey?: Array) => [useBackfillServiceListBackfillsKey, ...(queryKey ?? [{ active, dagId, limit, offset, orderBy }])]; +export type BackfillServiceListBackfills1DefaultResponse = Awaited>; +export type BackfillServiceListBackfills1QueryResult = UseQueryResult; export const useBackfillServiceListBackfills1Key = "BackfillServiceListBackfills1"; -export const UseBackfillServiceListBackfills1KeyFn = ( - { - dagId, - limit, - offset, - orderBy, - }: { - dagId: string; - limit?: number; - offset?: number; - orderBy?: string; - }, - queryKey?: Array, -) => [useBackfillServiceListBackfills1Key, ...(queryKey ?? [{ dagId, limit, offset, orderBy }])]; -export type BackfillServiceGetBackfillDefaultResponse = Awaited< - ReturnType ->; -export type BackfillServiceGetBackfillQueryResult< - TData = BackfillServiceGetBackfillDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseBackfillServiceListBackfills1KeyFn = ({ dagId, limit, offset, orderBy }: { + dagId: string; + limit?: number; + offset?: number; + orderBy?: string; +}, queryKey?: Array) => [useBackfillServiceListBackfills1Key, ...(queryKey ?? [{ dagId, limit, offset, orderBy }])]; +export type BackfillServiceGetBackfillDefaultResponse = Awaited>; +export type BackfillServiceGetBackfillQueryResult = UseQueryResult; export const useBackfillServiceGetBackfillKey = "BackfillServiceGetBackfill"; -export const UseBackfillServiceGetBackfillKeyFn = ( - { - backfillId, - }: { - backfillId: string; - }, - queryKey?: Array, -) => [useBackfillServiceGetBackfillKey, ...(queryKey ?? [{ backfillId }])]; +export const UseBackfillServiceGetBackfillKeyFn = ({ backfillId }: { + backfillId: string; +}, queryKey?: Array) => [useBackfillServiceGetBackfillKey, ...(queryKey ?? [{ backfillId }])]; export type GridServiceGridDataDefaultResponse = Awaited>; -export type GridServiceGridDataQueryResult< - TData = GridServiceGridDataDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type GridServiceGridDataQueryResult = UseQueryResult; export const useGridServiceGridDataKey = "GridServiceGridData"; -export const UseGridServiceGridDataKeyFn = ( - { - dagId, - includeDownstream, - includeUpstream, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - root, - runType, - state, - }: { - dagId: string; - includeDownstream?: boolean; - includeUpstream?: boolean; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - root?: string; - runType?: string[]; - state?: string[]; - }, - queryKey?: Array, -) => [ - useGridServiceGridDataKey, - ...(queryKey ?? [ - { - dagId, - includeDownstream, - includeUpstream, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - root, - runType, - state, - }, - ]), -]; -export type ConnectionServiceGetConnectionDefaultResponse = Awaited< - ReturnType ->; -export type ConnectionServiceGetConnectionQueryResult< - TData = ConnectionServiceGetConnectionDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseGridServiceGridDataKeyFn = ({ dagId, includeDownstream, includeUpstream, limit, logicalDateGte, logicalDateLte, offset, orderBy, root, runType, state }: { + dagId: string; + includeDownstream?: boolean; + includeUpstream?: boolean; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + root?: string; + runType?: string[]; + state?: string[]; +}, queryKey?: Array) => [useGridServiceGridDataKey, ...(queryKey ?? [{ dagId, includeDownstream, includeUpstream, limit, logicalDateGte, logicalDateLte, offset, orderBy, root, runType, state }])]; +export type ConnectionServiceGetConnectionDefaultResponse = Awaited>; +export type ConnectionServiceGetConnectionQueryResult = UseQueryResult; export const useConnectionServiceGetConnectionKey = "ConnectionServiceGetConnection"; -export const UseConnectionServiceGetConnectionKeyFn = ( - { - connectionId, - }: { - connectionId: string; - }, - queryKey?: Array, -) => [useConnectionServiceGetConnectionKey, ...(queryKey ?? [{ connectionId }])]; -export type ConnectionServiceGetConnectionsDefaultResponse = Awaited< - ReturnType ->; -export type ConnectionServiceGetConnectionsQueryResult< - TData = ConnectionServiceGetConnectionsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseConnectionServiceGetConnectionKeyFn = ({ connectionId }: { + connectionId: string; +}, queryKey?: Array) => [useConnectionServiceGetConnectionKey, ...(queryKey ?? [{ connectionId }])]; +export type ConnectionServiceGetConnectionsDefaultResponse = Awaited>; +export type ConnectionServiceGetConnectionsQueryResult = UseQueryResult; export const useConnectionServiceGetConnectionsKey = "ConnectionServiceGetConnections"; -export const UseConnectionServiceGetConnectionsKeyFn = ( - { - limit, - offset, - orderBy, - }: { - limit?: number; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: Array, -) => [useConnectionServiceGetConnectionsKey, ...(queryKey ?? [{ limit, offset, orderBy }])]; +export const UseConnectionServiceGetConnectionsKeyFn = ({ limit, offset, orderBy }: { + limit?: number; + offset?: number; + orderBy?: string; +} = {}, queryKey?: Array) => [useConnectionServiceGetConnectionsKey, ...(queryKey ?? [{ limit, offset, orderBy }])]; export type DagRunServiceGetDagRunDefaultResponse = Awaited>; -export type DagRunServiceGetDagRunQueryResult< - TData = DagRunServiceGetDagRunDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type DagRunServiceGetDagRunQueryResult = UseQueryResult; export const useDagRunServiceGetDagRunKey = "DagRunServiceGetDagRun"; -export const UseDagRunServiceGetDagRunKeyFn = ( - { - dagId, - dagRunId, - }: { - dagId: string; - dagRunId: string; - }, - queryKey?: Array, -) => [useDagRunServiceGetDagRunKey, ...(queryKey ?? [{ dagId, dagRunId }])]; -export type DagRunServiceGetUpstreamAssetEventsDefaultResponse = Awaited< - ReturnType ->; -export type DagRunServiceGetUpstreamAssetEventsQueryResult< - TData = DagRunServiceGetUpstreamAssetEventsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseDagRunServiceGetDagRunKeyFn = ({ dagId, dagRunId }: { + dagId: string; + dagRunId: string; +}, queryKey?: Array) => [useDagRunServiceGetDagRunKey, ...(queryKey ?? [{ dagId, dagRunId }])]; +export type DagRunServiceGetUpstreamAssetEventsDefaultResponse = Awaited>; +export type DagRunServiceGetUpstreamAssetEventsQueryResult = UseQueryResult; export const useDagRunServiceGetUpstreamAssetEventsKey = "DagRunServiceGetUpstreamAssetEvents"; -export const UseDagRunServiceGetUpstreamAssetEventsKeyFn = ( - { - dagId, - dagRunId, - }: { - dagId: string; - dagRunId: string; - }, - queryKey?: Array, -) => [useDagRunServiceGetUpstreamAssetEventsKey, ...(queryKey ?? [{ dagId, dagRunId }])]; +export const UseDagRunServiceGetUpstreamAssetEventsKeyFn = ({ dagId, dagRunId }: { + dagId: string; + dagRunId: string; +}, queryKey?: Array) => [useDagRunServiceGetUpstreamAssetEventsKey, ...(queryKey ?? [{ dagId, dagRunId }])]; export type DagRunServiceGetDagRunsDefaultResponse = Awaited>; -export type DagRunServiceGetDagRunsQueryResult< - TData = DagRunServiceGetDagRunsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type DagRunServiceGetDagRunsQueryResult = UseQueryResult; export const useDagRunServiceGetDagRunsKey = "DagRunServiceGetDagRuns"; -export const UseDagRunServiceGetDagRunsKeyFn = ( - { - dagId, - endDateGte, - endDateLte, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - startDateGte, - startDateLte, - state, - updatedAtGte, - updatedAtLte, - }: { - dagId: string; - endDateGte?: string; - endDateLte?: string; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - startDateGte?: string; - startDateLte?: string; - state?: string[]; - updatedAtGte?: string; - updatedAtLte?: string; - }, - queryKey?: Array, -) => [ - useDagRunServiceGetDagRunsKey, - ...(queryKey ?? [ - { - dagId, - endDateGte, - endDateLte, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - startDateGte, - startDateLte, - state, - updatedAtGte, - updatedAtLte, - }, - ]), -]; -export type DagSourceServiceGetDagSourceDefaultResponse = Awaited< - ReturnType ->; -export type DagSourceServiceGetDagSourceQueryResult< - TData = DagSourceServiceGetDagSourceDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseDagRunServiceGetDagRunsKeyFn = ({ dagId, endDateGte, endDateLte, limit, logicalDateGte, logicalDateLte, offset, orderBy, startDateGte, startDateLte, state, updatedAtGte, updatedAtLte }: { + dagId: string; + endDateGte?: string; + endDateLte?: string; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + startDateGte?: string; + startDateLte?: string; + state?: string[]; + updatedAtGte?: string; + updatedAtLte?: string; +}, queryKey?: Array) => [useDagRunServiceGetDagRunsKey, ...(queryKey ?? [{ dagId, endDateGte, endDateLte, limit, logicalDateGte, logicalDateLte, offset, orderBy, startDateGte, startDateLte, state, updatedAtGte, updatedAtLte }])]; +export type DagSourceServiceGetDagSourceDefaultResponse = Awaited>; +export type DagSourceServiceGetDagSourceQueryResult = UseQueryResult; export const useDagSourceServiceGetDagSourceKey = "DagSourceServiceGetDagSource"; -export const UseDagSourceServiceGetDagSourceKeyFn = ( - { - accept, - dagId, - versionNumber, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - dagId: string; - versionNumber?: number; - }, - queryKey?: Array, -) => [useDagSourceServiceGetDagSourceKey, ...(queryKey ?? [{ accept, dagId, versionNumber }])]; -export type DagStatsServiceGetDagStatsDefaultResponse = Awaited< - ReturnType ->; -export type DagStatsServiceGetDagStatsQueryResult< - TData = DagStatsServiceGetDagStatsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseDagSourceServiceGetDagSourceKeyFn = ({ accept, dagId, versionNumber }: { + accept?: "application/json" | "text/plain" | "*/*"; + dagId: string; + versionNumber?: number; +}, queryKey?: Array) => [useDagSourceServiceGetDagSourceKey, ...(queryKey ?? [{ accept, dagId, versionNumber }])]; +export type DagStatsServiceGetDagStatsDefaultResponse = Awaited>; +export type DagStatsServiceGetDagStatsQueryResult = UseQueryResult; export const useDagStatsServiceGetDagStatsKey = "DagStatsServiceGetDagStats"; -export const UseDagStatsServiceGetDagStatsKeyFn = ( - { - dagIds, - }: { - dagIds?: string[]; - } = {}, - queryKey?: Array, -) => [useDagStatsServiceGetDagStatsKey, ...(queryKey ?? [{ dagIds }])]; -export type DagWarningServiceListDagWarningsDefaultResponse = Awaited< - ReturnType ->; -export type DagWarningServiceListDagWarningsQueryResult< - TData = DagWarningServiceListDagWarningsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseDagStatsServiceGetDagStatsKeyFn = ({ dagIds }: { + dagIds?: string[]; +} = {}, queryKey?: Array) => [useDagStatsServiceGetDagStatsKey, ...(queryKey ?? [{ dagIds }])]; +export type DagWarningServiceListDagWarningsDefaultResponse = Awaited>; +export type DagWarningServiceListDagWarningsQueryResult = UseQueryResult; export const useDagWarningServiceListDagWarningsKey = "DagWarningServiceListDagWarnings"; -export const UseDagWarningServiceListDagWarningsKeyFn = ( - { - dagId, - limit, - offset, - orderBy, - warningType, - }: { - dagId?: string; - limit?: number; - offset?: number; - orderBy?: string; - warningType?: DagWarningType; - } = {}, - queryKey?: Array, -) => [ - useDagWarningServiceListDagWarningsKey, - ...(queryKey ?? [{ dagId, limit, offset, orderBy, warningType }]), -]; +export const UseDagWarningServiceListDagWarningsKeyFn = ({ dagId, limit, offset, orderBy, warningType }: { + dagId?: string; + limit?: number; + offset?: number; + orderBy?: string; + warningType?: DagWarningType; +} = {}, queryKey?: Array) => [useDagWarningServiceListDagWarningsKey, ...(queryKey ?? [{ dagId, limit, offset, orderBy, warningType }])]; export type DagServiceGetDagsDefaultResponse = Awaited>; -export type DagServiceGetDagsQueryResult< - TData = DagServiceGetDagsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type DagServiceGetDagsQueryResult = UseQueryResult; export const useDagServiceGetDagsKey = "DagServiceGetDags"; -export const UseDagServiceGetDagsKeyFn = ( - { - dagDisplayNamePattern, - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - orderBy, - owners, - paused, - tags, - }: { - dagDisplayNamePattern?: string; - dagIdPattern?: string; - lastDagRunState?: DagRunState; - limit?: number; - offset?: number; - onlyActive?: boolean; - orderBy?: string; - owners?: string[]; - paused?: boolean; - tags?: string[]; - } = {}, - queryKey?: Array, -) => [ - useDagServiceGetDagsKey, - ...(queryKey ?? [ - { - dagDisplayNamePattern, - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - orderBy, - owners, - paused, - tags, - }, - ]), -]; +export const UseDagServiceGetDagsKeyFn = ({ dagDisplayNamePattern, dagIdPattern, lastDagRunState, limit, offset, onlyActive, orderBy, owners, paused, tags }: { + dagDisplayNamePattern?: string; + dagIdPattern?: string; + lastDagRunState?: DagRunState; + limit?: number; + offset?: number; + onlyActive?: boolean; + orderBy?: string; + owners?: string[]; + paused?: boolean; + tags?: string[]; +} = {}, queryKey?: Array) => [useDagServiceGetDagsKey, ...(queryKey ?? [{ dagDisplayNamePattern, dagIdPattern, lastDagRunState, limit, offset, onlyActive, orderBy, owners, paused, tags }])]; export type DagServiceGetDagDefaultResponse = Awaited>; -export type DagServiceGetDagQueryResult< - TData = DagServiceGetDagDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type DagServiceGetDagQueryResult = UseQueryResult; export const useDagServiceGetDagKey = "DagServiceGetDag"; -export const UseDagServiceGetDagKeyFn = ( - { - dagId, - }: { - dagId: string; - }, - queryKey?: Array, -) => [useDagServiceGetDagKey, ...(queryKey ?? [{ dagId }])]; +export const UseDagServiceGetDagKeyFn = ({ dagId }: { + dagId: string; +}, queryKey?: Array) => [useDagServiceGetDagKey, ...(queryKey ?? [{ dagId }])]; export type DagServiceGetDagDetailsDefaultResponse = Awaited>; -export type DagServiceGetDagDetailsQueryResult< - TData = DagServiceGetDagDetailsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type DagServiceGetDagDetailsQueryResult = UseQueryResult; export const useDagServiceGetDagDetailsKey = "DagServiceGetDagDetails"; -export const UseDagServiceGetDagDetailsKeyFn = ( - { - dagId, - }: { - dagId: string; - }, - queryKey?: Array, -) => [useDagServiceGetDagDetailsKey, ...(queryKey ?? [{ dagId }])]; +export const UseDagServiceGetDagDetailsKeyFn = ({ dagId }: { + dagId: string; +}, queryKey?: Array) => [useDagServiceGetDagDetailsKey, ...(queryKey ?? [{ dagId }])]; export type DagServiceGetDagTagsDefaultResponse = Awaited>; -export type DagServiceGetDagTagsQueryResult< - TData = DagServiceGetDagTagsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type DagServiceGetDagTagsQueryResult = UseQueryResult; export const useDagServiceGetDagTagsKey = "DagServiceGetDagTags"; -export const UseDagServiceGetDagTagsKeyFn = ( - { - limit, - offset, - orderBy, - tagNamePattern, - }: { - limit?: number; - offset?: number; - orderBy?: string; - tagNamePattern?: string; - } = {}, - queryKey?: Array, -) => [useDagServiceGetDagTagsKey, ...(queryKey ?? [{ limit, offset, orderBy, tagNamePattern }])]; -export type EventLogServiceGetEventLogDefaultResponse = Awaited< - ReturnType ->; -export type EventLogServiceGetEventLogQueryResult< - TData = EventLogServiceGetEventLogDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseDagServiceGetDagTagsKeyFn = ({ limit, offset, orderBy, tagNamePattern }: { + limit?: number; + offset?: number; + orderBy?: string; + tagNamePattern?: string; +} = {}, queryKey?: Array) => [useDagServiceGetDagTagsKey, ...(queryKey ?? [{ limit, offset, orderBy, tagNamePattern }])]; +export type EventLogServiceGetEventLogDefaultResponse = Awaited>; +export type EventLogServiceGetEventLogQueryResult = UseQueryResult; export const useEventLogServiceGetEventLogKey = "EventLogServiceGetEventLog"; -export const UseEventLogServiceGetEventLogKeyFn = ( - { - eventLogId, - }: { - eventLogId: number; - }, - queryKey?: Array, -) => [useEventLogServiceGetEventLogKey, ...(queryKey ?? [{ eventLogId }])]; -export type EventLogServiceGetEventLogsDefaultResponse = Awaited< - ReturnType ->; -export type EventLogServiceGetEventLogsQueryResult< - TData = EventLogServiceGetEventLogsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseEventLogServiceGetEventLogKeyFn = ({ eventLogId }: { + eventLogId: number; +}, queryKey?: Array) => [useEventLogServiceGetEventLogKey, ...(queryKey ?? [{ eventLogId }])]; +export type EventLogServiceGetEventLogsDefaultResponse = Awaited>; +export type EventLogServiceGetEventLogsQueryResult = UseQueryResult; export const useEventLogServiceGetEventLogsKey = "EventLogServiceGetEventLogs"; -export const UseEventLogServiceGetEventLogsKeyFn = ( - { - after, - before, - dagId, - event, - excludedEvents, - includedEvents, - limit, - mapIndex, - offset, - orderBy, - owner, - runId, - taskId, - tryNumber, - }: { - after?: string; - before?: string; - dagId?: string; - event?: string; - excludedEvents?: string[]; - includedEvents?: string[]; - limit?: number; - mapIndex?: number; - offset?: number; - orderBy?: string; - owner?: string; - runId?: string; - taskId?: string; - tryNumber?: number; - } = {}, - queryKey?: Array, -) => [ - useEventLogServiceGetEventLogsKey, - ...(queryKey ?? [ - { - after, - before, - dagId, - event, - excludedEvents, - includedEvents, - limit, - mapIndex, - offset, - orderBy, - owner, - runId, - taskId, - tryNumber, - }, - ]), -]; -export type ExtraLinksServiceGetExtraLinksDefaultResponse = Awaited< - ReturnType ->; -export type ExtraLinksServiceGetExtraLinksQueryResult< - TData = ExtraLinksServiceGetExtraLinksDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseEventLogServiceGetEventLogsKeyFn = ({ after, before, dagId, event, excludedEvents, includedEvents, limit, mapIndex, offset, orderBy, owner, runId, taskId, tryNumber }: { + after?: string; + before?: string; + dagId?: string; + event?: string; + excludedEvents?: string[]; + includedEvents?: string[]; + limit?: number; + mapIndex?: number; + offset?: number; + orderBy?: string; + owner?: string; + runId?: string; + taskId?: string; + tryNumber?: number; +} = {}, queryKey?: Array) => [useEventLogServiceGetEventLogsKey, ...(queryKey ?? [{ after, before, dagId, event, excludedEvents, includedEvents, limit, mapIndex, offset, orderBy, owner, runId, taskId, tryNumber }])]; +export type ExtraLinksServiceGetExtraLinksDefaultResponse = Awaited>; +export type ExtraLinksServiceGetExtraLinksQueryResult = UseQueryResult; export const useExtraLinksServiceGetExtraLinksKey = "ExtraLinksServiceGetExtraLinks"; -export const UseExtraLinksServiceGetExtraLinksKeyFn = ( - { - dagId, - dagRunId, - taskId, - }: { - dagId: string; - dagRunId: string; - taskId: string; - }, - queryKey?: Array, -) => [useExtraLinksServiceGetExtraLinksKey, ...(queryKey ?? [{ dagId, dagRunId, taskId }])]; -export type TaskInstanceServiceGetExtraLinksDefaultResponse = Awaited< - ReturnType ->; -export type TaskInstanceServiceGetExtraLinksQueryResult< - TData = TaskInstanceServiceGetExtraLinksDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseExtraLinksServiceGetExtraLinksKeyFn = ({ dagId, dagRunId, taskId }: { + dagId: string; + dagRunId: string; + taskId: string; +}, queryKey?: Array) => [useExtraLinksServiceGetExtraLinksKey, ...(queryKey ?? [{ dagId, dagRunId, taskId }])]; +export type TaskInstanceServiceGetExtraLinksDefaultResponse = Awaited>; +export type TaskInstanceServiceGetExtraLinksQueryResult = UseQueryResult; export const useTaskInstanceServiceGetExtraLinksKey = "TaskInstanceServiceGetExtraLinks"; -export const UseTaskInstanceServiceGetExtraLinksKeyFn = ( - { - dagId, - dagRunId, - taskId, - }: { - dagId: string; - dagRunId: string; - taskId: string; - }, - queryKey?: Array, -) => [useTaskInstanceServiceGetExtraLinksKey, ...(queryKey ?? [{ dagId, dagRunId, taskId }])]; -export type TaskInstanceServiceGetTaskInstanceDefaultResponse = Awaited< - ReturnType ->; -export type TaskInstanceServiceGetTaskInstanceQueryResult< - TData = TaskInstanceServiceGetTaskInstanceDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseTaskInstanceServiceGetExtraLinksKeyFn = ({ dagId, dagRunId, taskId }: { + dagId: string; + dagRunId: string; + taskId: string; +}, queryKey?: Array) => [useTaskInstanceServiceGetExtraLinksKey, ...(queryKey ?? [{ dagId, dagRunId, taskId }])]; +export type TaskInstanceServiceGetTaskInstanceDefaultResponse = Awaited>; +export type TaskInstanceServiceGetTaskInstanceQueryResult = UseQueryResult; export const useTaskInstanceServiceGetTaskInstanceKey = "TaskInstanceServiceGetTaskInstance"; -export const UseTaskInstanceServiceGetTaskInstanceKeyFn = ( - { - dagId, - dagRunId, - taskId, - }: { - dagId: string; - dagRunId: string; - taskId: string; - }, - queryKey?: Array, -) => [useTaskInstanceServiceGetTaskInstanceKey, ...(queryKey ?? [{ dagId, dagRunId, taskId }])]; -export type TaskInstanceServiceGetMappedTaskInstancesDefaultResponse = Awaited< - ReturnType ->; -export type TaskInstanceServiceGetMappedTaskInstancesQueryResult< - TData = TaskInstanceServiceGetMappedTaskInstancesDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseTaskInstanceServiceGetTaskInstanceKeyFn = ({ dagId, dagRunId, taskId }: { + dagId: string; + dagRunId: string; + taskId: string; +}, queryKey?: Array) => [useTaskInstanceServiceGetTaskInstanceKey, ...(queryKey ?? [{ dagId, dagRunId, taskId }])]; +export type TaskInstanceServiceGetMappedTaskInstancesDefaultResponse = Awaited>; +export type TaskInstanceServiceGetMappedTaskInstancesQueryResult = UseQueryResult; export const useTaskInstanceServiceGetMappedTaskInstancesKey = "TaskInstanceServiceGetMappedTaskInstances"; -export const UseTaskInstanceServiceGetMappedTaskInstancesKeyFn = ( - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskId, - updatedAtGte, - updatedAtLte, - }: { - dagId: string; - dagRunId: string; - durationGte?: number; - durationLte?: number; - endDateGte?: string; - endDateLte?: string; - executor?: string[]; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - pool?: string[]; - queue?: string[]; - startDateGte?: string; - startDateLte?: string; - state?: string[]; - taskId: string; - updatedAtGte?: string; - updatedAtLte?: string; - }, - queryKey?: Array, -) => [ - useTaskInstanceServiceGetMappedTaskInstancesKey, - ...(queryKey ?? [ - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskId, - updatedAtGte, - updatedAtLte, - }, - ]), -]; -export type TaskInstanceServiceGetTaskInstanceDependenciesDefaultResponse = Awaited< - ReturnType ->; -export type TaskInstanceServiceGetTaskInstanceDependenciesQueryResult< - TData = TaskInstanceServiceGetTaskInstanceDependenciesDefaultResponse, - TError = unknown, -> = UseQueryResult; -export const useTaskInstanceServiceGetTaskInstanceDependenciesKey = - "TaskInstanceServiceGetTaskInstanceDependencies"; -export const UseTaskInstanceServiceGetTaskInstanceDependenciesKeyFn = ( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - }, - queryKey?: Array, -) => [ - useTaskInstanceServiceGetTaskInstanceDependenciesKey, - ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId }]), -]; -export type TaskInstanceServiceGetTaskInstanceDependencies1DefaultResponse = Awaited< - ReturnType ->; -export type TaskInstanceServiceGetTaskInstanceDependencies1QueryResult< - TData = TaskInstanceServiceGetTaskInstanceDependencies1DefaultResponse, - TError = unknown, -> = UseQueryResult; -export const useTaskInstanceServiceGetTaskInstanceDependencies1Key = - "TaskInstanceServiceGetTaskInstanceDependencies1"; -export const UseTaskInstanceServiceGetTaskInstanceDependencies1KeyFn = ( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex?: number; - taskId: string; - }, - queryKey?: Array, -) => [ - useTaskInstanceServiceGetTaskInstanceDependencies1Key, - ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId }]), -]; -export type TaskInstanceServiceGetTaskInstanceTriesDefaultResponse = Awaited< - ReturnType ->; -export type TaskInstanceServiceGetTaskInstanceTriesQueryResult< - TData = TaskInstanceServiceGetTaskInstanceTriesDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseTaskInstanceServiceGetMappedTaskInstancesKeyFn = ({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskId, updatedAtGte, updatedAtLte }: { + dagId: string; + dagRunId: string; + durationGte?: number; + durationLte?: number; + endDateGte?: string; + endDateLte?: string; + executor?: string[]; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + pool?: string[]; + queue?: string[]; + startDateGte?: string; + startDateLte?: string; + state?: string[]; + taskId: string; + updatedAtGte?: string; + updatedAtLte?: string; +}, queryKey?: Array) => [useTaskInstanceServiceGetMappedTaskInstancesKey, ...(queryKey ?? [{ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskId, updatedAtGte, updatedAtLte }])]; +export type TaskInstanceServiceGetTaskInstanceDependenciesDefaultResponse = Awaited>; +export type TaskInstanceServiceGetTaskInstanceDependenciesQueryResult = UseQueryResult; +export const useTaskInstanceServiceGetTaskInstanceDependenciesKey = "TaskInstanceServiceGetTaskInstanceDependencies"; +export const UseTaskInstanceServiceGetTaskInstanceDependenciesKeyFn = ({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; +}, queryKey?: Array) => [useTaskInstanceServiceGetTaskInstanceDependenciesKey, ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId }])]; +export type TaskInstanceServiceGetTaskInstanceDependencies1DefaultResponse = Awaited>; +export type TaskInstanceServiceGetTaskInstanceDependencies1QueryResult = UseQueryResult; +export const useTaskInstanceServiceGetTaskInstanceDependencies1Key = "TaskInstanceServiceGetTaskInstanceDependencies1"; +export const UseTaskInstanceServiceGetTaskInstanceDependencies1KeyFn = ({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex?: number; + taskId: string; +}, queryKey?: Array) => [useTaskInstanceServiceGetTaskInstanceDependencies1Key, ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId }])]; +export type TaskInstanceServiceGetTaskInstanceTriesDefaultResponse = Awaited>; +export type TaskInstanceServiceGetTaskInstanceTriesQueryResult = UseQueryResult; export const useTaskInstanceServiceGetTaskInstanceTriesKey = "TaskInstanceServiceGetTaskInstanceTries"; -export const UseTaskInstanceServiceGetTaskInstanceTriesKeyFn = ( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex?: number; - taskId: string; - }, - queryKey?: Array, -) => [ - useTaskInstanceServiceGetTaskInstanceTriesKey, - ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId }]), -]; -export type TaskInstanceServiceGetMappedTaskInstanceTriesDefaultResponse = Awaited< - ReturnType ->; -export type TaskInstanceServiceGetMappedTaskInstanceTriesQueryResult< - TData = TaskInstanceServiceGetMappedTaskInstanceTriesDefaultResponse, - TError = unknown, -> = UseQueryResult; -export const useTaskInstanceServiceGetMappedTaskInstanceTriesKey = - "TaskInstanceServiceGetMappedTaskInstanceTries"; -export const UseTaskInstanceServiceGetMappedTaskInstanceTriesKeyFn = ( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - }, - queryKey?: Array, -) => [ - useTaskInstanceServiceGetMappedTaskInstanceTriesKey, - ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId }]), -]; -export type TaskInstanceServiceGetMappedTaskInstanceDefaultResponse = Awaited< - ReturnType ->; -export type TaskInstanceServiceGetMappedTaskInstanceQueryResult< - TData = TaskInstanceServiceGetMappedTaskInstanceDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseTaskInstanceServiceGetTaskInstanceTriesKeyFn = ({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex?: number; + taskId: string; +}, queryKey?: Array) => [useTaskInstanceServiceGetTaskInstanceTriesKey, ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId }])]; +export type TaskInstanceServiceGetMappedTaskInstanceTriesDefaultResponse = Awaited>; +export type TaskInstanceServiceGetMappedTaskInstanceTriesQueryResult = UseQueryResult; +export const useTaskInstanceServiceGetMappedTaskInstanceTriesKey = "TaskInstanceServiceGetMappedTaskInstanceTries"; +export const UseTaskInstanceServiceGetMappedTaskInstanceTriesKeyFn = ({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; +}, queryKey?: Array) => [useTaskInstanceServiceGetMappedTaskInstanceTriesKey, ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId }])]; +export type TaskInstanceServiceGetMappedTaskInstanceDefaultResponse = Awaited>; +export type TaskInstanceServiceGetMappedTaskInstanceQueryResult = UseQueryResult; export const useTaskInstanceServiceGetMappedTaskInstanceKey = "TaskInstanceServiceGetMappedTaskInstance"; -export const UseTaskInstanceServiceGetMappedTaskInstanceKeyFn = ( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - }, - queryKey?: Array, -) => [ - useTaskInstanceServiceGetMappedTaskInstanceKey, - ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId }]), -]; -export type TaskInstanceServiceGetTaskInstancesDefaultResponse = Awaited< - ReturnType ->; -export type TaskInstanceServiceGetTaskInstancesQueryResult< - TData = TaskInstanceServiceGetTaskInstancesDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseTaskInstanceServiceGetMappedTaskInstanceKeyFn = ({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; +}, queryKey?: Array) => [useTaskInstanceServiceGetMappedTaskInstanceKey, ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId }])]; +export type TaskInstanceServiceGetTaskInstancesDefaultResponse = Awaited>; +export type TaskInstanceServiceGetTaskInstancesQueryResult = UseQueryResult; export const useTaskInstanceServiceGetTaskInstancesKey = "TaskInstanceServiceGetTaskInstances"; -export const UseTaskInstanceServiceGetTaskInstancesKeyFn = ( - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskDisplayNamePattern, - taskId, - updatedAtGte, - updatedAtLte, - }: { - dagId: string; - dagRunId: string; - durationGte?: number; - durationLte?: number; - endDateGte?: string; - endDateLte?: string; - executor?: string[]; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - pool?: string[]; - queue?: string[]; - startDateGte?: string; - startDateLte?: string; - state?: string[]; - taskDisplayNamePattern?: string; - taskId?: string; - updatedAtGte?: string; - updatedAtLte?: string; - }, - queryKey?: Array, -) => [ - useTaskInstanceServiceGetTaskInstancesKey, - ...(queryKey ?? [ - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskDisplayNamePattern, - taskId, - updatedAtGte, - updatedAtLte, - }, - ]), -]; -export type TaskInstanceServiceGetTaskInstanceTryDetailsDefaultResponse = Awaited< - ReturnType ->; -export type TaskInstanceServiceGetTaskInstanceTryDetailsQueryResult< - TData = TaskInstanceServiceGetTaskInstanceTryDetailsDefaultResponse, - TError = unknown, -> = UseQueryResult; -export const useTaskInstanceServiceGetTaskInstanceTryDetailsKey = - "TaskInstanceServiceGetTaskInstanceTryDetails"; -export const UseTaskInstanceServiceGetTaskInstanceTryDetailsKeyFn = ( - { - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }: { - dagId: string; - dagRunId: string; - mapIndex?: number; - taskId: string; - taskTryNumber: number; - }, - queryKey?: Array, -) => [ - useTaskInstanceServiceGetTaskInstanceTryDetailsKey, - ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId, taskTryNumber }]), -]; -export type TaskInstanceServiceGetMappedTaskInstanceTryDetailsDefaultResponse = Awaited< - ReturnType ->; -export type TaskInstanceServiceGetMappedTaskInstanceTryDetailsQueryResult< - TData = TaskInstanceServiceGetMappedTaskInstanceTryDetailsDefaultResponse, - TError = unknown, -> = UseQueryResult; -export const useTaskInstanceServiceGetMappedTaskInstanceTryDetailsKey = - "TaskInstanceServiceGetMappedTaskInstanceTryDetails"; -export const UseTaskInstanceServiceGetMappedTaskInstanceTryDetailsKeyFn = ( - { - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - taskTryNumber: number; - }, - queryKey?: Array, -) => [ - useTaskInstanceServiceGetMappedTaskInstanceTryDetailsKey, - ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId, taskTryNumber }]), -]; +export const UseTaskInstanceServiceGetTaskInstancesKeyFn = ({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskDisplayNamePattern, taskId, updatedAtGte, updatedAtLte }: { + dagId: string; + dagRunId: string; + durationGte?: number; + durationLte?: number; + endDateGte?: string; + endDateLte?: string; + executor?: string[]; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + pool?: string[]; + queue?: string[]; + startDateGte?: string; + startDateLte?: string; + state?: string[]; + taskDisplayNamePattern?: string; + taskId?: string; + updatedAtGte?: string; + updatedAtLte?: string; +}, queryKey?: Array) => [useTaskInstanceServiceGetTaskInstancesKey, ...(queryKey ?? [{ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskDisplayNamePattern, taskId, updatedAtGte, updatedAtLte }])]; +export type TaskInstanceServiceGetTaskInstanceTryDetailsDefaultResponse = Awaited>; +export type TaskInstanceServiceGetTaskInstanceTryDetailsQueryResult = UseQueryResult; +export const useTaskInstanceServiceGetTaskInstanceTryDetailsKey = "TaskInstanceServiceGetTaskInstanceTryDetails"; +export const UseTaskInstanceServiceGetTaskInstanceTryDetailsKeyFn = ({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }: { + dagId: string; + dagRunId: string; + mapIndex?: number; + taskId: string; + taskTryNumber: number; +}, queryKey?: Array) => [useTaskInstanceServiceGetTaskInstanceTryDetailsKey, ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId, taskTryNumber }])]; +export type TaskInstanceServiceGetMappedTaskInstanceTryDetailsDefaultResponse = Awaited>; +export type TaskInstanceServiceGetMappedTaskInstanceTryDetailsQueryResult = UseQueryResult; +export const useTaskInstanceServiceGetMappedTaskInstanceTryDetailsKey = "TaskInstanceServiceGetMappedTaskInstanceTryDetails"; +export const UseTaskInstanceServiceGetMappedTaskInstanceTryDetailsKeyFn = ({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; + taskTryNumber: number; +}, queryKey?: Array) => [useTaskInstanceServiceGetMappedTaskInstanceTryDetailsKey, ...(queryKey ?? [{ dagId, dagRunId, mapIndex, taskId, taskTryNumber }])]; export type TaskInstanceServiceGetLogDefaultResponse = Awaited>; -export type TaskInstanceServiceGetLogQueryResult< - TData = TaskInstanceServiceGetLogDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type TaskInstanceServiceGetLogQueryResult = UseQueryResult; export const useTaskInstanceServiceGetLogKey = "TaskInstanceServiceGetLog"; -export const UseTaskInstanceServiceGetLogKeyFn = ( - { - accept, - dagId, - dagRunId, - fullContent, - mapIndex, - taskId, - token, - tryNumber, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - dagId: string; - dagRunId: string; - fullContent?: boolean; - mapIndex?: number; - taskId: string; - token?: string; - tryNumber: number; - }, - queryKey?: Array, -) => [ - useTaskInstanceServiceGetLogKey, - ...(queryKey ?? [{ accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }]), -]; -export type ImportErrorServiceGetImportErrorDefaultResponse = Awaited< - ReturnType ->; -export type ImportErrorServiceGetImportErrorQueryResult< - TData = ImportErrorServiceGetImportErrorDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseTaskInstanceServiceGetLogKeyFn = ({ accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }: { + accept?: "application/json" | "text/plain" | "*/*"; + dagId: string; + dagRunId: string; + fullContent?: boolean; + mapIndex?: number; + taskId: string; + token?: string; + tryNumber: number; +}, queryKey?: Array) => [useTaskInstanceServiceGetLogKey, ...(queryKey ?? [{ accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }])]; +export type ImportErrorServiceGetImportErrorDefaultResponse = Awaited>; +export type ImportErrorServiceGetImportErrorQueryResult = UseQueryResult; export const useImportErrorServiceGetImportErrorKey = "ImportErrorServiceGetImportError"; -export const UseImportErrorServiceGetImportErrorKeyFn = ( - { - importErrorId, - }: { - importErrorId: number; - }, - queryKey?: Array, -) => [useImportErrorServiceGetImportErrorKey, ...(queryKey ?? [{ importErrorId }])]; -export type ImportErrorServiceGetImportErrorsDefaultResponse = Awaited< - ReturnType ->; -export type ImportErrorServiceGetImportErrorsQueryResult< - TData = ImportErrorServiceGetImportErrorsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseImportErrorServiceGetImportErrorKeyFn = ({ importErrorId }: { + importErrorId: number; +}, queryKey?: Array) => [useImportErrorServiceGetImportErrorKey, ...(queryKey ?? [{ importErrorId }])]; +export type ImportErrorServiceGetImportErrorsDefaultResponse = Awaited>; +export type ImportErrorServiceGetImportErrorsQueryResult = UseQueryResult; export const useImportErrorServiceGetImportErrorsKey = "ImportErrorServiceGetImportErrors"; -export const UseImportErrorServiceGetImportErrorsKeyFn = ( - { - limit, - offset, - orderBy, - }: { - limit?: number; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: Array, -) => [useImportErrorServiceGetImportErrorsKey, ...(queryKey ?? [{ limit, offset, orderBy }])]; +export const UseImportErrorServiceGetImportErrorsKeyFn = ({ limit, offset, orderBy }: { + limit?: number; + offset?: number; + orderBy?: string; +} = {}, queryKey?: Array) => [useImportErrorServiceGetImportErrorsKey, ...(queryKey ?? [{ limit, offset, orderBy }])]; export type JobServiceGetJobsDefaultResponse = Awaited>; -export type JobServiceGetJobsQueryResult< - TData = JobServiceGetJobsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type JobServiceGetJobsQueryResult = UseQueryResult; export const useJobServiceGetJobsKey = "JobServiceGetJobs"; -export const UseJobServiceGetJobsKeyFn = ( - { - endDateGte, - endDateLte, - executorClass, - hostname, - isAlive, - jobState, - jobType, - limit, - offset, - orderBy, - startDateGte, - startDateLte, - }: { - endDateGte?: string; - endDateLte?: string; - executorClass?: string; - hostname?: string; - isAlive?: boolean; - jobState?: string; - jobType?: string; - limit?: number; - offset?: number; - orderBy?: string; - startDateGte?: string; - startDateLte?: string; - } = {}, - queryKey?: Array, -) => [ - useJobServiceGetJobsKey, - ...(queryKey ?? [ - { - endDateGte, - endDateLte, - executorClass, - hostname, - isAlive, - jobState, - jobType, - limit, - offset, - orderBy, - startDateGte, - startDateLte, - }, - ]), -]; +export const UseJobServiceGetJobsKeyFn = ({ endDateGte, endDateLte, executorClass, hostname, isAlive, jobState, jobType, limit, offset, orderBy, startDateGte, startDateLte }: { + endDateGte?: string; + endDateLte?: string; + executorClass?: string; + hostname?: string; + isAlive?: boolean; + jobState?: string; + jobType?: string; + limit?: number; + offset?: number; + orderBy?: string; + startDateGte?: string; + startDateLte?: string; +} = {}, queryKey?: Array) => [useJobServiceGetJobsKey, ...(queryKey ?? [{ endDateGte, endDateLte, executorClass, hostname, isAlive, jobState, jobType, limit, offset, orderBy, startDateGte, startDateLte }])]; export type PluginServiceGetPluginsDefaultResponse = Awaited>; -export type PluginServiceGetPluginsQueryResult< - TData = PluginServiceGetPluginsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type PluginServiceGetPluginsQueryResult = UseQueryResult; export const usePluginServiceGetPluginsKey = "PluginServiceGetPlugins"; -export const UsePluginServiceGetPluginsKeyFn = ( - { - limit, - offset, - }: { - limit?: number; - offset?: number; - } = {}, - queryKey?: Array, -) => [usePluginServiceGetPluginsKey, ...(queryKey ?? [{ limit, offset }])]; +export const UsePluginServiceGetPluginsKeyFn = ({ limit, offset }: { + limit?: number; + offset?: number; +} = {}, queryKey?: Array) => [usePluginServiceGetPluginsKey, ...(queryKey ?? [{ limit, offset }])]; export type PoolServiceGetPoolDefaultResponse = Awaited>; -export type PoolServiceGetPoolQueryResult< - TData = PoolServiceGetPoolDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type PoolServiceGetPoolQueryResult = UseQueryResult; export const usePoolServiceGetPoolKey = "PoolServiceGetPool"; -export const UsePoolServiceGetPoolKeyFn = ( - { - poolName, - }: { - poolName: string; - }, - queryKey?: Array, -) => [usePoolServiceGetPoolKey, ...(queryKey ?? [{ poolName }])]; +export const UsePoolServiceGetPoolKeyFn = ({ poolName }: { + poolName: string; +}, queryKey?: Array) => [usePoolServiceGetPoolKey, ...(queryKey ?? [{ poolName }])]; export type PoolServiceGetPoolsDefaultResponse = Awaited>; -export type PoolServiceGetPoolsQueryResult< - TData = PoolServiceGetPoolsDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type PoolServiceGetPoolsQueryResult = UseQueryResult; export const usePoolServiceGetPoolsKey = "PoolServiceGetPools"; -export const UsePoolServiceGetPoolsKeyFn = ( - { - limit, - offset, - orderBy, - }: { - limit?: number; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: Array, -) => [usePoolServiceGetPoolsKey, ...(queryKey ?? [{ limit, offset, orderBy }])]; -export type ProviderServiceGetProvidersDefaultResponse = Awaited< - ReturnType ->; -export type ProviderServiceGetProvidersQueryResult< - TData = ProviderServiceGetProvidersDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UsePoolServiceGetPoolsKeyFn = ({ limit, offset, orderBy }: { + limit?: number; + offset?: number; + orderBy?: string; +} = {}, queryKey?: Array) => [usePoolServiceGetPoolsKey, ...(queryKey ?? [{ limit, offset, orderBy }])]; +export type ProviderServiceGetProvidersDefaultResponse = Awaited>; +export type ProviderServiceGetProvidersQueryResult = UseQueryResult; export const useProviderServiceGetProvidersKey = "ProviderServiceGetProviders"; -export const UseProviderServiceGetProvidersKeyFn = ( - { - limit, - offset, - }: { - limit?: number; - offset?: number; - } = {}, - queryKey?: Array, -) => [useProviderServiceGetProvidersKey, ...(queryKey ?? [{ limit, offset }])]; +export const UseProviderServiceGetProvidersKeyFn = ({ limit, offset }: { + limit?: number; + offset?: number; +} = {}, queryKey?: Array) => [useProviderServiceGetProvidersKey, ...(queryKey ?? [{ limit, offset }])]; export type XcomServiceGetXcomEntryDefaultResponse = Awaited>; -export type XcomServiceGetXcomEntryQueryResult< - TData = XcomServiceGetXcomEntryDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type XcomServiceGetXcomEntryQueryResult = UseQueryResult; export const useXcomServiceGetXcomEntryKey = "XcomServiceGetXcomEntry"; -export const UseXcomServiceGetXcomEntryKeyFn = ( - { - dagId, - dagRunId, - deserialize, - mapIndex, - stringify, - taskId, - xcomKey, - }: { - dagId: string; - dagRunId: string; - deserialize?: boolean; - mapIndex?: number; - stringify?: boolean; - taskId: string; - xcomKey: string; - }, - queryKey?: Array, -) => [ - useXcomServiceGetXcomEntryKey, - ...(queryKey ?? [{ dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }]), -]; +export const UseXcomServiceGetXcomEntryKeyFn = ({ dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }: { + dagId: string; + dagRunId: string; + deserialize?: boolean; + mapIndex?: number; + stringify?: boolean; + taskId: string; + xcomKey: string; +}, queryKey?: Array) => [useXcomServiceGetXcomEntryKey, ...(queryKey ?? [{ dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }])]; export type XcomServiceGetXcomEntriesDefaultResponse = Awaited>; -export type XcomServiceGetXcomEntriesQueryResult< - TData = XcomServiceGetXcomEntriesDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type XcomServiceGetXcomEntriesQueryResult = UseQueryResult; export const useXcomServiceGetXcomEntriesKey = "XcomServiceGetXcomEntries"; -export const UseXcomServiceGetXcomEntriesKeyFn = ( - { - dagId, - dagRunId, - limit, - mapIndex, - offset, - taskId, - xcomKey, - }: { - dagId: string; - dagRunId: string; - limit?: number; - mapIndex?: number; - offset?: number; - taskId: string; - xcomKey?: string; - }, - queryKey?: Array, -) => [ - useXcomServiceGetXcomEntriesKey, - ...(queryKey ?? [{ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }]), -]; +export const UseXcomServiceGetXcomEntriesKeyFn = ({ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }: { + dagId: string; + dagRunId: string; + limit?: number; + mapIndex?: number; + offset?: number; + taskId: string; + xcomKey?: string; +}, queryKey?: Array) => [useXcomServiceGetXcomEntriesKey, ...(queryKey ?? [{ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }])]; export type TaskServiceGetTasksDefaultResponse = Awaited>; -export type TaskServiceGetTasksQueryResult< - TData = TaskServiceGetTasksDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type TaskServiceGetTasksQueryResult = UseQueryResult; export const useTaskServiceGetTasksKey = "TaskServiceGetTasks"; -export const UseTaskServiceGetTasksKeyFn = ( - { - dagId, - orderBy, - }: { - dagId: string; - orderBy?: string; - }, - queryKey?: Array, -) => [useTaskServiceGetTasksKey, ...(queryKey ?? [{ dagId, orderBy }])]; +export const UseTaskServiceGetTasksKeyFn = ({ dagId, orderBy }: { + dagId: string; + orderBy?: string; +}, queryKey?: Array) => [useTaskServiceGetTasksKey, ...(queryKey ?? [{ dagId, orderBy }])]; export type TaskServiceGetTaskDefaultResponse = Awaited>; -export type TaskServiceGetTaskQueryResult< - TData = TaskServiceGetTaskDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type TaskServiceGetTaskQueryResult = UseQueryResult; export const useTaskServiceGetTaskKey = "TaskServiceGetTask"; -export const UseTaskServiceGetTaskKeyFn = ( - { - dagId, - taskId, - }: { - dagId: string; - taskId: unknown; - }, - queryKey?: Array, -) => [useTaskServiceGetTaskKey, ...(queryKey ?? [{ dagId, taskId }])]; -export type VariableServiceGetVariableDefaultResponse = Awaited< - ReturnType ->; -export type VariableServiceGetVariableQueryResult< - TData = VariableServiceGetVariableDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseTaskServiceGetTaskKeyFn = ({ dagId, taskId }: { + dagId: string; + taskId: unknown; +}, queryKey?: Array) => [useTaskServiceGetTaskKey, ...(queryKey ?? [{ dagId, taskId }])]; +export type VariableServiceGetVariableDefaultResponse = Awaited>; +export type VariableServiceGetVariableQueryResult = UseQueryResult; export const useVariableServiceGetVariableKey = "VariableServiceGetVariable"; -export const UseVariableServiceGetVariableKeyFn = ( - { - variableKey, - }: { - variableKey: string; - }, - queryKey?: Array, -) => [useVariableServiceGetVariableKey, ...(queryKey ?? [{ variableKey }])]; -export type VariableServiceGetVariablesDefaultResponse = Awaited< - ReturnType ->; -export type VariableServiceGetVariablesQueryResult< - TData = VariableServiceGetVariablesDefaultResponse, - TError = unknown, -> = UseQueryResult; +export const UseVariableServiceGetVariableKeyFn = ({ variableKey }: { + variableKey: string; +}, queryKey?: Array) => [useVariableServiceGetVariableKey, ...(queryKey ?? [{ variableKey }])]; +export type VariableServiceGetVariablesDefaultResponse = Awaited>; +export type VariableServiceGetVariablesQueryResult = UseQueryResult; export const useVariableServiceGetVariablesKey = "VariableServiceGetVariables"; -export const UseVariableServiceGetVariablesKeyFn = ( - { - limit, - offset, - orderBy, - variableKeyPattern, - }: { - limit?: number; - offset?: number; - orderBy?: string; - variableKeyPattern?: string; - } = {}, - queryKey?: Array, -) => [useVariableServiceGetVariablesKey, ...(queryKey ?? [{ limit, offset, orderBy, variableKeyPattern }])]; +export const UseVariableServiceGetVariablesKeyFn = ({ limit, offset, orderBy, variableKeyPattern }: { + limit?: number; + offset?: number; + orderBy?: string; + variableKeyPattern?: string; +} = {}, queryKey?: Array) => [useVariableServiceGetVariablesKey, ...(queryKey ?? [{ limit, offset, orderBy, variableKeyPattern }])]; export type MonitorServiceGetHealthDefaultResponse = Awaited>; -export type MonitorServiceGetHealthQueryResult< - TData = MonitorServiceGetHealthDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type MonitorServiceGetHealthQueryResult = UseQueryResult; export const useMonitorServiceGetHealthKey = "MonitorServiceGetHealth"; -export const UseMonitorServiceGetHealthKeyFn = (queryKey?: Array) => [ - useMonitorServiceGetHealthKey, - ...(queryKey ?? []), -]; +export const UseMonitorServiceGetHealthKeyFn = (queryKey?: Array) => [useMonitorServiceGetHealthKey, ...(queryKey ?? [])]; export type VersionServiceGetVersionDefaultResponse = Awaited>; -export type VersionServiceGetVersionQueryResult< - TData = VersionServiceGetVersionDefaultResponse, - TError = unknown, -> = UseQueryResult; +export type VersionServiceGetVersionQueryResult = UseQueryResult; export const useVersionServiceGetVersionKey = "VersionServiceGetVersion"; -export const UseVersionServiceGetVersionKeyFn = (queryKey?: Array) => [ - useVersionServiceGetVersionKey, - ...(queryKey ?? []), -]; -export type AssetServiceCreateAssetEventMutationResult = Awaited< - ReturnType ->; -export type BackfillServiceCreateBackfillMutationResult = Awaited< - ReturnType ->; -export type ConnectionServicePostConnectionMutationResult = Awaited< - ReturnType ->; -export type ConnectionServiceTestConnectionMutationResult = Awaited< - ReturnType ->; +export const UseVersionServiceGetVersionKeyFn = (queryKey?: Array) => [useVersionServiceGetVersionKey, ...(queryKey ?? [])]; +export type AssetServiceCreateAssetEventMutationResult = Awaited>; +export type BackfillServiceCreateBackfillMutationResult = Awaited>; +export type ConnectionServicePostConnectionMutationResult = Awaited>; +export type ConnectionServiceTestConnectionMutationResult = Awaited>; export type DagRunServiceClearDagRunMutationResult = Awaited>; -export type DagRunServiceTriggerDagRunMutationResult = Awaited< - ReturnType ->; -export type DagRunServiceGetListDagRunsBatchMutationResult = Awaited< - ReturnType ->; -export type TaskInstanceServiceGetTaskInstancesBatchMutationResult = Awaited< - ReturnType ->; -export type TaskInstanceServicePostClearTaskInstancesMutationResult = Awaited< - ReturnType ->; +export type DagRunServiceTriggerDagRunMutationResult = Awaited>; +export type DagRunServiceGetListDagRunsBatchMutationResult = Awaited>; +export type TaskInstanceServiceGetTaskInstancesBatchMutationResult = Awaited>; +export type TaskInstanceServicePostClearTaskInstancesMutationResult = Awaited>; export type PoolServicePostPoolMutationResult = Awaited>; -export type VariableServicePostVariableMutationResult = Awaited< - ReturnType ->; -export type VariableServiceImportVariablesMutationResult = Awaited< - ReturnType ->; -export type BackfillServicePauseBackfillMutationResult = Awaited< - ReturnType ->; -export type BackfillServiceUnpauseBackfillMutationResult = Awaited< - ReturnType ->; -export type BackfillServiceCancelBackfillMutationResult = Awaited< - ReturnType ->; -export type ConnectionServicePutConnectionsMutationResult = Awaited< - ReturnType ->; +export type VariableServicePostVariableMutationResult = Awaited>; +export type VariableServiceImportVariablesMutationResult = Awaited>; +export type BackfillServicePauseBackfillMutationResult = Awaited>; +export type BackfillServiceUnpauseBackfillMutationResult = Awaited>; +export type BackfillServiceCancelBackfillMutationResult = Awaited>; +export type ConnectionServicePutConnectionsMutationResult = Awaited>; export type PoolServicePutPoolsMutationResult = Awaited>; -export type DagParsingServiceReparseDagFileMutationResult = Awaited< - ReturnType ->; -export type ConnectionServicePatchConnectionMutationResult = Awaited< - ReturnType ->; +export type DagParsingServiceReparseDagFileMutationResult = Awaited>; +export type ConnectionServicePatchConnectionMutationResult = Awaited>; export type DagRunServicePatchDagRunMutationResult = Awaited>; export type DagServicePatchDagsMutationResult = Awaited>; export type DagServicePatchDagMutationResult = Awaited>; -export type TaskInstanceServicePatchTaskInstanceMutationResult = Awaited< - ReturnType ->; -export type TaskInstanceServicePatchTaskInstance1MutationResult = Awaited< - ReturnType ->; +export type TaskInstanceServicePatchTaskInstanceMutationResult = Awaited>; +export type TaskInstanceServicePatchTaskInstance1MutationResult = Awaited>; export type PoolServicePatchPoolMutationResult = Awaited>; -export type VariableServicePatchVariableMutationResult = Awaited< - ReturnType ->; -export type AssetServiceDeleteAssetQueuedEventsMutationResult = Awaited< - ReturnType ->; -export type AssetServiceDeleteDagAssetQueuedEventsMutationResult = Awaited< - ReturnType ->; -export type AssetServiceDeleteDagAssetQueuedEventMutationResult = Awaited< - ReturnType ->; -export type ConnectionServiceDeleteConnectionMutationResult = Awaited< - ReturnType ->; +export type VariableServicePatchVariableMutationResult = Awaited>; +export type AssetServiceDeleteAssetQueuedEventsMutationResult = Awaited>; +export type AssetServiceDeleteDagAssetQueuedEventsMutationResult = Awaited>; +export type AssetServiceDeleteDagAssetQueuedEventMutationResult = Awaited>; +export type ConnectionServiceDeleteConnectionMutationResult = Awaited>; export type DagRunServiceDeleteDagRunMutationResult = Awaited>; export type DagServiceDeleteDagMutationResult = Awaited>; export type PoolServiceDeletePoolMutationResult = Awaited>; -export type VariableServiceDeleteVariableMutationResult = Awaited< - ReturnType ->; +export type VariableServiceDeleteVariableMutationResult = Awaited>; diff --git a/airflow/ui/openapi-gen/queries/index.ts b/airflow/ui/openapi-gen/queries/index.ts index f9175269e31a5..4b02e765783a1 100644 --- a/airflow/ui/openapi-gen/queries/index.ts +++ b/airflow/ui/openapi-gen/queries/index.ts @@ -1,4 +1,4 @@ -// generated with @7nohe/openapi-react-query-codegen@1.6.0 +// generated with @7nohe/openapi-react-query-codegen@1.6.0 export * from "./common"; export * from "./queries"; diff --git a/airflow/ui/openapi-gen/queries/infiniteQueries.ts b/airflow/ui/openapi-gen/queries/infiniteQueries.ts index 505a8d455464d..146057a74a469 100644 --- a/airflow/ui/openapi-gen/queries/infiniteQueries.ts +++ b/airflow/ui/openapi-gen/queries/infiniteQueries.ts @@ -1 +1,2 @@ -// generated with @7nohe/openapi-react-query-codegen@1.6.0 +// generated with @7nohe/openapi-react-query-codegen@1.6.0 + diff --git a/airflow/ui/openapi-gen/queries/prefetch.ts b/airflow/ui/openapi-gen/queries/prefetch.ts index 82db0eccdedeb..41192c52069b7 100644 --- a/airflow/ui/openapi-gen/queries/prefetch.ts +++ b/airflow/ui/openapi-gen/queries/prefetch.ts @@ -1,2220 +1,1084 @@ -// generated with @7nohe/openapi-react-query-codegen@1.6.0 -import { type QueryClient } from "@tanstack/react-query"; +// generated with @7nohe/openapi-react-query-codegen@1.6.0 -import { - AssetService, - BackfillService, - ConfigService, - ConnectionService, - DagRunService, - DagService, - DagSourceService, - DagStatsService, - DagWarningService, - DagsService, - DashboardService, - EventLogService, - ExtraLinksService, - GridService, - ImportErrorService, - JobService, - MonitorService, - PluginService, - PoolService, - ProviderService, - StructureService, - TaskInstanceService, - TaskService, - VariableService, - VersionService, - XcomService, -} from "../requests/services.gen"; +import { type QueryClient } from "@tanstack/react-query"; +import { AssetService, BackfillService, ConfigService, ConnectionService, DagRunService, DagService, DagSourceService, DagStatsService, DagWarningService, DagsService, DashboardService, EventLogService, ExtraLinksService, GridService, ImportErrorService, JobService, MonitorService, PluginService, PoolService, ProviderService, StructureService, TaskInstanceService, TaskService, VariableService, VersionService, XcomService } from "../requests/services.gen"; import { DagRunState, DagWarningType } from "../requests/types.gen"; import * as Common from "./common"; - /** - * Next Run Assets - * @param data The data for the request. - * @param data.dagId - * @returns unknown Successful Response - * @throws ApiError - */ -export const prefetchUseAssetServiceNextRunAssets = ( - queryClient: QueryClient, - { - dagId, - }: { - dagId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseAssetServiceNextRunAssetsKeyFn({ dagId }), - queryFn: () => AssetService.nextRunAssets({ dagId }), - }); +* Next Run Assets +* @param data The data for the request. +* @param data.dagId +* @returns unknown Successful Response +* @throws ApiError +*/ +export const prefetchUseAssetServiceNextRunAssets = (queryClient: QueryClient, { dagId }: { + dagId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseAssetServiceNextRunAssetsKeyFn({ dagId }), queryFn: () => AssetService.nextRunAssets({ dagId }) }); /** - * Get Assets - * Get assets. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.namePattern - * @param data.uriPattern - * @param data.dagIds - * @param data.orderBy - * @returns AssetCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseAssetServiceGetAssets = ( - queryClient: QueryClient, - { - dagIds, - limit, - namePattern, - offset, - orderBy, - uriPattern, - }: { - dagIds?: string[]; - limit?: number; - namePattern?: string; - offset?: number; - orderBy?: string; - uriPattern?: string; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseAssetServiceGetAssetsKeyFn({ - dagIds, - limit, - namePattern, - offset, - orderBy, - uriPattern, - }), - queryFn: () => AssetService.getAssets({ dagIds, limit, namePattern, offset, orderBy, uriPattern }), - }); +* Get Assets +* Get assets. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.namePattern +* @param data.uriPattern +* @param data.dagIds +* @param data.orderBy +* @returns AssetCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseAssetServiceGetAssets = (queryClient: QueryClient, { dagIds, limit, namePattern, offset, orderBy, uriPattern }: { + dagIds?: string[]; + limit?: number; + namePattern?: string; + offset?: number; + orderBy?: string; + uriPattern?: string; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseAssetServiceGetAssetsKeyFn({ dagIds, limit, namePattern, offset, orderBy, uriPattern }), queryFn: () => AssetService.getAssets({ dagIds, limit, namePattern, offset, orderBy, uriPattern }) }); /** - * Get Asset Aliases - * Get asset aliases. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.namePattern - * @param data.orderBy - * @returns AssetAliasCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseAssetServiceGetAssetAliases = ( - queryClient: QueryClient, - { - limit, - namePattern, - offset, - orderBy, - }: { - limit?: number; - namePattern?: string; - offset?: number; - orderBy?: string; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseAssetServiceGetAssetAliasesKeyFn({ limit, namePattern, offset, orderBy }), - queryFn: () => AssetService.getAssetAliases({ limit, namePattern, offset, orderBy }), - }); +* Get Asset Aliases +* Get asset aliases. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.namePattern +* @param data.orderBy +* @returns AssetAliasCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseAssetServiceGetAssetAliases = (queryClient: QueryClient, { limit, namePattern, offset, orderBy }: { + limit?: number; + namePattern?: string; + offset?: number; + orderBy?: string; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseAssetServiceGetAssetAliasesKeyFn({ limit, namePattern, offset, orderBy }), queryFn: () => AssetService.getAssetAliases({ limit, namePattern, offset, orderBy }) }); /** - * Get Asset Alias - * Get an asset alias. - * @param data The data for the request. - * @param data.assetAliasId - * @returns unknown Successful Response - * @throws ApiError - */ -export const prefetchUseAssetServiceGetAssetAlias = ( - queryClient: QueryClient, - { - assetAliasId, - }: { - assetAliasId: number; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseAssetServiceGetAssetAliasKeyFn({ assetAliasId }), - queryFn: () => AssetService.getAssetAlias({ assetAliasId }), - }); +* Get Asset Alias +* Get an asset alias. +* @param data The data for the request. +* @param data.assetAliasId +* @returns unknown Successful Response +* @throws ApiError +*/ +export const prefetchUseAssetServiceGetAssetAlias = (queryClient: QueryClient, { assetAliasId }: { + assetAliasId: number; +}) => queryClient.prefetchQuery({ queryKey: Common.UseAssetServiceGetAssetAliasKeyFn({ assetAliasId }), queryFn: () => AssetService.getAssetAlias({ assetAliasId }) }); /** - * Get Asset Events - * Get asset events. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.assetId - * @param data.sourceDagId - * @param data.sourceTaskId - * @param data.sourceRunId - * @param data.sourceMapIndex - * @param data.timestampGte - * @param data.timestampLte - * @returns AssetEventCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseAssetServiceGetAssetEvents = ( - queryClient: QueryClient, - { - assetId, - limit, - offset, - orderBy, - sourceDagId, - sourceMapIndex, - sourceRunId, - sourceTaskId, - timestampGte, - timestampLte, - }: { - assetId?: number; - limit?: number; - offset?: number; - orderBy?: string; - sourceDagId?: string; - sourceMapIndex?: number; - sourceRunId?: string; - sourceTaskId?: string; - timestampGte?: string; - timestampLte?: string; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseAssetServiceGetAssetEventsKeyFn({ - assetId, - limit, - offset, - orderBy, - sourceDagId, - sourceMapIndex, - sourceRunId, - sourceTaskId, - timestampGte, - timestampLte, - }), - queryFn: () => - AssetService.getAssetEvents({ - assetId, - limit, - offset, - orderBy, - sourceDagId, - sourceMapIndex, - sourceRunId, - sourceTaskId, - timestampGte, - timestampLte, - }), - }); +* Get Asset Events +* Get asset events. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.assetId +* @param data.sourceDagId +* @param data.sourceTaskId +* @param data.sourceRunId +* @param data.sourceMapIndex +* @param data.timestampGte +* @param data.timestampLte +* @returns AssetEventCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseAssetServiceGetAssetEvents = (queryClient: QueryClient, { assetId, limit, offset, orderBy, sourceDagId, sourceMapIndex, sourceRunId, sourceTaskId, timestampGte, timestampLte }: { + assetId?: number; + limit?: number; + offset?: number; + orderBy?: string; + sourceDagId?: string; + sourceMapIndex?: number; + sourceRunId?: string; + sourceTaskId?: string; + timestampGte?: string; + timestampLte?: string; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseAssetServiceGetAssetEventsKeyFn({ assetId, limit, offset, orderBy, sourceDagId, sourceMapIndex, sourceRunId, sourceTaskId, timestampGte, timestampLte }), queryFn: () => AssetService.getAssetEvents({ assetId, limit, offset, orderBy, sourceDagId, sourceMapIndex, sourceRunId, sourceTaskId, timestampGte, timestampLte }) }); /** - * Get Asset Queued Events - * Get queued asset events for an asset. - * @param data The data for the request. - * @param data.assetId - * @param data.before - * @returns QueuedEventCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseAssetServiceGetAssetQueuedEvents = ( - queryClient: QueryClient, - { - assetId, - before, - }: { - assetId: number; - before?: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseAssetServiceGetAssetQueuedEventsKeyFn({ assetId, before }), - queryFn: () => AssetService.getAssetQueuedEvents({ assetId, before }), - }); +* Get Asset Queued Events +* Get queued asset events for an asset. +* @param data The data for the request. +* @param data.assetId +* @param data.before +* @returns QueuedEventCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseAssetServiceGetAssetQueuedEvents = (queryClient: QueryClient, { assetId, before }: { + assetId: number; + before?: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseAssetServiceGetAssetQueuedEventsKeyFn({ assetId, before }), queryFn: () => AssetService.getAssetQueuedEvents({ assetId, before }) }); /** - * Get Asset - * Get an asset. - * @param data The data for the request. - * @param data.assetId - * @returns AssetResponse Successful Response - * @throws ApiError - */ -export const prefetchUseAssetServiceGetAsset = ( - queryClient: QueryClient, - { - assetId, - }: { - assetId: number; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseAssetServiceGetAssetKeyFn({ assetId }), - queryFn: () => AssetService.getAsset({ assetId }), - }); +* Get Asset +* Get an asset. +* @param data The data for the request. +* @param data.assetId +* @returns AssetResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseAssetServiceGetAsset = (queryClient: QueryClient, { assetId }: { + assetId: number; +}) => queryClient.prefetchQuery({ queryKey: Common.UseAssetServiceGetAssetKeyFn({ assetId }), queryFn: () => AssetService.getAsset({ assetId }) }); /** - * Get Dag Asset Queued Events - * Get queued asset events for a DAG. - * @param data The data for the request. - * @param data.dagId - * @param data.before - * @returns QueuedEventCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseAssetServiceGetDagAssetQueuedEvents = ( - queryClient: QueryClient, - { - before, - dagId, - }: { - before?: string; - dagId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseAssetServiceGetDagAssetQueuedEventsKeyFn({ before, dagId }), - queryFn: () => AssetService.getDagAssetQueuedEvents({ before, dagId }), - }); +* Get Dag Asset Queued Events +* Get queued asset events for a DAG. +* @param data The data for the request. +* @param data.dagId +* @param data.before +* @returns QueuedEventCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseAssetServiceGetDagAssetQueuedEvents = (queryClient: QueryClient, { before, dagId }: { + before?: string; + dagId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseAssetServiceGetDagAssetQueuedEventsKeyFn({ before, dagId }), queryFn: () => AssetService.getDagAssetQueuedEvents({ before, dagId }) }); /** - * Get Dag Asset Queued Event - * Get a queued asset event for a DAG. - * @param data The data for the request. - * @param data.dagId - * @param data.assetId - * @param data.before - * @returns QueuedEventResponse Successful Response - * @throws ApiError - */ -export const prefetchUseAssetServiceGetDagAssetQueuedEvent = ( - queryClient: QueryClient, - { - assetId, - before, - dagId, - }: { - assetId: number; - before?: string; - dagId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseAssetServiceGetDagAssetQueuedEventKeyFn({ assetId, before, dagId }), - queryFn: () => AssetService.getDagAssetQueuedEvent({ assetId, before, dagId }), - }); +* Get Dag Asset Queued Event +* Get a queued asset event for a DAG. +* @param data The data for the request. +* @param data.dagId +* @param data.assetId +* @param data.before +* @returns QueuedEventResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseAssetServiceGetDagAssetQueuedEvent = (queryClient: QueryClient, { assetId, before, dagId }: { + assetId: number; + before?: string; + dagId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseAssetServiceGetDagAssetQueuedEventKeyFn({ assetId, before, dagId }), queryFn: () => AssetService.getDagAssetQueuedEvent({ assetId, before, dagId }) }); /** - * Get Configs - * Get configs for UI. - * @returns ConfigResponse Successful Response - * @throws ApiError - */ -export const prefetchUseConfigServiceGetConfigs = (queryClient: QueryClient) => - queryClient.prefetchQuery({ - queryKey: Common.UseConfigServiceGetConfigsKeyFn(), - queryFn: () => ConfigService.getConfigs(), - }); +* Get Configs +* Get configs for UI. +* @returns ConfigResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseConfigServiceGetConfigs = (queryClient: QueryClient) => queryClient.prefetchQuery({ queryKey: Common.UseConfigServiceGetConfigsKeyFn(), queryFn: () => ConfigService.getConfigs() }); /** - * Get Config - * @param data The data for the request. - * @param data.section - * @param data.accept - * @returns Config Successful Response - * @throws ApiError - */ -export const prefetchUseConfigServiceGetConfig = ( - queryClient: QueryClient, - { - accept, - section, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - section?: string; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseConfigServiceGetConfigKeyFn({ accept, section }), - queryFn: () => ConfigService.getConfig({ accept, section }), - }); +* Get Config +* @param data The data for the request. +* @param data.section +* @param data.accept +* @returns Config Successful Response +* @throws ApiError +*/ +export const prefetchUseConfigServiceGetConfig = (queryClient: QueryClient, { accept, section }: { + accept?: "application/json" | "text/plain" | "*/*"; + section?: string; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseConfigServiceGetConfigKeyFn({ accept, section }), queryFn: () => ConfigService.getConfig({ accept, section }) }); /** - * Get Config Value - * @param data The data for the request. - * @param data.section - * @param data.option - * @param data.accept - * @returns Config Successful Response - * @throws ApiError - */ -export const prefetchUseConfigServiceGetConfigValue = ( - queryClient: QueryClient, - { - accept, - option, - section, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - option: string; - section: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseConfigServiceGetConfigValueKeyFn({ accept, option, section }), - queryFn: () => ConfigService.getConfigValue({ accept, option, section }), - }); +* Get Config Value +* @param data The data for the request. +* @param data.section +* @param data.option +* @param data.accept +* @returns Config Successful Response +* @throws ApiError +*/ +export const prefetchUseConfigServiceGetConfigValue = (queryClient: QueryClient, { accept, option, section }: { + accept?: "application/json" | "text/plain" | "*/*"; + option: string; + section: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseConfigServiceGetConfigValueKeyFn({ accept, option, section }), queryFn: () => ConfigService.getConfigValue({ accept, option, section }) }); /** - * Recent Dag Runs - * Get recent DAG runs. - * @param data The data for the request. - * @param data.dagRunsLimit - * @param data.limit - * @param data.offset - * @param data.tags - * @param data.owners - * @param data.dagIds - * @param data.dagIdPattern - * @param data.dagDisplayNamePattern - * @param data.onlyActive - * @param data.paused - * @param data.lastDagRunState - * @returns DAGWithLatestDagRunsCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseDagsServiceRecentDagRuns = ( - queryClient: QueryClient, - { - dagDisplayNamePattern, - dagIdPattern, - dagIds, - dagRunsLimit, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - tags, - }: { - dagDisplayNamePattern?: string; - dagIdPattern?: string; - dagIds?: string[]; - dagRunsLimit?: number; - lastDagRunState?: DagRunState; - limit?: number; - offset?: number; - onlyActive?: boolean; - owners?: string[]; - paused?: boolean; - tags?: string[]; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseDagsServiceRecentDagRunsKeyFn({ - dagDisplayNamePattern, - dagIdPattern, - dagIds, - dagRunsLimit, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - tags, - }), - queryFn: () => - DagsService.recentDagRuns({ - dagDisplayNamePattern, - dagIdPattern, - dagIds, - dagRunsLimit, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - tags, - }), - }); +* Recent Dag Runs +* Get recent DAG runs. +* @param data The data for the request. +* @param data.dagRunsLimit +* @param data.limit +* @param data.offset +* @param data.tags +* @param data.owners +* @param data.dagIds +* @param data.dagIdPattern +* @param data.dagDisplayNamePattern +* @param data.onlyActive +* @param data.paused +* @param data.lastDagRunState +* @returns DAGWithLatestDagRunsCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseDagsServiceRecentDagRuns = (queryClient: QueryClient, { dagDisplayNamePattern, dagIdPattern, dagIds, dagRunsLimit, lastDagRunState, limit, offset, onlyActive, owners, paused, tags }: { + dagDisplayNamePattern?: string; + dagIdPattern?: string; + dagIds?: string[]; + dagRunsLimit?: number; + lastDagRunState?: DagRunState; + limit?: number; + offset?: number; + onlyActive?: boolean; + owners?: string[]; + paused?: boolean; + tags?: string[]; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseDagsServiceRecentDagRunsKeyFn({ dagDisplayNamePattern, dagIdPattern, dagIds, dagRunsLimit, lastDagRunState, limit, offset, onlyActive, owners, paused, tags }), queryFn: () => DagsService.recentDagRuns({ dagDisplayNamePattern, dagIdPattern, dagIds, dagRunsLimit, lastDagRunState, limit, offset, onlyActive, owners, paused, tags }) }); /** - * Historical Metrics - * Return cluster activity historical metrics. - * @param data The data for the request. - * @param data.startDate - * @param data.endDate - * @returns HistoricalMetricDataResponse Successful Response - * @throws ApiError - */ -export const prefetchUseDashboardServiceHistoricalMetrics = ( - queryClient: QueryClient, - { - endDate, - startDate, - }: { - endDate?: string; - startDate: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseDashboardServiceHistoricalMetricsKeyFn({ endDate, startDate }), - queryFn: () => DashboardService.historicalMetrics({ endDate, startDate }), - }); +* Historical Metrics +* Return cluster activity historical metrics. +* @param data The data for the request. +* @param data.startDate +* @param data.endDate +* @returns HistoricalMetricDataResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseDashboardServiceHistoricalMetrics = (queryClient: QueryClient, { endDate, startDate }: { + endDate?: string; + startDate: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseDashboardServiceHistoricalMetricsKeyFn({ endDate, startDate }), queryFn: () => DashboardService.historicalMetrics({ endDate, startDate }) }); /** - * Structure Data - * Get Structure Data. - * @param data The data for the request. - * @param data.dagId - * @param data.includeUpstream - * @param data.includeDownstream - * @param data.root - * @param data.externalDependencies - * @returns StructureDataResponse Successful Response - * @throws ApiError - */ -export const prefetchUseStructureServiceStructureData = ( - queryClient: QueryClient, - { - dagId, - externalDependencies, - includeDownstream, - includeUpstream, - root, - }: { - dagId: string; - externalDependencies?: boolean; - includeDownstream?: boolean; - includeUpstream?: boolean; - root?: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseStructureServiceStructureDataKeyFn({ - dagId, - externalDependencies, - includeDownstream, - includeUpstream, - root, - }), - queryFn: () => - StructureService.structureData({ - dagId, - externalDependencies, - includeDownstream, - includeUpstream, - root, - }), - }); +* Structure Data +* Get Structure Data. +* @param data The data for the request. +* @param data.dagId +* @param data.includeUpstream +* @param data.includeDownstream +* @param data.root +* @param data.externalDependencies +* @returns StructureDataResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseStructureServiceStructureData = (queryClient: QueryClient, { dagId, externalDependencies, includeDownstream, includeUpstream, root }: { + dagId: string; + externalDependencies?: boolean; + includeDownstream?: boolean; + includeUpstream?: boolean; + root?: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseStructureServiceStructureDataKeyFn({ dagId, externalDependencies, includeDownstream, includeUpstream, root }), queryFn: () => StructureService.structureData({ dagId, externalDependencies, includeDownstream, includeUpstream, root }) }); /** - * List Backfills - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.dagId - * @param data.active - * @returns BackfillCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseBackfillServiceListBackfills = ( - queryClient: QueryClient, - { - active, - dagId, - limit, - offset, - orderBy, - }: { - active?: boolean; - dagId?: string; - limit?: number; - offset?: number; - orderBy?: string; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseBackfillServiceListBackfillsKeyFn({ active, dagId, limit, offset, orderBy }), - queryFn: () => BackfillService.listBackfills({ active, dagId, limit, offset, orderBy }), - }); +* List Backfills +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.dagId +* @param data.active +* @returns BackfillCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseBackfillServiceListBackfills = (queryClient: QueryClient, { active, dagId, limit, offset, orderBy }: { + active?: boolean; + dagId?: string; + limit?: number; + offset?: number; + orderBy?: string; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseBackfillServiceListBackfillsKeyFn({ active, dagId, limit, offset, orderBy }), queryFn: () => BackfillService.listBackfills({ active, dagId, limit, offset, orderBy }) }); /** - * List Backfills - * @param data The data for the request. - * @param data.dagId - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns BackfillCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseBackfillServiceListBackfills1 = ( - queryClient: QueryClient, - { - dagId, - limit, - offset, - orderBy, - }: { - dagId: string; - limit?: number; - offset?: number; - orderBy?: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseBackfillServiceListBackfills1KeyFn({ dagId, limit, offset, orderBy }), - queryFn: () => BackfillService.listBackfills1({ dagId, limit, offset, orderBy }), - }); +* List Backfills +* @param data The data for the request. +* @param data.dagId +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns BackfillCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseBackfillServiceListBackfills1 = (queryClient: QueryClient, { dagId, limit, offset, orderBy }: { + dagId: string; + limit?: number; + offset?: number; + orderBy?: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseBackfillServiceListBackfills1KeyFn({ dagId, limit, offset, orderBy }), queryFn: () => BackfillService.listBackfills1({ dagId, limit, offset, orderBy }) }); /** - * Get Backfill - * @param data The data for the request. - * @param data.backfillId - * @returns BackfillResponse Successful Response - * @throws ApiError - */ -export const prefetchUseBackfillServiceGetBackfill = ( - queryClient: QueryClient, - { - backfillId, - }: { - backfillId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseBackfillServiceGetBackfillKeyFn({ backfillId }), - queryFn: () => BackfillService.getBackfill({ backfillId }), - }); +* Get Backfill +* @param data The data for the request. +* @param data.backfillId +* @returns BackfillResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseBackfillServiceGetBackfill = (queryClient: QueryClient, { backfillId }: { + backfillId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseBackfillServiceGetBackfillKeyFn({ backfillId }), queryFn: () => BackfillService.getBackfill({ backfillId }) }); /** - * Grid Data - * Return grid data. - * @param data The data for the request. - * @param data.dagId - * @param data.includeUpstream - * @param data.includeDownstream - * @param data.logicalDateGte - * @param data.logicalDateLte - * @param data.root - * @param data.offset - * @param data.runType - * @param data.state - * @param data.limit - * @param data.orderBy - * @returns GridResponse Successful Response - * @throws ApiError - */ -export const prefetchUseGridServiceGridData = ( - queryClient: QueryClient, - { - dagId, - includeDownstream, - includeUpstream, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - root, - runType, - state, - }: { - dagId: string; - includeDownstream?: boolean; - includeUpstream?: boolean; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - root?: string; - runType?: string[]; - state?: string[]; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseGridServiceGridDataKeyFn({ - dagId, - includeDownstream, - includeUpstream, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - root, - runType, - state, - }), - queryFn: () => - GridService.gridData({ - dagId, - includeDownstream, - includeUpstream, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - root, - runType, - state, - }), - }); +* Grid Data +* Return grid data. +* @param data The data for the request. +* @param data.dagId +* @param data.includeUpstream +* @param data.includeDownstream +* @param data.logicalDateGte +* @param data.logicalDateLte +* @param data.root +* @param data.offset +* @param data.runType +* @param data.state +* @param data.limit +* @param data.orderBy +* @returns GridResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseGridServiceGridData = (queryClient: QueryClient, { dagId, includeDownstream, includeUpstream, limit, logicalDateGte, logicalDateLte, offset, orderBy, root, runType, state }: { + dagId: string; + includeDownstream?: boolean; + includeUpstream?: boolean; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + root?: string; + runType?: string[]; + state?: string[]; +}) => queryClient.prefetchQuery({ queryKey: Common.UseGridServiceGridDataKeyFn({ dagId, includeDownstream, includeUpstream, limit, logicalDateGte, logicalDateLte, offset, orderBy, root, runType, state }), queryFn: () => GridService.gridData({ dagId, includeDownstream, includeUpstream, limit, logicalDateGte, logicalDateLte, offset, orderBy, root, runType, state }) }); /** - * Get Connection - * Get a connection entry. - * @param data The data for the request. - * @param data.connectionId - * @returns ConnectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseConnectionServiceGetConnection = ( - queryClient: QueryClient, - { - connectionId, - }: { - connectionId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseConnectionServiceGetConnectionKeyFn({ connectionId }), - queryFn: () => ConnectionService.getConnection({ connectionId }), - }); +* Get Connection +* Get a connection entry. +* @param data The data for the request. +* @param data.connectionId +* @returns ConnectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseConnectionServiceGetConnection = (queryClient: QueryClient, { connectionId }: { + connectionId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseConnectionServiceGetConnectionKeyFn({ connectionId }), queryFn: () => ConnectionService.getConnection({ connectionId }) }); /** - * Get Connections - * Get all connection entries. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns ConnectionCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseConnectionServiceGetConnections = ( - queryClient: QueryClient, - { - limit, - offset, - orderBy, - }: { - limit?: number; - offset?: number; - orderBy?: string; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseConnectionServiceGetConnectionsKeyFn({ limit, offset, orderBy }), - queryFn: () => ConnectionService.getConnections({ limit, offset, orderBy }), - }); +* Get Connections +* Get all connection entries. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns ConnectionCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseConnectionServiceGetConnections = (queryClient: QueryClient, { limit, offset, orderBy }: { + limit?: number; + offset?: number; + orderBy?: string; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseConnectionServiceGetConnectionsKeyFn({ limit, offset, orderBy }), queryFn: () => ConnectionService.getConnections({ limit, offset, orderBy }) }); /** - * Get Dag Run - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @returns DAGRunResponse Successful Response - * @throws ApiError - */ -export const prefetchUseDagRunServiceGetDagRun = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - }: { - dagId: string; - dagRunId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseDagRunServiceGetDagRunKeyFn({ dagId, dagRunId }), - queryFn: () => DagRunService.getDagRun({ dagId, dagRunId }), - }); +* Get Dag Run +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @returns DAGRunResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseDagRunServiceGetDagRun = (queryClient: QueryClient, { dagId, dagRunId }: { + dagId: string; + dagRunId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseDagRunServiceGetDagRunKeyFn({ dagId, dagRunId }), queryFn: () => DagRunService.getDagRun({ dagId, dagRunId }) }); /** - * Get Upstream Asset Events - * If dag run is asset-triggered, return the asset events that triggered it. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @returns AssetEventCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseDagRunServiceGetUpstreamAssetEvents = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - }: { - dagId: string; - dagRunId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseDagRunServiceGetUpstreamAssetEventsKeyFn({ dagId, dagRunId }), - queryFn: () => DagRunService.getUpstreamAssetEvents({ dagId, dagRunId }), - }); +* Get Upstream Asset Events +* If dag run is asset-triggered, return the asset events that triggered it. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @returns AssetEventCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseDagRunServiceGetUpstreamAssetEvents = (queryClient: QueryClient, { dagId, dagRunId }: { + dagId: string; + dagRunId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseDagRunServiceGetUpstreamAssetEventsKeyFn({ dagId, dagRunId }), queryFn: () => DagRunService.getUpstreamAssetEvents({ dagId, dagRunId }) }); /** - * Get Dag Runs - * Get all DAG Runs. - * - * This endpoint allows specifying `~` as the dag_id to retrieve Dag Runs for all DAGs. - * @param data The data for the request. - * @param data.dagId - * @param data.limit - * @param data.offset - * @param data.logicalDateGte - * @param data.logicalDateLte - * @param data.startDateGte - * @param data.startDateLte - * @param data.endDateGte - * @param data.endDateLte - * @param data.updatedAtGte - * @param data.updatedAtLte - * @param data.state - * @param data.orderBy - * @returns DAGRunCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseDagRunServiceGetDagRuns = ( - queryClient: QueryClient, - { - dagId, - endDateGte, - endDateLte, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - startDateGte, - startDateLte, - state, - updatedAtGte, - updatedAtLte, - }: { - dagId: string; - endDateGte?: string; - endDateLte?: string; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - startDateGte?: string; - startDateLte?: string; - state?: string[]; - updatedAtGte?: string; - updatedAtLte?: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseDagRunServiceGetDagRunsKeyFn({ - dagId, - endDateGte, - endDateLte, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - startDateGte, - startDateLte, - state, - updatedAtGte, - updatedAtLte, - }), - queryFn: () => - DagRunService.getDagRuns({ - dagId, - endDateGte, - endDateLte, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - startDateGte, - startDateLte, - state, - updatedAtGte, - updatedAtLte, - }), - }); +* Get Dag Runs +* Get all DAG Runs. +* +* This endpoint allows specifying `~` as the dag_id to retrieve Dag Runs for all DAGs. +* @param data The data for the request. +* @param data.dagId +* @param data.limit +* @param data.offset +* @param data.logicalDateGte +* @param data.logicalDateLte +* @param data.startDateGte +* @param data.startDateLte +* @param data.endDateGte +* @param data.endDateLte +* @param data.updatedAtGte +* @param data.updatedAtLte +* @param data.state +* @param data.orderBy +* @returns DAGRunCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseDagRunServiceGetDagRuns = (queryClient: QueryClient, { dagId, endDateGte, endDateLte, limit, logicalDateGte, logicalDateLte, offset, orderBy, startDateGte, startDateLte, state, updatedAtGte, updatedAtLte }: { + dagId: string; + endDateGte?: string; + endDateLte?: string; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + startDateGte?: string; + startDateLte?: string; + state?: string[]; + updatedAtGte?: string; + updatedAtLte?: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseDagRunServiceGetDagRunsKeyFn({ dagId, endDateGte, endDateLte, limit, logicalDateGte, logicalDateLte, offset, orderBy, startDateGte, startDateLte, state, updatedAtGte, updatedAtLte }), queryFn: () => DagRunService.getDagRuns({ dagId, endDateGte, endDateLte, limit, logicalDateGte, logicalDateLte, offset, orderBy, startDateGte, startDateLte, state, updatedAtGte, updatedAtLte }) }); /** - * Get Dag Source - * Get source code using file token. - * @param data The data for the request. - * @param data.dagId - * @param data.versionNumber - * @param data.accept - * @returns DAGSourceResponse Successful Response - * @throws ApiError - */ -export const prefetchUseDagSourceServiceGetDagSource = ( - queryClient: QueryClient, - { - accept, - dagId, - versionNumber, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - dagId: string; - versionNumber?: number; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseDagSourceServiceGetDagSourceKeyFn({ accept, dagId, versionNumber }), - queryFn: () => DagSourceService.getDagSource({ accept, dagId, versionNumber }), - }); +* Get Dag Source +* Get source code using file token. +* @param data The data for the request. +* @param data.dagId +* @param data.versionNumber +* @param data.accept +* @returns DAGSourceResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseDagSourceServiceGetDagSource = (queryClient: QueryClient, { accept, dagId, versionNumber }: { + accept?: "application/json" | "text/plain" | "*/*"; + dagId: string; + versionNumber?: number; +}) => queryClient.prefetchQuery({ queryKey: Common.UseDagSourceServiceGetDagSourceKeyFn({ accept, dagId, versionNumber }), queryFn: () => DagSourceService.getDagSource({ accept, dagId, versionNumber }) }); /** - * Get Dag Stats - * Get Dag statistics. - * @param data The data for the request. - * @param data.dagIds - * @returns DagStatsCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseDagStatsServiceGetDagStats = ( - queryClient: QueryClient, - { - dagIds, - }: { - dagIds?: string[]; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseDagStatsServiceGetDagStatsKeyFn({ dagIds }), - queryFn: () => DagStatsService.getDagStats({ dagIds }), - }); +* Get Dag Stats +* Get Dag statistics. +* @param data The data for the request. +* @param data.dagIds +* @returns DagStatsCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseDagStatsServiceGetDagStats = (queryClient: QueryClient, { dagIds }: { + dagIds?: string[]; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseDagStatsServiceGetDagStatsKeyFn({ dagIds }), queryFn: () => DagStatsService.getDagStats({ dagIds }) }); /** - * List Dag Warnings - * Get a list of DAG warnings. - * @param data The data for the request. - * @param data.dagId - * @param data.warningType - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns DAGWarningCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseDagWarningServiceListDagWarnings = ( - queryClient: QueryClient, - { - dagId, - limit, - offset, - orderBy, - warningType, - }: { - dagId?: string; - limit?: number; - offset?: number; - orderBy?: string; - warningType?: DagWarningType; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseDagWarningServiceListDagWarningsKeyFn({ dagId, limit, offset, orderBy, warningType }), - queryFn: () => DagWarningService.listDagWarnings({ dagId, limit, offset, orderBy, warningType }), - }); +* List Dag Warnings +* Get a list of DAG warnings. +* @param data The data for the request. +* @param data.dagId +* @param data.warningType +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns DAGWarningCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseDagWarningServiceListDagWarnings = (queryClient: QueryClient, { dagId, limit, offset, orderBy, warningType }: { + dagId?: string; + limit?: number; + offset?: number; + orderBy?: string; + warningType?: DagWarningType; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseDagWarningServiceListDagWarningsKeyFn({ dagId, limit, offset, orderBy, warningType }), queryFn: () => DagWarningService.listDagWarnings({ dagId, limit, offset, orderBy, warningType }) }); /** - * Get Dags - * Get all DAGs. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.tags - * @param data.owners - * @param data.dagIdPattern - * @param data.dagDisplayNamePattern - * @param data.onlyActive - * @param data.paused - * @param data.lastDagRunState - * @param data.orderBy - * @returns DAGCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseDagServiceGetDags = ( - queryClient: QueryClient, - { - dagDisplayNamePattern, - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - orderBy, - owners, - paused, - tags, - }: { - dagDisplayNamePattern?: string; - dagIdPattern?: string; - lastDagRunState?: DagRunState; - limit?: number; - offset?: number; - onlyActive?: boolean; - orderBy?: string; - owners?: string[]; - paused?: boolean; - tags?: string[]; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseDagServiceGetDagsKeyFn({ - dagDisplayNamePattern, - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - orderBy, - owners, - paused, - tags, - }), - queryFn: () => - DagService.getDags({ - dagDisplayNamePattern, - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - orderBy, - owners, - paused, - tags, - }), - }); +* Get Dags +* Get all DAGs. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.tags +* @param data.owners +* @param data.dagIdPattern +* @param data.dagDisplayNamePattern +* @param data.onlyActive +* @param data.paused +* @param data.lastDagRunState +* @param data.orderBy +* @returns DAGCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseDagServiceGetDags = (queryClient: QueryClient, { dagDisplayNamePattern, dagIdPattern, lastDagRunState, limit, offset, onlyActive, orderBy, owners, paused, tags }: { + dagDisplayNamePattern?: string; + dagIdPattern?: string; + lastDagRunState?: DagRunState; + limit?: number; + offset?: number; + onlyActive?: boolean; + orderBy?: string; + owners?: string[]; + paused?: boolean; + tags?: string[]; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseDagServiceGetDagsKeyFn({ dagDisplayNamePattern, dagIdPattern, lastDagRunState, limit, offset, onlyActive, orderBy, owners, paused, tags }), queryFn: () => DagService.getDags({ dagDisplayNamePattern, dagIdPattern, lastDagRunState, limit, offset, onlyActive, orderBy, owners, paused, tags }) }); /** - * Get Dag - * Get basic information about a DAG. - * @param data The data for the request. - * @param data.dagId - * @returns DAGResponse Successful Response - * @throws ApiError - */ -export const prefetchUseDagServiceGetDag = ( - queryClient: QueryClient, - { - dagId, - }: { - dagId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseDagServiceGetDagKeyFn({ dagId }), - queryFn: () => DagService.getDag({ dagId }), - }); +* Get Dag +* Get basic information about a DAG. +* @param data The data for the request. +* @param data.dagId +* @returns DAGResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseDagServiceGetDag = (queryClient: QueryClient, { dagId }: { + dagId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseDagServiceGetDagKeyFn({ dagId }), queryFn: () => DagService.getDag({ dagId }) }); /** - * Get Dag Details - * Get details of DAG. - * @param data The data for the request. - * @param data.dagId - * @returns DAGDetailsResponse Successful Response - * @throws ApiError - */ -export const prefetchUseDagServiceGetDagDetails = ( - queryClient: QueryClient, - { - dagId, - }: { - dagId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseDagServiceGetDagDetailsKeyFn({ dagId }), - queryFn: () => DagService.getDagDetails({ dagId }), - }); +* Get Dag Details +* Get details of DAG. +* @param data The data for the request. +* @param data.dagId +* @returns DAGDetailsResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseDagServiceGetDagDetails = (queryClient: QueryClient, { dagId }: { + dagId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseDagServiceGetDagDetailsKeyFn({ dagId }), queryFn: () => DagService.getDagDetails({ dagId }) }); /** - * Get Dag Tags - * Get all DAG tags. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.tagNamePattern - * @returns DAGTagCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseDagServiceGetDagTags = ( - queryClient: QueryClient, - { - limit, - offset, - orderBy, - tagNamePattern, - }: { - limit?: number; - offset?: number; - orderBy?: string; - tagNamePattern?: string; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseDagServiceGetDagTagsKeyFn({ limit, offset, orderBy, tagNamePattern }), - queryFn: () => DagService.getDagTags({ limit, offset, orderBy, tagNamePattern }), - }); +* Get Dag Tags +* Get all DAG tags. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.tagNamePattern +* @returns DAGTagCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseDagServiceGetDagTags = (queryClient: QueryClient, { limit, offset, orderBy, tagNamePattern }: { + limit?: number; + offset?: number; + orderBy?: string; + tagNamePattern?: string; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseDagServiceGetDagTagsKeyFn({ limit, offset, orderBy, tagNamePattern }), queryFn: () => DagService.getDagTags({ limit, offset, orderBy, tagNamePattern }) }); /** - * Get Event Log - * @param data The data for the request. - * @param data.eventLogId - * @returns EventLogResponse Successful Response - * @throws ApiError - */ -export const prefetchUseEventLogServiceGetEventLog = ( - queryClient: QueryClient, - { - eventLogId, - }: { - eventLogId: number; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseEventLogServiceGetEventLogKeyFn({ eventLogId }), - queryFn: () => EventLogService.getEventLog({ eventLogId }), - }); +* Get Event Log +* @param data The data for the request. +* @param data.eventLogId +* @returns EventLogResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseEventLogServiceGetEventLog = (queryClient: QueryClient, { eventLogId }: { + eventLogId: number; +}) => queryClient.prefetchQuery({ queryKey: Common.UseEventLogServiceGetEventLogKeyFn({ eventLogId }), queryFn: () => EventLogService.getEventLog({ eventLogId }) }); /** - * Get Event Logs - * Get all Event Logs. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.dagId - * @param data.taskId - * @param data.runId - * @param data.mapIndex - * @param data.tryNumber - * @param data.owner - * @param data.event - * @param data.excludedEvents - * @param data.includedEvents - * @param data.before - * @param data.after - * @returns EventLogCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseEventLogServiceGetEventLogs = ( - queryClient: QueryClient, - { - after, - before, - dagId, - event, - excludedEvents, - includedEvents, - limit, - mapIndex, - offset, - orderBy, - owner, - runId, - taskId, - tryNumber, - }: { - after?: string; - before?: string; - dagId?: string; - event?: string; - excludedEvents?: string[]; - includedEvents?: string[]; - limit?: number; - mapIndex?: number; - offset?: number; - orderBy?: string; - owner?: string; - runId?: string; - taskId?: string; - tryNumber?: number; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseEventLogServiceGetEventLogsKeyFn({ - after, - before, - dagId, - event, - excludedEvents, - includedEvents, - limit, - mapIndex, - offset, - orderBy, - owner, - runId, - taskId, - tryNumber, - }), - queryFn: () => - EventLogService.getEventLogs({ - after, - before, - dagId, - event, - excludedEvents, - includedEvents, - limit, - mapIndex, - offset, - orderBy, - owner, - runId, - taskId, - tryNumber, - }), - }); +* Get Event Logs +* Get all Event Logs. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.dagId +* @param data.taskId +* @param data.runId +* @param data.mapIndex +* @param data.tryNumber +* @param data.owner +* @param data.event +* @param data.excludedEvents +* @param data.includedEvents +* @param data.before +* @param data.after +* @returns EventLogCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseEventLogServiceGetEventLogs = (queryClient: QueryClient, { after, before, dagId, event, excludedEvents, includedEvents, limit, mapIndex, offset, orderBy, owner, runId, taskId, tryNumber }: { + after?: string; + before?: string; + dagId?: string; + event?: string; + excludedEvents?: string[]; + includedEvents?: string[]; + limit?: number; + mapIndex?: number; + offset?: number; + orderBy?: string; + owner?: string; + runId?: string; + taskId?: string; + tryNumber?: number; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseEventLogServiceGetEventLogsKeyFn({ after, before, dagId, event, excludedEvents, includedEvents, limit, mapIndex, offset, orderBy, owner, runId, taskId, tryNumber }), queryFn: () => EventLogService.getEventLogs({ after, before, dagId, event, excludedEvents, includedEvents, limit, mapIndex, offset, orderBy, owner, runId, taskId, tryNumber }) }); /** - * Get Extra Links - * Get extra links for task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @returns ExtraLinksResponse Successful Response - * @throws ApiError - */ -export const prefetchUseExtraLinksServiceGetExtraLinks = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - taskId, - }: { - dagId: string; - dagRunId: string; - taskId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseExtraLinksServiceGetExtraLinksKeyFn({ dagId, dagRunId, taskId }), - queryFn: () => ExtraLinksService.getExtraLinks({ dagId, dagRunId, taskId }), - }); +* Get Extra Links +* Get extra links for task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @returns ExtraLinksResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseExtraLinksServiceGetExtraLinks = (queryClient: QueryClient, { dagId, dagRunId, taskId }: { + dagId: string; + dagRunId: string; + taskId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseExtraLinksServiceGetExtraLinksKeyFn({ dagId, dagRunId, taskId }), queryFn: () => ExtraLinksService.getExtraLinks({ dagId, dagRunId, taskId }) }); /** - * Get Extra Links - * Get extra links for task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @returns ExtraLinksResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskInstanceServiceGetExtraLinks = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - taskId, - }: { - dagId: string; - dagRunId: string; - taskId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskInstanceServiceGetExtraLinksKeyFn({ dagId, dagRunId, taskId }), - queryFn: () => TaskInstanceService.getExtraLinks({ dagId, dagRunId, taskId }), - }); +* Get Extra Links +* Get extra links for task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @returns ExtraLinksResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskInstanceServiceGetExtraLinks = (queryClient: QueryClient, { dagId, dagRunId, taskId }: { + dagId: string; + dagRunId: string; + taskId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskInstanceServiceGetExtraLinksKeyFn({ dagId, dagRunId, taskId }), queryFn: () => TaskInstanceService.getExtraLinks({ dagId, dagRunId, taskId }) }); /** - * Get Task Instance - * Get task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @returns TaskInstanceResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskInstanceServiceGetTaskInstance = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - taskId, - }: { - dagId: string; - dagRunId: string; - taskId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceKeyFn({ dagId, dagRunId, taskId }), - queryFn: () => TaskInstanceService.getTaskInstance({ dagId, dagRunId, taskId }), - }); +* Get Task Instance +* Get task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @returns TaskInstanceResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskInstanceServiceGetTaskInstance = (queryClient: QueryClient, { dagId, dagRunId, taskId }: { + dagId: string; + dagRunId: string; + taskId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceKeyFn({ dagId, dagRunId, taskId }), queryFn: () => TaskInstanceService.getTaskInstance({ dagId, dagRunId, taskId }) }); /** - * Get Mapped Task Instances - * Get list of mapped task instances. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.logicalDateGte - * @param data.logicalDateLte - * @param data.startDateGte - * @param data.startDateLte - * @param data.endDateGte - * @param data.endDateLte - * @param data.updatedAtGte - * @param data.updatedAtLte - * @param data.durationGte - * @param data.durationLte - * @param data.state - * @param data.pool - * @param data.queue - * @param data.executor - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns TaskInstanceCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskInstanceServiceGetMappedTaskInstances = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskId, - updatedAtGte, - updatedAtLte, - }: { - dagId: string; - dagRunId: string; - durationGte?: number; - durationLte?: number; - endDateGte?: string; - endDateLte?: string; - executor?: string[]; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - pool?: string[]; - queue?: string[]; - startDateGte?: string; - startDateLte?: string; - state?: string[]; - taskId: string; - updatedAtGte?: string; - updatedAtLte?: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstancesKeyFn({ - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskId, - updatedAtGte, - updatedAtLte, - }), - queryFn: () => - TaskInstanceService.getMappedTaskInstances({ - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskId, - updatedAtGte, - updatedAtLte, - }), - }); +* Get Mapped Task Instances +* Get list of mapped task instances. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.logicalDateGte +* @param data.logicalDateLte +* @param data.startDateGte +* @param data.startDateLte +* @param data.endDateGte +* @param data.endDateLte +* @param data.updatedAtGte +* @param data.updatedAtLte +* @param data.durationGte +* @param data.durationLte +* @param data.state +* @param data.pool +* @param data.queue +* @param data.executor +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns TaskInstanceCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskInstanceServiceGetMappedTaskInstances = (queryClient: QueryClient, { dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskId, updatedAtGte, updatedAtLte }: { + dagId: string; + dagRunId: string; + durationGte?: number; + durationLte?: number; + endDateGte?: string; + endDateLte?: string; + executor?: string[]; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + pool?: string[]; + queue?: string[]; + startDateGte?: string; + startDateLte?: string; + state?: string[]; + taskId: string; + updatedAtGte?: string; + updatedAtLte?: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstancesKeyFn({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskId, updatedAtGte, updatedAtLte }), queryFn: () => TaskInstanceService.getMappedTaskInstances({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskId, updatedAtGte, updatedAtLte }) }); /** - * Get Task Instance Dependencies - * Get dependencies blocking task from getting scheduled. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskDependencyCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskInstanceServiceGetTaskInstanceDependencies = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceDependenciesKeyFn({ - dagId, - dagRunId, - mapIndex, - taskId, - }), - queryFn: () => TaskInstanceService.getTaskInstanceDependencies({ dagId, dagRunId, mapIndex, taskId }), - }); +* Get Task Instance Dependencies +* Get dependencies blocking task from getting scheduled. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskDependencyCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskInstanceServiceGetTaskInstanceDependencies = (queryClient: QueryClient, { dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceDependenciesKeyFn({ dagId, dagRunId, mapIndex, taskId }), queryFn: () => TaskInstanceService.getTaskInstanceDependencies({ dagId, dagRunId, mapIndex, taskId }) }); /** - * Get Task Instance Dependencies - * Get dependencies blocking task from getting scheduled. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskDependencyCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskInstanceServiceGetTaskInstanceDependencies1 = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex?: number; - taskId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceDependencies1KeyFn({ - dagId, - dagRunId, - mapIndex, - taskId, - }), - queryFn: () => TaskInstanceService.getTaskInstanceDependencies1({ dagId, dagRunId, mapIndex, taskId }), - }); +* Get Task Instance Dependencies +* Get dependencies blocking task from getting scheduled. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskDependencyCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskInstanceServiceGetTaskInstanceDependencies1 = (queryClient: QueryClient, { dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex?: number; + taskId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceDependencies1KeyFn({ dagId, dagRunId, mapIndex, taskId }), queryFn: () => TaskInstanceService.getTaskInstanceDependencies1({ dagId, dagRunId, mapIndex, taskId }) }); /** - * Get Task Instance Tries - * Get list of task instances history. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskInstanceHistoryCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskInstanceServiceGetTaskInstanceTries = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex?: number; - taskId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceTriesKeyFn({ dagId, dagRunId, mapIndex, taskId }), - queryFn: () => TaskInstanceService.getTaskInstanceTries({ dagId, dagRunId, mapIndex, taskId }), - }); +* Get Task Instance Tries +* Get list of task instances history. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskInstanceHistoryCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskInstanceServiceGetTaskInstanceTries = (queryClient: QueryClient, { dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex?: number; + taskId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceTriesKeyFn({ dagId, dagRunId, mapIndex, taskId }), queryFn: () => TaskInstanceService.getTaskInstanceTries({ dagId, dagRunId, mapIndex, taskId }) }); /** - * Get Mapped Task Instance Tries - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskInstanceHistoryCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskInstanceServiceGetMappedTaskInstanceTries = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceTriesKeyFn({ - dagId, - dagRunId, - mapIndex, - taskId, - }), - queryFn: () => TaskInstanceService.getMappedTaskInstanceTries({ dagId, dagRunId, mapIndex, taskId }), - }); +* Get Mapped Task Instance Tries +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskInstanceHistoryCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskInstanceServiceGetMappedTaskInstanceTries = (queryClient: QueryClient, { dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceTriesKeyFn({ dagId, dagRunId, mapIndex, taskId }), queryFn: () => TaskInstanceService.getMappedTaskInstanceTries({ dagId, dagRunId, mapIndex, taskId }) }); /** - * Get Mapped Task Instance - * Get task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskInstanceResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskInstanceServiceGetMappedTaskInstance = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceKeyFn({ dagId, dagRunId, mapIndex, taskId }), - queryFn: () => TaskInstanceService.getMappedTaskInstance({ dagId, dagRunId, mapIndex, taskId }), - }); +* Get Mapped Task Instance +* Get task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskInstanceResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskInstanceServiceGetMappedTaskInstance = (queryClient: QueryClient, { dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceKeyFn({ dagId, dagRunId, mapIndex, taskId }), queryFn: () => TaskInstanceService.getMappedTaskInstance({ dagId, dagRunId, mapIndex, taskId }) }); /** - * Get Task Instances - * Get list of task instances. - * - * This endpoint allows specifying `~` as the dag_id, dag_run_id to retrieve Task Instances for all DAGs - * and DAG runs. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.logicalDateGte - * @param data.logicalDateLte - * @param data.startDateGte - * @param data.startDateLte - * @param data.endDateGte - * @param data.endDateLte - * @param data.updatedAtGte - * @param data.updatedAtLte - * @param data.durationGte - * @param data.durationLte - * @param data.taskDisplayNamePattern - * @param data.state - * @param data.pool - * @param data.queue - * @param data.executor - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns TaskInstanceCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskInstanceServiceGetTaskInstances = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskDisplayNamePattern, - taskId, - updatedAtGte, - updatedAtLte, - }: { - dagId: string; - dagRunId: string; - durationGte?: number; - durationLte?: number; - endDateGte?: string; - endDateLte?: string; - executor?: string[]; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - pool?: string[]; - queue?: string[]; - startDateGte?: string; - startDateLte?: string; - state?: string[]; - taskDisplayNamePattern?: string; - taskId?: string; - updatedAtGte?: string; - updatedAtLte?: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstancesKeyFn({ - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskDisplayNamePattern, - taskId, - updatedAtGte, - updatedAtLte, - }), - queryFn: () => - TaskInstanceService.getTaskInstances({ - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskDisplayNamePattern, - taskId, - updatedAtGte, - updatedAtLte, - }), - }); +* Get Task Instances +* Get list of task instances. +* +* This endpoint allows specifying `~` as the dag_id, dag_run_id to retrieve Task Instances for all DAGs +* and DAG runs. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.logicalDateGte +* @param data.logicalDateLte +* @param data.startDateGte +* @param data.startDateLte +* @param data.endDateGte +* @param data.endDateLte +* @param data.updatedAtGte +* @param data.updatedAtLte +* @param data.durationGte +* @param data.durationLte +* @param data.taskDisplayNamePattern +* @param data.state +* @param data.pool +* @param data.queue +* @param data.executor +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns TaskInstanceCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskInstanceServiceGetTaskInstances = (queryClient: QueryClient, { dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskDisplayNamePattern, taskId, updatedAtGte, updatedAtLte }: { + dagId: string; + dagRunId: string; + durationGte?: number; + durationLte?: number; + endDateGte?: string; + endDateLte?: string; + executor?: string[]; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + pool?: string[]; + queue?: string[]; + startDateGte?: string; + startDateLte?: string; + state?: string[]; + taskDisplayNamePattern?: string; + taskId?: string; + updatedAtGte?: string; + updatedAtLte?: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstancesKeyFn({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskDisplayNamePattern, taskId, updatedAtGte, updatedAtLte }), queryFn: () => TaskInstanceService.getTaskInstances({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskDisplayNamePattern, taskId, updatedAtGte, updatedAtLte }) }); /** - * Get Task Instance Try Details - * Get task instance details by try number. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.taskTryNumber - * @param data.mapIndex - * @returns TaskInstanceHistoryResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskInstanceServiceGetTaskInstanceTryDetails = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }: { - dagId: string; - dagRunId: string; - mapIndex?: number; - taskId: string; - taskTryNumber: number; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceTryDetailsKeyFn({ - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }), - queryFn: () => - TaskInstanceService.getTaskInstanceTryDetails({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }), - }); +* Get Task Instance Try Details +* Get task instance details by try number. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.taskTryNumber +* @param data.mapIndex +* @returns TaskInstanceHistoryResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskInstanceServiceGetTaskInstanceTryDetails = (queryClient: QueryClient, { dagId, dagRunId, mapIndex, taskId, taskTryNumber }: { + dagId: string; + dagRunId: string; + mapIndex?: number; + taskId: string; + taskTryNumber: number; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceTryDetailsKeyFn({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }), queryFn: () => TaskInstanceService.getTaskInstanceTryDetails({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }) }); /** - * Get Mapped Task Instance Try Details - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.taskTryNumber - * @param data.mapIndex - * @returns TaskInstanceHistoryResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskInstanceServiceGetMappedTaskInstanceTryDetails = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - taskTryNumber: number; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceTryDetailsKeyFn({ - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }), - queryFn: () => - TaskInstanceService.getMappedTaskInstanceTryDetails({ - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }), - }); +* Get Mapped Task Instance Try Details +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.taskTryNumber +* @param data.mapIndex +* @returns TaskInstanceHistoryResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskInstanceServiceGetMappedTaskInstanceTryDetails = (queryClient: QueryClient, { dagId, dagRunId, mapIndex, taskId, taskTryNumber }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; + taskTryNumber: number; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceTryDetailsKeyFn({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }), queryFn: () => TaskInstanceService.getMappedTaskInstanceTryDetails({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }) }); /** - * Get Log - * Get logs for a specific task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.tryNumber - * @param data.fullContent - * @param data.mapIndex - * @param data.token - * @param data.accept - * @returns TaskInstancesLogResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskInstanceServiceGetLog = ( - queryClient: QueryClient, - { - accept, - dagId, - dagRunId, - fullContent, - mapIndex, - taskId, - token, - tryNumber, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - dagId: string; - dagRunId: string; - fullContent?: boolean; - mapIndex?: number; - taskId: string; - token?: string; - tryNumber: number; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskInstanceServiceGetLogKeyFn({ - accept, - dagId, - dagRunId, - fullContent, - mapIndex, - taskId, - token, - tryNumber, - }), - queryFn: () => - TaskInstanceService.getLog({ - accept, - dagId, - dagRunId, - fullContent, - mapIndex, - taskId, - token, - tryNumber, - }), - }); +* Get Log +* Get logs for a specific task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.tryNumber +* @param data.fullContent +* @param data.mapIndex +* @param data.token +* @param data.accept +* @returns TaskInstancesLogResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskInstanceServiceGetLog = (queryClient: QueryClient, { accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }: { + accept?: "application/json" | "text/plain" | "*/*"; + dagId: string; + dagRunId: string; + fullContent?: boolean; + mapIndex?: number; + taskId: string; + token?: string; + tryNumber: number; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskInstanceServiceGetLogKeyFn({ accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }), queryFn: () => TaskInstanceService.getLog({ accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }) }); /** - * Get Import Error - * Get an import error. - * @param data The data for the request. - * @param data.importErrorId - * @returns ImportErrorResponse Successful Response - * @throws ApiError - */ -export const prefetchUseImportErrorServiceGetImportError = ( - queryClient: QueryClient, - { - importErrorId, - }: { - importErrorId: number; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseImportErrorServiceGetImportErrorKeyFn({ importErrorId }), - queryFn: () => ImportErrorService.getImportError({ importErrorId }), - }); +* Get Import Error +* Get an import error. +* @param data The data for the request. +* @param data.importErrorId +* @returns ImportErrorResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseImportErrorServiceGetImportError = (queryClient: QueryClient, { importErrorId }: { + importErrorId: number; +}) => queryClient.prefetchQuery({ queryKey: Common.UseImportErrorServiceGetImportErrorKeyFn({ importErrorId }), queryFn: () => ImportErrorService.getImportError({ importErrorId }) }); /** - * Get Import Errors - * Get all import errors. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns ImportErrorCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseImportErrorServiceGetImportErrors = ( - queryClient: QueryClient, - { - limit, - offset, - orderBy, - }: { - limit?: number; - offset?: number; - orderBy?: string; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseImportErrorServiceGetImportErrorsKeyFn({ limit, offset, orderBy }), - queryFn: () => ImportErrorService.getImportErrors({ limit, offset, orderBy }), - }); +* Get Import Errors +* Get all import errors. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns ImportErrorCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseImportErrorServiceGetImportErrors = (queryClient: QueryClient, { limit, offset, orderBy }: { + limit?: number; + offset?: number; + orderBy?: string; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseImportErrorServiceGetImportErrorsKeyFn({ limit, offset, orderBy }), queryFn: () => ImportErrorService.getImportErrors({ limit, offset, orderBy }) }); /** - * Get Jobs - * Get all jobs. - * @param data The data for the request. - * @param data.isAlive - * @param data.startDateGte - * @param data.startDateLte - * @param data.endDateGte - * @param data.endDateLte - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.jobState - * @param data.jobType - * @param data.hostname - * @param data.executorClass - * @returns JobCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseJobServiceGetJobs = ( - queryClient: QueryClient, - { - endDateGte, - endDateLte, - executorClass, - hostname, - isAlive, - jobState, - jobType, - limit, - offset, - orderBy, - startDateGte, - startDateLte, - }: { - endDateGte?: string; - endDateLte?: string; - executorClass?: string; - hostname?: string; - isAlive?: boolean; - jobState?: string; - jobType?: string; - limit?: number; - offset?: number; - orderBy?: string; - startDateGte?: string; - startDateLte?: string; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseJobServiceGetJobsKeyFn({ - endDateGte, - endDateLte, - executorClass, - hostname, - isAlive, - jobState, - jobType, - limit, - offset, - orderBy, - startDateGte, - startDateLte, - }), - queryFn: () => - JobService.getJobs({ - endDateGte, - endDateLte, - executorClass, - hostname, - isAlive, - jobState, - jobType, - limit, - offset, - orderBy, - startDateGte, - startDateLte, - }), - }); +* Get Jobs +* Get all jobs. +* @param data The data for the request. +* @param data.isAlive +* @param data.startDateGte +* @param data.startDateLte +* @param data.endDateGte +* @param data.endDateLte +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.jobState +* @param data.jobType +* @param data.hostname +* @param data.executorClass +* @returns JobCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseJobServiceGetJobs = (queryClient: QueryClient, { endDateGte, endDateLte, executorClass, hostname, isAlive, jobState, jobType, limit, offset, orderBy, startDateGte, startDateLte }: { + endDateGte?: string; + endDateLte?: string; + executorClass?: string; + hostname?: string; + isAlive?: boolean; + jobState?: string; + jobType?: string; + limit?: number; + offset?: number; + orderBy?: string; + startDateGte?: string; + startDateLte?: string; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseJobServiceGetJobsKeyFn({ endDateGte, endDateLte, executorClass, hostname, isAlive, jobState, jobType, limit, offset, orderBy, startDateGte, startDateLte }), queryFn: () => JobService.getJobs({ endDateGte, endDateLte, executorClass, hostname, isAlive, jobState, jobType, limit, offset, orderBy, startDateGte, startDateLte }) }); /** - * Get Plugins - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @returns PluginCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUsePluginServiceGetPlugins = ( - queryClient: QueryClient, - { - limit, - offset, - }: { - limit?: number; - offset?: number; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UsePluginServiceGetPluginsKeyFn({ limit, offset }), - queryFn: () => PluginService.getPlugins({ limit, offset }), - }); +* Get Plugins +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @returns PluginCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUsePluginServiceGetPlugins = (queryClient: QueryClient, { limit, offset }: { + limit?: number; + offset?: number; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UsePluginServiceGetPluginsKeyFn({ limit, offset }), queryFn: () => PluginService.getPlugins({ limit, offset }) }); /** - * Get Pool - * Get a pool. - * @param data The data for the request. - * @param data.poolName - * @returns PoolResponse Successful Response - * @throws ApiError - */ -export const prefetchUsePoolServiceGetPool = ( - queryClient: QueryClient, - { - poolName, - }: { - poolName: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UsePoolServiceGetPoolKeyFn({ poolName }), - queryFn: () => PoolService.getPool({ poolName }), - }); +* Get Pool +* Get a pool. +* @param data The data for the request. +* @param data.poolName +* @returns PoolResponse Successful Response +* @throws ApiError +*/ +export const prefetchUsePoolServiceGetPool = (queryClient: QueryClient, { poolName }: { + poolName: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UsePoolServiceGetPoolKeyFn({ poolName }), queryFn: () => PoolService.getPool({ poolName }) }); /** - * Get Pools - * Get all pools entries. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns PoolCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUsePoolServiceGetPools = ( - queryClient: QueryClient, - { - limit, - offset, - orderBy, - }: { - limit?: number; - offset?: number; - orderBy?: string; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UsePoolServiceGetPoolsKeyFn({ limit, offset, orderBy }), - queryFn: () => PoolService.getPools({ limit, offset, orderBy }), - }); +* Get Pools +* Get all pools entries. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns PoolCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUsePoolServiceGetPools = (queryClient: QueryClient, { limit, offset, orderBy }: { + limit?: number; + offset?: number; + orderBy?: string; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UsePoolServiceGetPoolsKeyFn({ limit, offset, orderBy }), queryFn: () => PoolService.getPools({ limit, offset, orderBy }) }); /** - * Get Providers - * Get providers. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @returns ProviderCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseProviderServiceGetProviders = ( - queryClient: QueryClient, - { - limit, - offset, - }: { - limit?: number; - offset?: number; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseProviderServiceGetProvidersKeyFn({ limit, offset }), - queryFn: () => ProviderService.getProviders({ limit, offset }), - }); +* Get Providers +* Get providers. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @returns ProviderCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseProviderServiceGetProviders = (queryClient: QueryClient, { limit, offset }: { + limit?: number; + offset?: number; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseProviderServiceGetProvidersKeyFn({ limit, offset }), queryFn: () => ProviderService.getProviders({ limit, offset }) }); /** - * Get Xcom Entry - * Get an XCom entry. - * @param data The data for the request. - * @param data.dagId - * @param data.taskId - * @param data.dagRunId - * @param data.xcomKey - * @param data.mapIndex - * @param data.deserialize - * @param data.stringify - * @returns unknown Successful Response - * @throws ApiError - */ -export const prefetchUseXcomServiceGetXcomEntry = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - deserialize, - mapIndex, - stringify, - taskId, - xcomKey, - }: { - dagId: string; - dagRunId: string; - deserialize?: boolean; - mapIndex?: number; - stringify?: boolean; - taskId: string; - xcomKey: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseXcomServiceGetXcomEntryKeyFn({ - dagId, - dagRunId, - deserialize, - mapIndex, - stringify, - taskId, - xcomKey, - }), - queryFn: () => - XcomService.getXcomEntry({ dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }), - }); +* Get Xcom Entry +* Get an XCom entry. +* @param data The data for the request. +* @param data.dagId +* @param data.taskId +* @param data.dagRunId +* @param data.xcomKey +* @param data.mapIndex +* @param data.deserialize +* @param data.stringify +* @returns unknown Successful Response +* @throws ApiError +*/ +export const prefetchUseXcomServiceGetXcomEntry = (queryClient: QueryClient, { dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }: { + dagId: string; + dagRunId: string; + deserialize?: boolean; + mapIndex?: number; + stringify?: boolean; + taskId: string; + xcomKey: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseXcomServiceGetXcomEntryKeyFn({ dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }), queryFn: () => XcomService.getXcomEntry({ dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }) }); /** - * Get Xcom Entries - * Get all XCom entries. - * - * This endpoint allows specifying `~` as the dag_id, dag_run_id, task_id to retrieve XCom entries for all DAGs. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.xcomKey - * @param data.mapIndex - * @param data.limit - * @param data.offset - * @returns XComCollection Successful Response - * @throws ApiError - */ -export const prefetchUseXcomServiceGetXcomEntries = ( - queryClient: QueryClient, - { - dagId, - dagRunId, - limit, - mapIndex, - offset, - taskId, - xcomKey, - }: { - dagId: string; - dagRunId: string; - limit?: number; - mapIndex?: number; - offset?: number; - taskId: string; - xcomKey?: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseXcomServiceGetXcomEntriesKeyFn({ - dagId, - dagRunId, - limit, - mapIndex, - offset, - taskId, - xcomKey, - }), - queryFn: () => XcomService.getXcomEntries({ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }), - }); +* Get Xcom Entries +* Get all XCom entries. +* +* This endpoint allows specifying `~` as the dag_id, dag_run_id, task_id to retrieve XCom entries for all DAGs. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.xcomKey +* @param data.mapIndex +* @param data.limit +* @param data.offset +* @returns XComCollection Successful Response +* @throws ApiError +*/ +export const prefetchUseXcomServiceGetXcomEntries = (queryClient: QueryClient, { dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }: { + dagId: string; + dagRunId: string; + limit?: number; + mapIndex?: number; + offset?: number; + taskId: string; + xcomKey?: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseXcomServiceGetXcomEntriesKeyFn({ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }), queryFn: () => XcomService.getXcomEntries({ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }) }); /** - * Get Tasks - * Get tasks for DAG. - * @param data The data for the request. - * @param data.dagId - * @param data.orderBy - * @returns TaskCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskServiceGetTasks = ( - queryClient: QueryClient, - { - dagId, - orderBy, - }: { - dagId: string; - orderBy?: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskServiceGetTasksKeyFn({ dagId, orderBy }), - queryFn: () => TaskService.getTasks({ dagId, orderBy }), - }); +* Get Tasks +* Get tasks for DAG. +* @param data The data for the request. +* @param data.dagId +* @param data.orderBy +* @returns TaskCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskServiceGetTasks = (queryClient: QueryClient, { dagId, orderBy }: { + dagId: string; + orderBy?: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskServiceGetTasksKeyFn({ dagId, orderBy }), queryFn: () => TaskService.getTasks({ dagId, orderBy }) }); /** - * Get Task - * Get simplified representation of a task. - * @param data The data for the request. - * @param data.dagId - * @param data.taskId - * @returns TaskResponse Successful Response - * @throws ApiError - */ -export const prefetchUseTaskServiceGetTask = ( - queryClient: QueryClient, - { - dagId, - taskId, - }: { - dagId: string; - taskId: unknown; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseTaskServiceGetTaskKeyFn({ dagId, taskId }), - queryFn: () => TaskService.getTask({ dagId, taskId }), - }); +* Get Task +* Get simplified representation of a task. +* @param data The data for the request. +* @param data.dagId +* @param data.taskId +* @returns TaskResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseTaskServiceGetTask = (queryClient: QueryClient, { dagId, taskId }: { + dagId: string; + taskId: unknown; +}) => queryClient.prefetchQuery({ queryKey: Common.UseTaskServiceGetTaskKeyFn({ dagId, taskId }), queryFn: () => TaskService.getTask({ dagId, taskId }) }); /** - * Get Variable - * Get a variable entry. - * @param data The data for the request. - * @param data.variableKey - * @returns VariableResponse Successful Response - * @throws ApiError - */ -export const prefetchUseVariableServiceGetVariable = ( - queryClient: QueryClient, - { - variableKey, - }: { - variableKey: string; - }, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseVariableServiceGetVariableKeyFn({ variableKey }), - queryFn: () => VariableService.getVariable({ variableKey }), - }); +* Get Variable +* Get a variable entry. +* @param data The data for the request. +* @param data.variableKey +* @returns VariableResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseVariableServiceGetVariable = (queryClient: QueryClient, { variableKey }: { + variableKey: string; +}) => queryClient.prefetchQuery({ queryKey: Common.UseVariableServiceGetVariableKeyFn({ variableKey }), queryFn: () => VariableService.getVariable({ variableKey }) }); /** - * Get Variables - * Get all Variables entries. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.variableKeyPattern - * @returns VariableCollectionResponse Successful Response - * @throws ApiError - */ -export const prefetchUseVariableServiceGetVariables = ( - queryClient: QueryClient, - { - limit, - offset, - orderBy, - variableKeyPattern, - }: { - limit?: number; - offset?: number; - orderBy?: string; - variableKeyPattern?: string; - } = {}, -) => - queryClient.prefetchQuery({ - queryKey: Common.UseVariableServiceGetVariablesKeyFn({ limit, offset, orderBy, variableKeyPattern }), - queryFn: () => VariableService.getVariables({ limit, offset, orderBy, variableKeyPattern }), - }); +* Get Variables +* Get all Variables entries. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.variableKeyPattern +* @returns VariableCollectionResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseVariableServiceGetVariables = (queryClient: QueryClient, { limit, offset, orderBy, variableKeyPattern }: { + limit?: number; + offset?: number; + orderBy?: string; + variableKeyPattern?: string; +} = {}) => queryClient.prefetchQuery({ queryKey: Common.UseVariableServiceGetVariablesKeyFn({ limit, offset, orderBy, variableKeyPattern }), queryFn: () => VariableService.getVariables({ limit, offset, orderBy, variableKeyPattern }) }); /** - * Get Health - * @returns HealthInfoResponse Successful Response - * @throws ApiError - */ -export const prefetchUseMonitorServiceGetHealth = (queryClient: QueryClient) => - queryClient.prefetchQuery({ - queryKey: Common.UseMonitorServiceGetHealthKeyFn(), - queryFn: () => MonitorService.getHealth(), - }); +* Get Health +* @returns HealthInfoResponse Successful Response +* @throws ApiError +*/ +export const prefetchUseMonitorServiceGetHealth = (queryClient: QueryClient) => queryClient.prefetchQuery({ queryKey: Common.UseMonitorServiceGetHealthKeyFn(), queryFn: () => MonitorService.getHealth() }); /** - * Get Version - * Get version information. - * @returns VersionInfo Successful Response - * @throws ApiError - */ -export const prefetchUseVersionServiceGetVersion = (queryClient: QueryClient) => - queryClient.prefetchQuery({ - queryKey: Common.UseVersionServiceGetVersionKeyFn(), - queryFn: () => VersionService.getVersion(), - }); +* Get Version +* Get version information. +* @returns VersionInfo Successful Response +* @throws ApiError +*/ +export const prefetchUseVersionServiceGetVersion = (queryClient: QueryClient) => queryClient.prefetchQuery({ queryKey: Common.UseVersionServiceGetVersionKeyFn(), queryFn: () => VersionService.getVersion() }); diff --git a/airflow/ui/openapi-gen/queries/queries.ts b/airflow/ui/openapi-gen/queries/queries.ts index dadfaf92505ba..d0bf42efa707d 100644 --- a/airflow/ui/openapi-gen/queries/queries.ts +++ b/airflow/ui/openapi-gen/queries/queries.ts @@ -1,4063 +1,1655 @@ -// generated with @7nohe/openapi-react-query-codegen@1.6.0 -import { UseMutationOptions, UseQueryOptions, useMutation, useQuery } from "@tanstack/react-query"; +// generated with @7nohe/openapi-react-query-codegen@1.6.0 -import { - AssetService, - BackfillService, - ConfigService, - ConnectionService, - DagParsingService, - DagRunService, - DagService, - DagSourceService, - DagStatsService, - DagWarningService, - DagsService, - DashboardService, - EventLogService, - ExtraLinksService, - GridService, - ImportErrorService, - JobService, - MonitorService, - PluginService, - PoolService, - ProviderService, - StructureService, - TaskInstanceService, - TaskService, - VariableService, - VersionService, - XcomService, -} from "../requests/services.gen"; -import { - BackfillPostBody, - Body_import_variables, - ClearTaskInstancesBody, - ConnectionBody, - ConnectionBulkBody, - CreateAssetEventsBody, - DAGPatchBody, - DAGRunClearBody, - DAGRunPatchBody, - DAGRunsBatchBody, - DagRunState, - DagWarningType, - PatchTaskInstanceBody, - PoolPatchBody, - PoolPostBody, - PoolPostBulkBody, - TaskInstancesBatchBody, - TriggerDAGRunPostBody, - VariableBody, -} from "../requests/types.gen"; +import { UseMutationOptions, UseQueryOptions, useMutation, useQuery } from "@tanstack/react-query"; +import { AssetService, BackfillService, ConfigService, ConnectionService, DagParsingService, DagRunService, DagService, DagSourceService, DagStatsService, DagWarningService, DagsService, DashboardService, EventLogService, ExtraLinksService, GridService, ImportErrorService, JobService, MonitorService, PluginService, PoolService, ProviderService, StructureService, TaskInstanceService, TaskService, VariableService, VersionService, XcomService } from "../requests/services.gen"; +import { BackfillPostBody, Body_import_variables, ClearTaskInstancesBody, ConnectionBody, ConnectionBulkBody, CreateAssetEventsBody, DAGPatchBody, DAGRunClearBody, DAGRunPatchBody, DAGRunsBatchBody, DagRunState, DagWarningType, PatchTaskInstanceBody, PoolPatchBody, PoolPostBody, PoolPostBulkBody, TaskInstancesBatchBody, TriggerDAGRunPostBody, VariableBody } from "../requests/types.gen"; import * as Common from "./common"; - /** - * Next Run Assets - * @param data The data for the request. - * @param data.dagId - * @returns unknown Successful Response - * @throws ApiError - */ -export const useAssetServiceNextRunAssets = < - TData = Common.AssetServiceNextRunAssetsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - }: { - dagId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseAssetServiceNextRunAssetsKeyFn({ dagId }, queryKey), - queryFn: () => AssetService.nextRunAssets({ dagId }) as TData, - ...options, - }); -/** - * Get Assets - * Get assets. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.namePattern - * @param data.uriPattern - * @param data.dagIds - * @param data.orderBy - * @returns AssetCollectionResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetAssets = < - TData = Common.AssetServiceGetAssetsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagIds, - limit, - namePattern, - offset, - orderBy, - uriPattern, - }: { - dagIds?: string[]; - limit?: number; - namePattern?: string; - offset?: number; - orderBy?: string; - uriPattern?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseAssetServiceGetAssetsKeyFn( - { dagIds, limit, namePattern, offset, orderBy, uriPattern }, - queryKey, - ), - queryFn: () => - AssetService.getAssets({ dagIds, limit, namePattern, offset, orderBy, uriPattern }) as TData, - ...options, - }); -/** - * Get Asset Aliases - * Get asset aliases. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.namePattern - * @param data.orderBy - * @returns AssetAliasCollectionResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetAssetAliases = < - TData = Common.AssetServiceGetAssetAliasesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - namePattern, - offset, - orderBy, - }: { - limit?: number; - namePattern?: string; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseAssetServiceGetAssetAliasesKeyFn({ limit, namePattern, offset, orderBy }, queryKey), - queryFn: () => AssetService.getAssetAliases({ limit, namePattern, offset, orderBy }) as TData, - ...options, - }); -/** - * Get Asset Alias - * Get an asset alias. - * @param data The data for the request. - * @param data.assetAliasId - * @returns unknown Successful Response - * @throws ApiError - */ -export const useAssetServiceGetAssetAlias = < - TData = Common.AssetServiceGetAssetAliasDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - assetAliasId, - }: { - assetAliasId: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseAssetServiceGetAssetAliasKeyFn({ assetAliasId }, queryKey), - queryFn: () => AssetService.getAssetAlias({ assetAliasId }) as TData, - ...options, - }); -/** - * Get Asset Events - * Get asset events. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.assetId - * @param data.sourceDagId - * @param data.sourceTaskId - * @param data.sourceRunId - * @param data.sourceMapIndex - * @param data.timestampGte - * @param data.timestampLte - * @returns AssetEventCollectionResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetAssetEvents = < - TData = Common.AssetServiceGetAssetEventsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - assetId, - limit, - offset, - orderBy, - sourceDagId, - sourceMapIndex, - sourceRunId, - sourceTaskId, - timestampGte, - timestampLte, - }: { - assetId?: number; - limit?: number; - offset?: number; - orderBy?: string; - sourceDagId?: string; - sourceMapIndex?: number; - sourceRunId?: string; - sourceTaskId?: string; - timestampGte?: string; - timestampLte?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseAssetServiceGetAssetEventsKeyFn( - { - assetId, - limit, - offset, - orderBy, - sourceDagId, - sourceMapIndex, - sourceRunId, - sourceTaskId, - timestampGte, - timestampLte, - }, - queryKey, - ), - queryFn: () => - AssetService.getAssetEvents({ - assetId, - limit, - offset, - orderBy, - sourceDagId, - sourceMapIndex, - sourceRunId, - sourceTaskId, - timestampGte, - timestampLte, - }) as TData, - ...options, - }); -/** - * Get Asset Queued Events - * Get queued asset events for an asset. - * @param data The data for the request. - * @param data.assetId - * @param data.before - * @returns QueuedEventCollectionResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetAssetQueuedEvents = < - TData = Common.AssetServiceGetAssetQueuedEventsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - assetId, - before, - }: { - assetId: number; - before?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseAssetServiceGetAssetQueuedEventsKeyFn({ assetId, before }, queryKey), - queryFn: () => AssetService.getAssetQueuedEvents({ assetId, before }) as TData, - ...options, - }); -/** - * Get Asset - * Get an asset. - * @param data The data for the request. - * @param data.assetId - * @returns AssetResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetAsset = < - TData = Common.AssetServiceGetAssetDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - assetId, - }: { - assetId: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseAssetServiceGetAssetKeyFn({ assetId }, queryKey), - queryFn: () => AssetService.getAsset({ assetId }) as TData, - ...options, - }); -/** - * Get Dag Asset Queued Events - * Get queued asset events for a DAG. - * @param data The data for the request. - * @param data.dagId - * @param data.before - * @returns QueuedEventCollectionResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetDagAssetQueuedEvents = < - TData = Common.AssetServiceGetDagAssetQueuedEventsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - before, - dagId, - }: { - before?: string; - dagId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseAssetServiceGetDagAssetQueuedEventsKeyFn({ before, dagId }, queryKey), - queryFn: () => AssetService.getDagAssetQueuedEvents({ before, dagId }) as TData, - ...options, - }); -/** - * Get Dag Asset Queued Event - * Get a queued asset event for a DAG. - * @param data The data for the request. - * @param data.dagId - * @param data.assetId - * @param data.before - * @returns QueuedEventResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetDagAssetQueuedEvent = < - TData = Common.AssetServiceGetDagAssetQueuedEventDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - assetId, - before, - dagId, - }: { - assetId: number; - before?: string; - dagId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseAssetServiceGetDagAssetQueuedEventKeyFn({ assetId, before, dagId }, queryKey), - queryFn: () => AssetService.getDagAssetQueuedEvent({ assetId, before, dagId }) as TData, - ...options, - }); -/** - * Get Configs - * Get configs for UI. - * @returns ConfigResponse Successful Response - * @throws ApiError - */ -export const useConfigServiceGetConfigs = < - TData = Common.ConfigServiceGetConfigsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseConfigServiceGetConfigsKeyFn(queryKey), - queryFn: () => ConfigService.getConfigs() as TData, - ...options, - }); -/** - * Get Config - * @param data The data for the request. - * @param data.section - * @param data.accept - * @returns Config Successful Response - * @throws ApiError - */ -export const useConfigServiceGetConfig = < - TData = Common.ConfigServiceGetConfigDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - accept, - section, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - section?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseConfigServiceGetConfigKeyFn({ accept, section }, queryKey), - queryFn: () => ConfigService.getConfig({ accept, section }) as TData, - ...options, - }); -/** - * Get Config Value - * @param data The data for the request. - * @param data.section - * @param data.option - * @param data.accept - * @returns Config Successful Response - * @throws ApiError - */ -export const useConfigServiceGetConfigValue = < - TData = Common.ConfigServiceGetConfigValueDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - accept, - option, - section, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - option: string; - section: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseConfigServiceGetConfigValueKeyFn({ accept, option, section }, queryKey), - queryFn: () => ConfigService.getConfigValue({ accept, option, section }) as TData, - ...options, - }); -/** - * Recent Dag Runs - * Get recent DAG runs. - * @param data The data for the request. - * @param data.dagRunsLimit - * @param data.limit - * @param data.offset - * @param data.tags - * @param data.owners - * @param data.dagIds - * @param data.dagIdPattern - * @param data.dagDisplayNamePattern - * @param data.onlyActive - * @param data.paused - * @param data.lastDagRunState - * @returns DAGWithLatestDagRunsCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagsServiceRecentDagRuns = < - TData = Common.DagsServiceRecentDagRunsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagDisplayNamePattern, - dagIdPattern, - dagIds, - dagRunsLimit, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - tags, - }: { - dagDisplayNamePattern?: string; - dagIdPattern?: string; - dagIds?: string[]; - dagRunsLimit?: number; - lastDagRunState?: DagRunState; - limit?: number; - offset?: number; - onlyActive?: boolean; - owners?: string[]; - paused?: boolean; - tags?: string[]; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseDagsServiceRecentDagRunsKeyFn( - { - dagDisplayNamePattern, - dagIdPattern, - dagIds, - dagRunsLimit, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - tags, - }, - queryKey, - ), - queryFn: () => - DagsService.recentDagRuns({ - dagDisplayNamePattern, - dagIdPattern, - dagIds, - dagRunsLimit, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - tags, - }) as TData, - ...options, - }); -/** - * Historical Metrics - * Return cluster activity historical metrics. - * @param data The data for the request. - * @param data.startDate - * @param data.endDate - * @returns HistoricalMetricDataResponse Successful Response - * @throws ApiError - */ -export const useDashboardServiceHistoricalMetrics = < - TData = Common.DashboardServiceHistoricalMetricsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - endDate, - startDate, - }: { - endDate?: string; - startDate: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseDashboardServiceHistoricalMetricsKeyFn({ endDate, startDate }, queryKey), - queryFn: () => DashboardService.historicalMetrics({ endDate, startDate }) as TData, - ...options, - }); -/** - * Structure Data - * Get Structure Data. - * @param data The data for the request. - * @param data.dagId - * @param data.includeUpstream - * @param data.includeDownstream - * @param data.root - * @param data.externalDependencies - * @returns StructureDataResponse Successful Response - * @throws ApiError - */ -export const useStructureServiceStructureData = < - TData = Common.StructureServiceStructureDataDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - externalDependencies, - includeDownstream, - includeUpstream, - root, - }: { - dagId: string; - externalDependencies?: boolean; - includeDownstream?: boolean; - includeUpstream?: boolean; - root?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseStructureServiceStructureDataKeyFn( - { dagId, externalDependencies, includeDownstream, includeUpstream, root }, - queryKey, - ), - queryFn: () => - StructureService.structureData({ - dagId, - externalDependencies, - includeDownstream, - includeUpstream, - root, - }) as TData, - ...options, - }); -/** - * List Backfills - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.dagId - * @param data.active - * @returns BackfillCollectionResponse Successful Response - * @throws ApiError - */ -export const useBackfillServiceListBackfills = < - TData = Common.BackfillServiceListBackfillsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - active, - dagId, - limit, - offset, - orderBy, - }: { - active?: boolean; - dagId?: string; - limit?: number; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseBackfillServiceListBackfillsKeyFn( - { active, dagId, limit, offset, orderBy }, - queryKey, - ), - queryFn: () => BackfillService.listBackfills({ active, dagId, limit, offset, orderBy }) as TData, - ...options, - }); -/** - * List Backfills - * @param data The data for the request. - * @param data.dagId - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns BackfillCollectionResponse Successful Response - * @throws ApiError - */ -export const useBackfillServiceListBackfills1 = < - TData = Common.BackfillServiceListBackfills1DefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - limit, - offset, - orderBy, - }: { - dagId: string; - limit?: number; - offset?: number; - orderBy?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseBackfillServiceListBackfills1KeyFn({ dagId, limit, offset, orderBy }, queryKey), - queryFn: () => BackfillService.listBackfills1({ dagId, limit, offset, orderBy }) as TData, - ...options, - }); -/** - * Get Backfill - * @param data The data for the request. - * @param data.backfillId - * @returns BackfillResponse Successful Response - * @throws ApiError - */ -export const useBackfillServiceGetBackfill = < - TData = Common.BackfillServiceGetBackfillDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - backfillId, - }: { - backfillId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseBackfillServiceGetBackfillKeyFn({ backfillId }, queryKey), - queryFn: () => BackfillService.getBackfill({ backfillId }) as TData, - ...options, - }); -/** - * Grid Data - * Return grid data. - * @param data The data for the request. - * @param data.dagId - * @param data.includeUpstream - * @param data.includeDownstream - * @param data.logicalDateGte - * @param data.logicalDateLte - * @param data.root - * @param data.offset - * @param data.runType - * @param data.state - * @param data.limit - * @param data.orderBy - * @returns GridResponse Successful Response - * @throws ApiError - */ -export const useGridServiceGridData = < - TData = Common.GridServiceGridDataDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - includeDownstream, - includeUpstream, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - root, - runType, - state, - }: { - dagId: string; - includeDownstream?: boolean; - includeUpstream?: boolean; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - root?: string; - runType?: string[]; - state?: string[]; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseGridServiceGridDataKeyFn( - { - dagId, - includeDownstream, - includeUpstream, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - root, - runType, - state, - }, - queryKey, - ), - queryFn: () => - GridService.gridData({ - dagId, - includeDownstream, - includeUpstream, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - root, - runType, - state, - }) as TData, - ...options, - }); -/** - * Get Connection - * Get a connection entry. - * @param data The data for the request. - * @param data.connectionId - * @returns ConnectionResponse Successful Response - * @throws ApiError - */ -export const useConnectionServiceGetConnection = < - TData = Common.ConnectionServiceGetConnectionDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - connectionId, - }: { - connectionId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseConnectionServiceGetConnectionKeyFn({ connectionId }, queryKey), - queryFn: () => ConnectionService.getConnection({ connectionId }) as TData, - ...options, - }); -/** - * Get Connections - * Get all connection entries. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns ConnectionCollectionResponse Successful Response - * @throws ApiError - */ -export const useConnectionServiceGetConnections = < - TData = Common.ConnectionServiceGetConnectionsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - orderBy, - }: { - limit?: number; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseConnectionServiceGetConnectionsKeyFn({ limit, offset, orderBy }, queryKey), - queryFn: () => ConnectionService.getConnections({ limit, offset, orderBy }) as TData, - ...options, - }); -/** - * Get Dag Run - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @returns DAGRunResponse Successful Response - * @throws ApiError - */ -export const useDagRunServiceGetDagRun = < - TData = Common.DagRunServiceGetDagRunDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - }: { - dagId: string; - dagRunId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseDagRunServiceGetDagRunKeyFn({ dagId, dagRunId }, queryKey), - queryFn: () => DagRunService.getDagRun({ dagId, dagRunId }) as TData, - ...options, - }); -/** - * Get Upstream Asset Events - * If dag run is asset-triggered, return the asset events that triggered it. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @returns AssetEventCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagRunServiceGetUpstreamAssetEvents = < - TData = Common.DagRunServiceGetUpstreamAssetEventsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - }: { - dagId: string; - dagRunId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseDagRunServiceGetUpstreamAssetEventsKeyFn({ dagId, dagRunId }, queryKey), - queryFn: () => DagRunService.getUpstreamAssetEvents({ dagId, dagRunId }) as TData, - ...options, - }); -/** - * Get Dag Runs - * Get all DAG Runs. - * - * This endpoint allows specifying `~` as the dag_id to retrieve Dag Runs for all DAGs. - * @param data The data for the request. - * @param data.dagId - * @param data.limit - * @param data.offset - * @param data.logicalDateGte - * @param data.logicalDateLte - * @param data.startDateGte - * @param data.startDateLte - * @param data.endDateGte - * @param data.endDateLte - * @param data.updatedAtGte - * @param data.updatedAtLte - * @param data.state - * @param data.orderBy - * @returns DAGRunCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagRunServiceGetDagRuns = < - TData = Common.DagRunServiceGetDagRunsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - endDateGte, - endDateLte, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - startDateGte, - startDateLte, - state, - updatedAtGte, - updatedAtLte, - }: { - dagId: string; - endDateGte?: string; - endDateLte?: string; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - startDateGte?: string; - startDateLte?: string; - state?: string[]; - updatedAtGte?: string; - updatedAtLte?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseDagRunServiceGetDagRunsKeyFn( - { - dagId, - endDateGte, - endDateLte, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - startDateGte, - startDateLte, - state, - updatedAtGte, - updatedAtLte, - }, - queryKey, - ), - queryFn: () => - DagRunService.getDagRuns({ - dagId, - endDateGte, - endDateLte, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - startDateGte, - startDateLte, - state, - updatedAtGte, - updatedAtLte, - }) as TData, - ...options, - }); -/** - * Get Dag Source - * Get source code using file token. - * @param data The data for the request. - * @param data.dagId - * @param data.versionNumber - * @param data.accept - * @returns DAGSourceResponse Successful Response - * @throws ApiError - */ -export const useDagSourceServiceGetDagSource = < - TData = Common.DagSourceServiceGetDagSourceDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - accept, - dagId, - versionNumber, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - dagId: string; - versionNumber?: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseDagSourceServiceGetDagSourceKeyFn({ accept, dagId, versionNumber }, queryKey), - queryFn: () => DagSourceService.getDagSource({ accept, dagId, versionNumber }) as TData, - ...options, - }); -/** - * Get Dag Stats - * Get Dag statistics. - * @param data The data for the request. - * @param data.dagIds - * @returns DagStatsCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagStatsServiceGetDagStats = < - TData = Common.DagStatsServiceGetDagStatsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagIds, - }: { - dagIds?: string[]; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseDagStatsServiceGetDagStatsKeyFn({ dagIds }, queryKey), - queryFn: () => DagStatsService.getDagStats({ dagIds }) as TData, - ...options, - }); -/** - * List Dag Warnings - * Get a list of DAG warnings. - * @param data The data for the request. - * @param data.dagId - * @param data.warningType - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns DAGWarningCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagWarningServiceListDagWarnings = < - TData = Common.DagWarningServiceListDagWarningsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - limit, - offset, - orderBy, - warningType, - }: { - dagId?: string; - limit?: number; - offset?: number; - orderBy?: string; - warningType?: DagWarningType; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseDagWarningServiceListDagWarningsKeyFn( - { dagId, limit, offset, orderBy, warningType }, - queryKey, - ), - queryFn: () => DagWarningService.listDagWarnings({ dagId, limit, offset, orderBy, warningType }) as TData, - ...options, - }); -/** - * Get Dags - * Get all DAGs. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.tags - * @param data.owners - * @param data.dagIdPattern - * @param data.dagDisplayNamePattern - * @param data.onlyActive - * @param data.paused - * @param data.lastDagRunState - * @param data.orderBy - * @returns DAGCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagServiceGetDags = < - TData = Common.DagServiceGetDagsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagDisplayNamePattern, - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - orderBy, - owners, - paused, - tags, - }: { - dagDisplayNamePattern?: string; - dagIdPattern?: string; - lastDagRunState?: DagRunState; - limit?: number; - offset?: number; - onlyActive?: boolean; - orderBy?: string; - owners?: string[]; - paused?: boolean; - tags?: string[]; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseDagServiceGetDagsKeyFn( - { - dagDisplayNamePattern, - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - orderBy, - owners, - paused, - tags, - }, - queryKey, - ), - queryFn: () => - DagService.getDags({ - dagDisplayNamePattern, - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - orderBy, - owners, - paused, - tags, - }) as TData, - ...options, - }); -/** - * Get Dag - * Get basic information about a DAG. - * @param data The data for the request. - * @param data.dagId - * @returns DAGResponse Successful Response - * @throws ApiError - */ -export const useDagServiceGetDag = < - TData = Common.DagServiceGetDagDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - }: { - dagId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseDagServiceGetDagKeyFn({ dagId }, queryKey), - queryFn: () => DagService.getDag({ dagId }) as TData, - ...options, - }); -/** - * Get Dag Details - * Get details of DAG. - * @param data The data for the request. - * @param data.dagId - * @returns DAGDetailsResponse Successful Response - * @throws ApiError - */ -export const useDagServiceGetDagDetails = < - TData = Common.DagServiceGetDagDetailsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - }: { - dagId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseDagServiceGetDagDetailsKeyFn({ dagId }, queryKey), - queryFn: () => DagService.getDagDetails({ dagId }) as TData, - ...options, - }); -/** - * Get Dag Tags - * Get all DAG tags. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.tagNamePattern - * @returns DAGTagCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagServiceGetDagTags = < - TData = Common.DagServiceGetDagTagsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - orderBy, - tagNamePattern, - }: { - limit?: number; - offset?: number; - orderBy?: string; - tagNamePattern?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseDagServiceGetDagTagsKeyFn({ limit, offset, orderBy, tagNamePattern }, queryKey), - queryFn: () => DagService.getDagTags({ limit, offset, orderBy, tagNamePattern }) as TData, - ...options, - }); -/** - * Get Event Log - * @param data The data for the request. - * @param data.eventLogId - * @returns EventLogResponse Successful Response - * @throws ApiError - */ -export const useEventLogServiceGetEventLog = < - TData = Common.EventLogServiceGetEventLogDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - eventLogId, - }: { - eventLogId: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseEventLogServiceGetEventLogKeyFn({ eventLogId }, queryKey), - queryFn: () => EventLogService.getEventLog({ eventLogId }) as TData, - ...options, - }); -/** - * Get Event Logs - * Get all Event Logs. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.dagId - * @param data.taskId - * @param data.runId - * @param data.mapIndex - * @param data.tryNumber - * @param data.owner - * @param data.event - * @param data.excludedEvents - * @param data.includedEvents - * @param data.before - * @param data.after - * @returns EventLogCollectionResponse Successful Response - * @throws ApiError - */ -export const useEventLogServiceGetEventLogs = < - TData = Common.EventLogServiceGetEventLogsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - after, - before, - dagId, - event, - excludedEvents, - includedEvents, - limit, - mapIndex, - offset, - orderBy, - owner, - runId, - taskId, - tryNumber, - }: { - after?: string; - before?: string; - dagId?: string; - event?: string; - excludedEvents?: string[]; - includedEvents?: string[]; - limit?: number; - mapIndex?: number; - offset?: number; - orderBy?: string; - owner?: string; - runId?: string; - taskId?: string; - tryNumber?: number; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseEventLogServiceGetEventLogsKeyFn( - { - after, - before, - dagId, - event, - excludedEvents, - includedEvents, - limit, - mapIndex, - offset, - orderBy, - owner, - runId, - taskId, - tryNumber, - }, - queryKey, - ), - queryFn: () => - EventLogService.getEventLogs({ - after, - before, - dagId, - event, - excludedEvents, - includedEvents, - limit, - mapIndex, - offset, - orderBy, - owner, - runId, - taskId, - tryNumber, - }) as TData, - ...options, - }); -/** - * Get Extra Links - * Get extra links for task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @returns ExtraLinksResponse Successful Response - * @throws ApiError - */ -export const useExtraLinksServiceGetExtraLinks = < - TData = Common.ExtraLinksServiceGetExtraLinksDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - taskId, - }: { - dagId: string; - dagRunId: string; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseExtraLinksServiceGetExtraLinksKeyFn({ dagId, dagRunId, taskId }, queryKey), - queryFn: () => ExtraLinksService.getExtraLinks({ dagId, dagRunId, taskId }) as TData, - ...options, - }); -/** - * Get Extra Links - * Get extra links for task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @returns ExtraLinksResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetExtraLinks = < - TData = Common.TaskInstanceServiceGetExtraLinksDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - taskId, - }: { - dagId: string; - dagRunId: string; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskInstanceServiceGetExtraLinksKeyFn({ dagId, dagRunId, taskId }, queryKey), - queryFn: () => TaskInstanceService.getExtraLinks({ dagId, dagRunId, taskId }) as TData, - ...options, - }); -/** - * Get Task Instance - * Get task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @returns TaskInstanceResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstance = < - TData = Common.TaskInstanceServiceGetTaskInstanceDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - taskId, - }: { - dagId: string; - dagRunId: string; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceKeyFn({ dagId, dagRunId, taskId }, queryKey), - queryFn: () => TaskInstanceService.getTaskInstance({ dagId, dagRunId, taskId }) as TData, - ...options, - }); -/** - * Get Mapped Task Instances - * Get list of mapped task instances. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.logicalDateGte - * @param data.logicalDateLte - * @param data.startDateGte - * @param data.startDateLte - * @param data.endDateGte - * @param data.endDateLte - * @param data.updatedAtGte - * @param data.updatedAtLte - * @param data.durationGte - * @param data.durationLte - * @param data.state - * @param data.pool - * @param data.queue - * @param data.executor - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns TaskInstanceCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetMappedTaskInstances = < - TData = Common.TaskInstanceServiceGetMappedTaskInstancesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskId, - updatedAtGte, - updatedAtLte, - }: { - dagId: string; - dagRunId: string; - durationGte?: number; - durationLte?: number; - endDateGte?: string; - endDateLte?: string; - executor?: string[]; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - pool?: string[]; - queue?: string[]; - startDateGte?: string; - startDateLte?: string; - state?: string[]; - taskId: string; - updatedAtGte?: string; - updatedAtLte?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstancesKeyFn( - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskId, - updatedAtGte, - updatedAtLte, - }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getMappedTaskInstances({ - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskId, - updatedAtGte, - updatedAtLte, - }) as TData, - ...options, - }); -/** - * Get Task Instance Dependencies - * Get dependencies blocking task from getting scheduled. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskDependencyCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstanceDependencies = < - TData = Common.TaskInstanceServiceGetTaskInstanceDependenciesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceDependenciesKeyFn( - { dagId, dagRunId, mapIndex, taskId }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getTaskInstanceDependencies({ dagId, dagRunId, mapIndex, taskId }) as TData, - ...options, - }); -/** - * Get Task Instance Dependencies - * Get dependencies blocking task from getting scheduled. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskDependencyCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstanceDependencies1 = < - TData = Common.TaskInstanceServiceGetTaskInstanceDependencies1DefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex?: number; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceDependencies1KeyFn( - { dagId, dagRunId, mapIndex, taskId }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getTaskInstanceDependencies1({ dagId, dagRunId, mapIndex, taskId }) as TData, - ...options, - }); -/** - * Get Task Instance Tries - * Get list of task instances history. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskInstanceHistoryCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstanceTries = < - TData = Common.TaskInstanceServiceGetTaskInstanceTriesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex?: number; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceTriesKeyFn( - { dagId, dagRunId, mapIndex, taskId }, - queryKey, - ), - queryFn: () => TaskInstanceService.getTaskInstanceTries({ dagId, dagRunId, mapIndex, taskId }) as TData, - ...options, - }); -/** - * Get Mapped Task Instance Tries - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskInstanceHistoryCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetMappedTaskInstanceTries = < - TData = Common.TaskInstanceServiceGetMappedTaskInstanceTriesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceTriesKeyFn( - { dagId, dagRunId, mapIndex, taskId }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getMappedTaskInstanceTries({ dagId, dagRunId, mapIndex, taskId }) as TData, - ...options, - }); -/** - * Get Mapped Task Instance - * Get task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskInstanceResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetMappedTaskInstance = < - TData = Common.TaskInstanceServiceGetMappedTaskInstanceDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceKeyFn( - { dagId, dagRunId, mapIndex, taskId }, - queryKey, - ), - queryFn: () => TaskInstanceService.getMappedTaskInstance({ dagId, dagRunId, mapIndex, taskId }) as TData, - ...options, - }); -/** - * Get Task Instances - * Get list of task instances. - * - * This endpoint allows specifying `~` as the dag_id, dag_run_id to retrieve Task Instances for all DAGs - * and DAG runs. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.logicalDateGte - * @param data.logicalDateLte - * @param data.startDateGte - * @param data.startDateLte - * @param data.endDateGte - * @param data.endDateLte - * @param data.updatedAtGte - * @param data.updatedAtLte - * @param data.durationGte - * @param data.durationLte - * @param data.taskDisplayNamePattern - * @param data.state - * @param data.pool - * @param data.queue - * @param data.executor - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns TaskInstanceCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstances = < - TData = Common.TaskInstanceServiceGetTaskInstancesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskDisplayNamePattern, - taskId, - updatedAtGte, - updatedAtLte, - }: { - dagId: string; - dagRunId: string; - durationGte?: number; - durationLte?: number; - endDateGte?: string; - endDateLte?: string; - executor?: string[]; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - pool?: string[]; - queue?: string[]; - startDateGte?: string; - startDateLte?: string; - state?: string[]; - taskDisplayNamePattern?: string; - taskId?: string; - updatedAtGte?: string; - updatedAtLte?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstancesKeyFn( - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskDisplayNamePattern, - taskId, - updatedAtGte, - updatedAtLte, - }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getTaskInstances({ - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskDisplayNamePattern, - taskId, - updatedAtGte, - updatedAtLte, - }) as TData, - ...options, - }); -/** - * Get Task Instance Try Details - * Get task instance details by try number. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.taskTryNumber - * @param data.mapIndex - * @returns TaskInstanceHistoryResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstanceTryDetails = < - TData = Common.TaskInstanceServiceGetTaskInstanceTryDetailsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }: { - dagId: string; - dagRunId: string; - mapIndex?: number; - taskId: string; - taskTryNumber: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceTryDetailsKeyFn( - { dagId, dagRunId, mapIndex, taskId, taskTryNumber }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getTaskInstanceTryDetails({ - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }) as TData, - ...options, - }); -/** - * Get Mapped Task Instance Try Details - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.taskTryNumber - * @param data.mapIndex - * @returns TaskInstanceHistoryResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetMappedTaskInstanceTryDetails = < - TData = Common.TaskInstanceServiceGetMappedTaskInstanceTryDetailsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - taskTryNumber: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceTryDetailsKeyFn( - { dagId, dagRunId, mapIndex, taskId, taskTryNumber }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getMappedTaskInstanceTryDetails({ - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }) as TData, - ...options, - }); -/** - * Get Log - * Get logs for a specific task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.tryNumber - * @param data.fullContent - * @param data.mapIndex - * @param data.token - * @param data.accept - * @returns TaskInstancesLogResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetLog = < - TData = Common.TaskInstanceServiceGetLogDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - accept, - dagId, - dagRunId, - fullContent, - mapIndex, - taskId, - token, - tryNumber, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - dagId: string; - dagRunId: string; - fullContent?: boolean; - mapIndex?: number; - taskId: string; - token?: string; - tryNumber: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskInstanceServiceGetLogKeyFn( - { accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getLog({ - accept, - dagId, - dagRunId, - fullContent, - mapIndex, - taskId, - token, - tryNumber, - }) as TData, - ...options, - }); -/** - * Get Import Error - * Get an import error. - * @param data The data for the request. - * @param data.importErrorId - * @returns ImportErrorResponse Successful Response - * @throws ApiError - */ -export const useImportErrorServiceGetImportError = < - TData = Common.ImportErrorServiceGetImportErrorDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - importErrorId, - }: { - importErrorId: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseImportErrorServiceGetImportErrorKeyFn({ importErrorId }, queryKey), - queryFn: () => ImportErrorService.getImportError({ importErrorId }) as TData, - ...options, - }); -/** - * Get Import Errors - * Get all import errors. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns ImportErrorCollectionResponse Successful Response - * @throws ApiError - */ -export const useImportErrorServiceGetImportErrors = < - TData = Common.ImportErrorServiceGetImportErrorsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - orderBy, - }: { - limit?: number; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseImportErrorServiceGetImportErrorsKeyFn({ limit, offset, orderBy }, queryKey), - queryFn: () => ImportErrorService.getImportErrors({ limit, offset, orderBy }) as TData, - ...options, - }); -/** - * Get Jobs - * Get all jobs. - * @param data The data for the request. - * @param data.isAlive - * @param data.startDateGte - * @param data.startDateLte - * @param data.endDateGte - * @param data.endDateLte - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.jobState - * @param data.jobType - * @param data.hostname - * @param data.executorClass - * @returns JobCollectionResponse Successful Response - * @throws ApiError - */ -export const useJobServiceGetJobs = < - TData = Common.JobServiceGetJobsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - endDateGte, - endDateLte, - executorClass, - hostname, - isAlive, - jobState, - jobType, - limit, - offset, - orderBy, - startDateGte, - startDateLte, - }: { - endDateGte?: string; - endDateLte?: string; - executorClass?: string; - hostname?: string; - isAlive?: boolean; - jobState?: string; - jobType?: string; - limit?: number; - offset?: number; - orderBy?: string; - startDateGte?: string; - startDateLte?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseJobServiceGetJobsKeyFn( - { - endDateGte, - endDateLte, - executorClass, - hostname, - isAlive, - jobState, - jobType, - limit, - offset, - orderBy, - startDateGte, - startDateLte, - }, - queryKey, - ), - queryFn: () => - JobService.getJobs({ - endDateGte, - endDateLte, - executorClass, - hostname, - isAlive, - jobState, - jobType, - limit, - offset, - orderBy, - startDateGte, - startDateLte, - }) as TData, - ...options, - }); -/** - * Get Plugins - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @returns PluginCollectionResponse Successful Response - * @throws ApiError - */ -export const usePluginServiceGetPlugins = < - TData = Common.PluginServiceGetPluginsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - }: { - limit?: number; - offset?: number; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UsePluginServiceGetPluginsKeyFn({ limit, offset }, queryKey), - queryFn: () => PluginService.getPlugins({ limit, offset }) as TData, - ...options, - }); -/** - * Get Pool - * Get a pool. - * @param data The data for the request. - * @param data.poolName - * @returns PoolResponse Successful Response - * @throws ApiError - */ -export const usePoolServiceGetPool = < - TData = Common.PoolServiceGetPoolDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - poolName, - }: { - poolName: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UsePoolServiceGetPoolKeyFn({ poolName }, queryKey), - queryFn: () => PoolService.getPool({ poolName }) as TData, - ...options, - }); -/** - * Get Pools - * Get all pools entries. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns PoolCollectionResponse Successful Response - * @throws ApiError - */ -export const usePoolServiceGetPools = < - TData = Common.PoolServiceGetPoolsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - orderBy, - }: { - limit?: number; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UsePoolServiceGetPoolsKeyFn({ limit, offset, orderBy }, queryKey), - queryFn: () => PoolService.getPools({ limit, offset, orderBy }) as TData, - ...options, - }); -/** - * Get Providers - * Get providers. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @returns ProviderCollectionResponse Successful Response - * @throws ApiError - */ -export const useProviderServiceGetProviders = < - TData = Common.ProviderServiceGetProvidersDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - }: { - limit?: number; - offset?: number; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseProviderServiceGetProvidersKeyFn({ limit, offset }, queryKey), - queryFn: () => ProviderService.getProviders({ limit, offset }) as TData, - ...options, - }); -/** - * Get Xcom Entry - * Get an XCom entry. - * @param data The data for the request. - * @param data.dagId - * @param data.taskId - * @param data.dagRunId - * @param data.xcomKey - * @param data.mapIndex - * @param data.deserialize - * @param data.stringify - * @returns unknown Successful Response - * @throws ApiError - */ -export const useXcomServiceGetXcomEntry = < - TData = Common.XcomServiceGetXcomEntryDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - deserialize, - mapIndex, - stringify, - taskId, - xcomKey, - }: { - dagId: string; - dagRunId: string; - deserialize?: boolean; - mapIndex?: number; - stringify?: boolean; - taskId: string; - xcomKey: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseXcomServiceGetXcomEntryKeyFn( - { dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }, - queryKey, - ), - queryFn: () => - XcomService.getXcomEntry({ - dagId, - dagRunId, - deserialize, - mapIndex, - stringify, - taskId, - xcomKey, - }) as TData, - ...options, - }); -/** - * Get Xcom Entries - * Get all XCom entries. - * - * This endpoint allows specifying `~` as the dag_id, dag_run_id, task_id to retrieve XCom entries for all DAGs. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.xcomKey - * @param data.mapIndex - * @param data.limit - * @param data.offset - * @returns XComCollection Successful Response - * @throws ApiError - */ -export const useXcomServiceGetXcomEntries = < - TData = Common.XcomServiceGetXcomEntriesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - limit, - mapIndex, - offset, - taskId, - xcomKey, - }: { - dagId: string; - dagRunId: string; - limit?: number; - mapIndex?: number; - offset?: number; - taskId: string; - xcomKey?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseXcomServiceGetXcomEntriesKeyFn( - { dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }, - queryKey, - ), - queryFn: () => - XcomService.getXcomEntries({ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }) as TData, - ...options, - }); -/** - * Get Tasks - * Get tasks for DAG. - * @param data The data for the request. - * @param data.dagId - * @param data.orderBy - * @returns TaskCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskServiceGetTasks = < - TData = Common.TaskServiceGetTasksDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - orderBy, - }: { - dagId: string; - orderBy?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskServiceGetTasksKeyFn({ dagId, orderBy }, queryKey), - queryFn: () => TaskService.getTasks({ dagId, orderBy }) as TData, - ...options, - }); -/** - * Get Task - * Get simplified representation of a task. - * @param data The data for the request. - * @param data.dagId - * @param data.taskId - * @returns TaskResponse Successful Response - * @throws ApiError - */ -export const useTaskServiceGetTask = < - TData = Common.TaskServiceGetTaskDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - taskId, - }: { - dagId: string; - taskId: unknown; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseTaskServiceGetTaskKeyFn({ dagId, taskId }, queryKey), - queryFn: () => TaskService.getTask({ dagId, taskId }) as TData, - ...options, - }); -/** - * Get Variable - * Get a variable entry. - * @param data The data for the request. - * @param data.variableKey - * @returns VariableResponse Successful Response - * @throws ApiError - */ -export const useVariableServiceGetVariable = < - TData = Common.VariableServiceGetVariableDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - variableKey, - }: { - variableKey: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseVariableServiceGetVariableKeyFn({ variableKey }, queryKey), - queryFn: () => VariableService.getVariable({ variableKey }) as TData, - ...options, - }); -/** - * Get Variables - * Get all Variables entries. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.variableKeyPattern - * @returns VariableCollectionResponse Successful Response - * @throws ApiError - */ -export const useVariableServiceGetVariables = < - TData = Common.VariableServiceGetVariablesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - orderBy, - variableKeyPattern, - }: { - limit?: number; - offset?: number; - orderBy?: string; - variableKeyPattern?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseVariableServiceGetVariablesKeyFn( - { limit, offset, orderBy, variableKeyPattern }, - queryKey, - ), - queryFn: () => VariableService.getVariables({ limit, offset, orderBy, variableKeyPattern }) as TData, - ...options, - }); -/** - * Get Health - * @returns HealthInfoResponse Successful Response - * @throws ApiError - */ -export const useMonitorServiceGetHealth = < - TData = Common.MonitorServiceGetHealthDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseMonitorServiceGetHealthKeyFn(queryKey), - queryFn: () => MonitorService.getHealth() as TData, - ...options, - }); -/** - * Get Version - * Get version information. - * @returns VersionInfo Successful Response - * @throws ApiError - */ -export const useVersionServiceGetVersion = < - TData = Common.VersionServiceGetVersionDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useQuery({ - queryKey: Common.UseVersionServiceGetVersionKeyFn(queryKey), - queryFn: () => VersionService.getVersion() as TData, - ...options, - }); -/** - * Create Asset Event - * Create asset events. - * @param data The data for the request. - * @param data.requestBody - * @returns AssetEventResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceCreateAssetEvent = < - TData = Common.AssetServiceCreateAssetEventMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - requestBody: CreateAssetEventsBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - requestBody: CreateAssetEventsBody; - }, - TContext - >({ - mutationFn: ({ requestBody }) => - AssetService.createAssetEvent({ requestBody }) as unknown as Promise, - ...options, - }); -/** - * Create Backfill - * @param data The data for the request. - * @param data.requestBody - * @returns BackfillResponse Successful Response - * @throws ApiError - */ -export const useBackfillServiceCreateBackfill = < - TData = Common.BackfillServiceCreateBackfillMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - requestBody: BackfillPostBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - requestBody: BackfillPostBody; - }, - TContext - >({ - mutationFn: ({ requestBody }) => - BackfillService.createBackfill({ requestBody }) as unknown as Promise, - ...options, - }); -/** - * Post Connection - * Create connection entry. - * @param data The data for the request. - * @param data.requestBody - * @returns ConnectionResponse Successful Response - * @throws ApiError - */ -export const useConnectionServicePostConnection = < - TData = Common.ConnectionServicePostConnectionMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - requestBody: ConnectionBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - requestBody: ConnectionBody; - }, - TContext - >({ - mutationFn: ({ requestBody }) => - ConnectionService.postConnection({ requestBody }) as unknown as Promise, - ...options, - }); -/** - * Test Connection - * Test an API connection. - * - * This method first creates an in-memory transient conn_id & exports that to an env var, - * as some hook classes tries to find out the `conn` from their __init__ method & errors out if not found. - * It also deletes the conn id env variable after the test. - * @param data The data for the request. - * @param data.requestBody - * @returns ConnectionTestResponse Successful Response - * @throws ApiError - */ -export const useConnectionServiceTestConnection = < - TData = Common.ConnectionServiceTestConnectionMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - requestBody: ConnectionBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - requestBody: ConnectionBody; - }, - TContext - >({ - mutationFn: ({ requestBody }) => - ConnectionService.testConnection({ requestBody }) as unknown as Promise, - ...options, - }); -/** - * Clear Dag Run - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.requestBody - * @returns unknown Successful Response - * @throws ApiError - */ -export const useDagRunServiceClearDagRun = < - TData = Common.DagRunServiceClearDagRunMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - dagId: string; - dagRunId: string; - requestBody: DAGRunClearBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - dagId: string; - dagRunId: string; - requestBody: DAGRunClearBody; - }, - TContext - >({ - mutationFn: ({ dagId, dagRunId, requestBody }) => - DagRunService.clearDagRun({ dagId, dagRunId, requestBody }) as unknown as Promise, - ...options, - }); -/** - * Trigger Dag Run - * Trigger a DAG. - * @param data The data for the request. - * @param data.dagId - * @param data.requestBody - * @returns DAGRunResponse Successful Response - * @throws ApiError - */ -export const useDagRunServiceTriggerDagRun = < - TData = Common.DagRunServiceTriggerDagRunMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - dagId: unknown; - requestBody: TriggerDAGRunPostBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - dagId: unknown; - requestBody: TriggerDAGRunPostBody; - }, - TContext - >({ - mutationFn: ({ dagId, requestBody }) => - DagRunService.triggerDagRun({ dagId, requestBody }) as unknown as Promise, - ...options, - }); -/** - * Get List Dag Runs Batch - * Get a list of DAG Runs. - * @param data The data for the request. - * @param data.dagId - * @param data.requestBody - * @returns DAGRunCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagRunServiceGetListDagRunsBatch = < - TData = Common.DagRunServiceGetListDagRunsBatchMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - dagId: "~"; - requestBody: DAGRunsBatchBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - dagId: "~"; - requestBody: DAGRunsBatchBody; - }, - TContext - >({ - mutationFn: ({ dagId, requestBody }) => - DagRunService.getListDagRunsBatch({ dagId, requestBody }) as unknown as Promise, - ...options, - }); -/** - * Get Task Instances Batch - * Get list of task instances. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.requestBody - * @returns TaskInstanceCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstancesBatch = < - TData = Common.TaskInstanceServiceGetTaskInstancesBatchMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - dagId: "~"; - dagRunId: "~"; - requestBody: TaskInstancesBatchBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - dagId: "~"; - dagRunId: "~"; - requestBody: TaskInstancesBatchBody; - }, - TContext - >({ - mutationFn: ({ dagId, dagRunId, requestBody }) => - TaskInstanceService.getTaskInstancesBatch({ - dagId, - dagRunId, - requestBody, - }) as unknown as Promise, - ...options, - }); -/** - * Post Clear Task Instances - * Clear task instances. - * @param data The data for the request. - * @param data.dagId - * @param data.requestBody - * @returns TaskInstanceReferenceCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServicePostClearTaskInstances = < - TData = Common.TaskInstanceServicePostClearTaskInstancesMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - dagId: string; - requestBody: ClearTaskInstancesBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - dagId: string; - requestBody: ClearTaskInstancesBody; - }, - TContext - >({ - mutationFn: ({ dagId, requestBody }) => - TaskInstanceService.postClearTaskInstances({ dagId, requestBody }) as unknown as Promise, - ...options, - }); -/** - * Post Pool - * Create a Pool. - * @param data The data for the request. - * @param data.requestBody - * @returns PoolResponse Successful Response - * @throws ApiError - */ -export const usePoolServicePostPool = < - TData = Common.PoolServicePostPoolMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - requestBody: PoolPostBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - requestBody: PoolPostBody; - }, - TContext - >({ - mutationFn: ({ requestBody }) => PoolService.postPool({ requestBody }) as unknown as Promise, - ...options, - }); -/** - * Post Variable - * Create a variable. - * @param data The data for the request. - * @param data.requestBody - * @returns VariableResponse Successful Response - * @throws ApiError - */ -export const useVariableServicePostVariable = < - TData = Common.VariableServicePostVariableMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - requestBody: VariableBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - requestBody: VariableBody; - }, - TContext - >({ - mutationFn: ({ requestBody }) => - VariableService.postVariable({ requestBody }) as unknown as Promise, - ...options, - }); -/** - * Import Variables - * Import variables from a JSON file. - * @param data The data for the request. - * @param data.formData - * @param data.actionIfExists - * @returns VariablesImportResponse Successful Response - * @throws ApiError - */ -export const useVariableServiceImportVariables = < - TData = Common.VariableServiceImportVariablesMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - actionIfExists?: "overwrite" | "fail" | "skip"; - formData: Body_import_variables; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - actionIfExists?: "overwrite" | "fail" | "skip"; - formData: Body_import_variables; - }, - TContext - >({ - mutationFn: ({ actionIfExists, formData }) => - VariableService.importVariables({ actionIfExists, formData }) as unknown as Promise, - ...options, - }); -/** - * Pause Backfill - * @param data The data for the request. - * @param data.backfillId - * @returns BackfillResponse Successful Response - * @throws ApiError - */ -export const useBackfillServicePauseBackfill = < - TData = Common.BackfillServicePauseBackfillMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - backfillId: unknown; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - backfillId: unknown; - }, - TContext - >({ - mutationFn: ({ backfillId }) => - BackfillService.pauseBackfill({ backfillId }) as unknown as Promise, - ...options, - }); -/** - * Unpause Backfill - * @param data The data for the request. - * @param data.backfillId - * @returns BackfillResponse Successful Response - * @throws ApiError - */ -export const useBackfillServiceUnpauseBackfill = < - TData = Common.BackfillServiceUnpauseBackfillMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - backfillId: unknown; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - backfillId: unknown; - }, - TContext - >({ - mutationFn: ({ backfillId }) => - BackfillService.unpauseBackfill({ backfillId }) as unknown as Promise, - ...options, - }); -/** - * Cancel Backfill - * @param data The data for the request. - * @param data.backfillId - * @returns BackfillResponse Successful Response - * @throws ApiError - */ -export const useBackfillServiceCancelBackfill = < - TData = Common.BackfillServiceCancelBackfillMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - backfillId: unknown; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - backfillId: unknown; - }, - TContext - >({ - mutationFn: ({ backfillId }) => - BackfillService.cancelBackfill({ backfillId }) as unknown as Promise, - ...options, - }); -/** - * Put Connections - * Create connection entry. - * @param data The data for the request. - * @param data.requestBody - * @returns ConnectionCollectionResponse Created with overwrite - * @returns ConnectionCollectionResponse Created - * @throws ApiError - */ -export const useConnectionServicePutConnections = < - TData = Common.ConnectionServicePutConnectionsMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - requestBody: ConnectionBulkBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - requestBody: ConnectionBulkBody; - }, - TContext - >({ - mutationFn: ({ requestBody }) => - ConnectionService.putConnections({ requestBody }) as unknown as Promise, - ...options, - }); -/** - * Put Pools - * Create multiple pools. - * @param data The data for the request. - * @param data.requestBody - * @returns PoolCollectionResponse Created with overwriting - * @returns PoolCollectionResponse Created - * @throws ApiError - */ -export const usePoolServicePutPools = < - TData = Common.PoolServicePutPoolsMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - requestBody: PoolPostBulkBody; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - requestBody: PoolPostBulkBody; - }, - TContext - >({ - mutationFn: ({ requestBody }) => PoolService.putPools({ requestBody }) as unknown as Promise, - ...options, - }); -/** - * Reparse Dag File - * Request re-parsing a DAG file. - * @param data The data for the request. - * @param data.fileToken - * @returns null Successful Response - * @throws ApiError - */ -export const useDagParsingServiceReparseDagFile = < - TData = Common.DagParsingServiceReparseDagFileMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - fileToken: string; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - fileToken: string; - }, - TContext - >({ - mutationFn: ({ fileToken }) => - DagParsingService.reparseDagFile({ fileToken }) as unknown as Promise, - ...options, - }); -/** - * Patch Connection - * Update a connection entry. - * @param data The data for the request. - * @param data.connectionId - * @param data.requestBody - * @param data.updateMask - * @returns ConnectionResponse Successful Response - * @throws ApiError - */ -export const useConnectionServicePatchConnection = < - TData = Common.ConnectionServicePatchConnectionMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - connectionId: string; - requestBody: ConnectionBody; - updateMask?: string[]; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - connectionId: string; - requestBody: ConnectionBody; - updateMask?: string[]; - }, - TContext - >({ - mutationFn: ({ connectionId, requestBody, updateMask }) => - ConnectionService.patchConnection({ - connectionId, - requestBody, - updateMask, - }) as unknown as Promise, - ...options, - }); -/** - * Patch Dag Run - * Modify a DAG Run. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.requestBody - * @param data.updateMask - * @returns DAGRunResponse Successful Response - * @throws ApiError - */ -export const useDagRunServicePatchDagRun = < - TData = Common.DagRunServicePatchDagRunMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - dagId: string; - dagRunId: string; - requestBody: DAGRunPatchBody; - updateMask?: string[]; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - dagId: string; - dagRunId: string; - requestBody: DAGRunPatchBody; - updateMask?: string[]; - }, - TContext - >({ - mutationFn: ({ dagId, dagRunId, requestBody, updateMask }) => - DagRunService.patchDagRun({ dagId, dagRunId, requestBody, updateMask }) as unknown as Promise, - ...options, - }); -/** - * Patch Dags - * Patch multiple DAGs. - * @param data The data for the request. - * @param data.requestBody - * @param data.updateMask - * @param data.limit - * @param data.offset - * @param data.tags - * @param data.owners - * @param data.dagIdPattern - * @param data.onlyActive - * @param data.paused - * @param data.lastDagRunState - * @returns DAGCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagServicePatchDags = < - TData = Common.DagServicePatchDagsMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - dagIdPattern?: string; - lastDagRunState?: DagRunState; - limit?: number; - offset?: number; - onlyActive?: boolean; - owners?: string[]; - paused?: boolean; - requestBody: DAGPatchBody; - tags?: string[]; - updateMask?: string[]; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - dagIdPattern?: string; - lastDagRunState?: DagRunState; - limit?: number; - offset?: number; - onlyActive?: boolean; - owners?: string[]; - paused?: boolean; - requestBody: DAGPatchBody; - tags?: string[]; - updateMask?: string[]; - }, - TContext - >({ - mutationFn: ({ - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - requestBody, - tags, - updateMask, - }) => - DagService.patchDags({ - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - requestBody, - tags, - updateMask, - }) as unknown as Promise, - ...options, - }); -/** - * Patch Dag - * Patch the specific DAG. - * @param data The data for the request. - * @param data.dagId - * @param data.requestBody - * @param data.updateMask - * @returns DAGResponse Successful Response - * @throws ApiError - */ -export const useDagServicePatchDag = < - TData = Common.DagServicePatchDagMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - dagId: string; - requestBody: DAGPatchBody; - updateMask?: string[]; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - dagId: string; - requestBody: DAGPatchBody; - updateMask?: string[]; - }, - TContext - >({ - mutationFn: ({ dagId, requestBody, updateMask }) => - DagService.patchDag({ dagId, requestBody, updateMask }) as unknown as Promise, - ...options, - }); -/** - * Patch Task Instance - * Update the state of a task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.requestBody - * @param data.mapIndex - * @param data.updateMask - * @returns TaskInstanceResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServicePatchTaskInstance = < - TData = Common.TaskInstanceServicePatchTaskInstanceMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - dagId: string; - dagRunId: string; - mapIndex?: number; - requestBody: PatchTaskInstanceBody; - taskId: string; - updateMask?: string[]; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - dagId: string; - dagRunId: string; - mapIndex?: number; - requestBody: PatchTaskInstanceBody; - taskId: string; - updateMask?: string[]; - }, - TContext - >({ - mutationFn: ({ dagId, dagRunId, mapIndex, requestBody, taskId, updateMask }) => - TaskInstanceService.patchTaskInstance({ - dagId, - dagRunId, - mapIndex, - requestBody, - taskId, - updateMask, - }) as unknown as Promise, - ...options, - }); -/** - * Patch Task Instance - * Update the state of a task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @param data.requestBody - * @param data.updateMask - * @returns TaskInstanceResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServicePatchTaskInstance1 = < - TData = Common.TaskInstanceServicePatchTaskInstance1MutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - dagId: string; - dagRunId: string; - mapIndex: number; - requestBody: PatchTaskInstanceBody; - taskId: string; - updateMask?: string[]; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - dagId: string; - dagRunId: string; - mapIndex: number; - requestBody: PatchTaskInstanceBody; - taskId: string; - updateMask?: string[]; - }, - TContext - >({ - mutationFn: ({ dagId, dagRunId, mapIndex, requestBody, taskId, updateMask }) => - TaskInstanceService.patchTaskInstance1({ - dagId, - dagRunId, - mapIndex, - requestBody, - taskId, - updateMask, - }) as unknown as Promise, - ...options, - }); -/** - * Patch Pool - * Update a Pool. - * @param data The data for the request. - * @param data.poolName - * @param data.requestBody - * @param data.updateMask - * @returns PoolResponse Successful Response - * @throws ApiError - */ -export const usePoolServicePatchPool = < - TData = Common.PoolServicePatchPoolMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - poolName: string; - requestBody: PoolPatchBody; - updateMask?: string[]; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - poolName: string; - requestBody: PoolPatchBody; - updateMask?: string[]; - }, - TContext - >({ - mutationFn: ({ poolName, requestBody, updateMask }) => - PoolService.patchPool({ poolName, requestBody, updateMask }) as unknown as Promise, - ...options, - }); -/** - * Patch Variable - * Update a variable by key. - * @param data The data for the request. - * @param data.variableKey - * @param data.requestBody - * @param data.updateMask - * @returns VariableResponse Successful Response - * @throws ApiError - */ -export const useVariableServicePatchVariable = < - TData = Common.VariableServicePatchVariableMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - requestBody: VariableBody; - updateMask?: string[]; - variableKey: string; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - requestBody: VariableBody; - updateMask?: string[]; - variableKey: string; - }, - TContext - >({ - mutationFn: ({ requestBody, updateMask, variableKey }) => - VariableService.patchVariable({ requestBody, updateMask, variableKey }) as unknown as Promise, - ...options, - }); -/** - * Delete Asset Queued Events - * Delete queued asset events for an asset. - * @param data The data for the request. - * @param data.assetId - * @param data.before - * @returns void Successful Response - * @throws ApiError - */ -export const useAssetServiceDeleteAssetQueuedEvents = < - TData = Common.AssetServiceDeleteAssetQueuedEventsMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - assetId: number; - before?: string; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - assetId: number; - before?: string; - }, - TContext - >({ - mutationFn: ({ assetId, before }) => - AssetService.deleteAssetQueuedEvents({ assetId, before }) as unknown as Promise, - ...options, - }); -/** - * Delete Dag Asset Queued Events - * @param data The data for the request. - * @param data.dagId - * @param data.before - * @returns void Successful Response - * @throws ApiError - */ -export const useAssetServiceDeleteDagAssetQueuedEvents = < - TData = Common.AssetServiceDeleteDagAssetQueuedEventsMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - before?: string; - dagId: string; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - before?: string; - dagId: string; - }, - TContext - >({ - mutationFn: ({ before, dagId }) => - AssetService.deleteDagAssetQueuedEvents({ before, dagId }) as unknown as Promise, - ...options, - }); -/** - * Delete Dag Asset Queued Event - * Delete a queued asset event for a DAG. - * @param data The data for the request. - * @param data.dagId - * @param data.assetId - * @param data.before - * @returns void Successful Response - * @throws ApiError - */ -export const useAssetServiceDeleteDagAssetQueuedEvent = < - TData = Common.AssetServiceDeleteDagAssetQueuedEventMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - assetId: number; - before?: string; - dagId: string; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - assetId: number; - before?: string; - dagId: string; - }, - TContext - >({ - mutationFn: ({ assetId, before, dagId }) => - AssetService.deleteDagAssetQueuedEvent({ assetId, before, dagId }) as unknown as Promise, - ...options, - }); -/** - * Delete Connection - * Delete a connection entry. - * @param data The data for the request. - * @param data.connectionId - * @returns void Successful Response - * @throws ApiError - */ -export const useConnectionServiceDeleteConnection = < - TData = Common.ConnectionServiceDeleteConnectionMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - connectionId: string; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - connectionId: string; - }, - TContext - >({ - mutationFn: ({ connectionId }) => - ConnectionService.deleteConnection({ connectionId }) as unknown as Promise, - ...options, - }); -/** - * Delete Dag Run - * Delete a DAG Run entry. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @returns void Successful Response - * @throws ApiError - */ -export const useDagRunServiceDeleteDagRun = < - TData = Common.DagRunServiceDeleteDagRunMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - dagId: string; - dagRunId: string; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - dagId: string; - dagRunId: string; - }, - TContext - >({ - mutationFn: ({ dagId, dagRunId }) => - DagRunService.deleteDagRun({ dagId, dagRunId }) as unknown as Promise, - ...options, - }); -/** - * Delete Dag - * Delete the specific DAG. - * @param data The data for the request. - * @param data.dagId - * @returns unknown Successful Response - * @throws ApiError - */ -export const useDagServiceDeleteDag = < - TData = Common.DagServiceDeleteDagMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - dagId: string; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - dagId: string; - }, - TContext - >({ mutationFn: ({ dagId }) => DagService.deleteDag({ dagId }) as unknown as Promise, ...options }); -/** - * Delete Pool - * Delete a pool entry. - * @param data The data for the request. - * @param data.poolName - * @returns void Successful Response - * @throws ApiError - */ -export const usePoolServiceDeletePool = < - TData = Common.PoolServiceDeletePoolMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - poolName: string; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - poolName: string; - }, - TContext - >({ - mutationFn: ({ poolName }) => PoolService.deletePool({ poolName }) as unknown as Promise, - ...options, - }); -/** - * Delete Variable - * Delete a variable entry. - * @param data The data for the request. - * @param data.variableKey - * @returns void Successful Response - * @throws ApiError - */ -export const useVariableServiceDeleteVariable = < - TData = Common.VariableServiceDeleteVariableMutationResult, - TError = unknown, - TContext = unknown, ->( - options?: Omit< - UseMutationOptions< - TData, - TError, - { - variableKey: string; - }, - TContext - >, - "mutationFn" - >, -) => - useMutation< - TData, - TError, - { - variableKey: string; - }, - TContext - >({ - mutationFn: ({ variableKey }) => - VariableService.deleteVariable({ variableKey }) as unknown as Promise, - ...options, - }); +* Next Run Assets +* @param data The data for the request. +* @param data.dagId +* @returns unknown Successful Response +* @throws ApiError +*/ +export const useAssetServiceNextRunAssets = = unknown[]>({ dagId }: { + dagId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseAssetServiceNextRunAssetsKeyFn({ dagId }, queryKey), queryFn: () => AssetService.nextRunAssets({ dagId }) as TData, ...options }); +/** +* Get Assets +* Get assets. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.namePattern +* @param data.uriPattern +* @param data.dagIds +* @param data.orderBy +* @returns AssetCollectionResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetAssets = = unknown[]>({ dagIds, limit, namePattern, offset, orderBy, uriPattern }: { + dagIds?: string[]; + limit?: number; + namePattern?: string; + offset?: number; + orderBy?: string; + uriPattern?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseAssetServiceGetAssetsKeyFn({ dagIds, limit, namePattern, offset, orderBy, uriPattern }, queryKey), queryFn: () => AssetService.getAssets({ dagIds, limit, namePattern, offset, orderBy, uriPattern }) as TData, ...options }); +/** +* Get Asset Aliases +* Get asset aliases. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.namePattern +* @param data.orderBy +* @returns AssetAliasCollectionResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetAssetAliases = = unknown[]>({ limit, namePattern, offset, orderBy }: { + limit?: number; + namePattern?: string; + offset?: number; + orderBy?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseAssetServiceGetAssetAliasesKeyFn({ limit, namePattern, offset, orderBy }, queryKey), queryFn: () => AssetService.getAssetAliases({ limit, namePattern, offset, orderBy }) as TData, ...options }); +/** +* Get Asset Alias +* Get an asset alias. +* @param data The data for the request. +* @param data.assetAliasId +* @returns unknown Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetAssetAlias = = unknown[]>({ assetAliasId }: { + assetAliasId: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseAssetServiceGetAssetAliasKeyFn({ assetAliasId }, queryKey), queryFn: () => AssetService.getAssetAlias({ assetAliasId }) as TData, ...options }); +/** +* Get Asset Events +* Get asset events. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.assetId +* @param data.sourceDagId +* @param data.sourceTaskId +* @param data.sourceRunId +* @param data.sourceMapIndex +* @param data.timestampGte +* @param data.timestampLte +* @returns AssetEventCollectionResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetAssetEvents = = unknown[]>({ assetId, limit, offset, orderBy, sourceDagId, sourceMapIndex, sourceRunId, sourceTaskId, timestampGte, timestampLte }: { + assetId?: number; + limit?: number; + offset?: number; + orderBy?: string; + sourceDagId?: string; + sourceMapIndex?: number; + sourceRunId?: string; + sourceTaskId?: string; + timestampGte?: string; + timestampLte?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseAssetServiceGetAssetEventsKeyFn({ assetId, limit, offset, orderBy, sourceDagId, sourceMapIndex, sourceRunId, sourceTaskId, timestampGte, timestampLte }, queryKey), queryFn: () => AssetService.getAssetEvents({ assetId, limit, offset, orderBy, sourceDagId, sourceMapIndex, sourceRunId, sourceTaskId, timestampGte, timestampLte }) as TData, ...options }); +/** +* Get Asset Queued Events +* Get queued asset events for an asset. +* @param data The data for the request. +* @param data.assetId +* @param data.before +* @returns QueuedEventCollectionResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetAssetQueuedEvents = = unknown[]>({ assetId, before }: { + assetId: number; + before?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseAssetServiceGetAssetQueuedEventsKeyFn({ assetId, before }, queryKey), queryFn: () => AssetService.getAssetQueuedEvents({ assetId, before }) as TData, ...options }); +/** +* Get Asset +* Get an asset. +* @param data The data for the request. +* @param data.assetId +* @returns AssetResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetAsset = = unknown[]>({ assetId }: { + assetId: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseAssetServiceGetAssetKeyFn({ assetId }, queryKey), queryFn: () => AssetService.getAsset({ assetId }) as TData, ...options }); +/** +* Get Dag Asset Queued Events +* Get queued asset events for a DAG. +* @param data The data for the request. +* @param data.dagId +* @param data.before +* @returns QueuedEventCollectionResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetDagAssetQueuedEvents = = unknown[]>({ before, dagId }: { + before?: string; + dagId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseAssetServiceGetDagAssetQueuedEventsKeyFn({ before, dagId }, queryKey), queryFn: () => AssetService.getDagAssetQueuedEvents({ before, dagId }) as TData, ...options }); +/** +* Get Dag Asset Queued Event +* Get a queued asset event for a DAG. +* @param data The data for the request. +* @param data.dagId +* @param data.assetId +* @param data.before +* @returns QueuedEventResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetDagAssetQueuedEvent = = unknown[]>({ assetId, before, dagId }: { + assetId: number; + before?: string; + dagId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseAssetServiceGetDagAssetQueuedEventKeyFn({ assetId, before, dagId }, queryKey), queryFn: () => AssetService.getDagAssetQueuedEvent({ assetId, before, dagId }) as TData, ...options }); +/** +* Get Configs +* Get configs for UI. +* @returns ConfigResponse Successful Response +* @throws ApiError +*/ +export const useConfigServiceGetConfigs = = unknown[]>(queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseConfigServiceGetConfigsKeyFn(queryKey), queryFn: () => ConfigService.getConfigs() as TData, ...options }); +/** +* Get Config +* @param data The data for the request. +* @param data.section +* @param data.accept +* @returns Config Successful Response +* @throws ApiError +*/ +export const useConfigServiceGetConfig = = unknown[]>({ accept, section }: { + accept?: "application/json" | "text/plain" | "*/*"; + section?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseConfigServiceGetConfigKeyFn({ accept, section }, queryKey), queryFn: () => ConfigService.getConfig({ accept, section }) as TData, ...options }); +/** +* Get Config Value +* @param data The data for the request. +* @param data.section +* @param data.option +* @param data.accept +* @returns Config Successful Response +* @throws ApiError +*/ +export const useConfigServiceGetConfigValue = = unknown[]>({ accept, option, section }: { + accept?: "application/json" | "text/plain" | "*/*"; + option: string; + section: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseConfigServiceGetConfigValueKeyFn({ accept, option, section }, queryKey), queryFn: () => ConfigService.getConfigValue({ accept, option, section }) as TData, ...options }); +/** +* Recent Dag Runs +* Get recent DAG runs. +* @param data The data for the request. +* @param data.dagRunsLimit +* @param data.limit +* @param data.offset +* @param data.tags +* @param data.owners +* @param data.dagIds +* @param data.dagIdPattern +* @param data.dagDisplayNamePattern +* @param data.onlyActive +* @param data.paused +* @param data.lastDagRunState +* @returns DAGWithLatestDagRunsCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagsServiceRecentDagRuns = = unknown[]>({ dagDisplayNamePattern, dagIdPattern, dagIds, dagRunsLimit, lastDagRunState, limit, offset, onlyActive, owners, paused, tags }: { + dagDisplayNamePattern?: string; + dagIdPattern?: string; + dagIds?: string[]; + dagRunsLimit?: number; + lastDagRunState?: DagRunState; + limit?: number; + offset?: number; + onlyActive?: boolean; + owners?: string[]; + paused?: boolean; + tags?: string[]; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseDagsServiceRecentDagRunsKeyFn({ dagDisplayNamePattern, dagIdPattern, dagIds, dagRunsLimit, lastDagRunState, limit, offset, onlyActive, owners, paused, tags }, queryKey), queryFn: () => DagsService.recentDagRuns({ dagDisplayNamePattern, dagIdPattern, dagIds, dagRunsLimit, lastDagRunState, limit, offset, onlyActive, owners, paused, tags }) as TData, ...options }); +/** +* Historical Metrics +* Return cluster activity historical metrics. +* @param data The data for the request. +* @param data.startDate +* @param data.endDate +* @returns HistoricalMetricDataResponse Successful Response +* @throws ApiError +*/ +export const useDashboardServiceHistoricalMetrics = = unknown[]>({ endDate, startDate }: { + endDate?: string; + startDate: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseDashboardServiceHistoricalMetricsKeyFn({ endDate, startDate }, queryKey), queryFn: () => DashboardService.historicalMetrics({ endDate, startDate }) as TData, ...options }); +/** +* Structure Data +* Get Structure Data. +* @param data The data for the request. +* @param data.dagId +* @param data.includeUpstream +* @param data.includeDownstream +* @param data.root +* @param data.externalDependencies +* @returns StructureDataResponse Successful Response +* @throws ApiError +*/ +export const useStructureServiceStructureData = = unknown[]>({ dagId, externalDependencies, includeDownstream, includeUpstream, root }: { + dagId: string; + externalDependencies?: boolean; + includeDownstream?: boolean; + includeUpstream?: boolean; + root?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseStructureServiceStructureDataKeyFn({ dagId, externalDependencies, includeDownstream, includeUpstream, root }, queryKey), queryFn: () => StructureService.structureData({ dagId, externalDependencies, includeDownstream, includeUpstream, root }) as TData, ...options }); +/** +* List Backfills +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.dagId +* @param data.active +* @returns BackfillCollectionResponse Successful Response +* @throws ApiError +*/ +export const useBackfillServiceListBackfills = = unknown[]>({ active, dagId, limit, offset, orderBy }: { + active?: boolean; + dagId?: string; + limit?: number; + offset?: number; + orderBy?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseBackfillServiceListBackfillsKeyFn({ active, dagId, limit, offset, orderBy }, queryKey), queryFn: () => BackfillService.listBackfills({ active, dagId, limit, offset, orderBy }) as TData, ...options }); +/** +* List Backfills +* @param data The data for the request. +* @param data.dagId +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns BackfillCollectionResponse Successful Response +* @throws ApiError +*/ +export const useBackfillServiceListBackfills1 = = unknown[]>({ dagId, limit, offset, orderBy }: { + dagId: string; + limit?: number; + offset?: number; + orderBy?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseBackfillServiceListBackfills1KeyFn({ dagId, limit, offset, orderBy }, queryKey), queryFn: () => BackfillService.listBackfills1({ dagId, limit, offset, orderBy }) as TData, ...options }); +/** +* Get Backfill +* @param data The data for the request. +* @param data.backfillId +* @returns BackfillResponse Successful Response +* @throws ApiError +*/ +export const useBackfillServiceGetBackfill = = unknown[]>({ backfillId }: { + backfillId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseBackfillServiceGetBackfillKeyFn({ backfillId }, queryKey), queryFn: () => BackfillService.getBackfill({ backfillId }) as TData, ...options }); +/** +* Grid Data +* Return grid data. +* @param data The data for the request. +* @param data.dagId +* @param data.includeUpstream +* @param data.includeDownstream +* @param data.logicalDateGte +* @param data.logicalDateLte +* @param data.root +* @param data.offset +* @param data.runType +* @param data.state +* @param data.limit +* @param data.orderBy +* @returns GridResponse Successful Response +* @throws ApiError +*/ +export const useGridServiceGridData = = unknown[]>({ dagId, includeDownstream, includeUpstream, limit, logicalDateGte, logicalDateLte, offset, orderBy, root, runType, state }: { + dagId: string; + includeDownstream?: boolean; + includeUpstream?: boolean; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + root?: string; + runType?: string[]; + state?: string[]; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseGridServiceGridDataKeyFn({ dagId, includeDownstream, includeUpstream, limit, logicalDateGte, logicalDateLte, offset, orderBy, root, runType, state }, queryKey), queryFn: () => GridService.gridData({ dagId, includeDownstream, includeUpstream, limit, logicalDateGte, logicalDateLte, offset, orderBy, root, runType, state }) as TData, ...options }); +/** +* Get Connection +* Get a connection entry. +* @param data The data for the request. +* @param data.connectionId +* @returns ConnectionResponse Successful Response +* @throws ApiError +*/ +export const useConnectionServiceGetConnection = = unknown[]>({ connectionId }: { + connectionId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseConnectionServiceGetConnectionKeyFn({ connectionId }, queryKey), queryFn: () => ConnectionService.getConnection({ connectionId }) as TData, ...options }); +/** +* Get Connections +* Get all connection entries. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns ConnectionCollectionResponse Successful Response +* @throws ApiError +*/ +export const useConnectionServiceGetConnections = = unknown[]>({ limit, offset, orderBy }: { + limit?: number; + offset?: number; + orderBy?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseConnectionServiceGetConnectionsKeyFn({ limit, offset, orderBy }, queryKey), queryFn: () => ConnectionService.getConnections({ limit, offset, orderBy }) as TData, ...options }); +/** +* Get Dag Run +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @returns DAGRunResponse Successful Response +* @throws ApiError +*/ +export const useDagRunServiceGetDagRun = = unknown[]>({ dagId, dagRunId }: { + dagId: string; + dagRunId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseDagRunServiceGetDagRunKeyFn({ dagId, dagRunId }, queryKey), queryFn: () => DagRunService.getDagRun({ dagId, dagRunId }) as TData, ...options }); +/** +* Get Upstream Asset Events +* If dag run is asset-triggered, return the asset events that triggered it. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @returns AssetEventCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagRunServiceGetUpstreamAssetEvents = = unknown[]>({ dagId, dagRunId }: { + dagId: string; + dagRunId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseDagRunServiceGetUpstreamAssetEventsKeyFn({ dagId, dagRunId }, queryKey), queryFn: () => DagRunService.getUpstreamAssetEvents({ dagId, dagRunId }) as TData, ...options }); +/** +* Get Dag Runs +* Get all DAG Runs. +* +* This endpoint allows specifying `~` as the dag_id to retrieve Dag Runs for all DAGs. +* @param data The data for the request. +* @param data.dagId +* @param data.limit +* @param data.offset +* @param data.logicalDateGte +* @param data.logicalDateLte +* @param data.startDateGte +* @param data.startDateLte +* @param data.endDateGte +* @param data.endDateLte +* @param data.updatedAtGte +* @param data.updatedAtLte +* @param data.state +* @param data.orderBy +* @returns DAGRunCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagRunServiceGetDagRuns = = unknown[]>({ dagId, endDateGte, endDateLte, limit, logicalDateGte, logicalDateLte, offset, orderBy, startDateGte, startDateLte, state, updatedAtGte, updatedAtLte }: { + dagId: string; + endDateGte?: string; + endDateLte?: string; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + startDateGte?: string; + startDateLte?: string; + state?: string[]; + updatedAtGte?: string; + updatedAtLte?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseDagRunServiceGetDagRunsKeyFn({ dagId, endDateGte, endDateLte, limit, logicalDateGte, logicalDateLte, offset, orderBy, startDateGte, startDateLte, state, updatedAtGte, updatedAtLte }, queryKey), queryFn: () => DagRunService.getDagRuns({ dagId, endDateGte, endDateLte, limit, logicalDateGte, logicalDateLte, offset, orderBy, startDateGte, startDateLte, state, updatedAtGte, updatedAtLte }) as TData, ...options }); +/** +* Get Dag Source +* Get source code using file token. +* @param data The data for the request. +* @param data.dagId +* @param data.versionNumber +* @param data.accept +* @returns DAGSourceResponse Successful Response +* @throws ApiError +*/ +export const useDagSourceServiceGetDagSource = = unknown[]>({ accept, dagId, versionNumber }: { + accept?: "application/json" | "text/plain" | "*/*"; + dagId: string; + versionNumber?: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseDagSourceServiceGetDagSourceKeyFn({ accept, dagId, versionNumber }, queryKey), queryFn: () => DagSourceService.getDagSource({ accept, dagId, versionNumber }) as TData, ...options }); +/** +* Get Dag Stats +* Get Dag statistics. +* @param data The data for the request. +* @param data.dagIds +* @returns DagStatsCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagStatsServiceGetDagStats = = unknown[]>({ dagIds }: { + dagIds?: string[]; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseDagStatsServiceGetDagStatsKeyFn({ dagIds }, queryKey), queryFn: () => DagStatsService.getDagStats({ dagIds }) as TData, ...options }); +/** +* List Dag Warnings +* Get a list of DAG warnings. +* @param data The data for the request. +* @param data.dagId +* @param data.warningType +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns DAGWarningCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagWarningServiceListDagWarnings = = unknown[]>({ dagId, limit, offset, orderBy, warningType }: { + dagId?: string; + limit?: number; + offset?: number; + orderBy?: string; + warningType?: DagWarningType; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseDagWarningServiceListDagWarningsKeyFn({ dagId, limit, offset, orderBy, warningType }, queryKey), queryFn: () => DagWarningService.listDagWarnings({ dagId, limit, offset, orderBy, warningType }) as TData, ...options }); +/** +* Get Dags +* Get all DAGs. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.tags +* @param data.owners +* @param data.dagIdPattern +* @param data.dagDisplayNamePattern +* @param data.onlyActive +* @param data.paused +* @param data.lastDagRunState +* @param data.orderBy +* @returns DAGCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagServiceGetDags = = unknown[]>({ dagDisplayNamePattern, dagIdPattern, lastDagRunState, limit, offset, onlyActive, orderBy, owners, paused, tags }: { + dagDisplayNamePattern?: string; + dagIdPattern?: string; + lastDagRunState?: DagRunState; + limit?: number; + offset?: number; + onlyActive?: boolean; + orderBy?: string; + owners?: string[]; + paused?: boolean; + tags?: string[]; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseDagServiceGetDagsKeyFn({ dagDisplayNamePattern, dagIdPattern, lastDagRunState, limit, offset, onlyActive, orderBy, owners, paused, tags }, queryKey), queryFn: () => DagService.getDags({ dagDisplayNamePattern, dagIdPattern, lastDagRunState, limit, offset, onlyActive, orderBy, owners, paused, tags }) as TData, ...options }); +/** +* Get Dag +* Get basic information about a DAG. +* @param data The data for the request. +* @param data.dagId +* @returns DAGResponse Successful Response +* @throws ApiError +*/ +export const useDagServiceGetDag = = unknown[]>({ dagId }: { + dagId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseDagServiceGetDagKeyFn({ dagId }, queryKey), queryFn: () => DagService.getDag({ dagId }) as TData, ...options }); +/** +* Get Dag Details +* Get details of DAG. +* @param data The data for the request. +* @param data.dagId +* @returns DAGDetailsResponse Successful Response +* @throws ApiError +*/ +export const useDagServiceGetDagDetails = = unknown[]>({ dagId }: { + dagId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseDagServiceGetDagDetailsKeyFn({ dagId }, queryKey), queryFn: () => DagService.getDagDetails({ dagId }) as TData, ...options }); +/** +* Get Dag Tags +* Get all DAG tags. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.tagNamePattern +* @returns DAGTagCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagServiceGetDagTags = = unknown[]>({ limit, offset, orderBy, tagNamePattern }: { + limit?: number; + offset?: number; + orderBy?: string; + tagNamePattern?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseDagServiceGetDagTagsKeyFn({ limit, offset, orderBy, tagNamePattern }, queryKey), queryFn: () => DagService.getDagTags({ limit, offset, orderBy, tagNamePattern }) as TData, ...options }); +/** +* Get Event Log +* @param data The data for the request. +* @param data.eventLogId +* @returns EventLogResponse Successful Response +* @throws ApiError +*/ +export const useEventLogServiceGetEventLog = = unknown[]>({ eventLogId }: { + eventLogId: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseEventLogServiceGetEventLogKeyFn({ eventLogId }, queryKey), queryFn: () => EventLogService.getEventLog({ eventLogId }) as TData, ...options }); +/** +* Get Event Logs +* Get all Event Logs. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.dagId +* @param data.taskId +* @param data.runId +* @param data.mapIndex +* @param data.tryNumber +* @param data.owner +* @param data.event +* @param data.excludedEvents +* @param data.includedEvents +* @param data.before +* @param data.after +* @returns EventLogCollectionResponse Successful Response +* @throws ApiError +*/ +export const useEventLogServiceGetEventLogs = = unknown[]>({ after, before, dagId, event, excludedEvents, includedEvents, limit, mapIndex, offset, orderBy, owner, runId, taskId, tryNumber }: { + after?: string; + before?: string; + dagId?: string; + event?: string; + excludedEvents?: string[]; + includedEvents?: string[]; + limit?: number; + mapIndex?: number; + offset?: number; + orderBy?: string; + owner?: string; + runId?: string; + taskId?: string; + tryNumber?: number; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseEventLogServiceGetEventLogsKeyFn({ after, before, dagId, event, excludedEvents, includedEvents, limit, mapIndex, offset, orderBy, owner, runId, taskId, tryNumber }, queryKey), queryFn: () => EventLogService.getEventLogs({ after, before, dagId, event, excludedEvents, includedEvents, limit, mapIndex, offset, orderBy, owner, runId, taskId, tryNumber }) as TData, ...options }); +/** +* Get Extra Links +* Get extra links for task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @returns ExtraLinksResponse Successful Response +* @throws ApiError +*/ +export const useExtraLinksServiceGetExtraLinks = = unknown[]>({ dagId, dagRunId, taskId }: { + dagId: string; + dagRunId: string; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseExtraLinksServiceGetExtraLinksKeyFn({ dagId, dagRunId, taskId }, queryKey), queryFn: () => ExtraLinksService.getExtraLinks({ dagId, dagRunId, taskId }) as TData, ...options }); +/** +* Get Extra Links +* Get extra links for task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @returns ExtraLinksResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetExtraLinks = = unknown[]>({ dagId, dagRunId, taskId }: { + dagId: string; + dagRunId: string; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskInstanceServiceGetExtraLinksKeyFn({ dagId, dagRunId, taskId }, queryKey), queryFn: () => TaskInstanceService.getExtraLinks({ dagId, dagRunId, taskId }) as TData, ...options }); +/** +* Get Task Instance +* Get task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @returns TaskInstanceResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstance = = unknown[]>({ dagId, dagRunId, taskId }: { + dagId: string; + dagRunId: string; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceKeyFn({ dagId, dagRunId, taskId }, queryKey), queryFn: () => TaskInstanceService.getTaskInstance({ dagId, dagRunId, taskId }) as TData, ...options }); +/** +* Get Mapped Task Instances +* Get list of mapped task instances. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.logicalDateGte +* @param data.logicalDateLte +* @param data.startDateGte +* @param data.startDateLte +* @param data.endDateGte +* @param data.endDateLte +* @param data.updatedAtGte +* @param data.updatedAtLte +* @param data.durationGte +* @param data.durationLte +* @param data.state +* @param data.pool +* @param data.queue +* @param data.executor +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns TaskInstanceCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetMappedTaskInstances = = unknown[]>({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskId, updatedAtGte, updatedAtLte }: { + dagId: string; + dagRunId: string; + durationGte?: number; + durationLte?: number; + endDateGte?: string; + endDateLte?: string; + executor?: string[]; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + pool?: string[]; + queue?: string[]; + startDateGte?: string; + startDateLte?: string; + state?: string[]; + taskId: string; + updatedAtGte?: string; + updatedAtLte?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstancesKeyFn({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskId, updatedAtGte, updatedAtLte }, queryKey), queryFn: () => TaskInstanceService.getMappedTaskInstances({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskId, updatedAtGte, updatedAtLte }) as TData, ...options }); +/** +* Get Task Instance Dependencies +* Get dependencies blocking task from getting scheduled. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskDependencyCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstanceDependencies = = unknown[]>({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceDependenciesKeyFn({ dagId, dagRunId, mapIndex, taskId }, queryKey), queryFn: () => TaskInstanceService.getTaskInstanceDependencies({ dagId, dagRunId, mapIndex, taskId }) as TData, ...options }); +/** +* Get Task Instance Dependencies +* Get dependencies blocking task from getting scheduled. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskDependencyCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstanceDependencies1 = = unknown[]>({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex?: number; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceDependencies1KeyFn({ dagId, dagRunId, mapIndex, taskId }, queryKey), queryFn: () => TaskInstanceService.getTaskInstanceDependencies1({ dagId, dagRunId, mapIndex, taskId }) as TData, ...options }); +/** +* Get Task Instance Tries +* Get list of task instances history. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskInstanceHistoryCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstanceTries = = unknown[]>({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex?: number; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceTriesKeyFn({ dagId, dagRunId, mapIndex, taskId }, queryKey), queryFn: () => TaskInstanceService.getTaskInstanceTries({ dagId, dagRunId, mapIndex, taskId }) as TData, ...options }); +/** +* Get Mapped Task Instance Tries +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskInstanceHistoryCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetMappedTaskInstanceTries = = unknown[]>({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceTriesKeyFn({ dagId, dagRunId, mapIndex, taskId }, queryKey), queryFn: () => TaskInstanceService.getMappedTaskInstanceTries({ dagId, dagRunId, mapIndex, taskId }) as TData, ...options }); +/** +* Get Mapped Task Instance +* Get task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskInstanceResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetMappedTaskInstance = = unknown[]>({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceKeyFn({ dagId, dagRunId, mapIndex, taskId }, queryKey), queryFn: () => TaskInstanceService.getMappedTaskInstance({ dagId, dagRunId, mapIndex, taskId }) as TData, ...options }); +/** +* Get Task Instances +* Get list of task instances. +* +* This endpoint allows specifying `~` as the dag_id, dag_run_id to retrieve Task Instances for all DAGs +* and DAG runs. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.logicalDateGte +* @param data.logicalDateLte +* @param data.startDateGte +* @param data.startDateLte +* @param data.endDateGte +* @param data.endDateLte +* @param data.updatedAtGte +* @param data.updatedAtLte +* @param data.durationGte +* @param data.durationLte +* @param data.taskDisplayNamePattern +* @param data.state +* @param data.pool +* @param data.queue +* @param data.executor +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns TaskInstanceCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstances = = unknown[]>({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskDisplayNamePattern, taskId, updatedAtGte, updatedAtLte }: { + dagId: string; + dagRunId: string; + durationGte?: number; + durationLte?: number; + endDateGte?: string; + endDateLte?: string; + executor?: string[]; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + pool?: string[]; + queue?: string[]; + startDateGte?: string; + startDateLte?: string; + state?: string[]; + taskDisplayNamePattern?: string; + taskId?: string; + updatedAtGte?: string; + updatedAtLte?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstancesKeyFn({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskDisplayNamePattern, taskId, updatedAtGte, updatedAtLte }, queryKey), queryFn: () => TaskInstanceService.getTaskInstances({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskDisplayNamePattern, taskId, updatedAtGte, updatedAtLte }) as TData, ...options }); +/** +* Get Task Instance Try Details +* Get task instance details by try number. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.taskTryNumber +* @param data.mapIndex +* @returns TaskInstanceHistoryResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstanceTryDetails = = unknown[]>({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }: { + dagId: string; + dagRunId: string; + mapIndex?: number; + taskId: string; + taskTryNumber: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceTryDetailsKeyFn({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }, queryKey), queryFn: () => TaskInstanceService.getTaskInstanceTryDetails({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }) as TData, ...options }); +/** +* Get Mapped Task Instance Try Details +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.taskTryNumber +* @param data.mapIndex +* @returns TaskInstanceHistoryResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetMappedTaskInstanceTryDetails = = unknown[]>({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; + taskTryNumber: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceTryDetailsKeyFn({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }, queryKey), queryFn: () => TaskInstanceService.getMappedTaskInstanceTryDetails({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }) as TData, ...options }); +/** +* Get Log +* Get logs for a specific task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.tryNumber +* @param data.fullContent +* @param data.mapIndex +* @param data.token +* @param data.accept +* @returns TaskInstancesLogResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetLog = = unknown[]>({ accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }: { + accept?: "application/json" | "text/plain" | "*/*"; + dagId: string; + dagRunId: string; + fullContent?: boolean; + mapIndex?: number; + taskId: string; + token?: string; + tryNumber: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskInstanceServiceGetLogKeyFn({ accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }, queryKey), queryFn: () => TaskInstanceService.getLog({ accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }) as TData, ...options }); +/** +* Get Import Error +* Get an import error. +* @param data The data for the request. +* @param data.importErrorId +* @returns ImportErrorResponse Successful Response +* @throws ApiError +*/ +export const useImportErrorServiceGetImportError = = unknown[]>({ importErrorId }: { + importErrorId: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseImportErrorServiceGetImportErrorKeyFn({ importErrorId }, queryKey), queryFn: () => ImportErrorService.getImportError({ importErrorId }) as TData, ...options }); +/** +* Get Import Errors +* Get all import errors. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns ImportErrorCollectionResponse Successful Response +* @throws ApiError +*/ +export const useImportErrorServiceGetImportErrors = = unknown[]>({ limit, offset, orderBy }: { + limit?: number; + offset?: number; + orderBy?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseImportErrorServiceGetImportErrorsKeyFn({ limit, offset, orderBy }, queryKey), queryFn: () => ImportErrorService.getImportErrors({ limit, offset, orderBy }) as TData, ...options }); +/** +* Get Jobs +* Get all jobs. +* @param data The data for the request. +* @param data.isAlive +* @param data.startDateGte +* @param data.startDateLte +* @param data.endDateGte +* @param data.endDateLte +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.jobState +* @param data.jobType +* @param data.hostname +* @param data.executorClass +* @returns JobCollectionResponse Successful Response +* @throws ApiError +*/ +export const useJobServiceGetJobs = = unknown[]>({ endDateGte, endDateLte, executorClass, hostname, isAlive, jobState, jobType, limit, offset, orderBy, startDateGte, startDateLte }: { + endDateGte?: string; + endDateLte?: string; + executorClass?: string; + hostname?: string; + isAlive?: boolean; + jobState?: string; + jobType?: string; + limit?: number; + offset?: number; + orderBy?: string; + startDateGte?: string; + startDateLte?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseJobServiceGetJobsKeyFn({ endDateGte, endDateLte, executorClass, hostname, isAlive, jobState, jobType, limit, offset, orderBy, startDateGte, startDateLte }, queryKey), queryFn: () => JobService.getJobs({ endDateGte, endDateLte, executorClass, hostname, isAlive, jobState, jobType, limit, offset, orderBy, startDateGte, startDateLte }) as TData, ...options }); +/** +* Get Plugins +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @returns PluginCollectionResponse Successful Response +* @throws ApiError +*/ +export const usePluginServiceGetPlugins = = unknown[]>({ limit, offset }: { + limit?: number; + offset?: number; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UsePluginServiceGetPluginsKeyFn({ limit, offset }, queryKey), queryFn: () => PluginService.getPlugins({ limit, offset }) as TData, ...options }); +/** +* Get Pool +* Get a pool. +* @param data The data for the request. +* @param data.poolName +* @returns PoolResponse Successful Response +* @throws ApiError +*/ +export const usePoolServiceGetPool = = unknown[]>({ poolName }: { + poolName: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UsePoolServiceGetPoolKeyFn({ poolName }, queryKey), queryFn: () => PoolService.getPool({ poolName }) as TData, ...options }); +/** +* Get Pools +* Get all pools entries. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns PoolCollectionResponse Successful Response +* @throws ApiError +*/ +export const usePoolServiceGetPools = = unknown[]>({ limit, offset, orderBy }: { + limit?: number; + offset?: number; + orderBy?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UsePoolServiceGetPoolsKeyFn({ limit, offset, orderBy }, queryKey), queryFn: () => PoolService.getPools({ limit, offset, orderBy }) as TData, ...options }); +/** +* Get Providers +* Get providers. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @returns ProviderCollectionResponse Successful Response +* @throws ApiError +*/ +export const useProviderServiceGetProviders = = unknown[]>({ limit, offset }: { + limit?: number; + offset?: number; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseProviderServiceGetProvidersKeyFn({ limit, offset }, queryKey), queryFn: () => ProviderService.getProviders({ limit, offset }) as TData, ...options }); +/** +* Get Xcom Entry +* Get an XCom entry. +* @param data The data for the request. +* @param data.dagId +* @param data.taskId +* @param data.dagRunId +* @param data.xcomKey +* @param data.mapIndex +* @param data.deserialize +* @param data.stringify +* @returns unknown Successful Response +* @throws ApiError +*/ +export const useXcomServiceGetXcomEntry = = unknown[]>({ dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }: { + dagId: string; + dagRunId: string; + deserialize?: boolean; + mapIndex?: number; + stringify?: boolean; + taskId: string; + xcomKey: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseXcomServiceGetXcomEntryKeyFn({ dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }, queryKey), queryFn: () => XcomService.getXcomEntry({ dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }) as TData, ...options }); +/** +* Get Xcom Entries +* Get all XCom entries. +* +* This endpoint allows specifying `~` as the dag_id, dag_run_id, task_id to retrieve XCom entries for all DAGs. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.xcomKey +* @param data.mapIndex +* @param data.limit +* @param data.offset +* @returns XComCollection Successful Response +* @throws ApiError +*/ +export const useXcomServiceGetXcomEntries = = unknown[]>({ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }: { + dagId: string; + dagRunId: string; + limit?: number; + mapIndex?: number; + offset?: number; + taskId: string; + xcomKey?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseXcomServiceGetXcomEntriesKeyFn({ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }, queryKey), queryFn: () => XcomService.getXcomEntries({ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }) as TData, ...options }); +/** +* Get Tasks +* Get tasks for DAG. +* @param data The data for the request. +* @param data.dagId +* @param data.orderBy +* @returns TaskCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskServiceGetTasks = = unknown[]>({ dagId, orderBy }: { + dagId: string; + orderBy?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskServiceGetTasksKeyFn({ dagId, orderBy }, queryKey), queryFn: () => TaskService.getTasks({ dagId, orderBy }) as TData, ...options }); +/** +* Get Task +* Get simplified representation of a task. +* @param data The data for the request. +* @param data.dagId +* @param data.taskId +* @returns TaskResponse Successful Response +* @throws ApiError +*/ +export const useTaskServiceGetTask = = unknown[]>({ dagId, taskId }: { + dagId: string; + taskId: unknown; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseTaskServiceGetTaskKeyFn({ dagId, taskId }, queryKey), queryFn: () => TaskService.getTask({ dagId, taskId }) as TData, ...options }); +/** +* Get Variable +* Get a variable entry. +* @param data The data for the request. +* @param data.variableKey +* @returns VariableResponse Successful Response +* @throws ApiError +*/ +export const useVariableServiceGetVariable = = unknown[]>({ variableKey }: { + variableKey: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseVariableServiceGetVariableKeyFn({ variableKey }, queryKey), queryFn: () => VariableService.getVariable({ variableKey }) as TData, ...options }); +/** +* Get Variables +* Get all Variables entries. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.variableKeyPattern +* @returns VariableCollectionResponse Successful Response +* @throws ApiError +*/ +export const useVariableServiceGetVariables = = unknown[]>({ limit, offset, orderBy, variableKeyPattern }: { + limit?: number; + offset?: number; + orderBy?: string; + variableKeyPattern?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseVariableServiceGetVariablesKeyFn({ limit, offset, orderBy, variableKeyPattern }, queryKey), queryFn: () => VariableService.getVariables({ limit, offset, orderBy, variableKeyPattern }) as TData, ...options }); +/** +* Get Health +* @returns HealthInfoResponse Successful Response +* @throws ApiError +*/ +export const useMonitorServiceGetHealth = = unknown[]>(queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseMonitorServiceGetHealthKeyFn(queryKey), queryFn: () => MonitorService.getHealth() as TData, ...options }); +/** +* Get Version +* Get version information. +* @returns VersionInfo Successful Response +* @throws ApiError +*/ +export const useVersionServiceGetVersion = = unknown[]>(queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useQuery({ queryKey: Common.UseVersionServiceGetVersionKeyFn(queryKey), queryFn: () => VersionService.getVersion() as TData, ...options }); +/** +* Create Asset Event +* Create asset events. +* @param data The data for the request. +* @param data.requestBody +* @returns AssetEventResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceCreateAssetEvent = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ requestBody }) => AssetService.createAssetEvent({ requestBody }) as unknown as Promise, ...options }); +/** +* Create Backfill +* @param data The data for the request. +* @param data.requestBody +* @returns BackfillResponse Successful Response +* @throws ApiError +*/ +export const useBackfillServiceCreateBackfill = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ requestBody }) => BackfillService.createBackfill({ requestBody }) as unknown as Promise, ...options }); +/** +* Post Connection +* Create connection entry. +* @param data The data for the request. +* @param data.requestBody +* @returns ConnectionResponse Successful Response +* @throws ApiError +*/ +export const useConnectionServicePostConnection = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ requestBody }) => ConnectionService.postConnection({ requestBody }) as unknown as Promise, ...options }); +/** +* Test Connection +* Test an API connection. +* +* This method first creates an in-memory transient conn_id & exports that to an env var, +* as some hook classes tries to find out the `conn` from their __init__ method & errors out if not found. +* It also deletes the conn id env variable after the test. +* @param data The data for the request. +* @param data.requestBody +* @returns ConnectionTestResponse Successful Response +* @throws ApiError +*/ +export const useConnectionServiceTestConnection = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ requestBody }) => ConnectionService.testConnection({ requestBody }) as unknown as Promise, ...options }); +/** +* Clear Dag Run +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.requestBody +* @returns unknown Successful Response +* @throws ApiError +*/ +export const useDagRunServiceClearDagRun = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ dagId, dagRunId, requestBody }) => DagRunService.clearDagRun({ dagId, dagRunId, requestBody }) as unknown as Promise, ...options }); +/** +* Trigger Dag Run +* Trigger a DAG. +* @param data The data for the request. +* @param data.dagId +* @param data.requestBody +* @returns DAGRunResponse Successful Response +* @throws ApiError +*/ +export const useDagRunServiceTriggerDagRun = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ dagId, requestBody }) => DagRunService.triggerDagRun({ dagId, requestBody }) as unknown as Promise, ...options }); +/** +* Get List Dag Runs Batch +* Get a list of DAG Runs. +* @param data The data for the request. +* @param data.dagId +* @param data.requestBody +* @returns DAGRunCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagRunServiceGetListDagRunsBatch = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ dagId, requestBody }) => DagRunService.getListDagRunsBatch({ dagId, requestBody }) as unknown as Promise, ...options }); +/** +* Get Task Instances Batch +* Get list of task instances. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.requestBody +* @returns TaskInstanceCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstancesBatch = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ dagId, dagRunId, requestBody }) => TaskInstanceService.getTaskInstancesBatch({ dagId, dagRunId, requestBody }) as unknown as Promise, ...options }); +/** +* Post Clear Task Instances +* Clear task instances. +* @param data The data for the request. +* @param data.dagId +* @param data.requestBody +* @returns TaskInstanceReferenceCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServicePostClearTaskInstances = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ dagId, requestBody }) => TaskInstanceService.postClearTaskInstances({ dagId, requestBody }) as unknown as Promise, ...options }); +/** +* Post Pool +* Create a Pool. +* @param data The data for the request. +* @param data.requestBody +* @returns PoolResponse Successful Response +* @throws ApiError +*/ +export const usePoolServicePostPool = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ requestBody }) => PoolService.postPool({ requestBody }) as unknown as Promise, ...options }); +/** +* Post Variable +* Create a variable. +* @param data The data for the request. +* @param data.requestBody +* @returns VariableResponse Successful Response +* @throws ApiError +*/ +export const useVariableServicePostVariable = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ requestBody }) => VariableService.postVariable({ requestBody }) as unknown as Promise, ...options }); +/** +* Import Variables +* Import variables from a JSON file. +* @param data The data for the request. +* @param data.formData +* @param data.actionIfExists +* @returns VariablesImportResponse Successful Response +* @throws ApiError +*/ +export const useVariableServiceImportVariables = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ actionIfExists, formData }) => VariableService.importVariables({ actionIfExists, formData }) as unknown as Promise, ...options }); +/** +* Pause Backfill +* @param data The data for the request. +* @param data.backfillId +* @returns BackfillResponse Successful Response +* @throws ApiError +*/ +export const useBackfillServicePauseBackfill = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ backfillId }) => BackfillService.pauseBackfill({ backfillId }) as unknown as Promise, ...options }); +/** +* Unpause Backfill +* @param data The data for the request. +* @param data.backfillId +* @returns BackfillResponse Successful Response +* @throws ApiError +*/ +export const useBackfillServiceUnpauseBackfill = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ backfillId }) => BackfillService.unpauseBackfill({ backfillId }) as unknown as Promise, ...options }); +/** +* Cancel Backfill +* @param data The data for the request. +* @param data.backfillId +* @returns BackfillResponse Successful Response +* @throws ApiError +*/ +export const useBackfillServiceCancelBackfill = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ backfillId }) => BackfillService.cancelBackfill({ backfillId }) as unknown as Promise, ...options }); +/** +* Put Connections +* Create connection entry. +* @param data The data for the request. +* @param data.requestBody +* @returns ConnectionCollectionResponse Created with overwrite +* @returns ConnectionCollectionResponse Created +* @throws ApiError +*/ +export const useConnectionServicePutConnections = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ requestBody }) => ConnectionService.putConnections({ requestBody }) as unknown as Promise, ...options }); +/** +* Put Pools +* Create multiple pools. +* @param data The data for the request. +* @param data.requestBody +* @returns PoolCollectionResponse Created with overwriting +* @returns PoolCollectionResponse Created +* @throws ApiError +*/ +export const usePoolServicePutPools = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ requestBody }) => PoolService.putPools({ requestBody }) as unknown as Promise, ...options }); +/** +* Reparse Dag File +* Request re-parsing a DAG file. +* @param data The data for the request. +* @param data.fileToken +* @returns null Successful Response +* @throws ApiError +*/ +export const useDagParsingServiceReparseDagFile = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ fileToken }) => DagParsingService.reparseDagFile({ fileToken }) as unknown as Promise, ...options }); +/** +* Patch Connection +* Update a connection entry. +* @param data The data for the request. +* @param data.connectionId +* @param data.requestBody +* @param data.updateMask +* @returns ConnectionResponse Successful Response +* @throws ApiError +*/ +export const useConnectionServicePatchConnection = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ connectionId, requestBody, updateMask }) => ConnectionService.patchConnection({ connectionId, requestBody, updateMask }) as unknown as Promise, ...options }); +/** +* Patch Dag Run +* Modify a DAG Run. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.requestBody +* @param data.updateMask +* @returns DAGRunResponse Successful Response +* @throws ApiError +*/ +export const useDagRunServicePatchDagRun = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ dagId, dagRunId, requestBody, updateMask }) => DagRunService.patchDagRun({ dagId, dagRunId, requestBody, updateMask }) as unknown as Promise, ...options }); +/** +* Patch Dags +* Patch multiple DAGs. +* @param data The data for the request. +* @param data.requestBody +* @param data.updateMask +* @param data.limit +* @param data.offset +* @param data.tags +* @param data.owners +* @param data.dagIdPattern +* @param data.onlyActive +* @param data.paused +* @param data.lastDagRunState +* @returns DAGCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagServicePatchDags = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ dagIdPattern, lastDagRunState, limit, offset, onlyActive, owners, paused, requestBody, tags, updateMask }) => DagService.patchDags({ dagIdPattern, lastDagRunState, limit, offset, onlyActive, owners, paused, requestBody, tags, updateMask }) as unknown as Promise, ...options }); +/** +* Patch Dag +* Patch the specific DAG. +* @param data The data for the request. +* @param data.dagId +* @param data.requestBody +* @param data.updateMask +* @returns DAGResponse Successful Response +* @throws ApiError +*/ +export const useDagServicePatchDag = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ dagId, requestBody, updateMask }) => DagService.patchDag({ dagId, requestBody, updateMask }) as unknown as Promise, ...options }); +/** +* Patch Task Instance +* Update the state of a task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.requestBody +* @param data.mapIndex +* @param data.updateMask +* @returns TaskInstanceResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServicePatchTaskInstance = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ dagId, dagRunId, mapIndex, requestBody, taskId, updateMask }) => TaskInstanceService.patchTaskInstance({ dagId, dagRunId, mapIndex, requestBody, taskId, updateMask }) as unknown as Promise, ...options }); +/** +* Patch Task Instance +* Update the state of a task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @param data.requestBody +* @param data.updateMask +* @returns TaskInstanceResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServicePatchTaskInstance1 = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ dagId, dagRunId, mapIndex, requestBody, taskId, updateMask }) => TaskInstanceService.patchTaskInstance1({ dagId, dagRunId, mapIndex, requestBody, taskId, updateMask }) as unknown as Promise, ...options }); +/** +* Patch Pool +* Update a Pool. +* @param data The data for the request. +* @param data.poolName +* @param data.requestBody +* @param data.updateMask +* @returns PoolResponse Successful Response +* @throws ApiError +*/ +export const usePoolServicePatchPool = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ poolName, requestBody, updateMask }) => PoolService.patchPool({ poolName, requestBody, updateMask }) as unknown as Promise, ...options }); +/** +* Patch Variable +* Update a variable by key. +* @param data The data for the request. +* @param data.variableKey +* @param data.requestBody +* @param data.updateMask +* @returns VariableResponse Successful Response +* @throws ApiError +*/ +export const useVariableServicePatchVariable = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ requestBody, updateMask, variableKey }) => VariableService.patchVariable({ requestBody, updateMask, variableKey }) as unknown as Promise, ...options }); +/** +* Delete Asset Queued Events +* Delete queued asset events for an asset. +* @param data The data for the request. +* @param data.assetId +* @param data.before +* @returns void Successful Response +* @throws ApiError +*/ +export const useAssetServiceDeleteAssetQueuedEvents = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ assetId, before }) => AssetService.deleteAssetQueuedEvents({ assetId, before }) as unknown as Promise, ...options }); +/** +* Delete Dag Asset Queued Events +* @param data The data for the request. +* @param data.dagId +* @param data.before +* @returns void Successful Response +* @throws ApiError +*/ +export const useAssetServiceDeleteDagAssetQueuedEvents = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ before, dagId }) => AssetService.deleteDagAssetQueuedEvents({ before, dagId }) as unknown as Promise, ...options }); +/** +* Delete Dag Asset Queued Event +* Delete a queued asset event for a DAG. +* @param data The data for the request. +* @param data.dagId +* @param data.assetId +* @param data.before +* @returns void Successful Response +* @throws ApiError +*/ +export const useAssetServiceDeleteDagAssetQueuedEvent = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ assetId, before, dagId }) => AssetService.deleteDagAssetQueuedEvent({ assetId, before, dagId }) as unknown as Promise, ...options }); +/** +* Delete Connection +* Delete a connection entry. +* @param data The data for the request. +* @param data.connectionId +* @returns void Successful Response +* @throws ApiError +*/ +export const useConnectionServiceDeleteConnection = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ connectionId }) => ConnectionService.deleteConnection({ connectionId }) as unknown as Promise, ...options }); +/** +* Delete Dag Run +* Delete a DAG Run entry. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @returns void Successful Response +* @throws ApiError +*/ +export const useDagRunServiceDeleteDagRun = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ dagId, dagRunId }) => DagRunService.deleteDagRun({ dagId, dagRunId }) as unknown as Promise, ...options }); +/** +* Delete Dag +* Delete the specific DAG. +* @param data The data for the request. +* @param data.dagId +* @returns unknown Successful Response +* @throws ApiError +*/ +export const useDagServiceDeleteDag = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ dagId }) => DagService.deleteDag({ dagId }) as unknown as Promise, ...options }); +/** +* Delete Pool +* Delete a pool entry. +* @param data The data for the request. +* @param data.poolName +* @returns void Successful Response +* @throws ApiError +*/ +export const usePoolServiceDeletePool = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ poolName }) => PoolService.deletePool({ poolName }) as unknown as Promise, ...options }); +/** +* Delete Variable +* Delete a variable entry. +* @param data The data for the request. +* @param data.variableKey +* @returns void Successful Response +* @throws ApiError +*/ +export const useVariableServiceDeleteVariable = (options?: Omit, "mutationFn">) => useMutation({ mutationFn: ({ variableKey }) => VariableService.deleteVariable({ variableKey }) as unknown as Promise, ...options }); diff --git a/airflow/ui/openapi-gen/queries/suspense.ts b/airflow/ui/openapi-gen/queries/suspense.ts index f56b431a4c537..ee444de20b9eb 100644 --- a/airflow/ui/openapi-gen/queries/suspense.ts +++ b/airflow/ui/openapi-gen/queries/suspense.ts @@ -1,2618 +1,1084 @@ -// generated with @7nohe/openapi-react-query-codegen@1.6.0 -import { UseQueryOptions, useSuspenseQuery } from "@tanstack/react-query"; +// generated with @7nohe/openapi-react-query-codegen@1.6.0 -import { - AssetService, - BackfillService, - ConfigService, - ConnectionService, - DagRunService, - DagService, - DagSourceService, - DagStatsService, - DagWarningService, - DagsService, - DashboardService, - EventLogService, - ExtraLinksService, - GridService, - ImportErrorService, - JobService, - MonitorService, - PluginService, - PoolService, - ProviderService, - StructureService, - TaskInstanceService, - TaskService, - VariableService, - VersionService, - XcomService, -} from "../requests/services.gen"; +import { UseQueryOptions, useSuspenseQuery } from "@tanstack/react-query"; +import { AssetService, BackfillService, ConfigService, ConnectionService, DagRunService, DagService, DagSourceService, DagStatsService, DagWarningService, DagsService, DashboardService, EventLogService, ExtraLinksService, GridService, ImportErrorService, JobService, MonitorService, PluginService, PoolService, ProviderService, StructureService, TaskInstanceService, TaskService, VariableService, VersionService, XcomService } from "../requests/services.gen"; import { DagRunState, DagWarningType } from "../requests/types.gen"; import * as Common from "./common"; - /** - * Next Run Assets - * @param data The data for the request. - * @param data.dagId - * @returns unknown Successful Response - * @throws ApiError - */ -export const useAssetServiceNextRunAssetsSuspense = < - TData = Common.AssetServiceNextRunAssetsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - }: { - dagId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseAssetServiceNextRunAssetsKeyFn({ dagId }, queryKey), - queryFn: () => AssetService.nextRunAssets({ dagId }) as TData, - ...options, - }); +* Next Run Assets +* @param data The data for the request. +* @param data.dagId +* @returns unknown Successful Response +* @throws ApiError +*/ +export const useAssetServiceNextRunAssetsSuspense = = unknown[]>({ dagId }: { + dagId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseAssetServiceNextRunAssetsKeyFn({ dagId }, queryKey), queryFn: () => AssetService.nextRunAssets({ dagId }) as TData, ...options }); /** - * Get Assets - * Get assets. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.namePattern - * @param data.uriPattern - * @param data.dagIds - * @param data.orderBy - * @returns AssetCollectionResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetAssetsSuspense = < - TData = Common.AssetServiceGetAssetsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagIds, - limit, - namePattern, - offset, - orderBy, - uriPattern, - }: { - dagIds?: string[]; - limit?: number; - namePattern?: string; - offset?: number; - orderBy?: string; - uriPattern?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseAssetServiceGetAssetsKeyFn( - { dagIds, limit, namePattern, offset, orderBy, uriPattern }, - queryKey, - ), - queryFn: () => - AssetService.getAssets({ dagIds, limit, namePattern, offset, orderBy, uriPattern }) as TData, - ...options, - }); +* Get Assets +* Get assets. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.namePattern +* @param data.uriPattern +* @param data.dagIds +* @param data.orderBy +* @returns AssetCollectionResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetAssetsSuspense = = unknown[]>({ dagIds, limit, namePattern, offset, orderBy, uriPattern }: { + dagIds?: string[]; + limit?: number; + namePattern?: string; + offset?: number; + orderBy?: string; + uriPattern?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseAssetServiceGetAssetsKeyFn({ dagIds, limit, namePattern, offset, orderBy, uriPattern }, queryKey), queryFn: () => AssetService.getAssets({ dagIds, limit, namePattern, offset, orderBy, uriPattern }) as TData, ...options }); /** - * Get Asset Aliases - * Get asset aliases. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.namePattern - * @param data.orderBy - * @returns AssetAliasCollectionResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetAssetAliasesSuspense = < - TData = Common.AssetServiceGetAssetAliasesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - namePattern, - offset, - orderBy, - }: { - limit?: number; - namePattern?: string; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseAssetServiceGetAssetAliasesKeyFn({ limit, namePattern, offset, orderBy }, queryKey), - queryFn: () => AssetService.getAssetAliases({ limit, namePattern, offset, orderBy }) as TData, - ...options, - }); +* Get Asset Aliases +* Get asset aliases. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.namePattern +* @param data.orderBy +* @returns AssetAliasCollectionResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetAssetAliasesSuspense = = unknown[]>({ limit, namePattern, offset, orderBy }: { + limit?: number; + namePattern?: string; + offset?: number; + orderBy?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseAssetServiceGetAssetAliasesKeyFn({ limit, namePattern, offset, orderBy }, queryKey), queryFn: () => AssetService.getAssetAliases({ limit, namePattern, offset, orderBy }) as TData, ...options }); /** - * Get Asset Alias - * Get an asset alias. - * @param data The data for the request. - * @param data.assetAliasId - * @returns unknown Successful Response - * @throws ApiError - */ -export const useAssetServiceGetAssetAliasSuspense = < - TData = Common.AssetServiceGetAssetAliasDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - assetAliasId, - }: { - assetAliasId: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseAssetServiceGetAssetAliasKeyFn({ assetAliasId }, queryKey), - queryFn: () => AssetService.getAssetAlias({ assetAliasId }) as TData, - ...options, - }); +* Get Asset Alias +* Get an asset alias. +* @param data The data for the request. +* @param data.assetAliasId +* @returns unknown Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetAssetAliasSuspense = = unknown[]>({ assetAliasId }: { + assetAliasId: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseAssetServiceGetAssetAliasKeyFn({ assetAliasId }, queryKey), queryFn: () => AssetService.getAssetAlias({ assetAliasId }) as TData, ...options }); /** - * Get Asset Events - * Get asset events. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.assetId - * @param data.sourceDagId - * @param data.sourceTaskId - * @param data.sourceRunId - * @param data.sourceMapIndex - * @param data.timestampGte - * @param data.timestampLte - * @returns AssetEventCollectionResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetAssetEventsSuspense = < - TData = Common.AssetServiceGetAssetEventsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - assetId, - limit, - offset, - orderBy, - sourceDagId, - sourceMapIndex, - sourceRunId, - sourceTaskId, - timestampGte, - timestampLte, - }: { - assetId?: number; - limit?: number; - offset?: number; - orderBy?: string; - sourceDagId?: string; - sourceMapIndex?: number; - sourceRunId?: string; - sourceTaskId?: string; - timestampGte?: string; - timestampLte?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseAssetServiceGetAssetEventsKeyFn( - { - assetId, - limit, - offset, - orderBy, - sourceDagId, - sourceMapIndex, - sourceRunId, - sourceTaskId, - timestampGte, - timestampLte, - }, - queryKey, - ), - queryFn: () => - AssetService.getAssetEvents({ - assetId, - limit, - offset, - orderBy, - sourceDagId, - sourceMapIndex, - sourceRunId, - sourceTaskId, - timestampGte, - timestampLte, - }) as TData, - ...options, - }); +* Get Asset Events +* Get asset events. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.assetId +* @param data.sourceDagId +* @param data.sourceTaskId +* @param data.sourceRunId +* @param data.sourceMapIndex +* @param data.timestampGte +* @param data.timestampLte +* @returns AssetEventCollectionResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetAssetEventsSuspense = = unknown[]>({ assetId, limit, offset, orderBy, sourceDagId, sourceMapIndex, sourceRunId, sourceTaskId, timestampGte, timestampLte }: { + assetId?: number; + limit?: number; + offset?: number; + orderBy?: string; + sourceDagId?: string; + sourceMapIndex?: number; + sourceRunId?: string; + sourceTaskId?: string; + timestampGte?: string; + timestampLte?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseAssetServiceGetAssetEventsKeyFn({ assetId, limit, offset, orderBy, sourceDagId, sourceMapIndex, sourceRunId, sourceTaskId, timestampGte, timestampLte }, queryKey), queryFn: () => AssetService.getAssetEvents({ assetId, limit, offset, orderBy, sourceDagId, sourceMapIndex, sourceRunId, sourceTaskId, timestampGte, timestampLte }) as TData, ...options }); /** - * Get Asset Queued Events - * Get queued asset events for an asset. - * @param data The data for the request. - * @param data.assetId - * @param data.before - * @returns QueuedEventCollectionResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetAssetQueuedEventsSuspense = < - TData = Common.AssetServiceGetAssetQueuedEventsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - assetId, - before, - }: { - assetId: number; - before?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseAssetServiceGetAssetQueuedEventsKeyFn({ assetId, before }, queryKey), - queryFn: () => AssetService.getAssetQueuedEvents({ assetId, before }) as TData, - ...options, - }); +* Get Asset Queued Events +* Get queued asset events for an asset. +* @param data The data for the request. +* @param data.assetId +* @param data.before +* @returns QueuedEventCollectionResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetAssetQueuedEventsSuspense = = unknown[]>({ assetId, before }: { + assetId: number; + before?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseAssetServiceGetAssetQueuedEventsKeyFn({ assetId, before }, queryKey), queryFn: () => AssetService.getAssetQueuedEvents({ assetId, before }) as TData, ...options }); /** - * Get Asset - * Get an asset. - * @param data The data for the request. - * @param data.assetId - * @returns AssetResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetAssetSuspense = < - TData = Common.AssetServiceGetAssetDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - assetId, - }: { - assetId: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseAssetServiceGetAssetKeyFn({ assetId }, queryKey), - queryFn: () => AssetService.getAsset({ assetId }) as TData, - ...options, - }); +* Get Asset +* Get an asset. +* @param data The data for the request. +* @param data.assetId +* @returns AssetResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetAssetSuspense = = unknown[]>({ assetId }: { + assetId: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseAssetServiceGetAssetKeyFn({ assetId }, queryKey), queryFn: () => AssetService.getAsset({ assetId }) as TData, ...options }); /** - * Get Dag Asset Queued Events - * Get queued asset events for a DAG. - * @param data The data for the request. - * @param data.dagId - * @param data.before - * @returns QueuedEventCollectionResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetDagAssetQueuedEventsSuspense = < - TData = Common.AssetServiceGetDagAssetQueuedEventsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - before, - dagId, - }: { - before?: string; - dagId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseAssetServiceGetDagAssetQueuedEventsKeyFn({ before, dagId }, queryKey), - queryFn: () => AssetService.getDagAssetQueuedEvents({ before, dagId }) as TData, - ...options, - }); +* Get Dag Asset Queued Events +* Get queued asset events for a DAG. +* @param data The data for the request. +* @param data.dagId +* @param data.before +* @returns QueuedEventCollectionResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetDagAssetQueuedEventsSuspense = = unknown[]>({ before, dagId }: { + before?: string; + dagId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseAssetServiceGetDagAssetQueuedEventsKeyFn({ before, dagId }, queryKey), queryFn: () => AssetService.getDagAssetQueuedEvents({ before, dagId }) as TData, ...options }); /** - * Get Dag Asset Queued Event - * Get a queued asset event for a DAG. - * @param data The data for the request. - * @param data.dagId - * @param data.assetId - * @param data.before - * @returns QueuedEventResponse Successful Response - * @throws ApiError - */ -export const useAssetServiceGetDagAssetQueuedEventSuspense = < - TData = Common.AssetServiceGetDagAssetQueuedEventDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - assetId, - before, - dagId, - }: { - assetId: number; - before?: string; - dagId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseAssetServiceGetDagAssetQueuedEventKeyFn({ assetId, before, dagId }, queryKey), - queryFn: () => AssetService.getDagAssetQueuedEvent({ assetId, before, dagId }) as TData, - ...options, - }); +* Get Dag Asset Queued Event +* Get a queued asset event for a DAG. +* @param data The data for the request. +* @param data.dagId +* @param data.assetId +* @param data.before +* @returns QueuedEventResponse Successful Response +* @throws ApiError +*/ +export const useAssetServiceGetDagAssetQueuedEventSuspense = = unknown[]>({ assetId, before, dagId }: { + assetId: number; + before?: string; + dagId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseAssetServiceGetDagAssetQueuedEventKeyFn({ assetId, before, dagId }, queryKey), queryFn: () => AssetService.getDagAssetQueuedEvent({ assetId, before, dagId }) as TData, ...options }); /** - * Get Configs - * Get configs for UI. - * @returns ConfigResponse Successful Response - * @throws ApiError - */ -export const useConfigServiceGetConfigsSuspense = < - TData = Common.ConfigServiceGetConfigsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseConfigServiceGetConfigsKeyFn(queryKey), - queryFn: () => ConfigService.getConfigs() as TData, - ...options, - }); +* Get Configs +* Get configs for UI. +* @returns ConfigResponse Successful Response +* @throws ApiError +*/ +export const useConfigServiceGetConfigsSuspense = = unknown[]>(queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseConfigServiceGetConfigsKeyFn(queryKey), queryFn: () => ConfigService.getConfigs() as TData, ...options }); /** - * Get Config - * @param data The data for the request. - * @param data.section - * @param data.accept - * @returns Config Successful Response - * @throws ApiError - */ -export const useConfigServiceGetConfigSuspense = < - TData = Common.ConfigServiceGetConfigDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - accept, - section, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - section?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseConfigServiceGetConfigKeyFn({ accept, section }, queryKey), - queryFn: () => ConfigService.getConfig({ accept, section }) as TData, - ...options, - }); +* Get Config +* @param data The data for the request. +* @param data.section +* @param data.accept +* @returns Config Successful Response +* @throws ApiError +*/ +export const useConfigServiceGetConfigSuspense = = unknown[]>({ accept, section }: { + accept?: "application/json" | "text/plain" | "*/*"; + section?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseConfigServiceGetConfigKeyFn({ accept, section }, queryKey), queryFn: () => ConfigService.getConfig({ accept, section }) as TData, ...options }); /** - * Get Config Value - * @param data The data for the request. - * @param data.section - * @param data.option - * @param data.accept - * @returns Config Successful Response - * @throws ApiError - */ -export const useConfigServiceGetConfigValueSuspense = < - TData = Common.ConfigServiceGetConfigValueDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - accept, - option, - section, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - option: string; - section: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseConfigServiceGetConfigValueKeyFn({ accept, option, section }, queryKey), - queryFn: () => ConfigService.getConfigValue({ accept, option, section }) as TData, - ...options, - }); +* Get Config Value +* @param data The data for the request. +* @param data.section +* @param data.option +* @param data.accept +* @returns Config Successful Response +* @throws ApiError +*/ +export const useConfigServiceGetConfigValueSuspense = = unknown[]>({ accept, option, section }: { + accept?: "application/json" | "text/plain" | "*/*"; + option: string; + section: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseConfigServiceGetConfigValueKeyFn({ accept, option, section }, queryKey), queryFn: () => ConfigService.getConfigValue({ accept, option, section }) as TData, ...options }); /** - * Recent Dag Runs - * Get recent DAG runs. - * @param data The data for the request. - * @param data.dagRunsLimit - * @param data.limit - * @param data.offset - * @param data.tags - * @param data.owners - * @param data.dagIds - * @param data.dagIdPattern - * @param data.dagDisplayNamePattern - * @param data.onlyActive - * @param data.paused - * @param data.lastDagRunState - * @returns DAGWithLatestDagRunsCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagsServiceRecentDagRunsSuspense = < - TData = Common.DagsServiceRecentDagRunsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagDisplayNamePattern, - dagIdPattern, - dagIds, - dagRunsLimit, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - tags, - }: { - dagDisplayNamePattern?: string; - dagIdPattern?: string; - dagIds?: string[]; - dagRunsLimit?: number; - lastDagRunState?: DagRunState; - limit?: number; - offset?: number; - onlyActive?: boolean; - owners?: string[]; - paused?: boolean; - tags?: string[]; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseDagsServiceRecentDagRunsKeyFn( - { - dagDisplayNamePattern, - dagIdPattern, - dagIds, - dagRunsLimit, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - tags, - }, - queryKey, - ), - queryFn: () => - DagsService.recentDagRuns({ - dagDisplayNamePattern, - dagIdPattern, - dagIds, - dagRunsLimit, - lastDagRunState, - limit, - offset, - onlyActive, - owners, - paused, - tags, - }) as TData, - ...options, - }); +* Recent Dag Runs +* Get recent DAG runs. +* @param data The data for the request. +* @param data.dagRunsLimit +* @param data.limit +* @param data.offset +* @param data.tags +* @param data.owners +* @param data.dagIds +* @param data.dagIdPattern +* @param data.dagDisplayNamePattern +* @param data.onlyActive +* @param data.paused +* @param data.lastDagRunState +* @returns DAGWithLatestDagRunsCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagsServiceRecentDagRunsSuspense = = unknown[]>({ dagDisplayNamePattern, dagIdPattern, dagIds, dagRunsLimit, lastDagRunState, limit, offset, onlyActive, owners, paused, tags }: { + dagDisplayNamePattern?: string; + dagIdPattern?: string; + dagIds?: string[]; + dagRunsLimit?: number; + lastDagRunState?: DagRunState; + limit?: number; + offset?: number; + onlyActive?: boolean; + owners?: string[]; + paused?: boolean; + tags?: string[]; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseDagsServiceRecentDagRunsKeyFn({ dagDisplayNamePattern, dagIdPattern, dagIds, dagRunsLimit, lastDagRunState, limit, offset, onlyActive, owners, paused, tags }, queryKey), queryFn: () => DagsService.recentDagRuns({ dagDisplayNamePattern, dagIdPattern, dagIds, dagRunsLimit, lastDagRunState, limit, offset, onlyActive, owners, paused, tags }) as TData, ...options }); /** - * Historical Metrics - * Return cluster activity historical metrics. - * @param data The data for the request. - * @param data.startDate - * @param data.endDate - * @returns HistoricalMetricDataResponse Successful Response - * @throws ApiError - */ -export const useDashboardServiceHistoricalMetricsSuspense = < - TData = Common.DashboardServiceHistoricalMetricsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - endDate, - startDate, - }: { - endDate?: string; - startDate: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseDashboardServiceHistoricalMetricsKeyFn({ endDate, startDate }, queryKey), - queryFn: () => DashboardService.historicalMetrics({ endDate, startDate }) as TData, - ...options, - }); +* Historical Metrics +* Return cluster activity historical metrics. +* @param data The data for the request. +* @param data.startDate +* @param data.endDate +* @returns HistoricalMetricDataResponse Successful Response +* @throws ApiError +*/ +export const useDashboardServiceHistoricalMetricsSuspense = = unknown[]>({ endDate, startDate }: { + endDate?: string; + startDate: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseDashboardServiceHistoricalMetricsKeyFn({ endDate, startDate }, queryKey), queryFn: () => DashboardService.historicalMetrics({ endDate, startDate }) as TData, ...options }); /** - * Structure Data - * Get Structure Data. - * @param data The data for the request. - * @param data.dagId - * @param data.includeUpstream - * @param data.includeDownstream - * @param data.root - * @param data.externalDependencies - * @returns StructureDataResponse Successful Response - * @throws ApiError - */ -export const useStructureServiceStructureDataSuspense = < - TData = Common.StructureServiceStructureDataDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - externalDependencies, - includeDownstream, - includeUpstream, - root, - }: { - dagId: string; - externalDependencies?: boolean; - includeDownstream?: boolean; - includeUpstream?: boolean; - root?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseStructureServiceStructureDataKeyFn( - { dagId, externalDependencies, includeDownstream, includeUpstream, root }, - queryKey, - ), - queryFn: () => - StructureService.structureData({ - dagId, - externalDependencies, - includeDownstream, - includeUpstream, - root, - }) as TData, - ...options, - }); +* Structure Data +* Get Structure Data. +* @param data The data for the request. +* @param data.dagId +* @param data.includeUpstream +* @param data.includeDownstream +* @param data.root +* @param data.externalDependencies +* @returns StructureDataResponse Successful Response +* @throws ApiError +*/ +export const useStructureServiceStructureDataSuspense = = unknown[]>({ dagId, externalDependencies, includeDownstream, includeUpstream, root }: { + dagId: string; + externalDependencies?: boolean; + includeDownstream?: boolean; + includeUpstream?: boolean; + root?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseStructureServiceStructureDataKeyFn({ dagId, externalDependencies, includeDownstream, includeUpstream, root }, queryKey), queryFn: () => StructureService.structureData({ dagId, externalDependencies, includeDownstream, includeUpstream, root }) as TData, ...options }); /** - * List Backfills - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.dagId - * @param data.active - * @returns BackfillCollectionResponse Successful Response - * @throws ApiError - */ -export const useBackfillServiceListBackfillsSuspense = < - TData = Common.BackfillServiceListBackfillsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - active, - dagId, - limit, - offset, - orderBy, - }: { - active?: boolean; - dagId?: string; - limit?: number; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseBackfillServiceListBackfillsKeyFn( - { active, dagId, limit, offset, orderBy }, - queryKey, - ), - queryFn: () => BackfillService.listBackfills({ active, dagId, limit, offset, orderBy }) as TData, - ...options, - }); +* List Backfills +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.dagId +* @param data.active +* @returns BackfillCollectionResponse Successful Response +* @throws ApiError +*/ +export const useBackfillServiceListBackfillsSuspense = = unknown[]>({ active, dagId, limit, offset, orderBy }: { + active?: boolean; + dagId?: string; + limit?: number; + offset?: number; + orderBy?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseBackfillServiceListBackfillsKeyFn({ active, dagId, limit, offset, orderBy }, queryKey), queryFn: () => BackfillService.listBackfills({ active, dagId, limit, offset, orderBy }) as TData, ...options }); /** - * List Backfills - * @param data The data for the request. - * @param data.dagId - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns BackfillCollectionResponse Successful Response - * @throws ApiError - */ -export const useBackfillServiceListBackfills1Suspense = < - TData = Common.BackfillServiceListBackfills1DefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - limit, - offset, - orderBy, - }: { - dagId: string; - limit?: number; - offset?: number; - orderBy?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseBackfillServiceListBackfills1KeyFn({ dagId, limit, offset, orderBy }, queryKey), - queryFn: () => BackfillService.listBackfills1({ dagId, limit, offset, orderBy }) as TData, - ...options, - }); +* List Backfills +* @param data The data for the request. +* @param data.dagId +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns BackfillCollectionResponse Successful Response +* @throws ApiError +*/ +export const useBackfillServiceListBackfills1Suspense = = unknown[]>({ dagId, limit, offset, orderBy }: { + dagId: string; + limit?: number; + offset?: number; + orderBy?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseBackfillServiceListBackfills1KeyFn({ dagId, limit, offset, orderBy }, queryKey), queryFn: () => BackfillService.listBackfills1({ dagId, limit, offset, orderBy }) as TData, ...options }); /** - * Get Backfill - * @param data The data for the request. - * @param data.backfillId - * @returns BackfillResponse Successful Response - * @throws ApiError - */ -export const useBackfillServiceGetBackfillSuspense = < - TData = Common.BackfillServiceGetBackfillDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - backfillId, - }: { - backfillId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseBackfillServiceGetBackfillKeyFn({ backfillId }, queryKey), - queryFn: () => BackfillService.getBackfill({ backfillId }) as TData, - ...options, - }); +* Get Backfill +* @param data The data for the request. +* @param data.backfillId +* @returns BackfillResponse Successful Response +* @throws ApiError +*/ +export const useBackfillServiceGetBackfillSuspense = = unknown[]>({ backfillId }: { + backfillId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseBackfillServiceGetBackfillKeyFn({ backfillId }, queryKey), queryFn: () => BackfillService.getBackfill({ backfillId }) as TData, ...options }); /** - * Grid Data - * Return grid data. - * @param data The data for the request. - * @param data.dagId - * @param data.includeUpstream - * @param data.includeDownstream - * @param data.logicalDateGte - * @param data.logicalDateLte - * @param data.root - * @param data.offset - * @param data.runType - * @param data.state - * @param data.limit - * @param data.orderBy - * @returns GridResponse Successful Response - * @throws ApiError - */ -export const useGridServiceGridDataSuspense = < - TData = Common.GridServiceGridDataDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - includeDownstream, - includeUpstream, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - root, - runType, - state, - }: { - dagId: string; - includeDownstream?: boolean; - includeUpstream?: boolean; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - root?: string; - runType?: string[]; - state?: string[]; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseGridServiceGridDataKeyFn( - { - dagId, - includeDownstream, - includeUpstream, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - root, - runType, - state, - }, - queryKey, - ), - queryFn: () => - GridService.gridData({ - dagId, - includeDownstream, - includeUpstream, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - root, - runType, - state, - }) as TData, - ...options, - }); +* Grid Data +* Return grid data. +* @param data The data for the request. +* @param data.dagId +* @param data.includeUpstream +* @param data.includeDownstream +* @param data.logicalDateGte +* @param data.logicalDateLte +* @param data.root +* @param data.offset +* @param data.runType +* @param data.state +* @param data.limit +* @param data.orderBy +* @returns GridResponse Successful Response +* @throws ApiError +*/ +export const useGridServiceGridDataSuspense = = unknown[]>({ dagId, includeDownstream, includeUpstream, limit, logicalDateGte, logicalDateLte, offset, orderBy, root, runType, state }: { + dagId: string; + includeDownstream?: boolean; + includeUpstream?: boolean; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + root?: string; + runType?: string[]; + state?: string[]; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseGridServiceGridDataKeyFn({ dagId, includeDownstream, includeUpstream, limit, logicalDateGte, logicalDateLte, offset, orderBy, root, runType, state }, queryKey), queryFn: () => GridService.gridData({ dagId, includeDownstream, includeUpstream, limit, logicalDateGte, logicalDateLte, offset, orderBy, root, runType, state }) as TData, ...options }); /** - * Get Connection - * Get a connection entry. - * @param data The data for the request. - * @param data.connectionId - * @returns ConnectionResponse Successful Response - * @throws ApiError - */ -export const useConnectionServiceGetConnectionSuspense = < - TData = Common.ConnectionServiceGetConnectionDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - connectionId, - }: { - connectionId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseConnectionServiceGetConnectionKeyFn({ connectionId }, queryKey), - queryFn: () => ConnectionService.getConnection({ connectionId }) as TData, - ...options, - }); +* Get Connection +* Get a connection entry. +* @param data The data for the request. +* @param data.connectionId +* @returns ConnectionResponse Successful Response +* @throws ApiError +*/ +export const useConnectionServiceGetConnectionSuspense = = unknown[]>({ connectionId }: { + connectionId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseConnectionServiceGetConnectionKeyFn({ connectionId }, queryKey), queryFn: () => ConnectionService.getConnection({ connectionId }) as TData, ...options }); /** - * Get Connections - * Get all connection entries. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns ConnectionCollectionResponse Successful Response - * @throws ApiError - */ -export const useConnectionServiceGetConnectionsSuspense = < - TData = Common.ConnectionServiceGetConnectionsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - orderBy, - }: { - limit?: number; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseConnectionServiceGetConnectionsKeyFn({ limit, offset, orderBy }, queryKey), - queryFn: () => ConnectionService.getConnections({ limit, offset, orderBy }) as TData, - ...options, - }); +* Get Connections +* Get all connection entries. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns ConnectionCollectionResponse Successful Response +* @throws ApiError +*/ +export const useConnectionServiceGetConnectionsSuspense = = unknown[]>({ limit, offset, orderBy }: { + limit?: number; + offset?: number; + orderBy?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseConnectionServiceGetConnectionsKeyFn({ limit, offset, orderBy }, queryKey), queryFn: () => ConnectionService.getConnections({ limit, offset, orderBy }) as TData, ...options }); /** - * Get Dag Run - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @returns DAGRunResponse Successful Response - * @throws ApiError - */ -export const useDagRunServiceGetDagRunSuspense = < - TData = Common.DagRunServiceGetDagRunDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - }: { - dagId: string; - dagRunId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseDagRunServiceGetDagRunKeyFn({ dagId, dagRunId }, queryKey), - queryFn: () => DagRunService.getDagRun({ dagId, dagRunId }) as TData, - ...options, - }); +* Get Dag Run +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @returns DAGRunResponse Successful Response +* @throws ApiError +*/ +export const useDagRunServiceGetDagRunSuspense = = unknown[]>({ dagId, dagRunId }: { + dagId: string; + dagRunId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseDagRunServiceGetDagRunKeyFn({ dagId, dagRunId }, queryKey), queryFn: () => DagRunService.getDagRun({ dagId, dagRunId }) as TData, ...options }); /** - * Get Upstream Asset Events - * If dag run is asset-triggered, return the asset events that triggered it. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @returns AssetEventCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagRunServiceGetUpstreamAssetEventsSuspense = < - TData = Common.DagRunServiceGetUpstreamAssetEventsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - }: { - dagId: string; - dagRunId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseDagRunServiceGetUpstreamAssetEventsKeyFn({ dagId, dagRunId }, queryKey), - queryFn: () => DagRunService.getUpstreamAssetEvents({ dagId, dagRunId }) as TData, - ...options, - }); +* Get Upstream Asset Events +* If dag run is asset-triggered, return the asset events that triggered it. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @returns AssetEventCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagRunServiceGetUpstreamAssetEventsSuspense = = unknown[]>({ dagId, dagRunId }: { + dagId: string; + dagRunId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseDagRunServiceGetUpstreamAssetEventsKeyFn({ dagId, dagRunId }, queryKey), queryFn: () => DagRunService.getUpstreamAssetEvents({ dagId, dagRunId }) as TData, ...options }); /** - * Get Dag Runs - * Get all DAG Runs. - * - * This endpoint allows specifying `~` as the dag_id to retrieve Dag Runs for all DAGs. - * @param data The data for the request. - * @param data.dagId - * @param data.limit - * @param data.offset - * @param data.logicalDateGte - * @param data.logicalDateLte - * @param data.startDateGte - * @param data.startDateLte - * @param data.endDateGte - * @param data.endDateLte - * @param data.updatedAtGte - * @param data.updatedAtLte - * @param data.state - * @param data.orderBy - * @returns DAGRunCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagRunServiceGetDagRunsSuspense = < - TData = Common.DagRunServiceGetDagRunsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - endDateGte, - endDateLte, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - startDateGte, - startDateLte, - state, - updatedAtGte, - updatedAtLte, - }: { - dagId: string; - endDateGte?: string; - endDateLte?: string; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - startDateGte?: string; - startDateLte?: string; - state?: string[]; - updatedAtGte?: string; - updatedAtLte?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseDagRunServiceGetDagRunsKeyFn( - { - dagId, - endDateGte, - endDateLte, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - startDateGte, - startDateLte, - state, - updatedAtGte, - updatedAtLte, - }, - queryKey, - ), - queryFn: () => - DagRunService.getDagRuns({ - dagId, - endDateGte, - endDateLte, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - startDateGte, - startDateLte, - state, - updatedAtGte, - updatedAtLte, - }) as TData, - ...options, - }); +* Get Dag Runs +* Get all DAG Runs. +* +* This endpoint allows specifying `~` as the dag_id to retrieve Dag Runs for all DAGs. +* @param data The data for the request. +* @param data.dagId +* @param data.limit +* @param data.offset +* @param data.logicalDateGte +* @param data.logicalDateLte +* @param data.startDateGte +* @param data.startDateLte +* @param data.endDateGte +* @param data.endDateLte +* @param data.updatedAtGte +* @param data.updatedAtLte +* @param data.state +* @param data.orderBy +* @returns DAGRunCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagRunServiceGetDagRunsSuspense = = unknown[]>({ dagId, endDateGte, endDateLte, limit, logicalDateGte, logicalDateLte, offset, orderBy, startDateGte, startDateLte, state, updatedAtGte, updatedAtLte }: { + dagId: string; + endDateGte?: string; + endDateLte?: string; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + startDateGte?: string; + startDateLte?: string; + state?: string[]; + updatedAtGte?: string; + updatedAtLte?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseDagRunServiceGetDagRunsKeyFn({ dagId, endDateGte, endDateLte, limit, logicalDateGte, logicalDateLte, offset, orderBy, startDateGte, startDateLte, state, updatedAtGte, updatedAtLte }, queryKey), queryFn: () => DagRunService.getDagRuns({ dagId, endDateGte, endDateLte, limit, logicalDateGte, logicalDateLte, offset, orderBy, startDateGte, startDateLte, state, updatedAtGte, updatedAtLte }) as TData, ...options }); /** - * Get Dag Source - * Get source code using file token. - * @param data The data for the request. - * @param data.dagId - * @param data.versionNumber - * @param data.accept - * @returns DAGSourceResponse Successful Response - * @throws ApiError - */ -export const useDagSourceServiceGetDagSourceSuspense = < - TData = Common.DagSourceServiceGetDagSourceDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - accept, - dagId, - versionNumber, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - dagId: string; - versionNumber?: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseDagSourceServiceGetDagSourceKeyFn({ accept, dagId, versionNumber }, queryKey), - queryFn: () => DagSourceService.getDagSource({ accept, dagId, versionNumber }) as TData, - ...options, - }); +* Get Dag Source +* Get source code using file token. +* @param data The data for the request. +* @param data.dagId +* @param data.versionNumber +* @param data.accept +* @returns DAGSourceResponse Successful Response +* @throws ApiError +*/ +export const useDagSourceServiceGetDagSourceSuspense = = unknown[]>({ accept, dagId, versionNumber }: { + accept?: "application/json" | "text/plain" | "*/*"; + dagId: string; + versionNumber?: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseDagSourceServiceGetDagSourceKeyFn({ accept, dagId, versionNumber }, queryKey), queryFn: () => DagSourceService.getDagSource({ accept, dagId, versionNumber }) as TData, ...options }); /** - * Get Dag Stats - * Get Dag statistics. - * @param data The data for the request. - * @param data.dagIds - * @returns DagStatsCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagStatsServiceGetDagStatsSuspense = < - TData = Common.DagStatsServiceGetDagStatsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagIds, - }: { - dagIds?: string[]; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseDagStatsServiceGetDagStatsKeyFn({ dagIds }, queryKey), - queryFn: () => DagStatsService.getDagStats({ dagIds }) as TData, - ...options, - }); +* Get Dag Stats +* Get Dag statistics. +* @param data The data for the request. +* @param data.dagIds +* @returns DagStatsCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagStatsServiceGetDagStatsSuspense = = unknown[]>({ dagIds }: { + dagIds?: string[]; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseDagStatsServiceGetDagStatsKeyFn({ dagIds }, queryKey), queryFn: () => DagStatsService.getDagStats({ dagIds }) as TData, ...options }); /** - * List Dag Warnings - * Get a list of DAG warnings. - * @param data The data for the request. - * @param data.dagId - * @param data.warningType - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns DAGWarningCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagWarningServiceListDagWarningsSuspense = < - TData = Common.DagWarningServiceListDagWarningsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - limit, - offset, - orderBy, - warningType, - }: { - dagId?: string; - limit?: number; - offset?: number; - orderBy?: string; - warningType?: DagWarningType; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseDagWarningServiceListDagWarningsKeyFn( - { dagId, limit, offset, orderBy, warningType }, - queryKey, - ), - queryFn: () => DagWarningService.listDagWarnings({ dagId, limit, offset, orderBy, warningType }) as TData, - ...options, - }); +* List Dag Warnings +* Get a list of DAG warnings. +* @param data The data for the request. +* @param data.dagId +* @param data.warningType +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns DAGWarningCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagWarningServiceListDagWarningsSuspense = = unknown[]>({ dagId, limit, offset, orderBy, warningType }: { + dagId?: string; + limit?: number; + offset?: number; + orderBy?: string; + warningType?: DagWarningType; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseDagWarningServiceListDagWarningsKeyFn({ dagId, limit, offset, orderBy, warningType }, queryKey), queryFn: () => DagWarningService.listDagWarnings({ dagId, limit, offset, orderBy, warningType }) as TData, ...options }); /** - * Get Dags - * Get all DAGs. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.tags - * @param data.owners - * @param data.dagIdPattern - * @param data.dagDisplayNamePattern - * @param data.onlyActive - * @param data.paused - * @param data.lastDagRunState - * @param data.orderBy - * @returns DAGCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagServiceGetDagsSuspense = < - TData = Common.DagServiceGetDagsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagDisplayNamePattern, - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - orderBy, - owners, - paused, - tags, - }: { - dagDisplayNamePattern?: string; - dagIdPattern?: string; - lastDagRunState?: DagRunState; - limit?: number; - offset?: number; - onlyActive?: boolean; - orderBy?: string; - owners?: string[]; - paused?: boolean; - tags?: string[]; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseDagServiceGetDagsKeyFn( - { - dagDisplayNamePattern, - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - orderBy, - owners, - paused, - tags, - }, - queryKey, - ), - queryFn: () => - DagService.getDags({ - dagDisplayNamePattern, - dagIdPattern, - lastDagRunState, - limit, - offset, - onlyActive, - orderBy, - owners, - paused, - tags, - }) as TData, - ...options, - }); +* Get Dags +* Get all DAGs. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.tags +* @param data.owners +* @param data.dagIdPattern +* @param data.dagDisplayNamePattern +* @param data.onlyActive +* @param data.paused +* @param data.lastDagRunState +* @param data.orderBy +* @returns DAGCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagServiceGetDagsSuspense = = unknown[]>({ dagDisplayNamePattern, dagIdPattern, lastDagRunState, limit, offset, onlyActive, orderBy, owners, paused, tags }: { + dagDisplayNamePattern?: string; + dagIdPattern?: string; + lastDagRunState?: DagRunState; + limit?: number; + offset?: number; + onlyActive?: boolean; + orderBy?: string; + owners?: string[]; + paused?: boolean; + tags?: string[]; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseDagServiceGetDagsKeyFn({ dagDisplayNamePattern, dagIdPattern, lastDagRunState, limit, offset, onlyActive, orderBy, owners, paused, tags }, queryKey), queryFn: () => DagService.getDags({ dagDisplayNamePattern, dagIdPattern, lastDagRunState, limit, offset, onlyActive, orderBy, owners, paused, tags }) as TData, ...options }); /** - * Get Dag - * Get basic information about a DAG. - * @param data The data for the request. - * @param data.dagId - * @returns DAGResponse Successful Response - * @throws ApiError - */ -export const useDagServiceGetDagSuspense = < - TData = Common.DagServiceGetDagDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - }: { - dagId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseDagServiceGetDagKeyFn({ dagId }, queryKey), - queryFn: () => DagService.getDag({ dagId }) as TData, - ...options, - }); +* Get Dag +* Get basic information about a DAG. +* @param data The data for the request. +* @param data.dagId +* @returns DAGResponse Successful Response +* @throws ApiError +*/ +export const useDagServiceGetDagSuspense = = unknown[]>({ dagId }: { + dagId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseDagServiceGetDagKeyFn({ dagId }, queryKey), queryFn: () => DagService.getDag({ dagId }) as TData, ...options }); /** - * Get Dag Details - * Get details of DAG. - * @param data The data for the request. - * @param data.dagId - * @returns DAGDetailsResponse Successful Response - * @throws ApiError - */ -export const useDagServiceGetDagDetailsSuspense = < - TData = Common.DagServiceGetDagDetailsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - }: { - dagId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseDagServiceGetDagDetailsKeyFn({ dagId }, queryKey), - queryFn: () => DagService.getDagDetails({ dagId }) as TData, - ...options, - }); +* Get Dag Details +* Get details of DAG. +* @param data The data for the request. +* @param data.dagId +* @returns DAGDetailsResponse Successful Response +* @throws ApiError +*/ +export const useDagServiceGetDagDetailsSuspense = = unknown[]>({ dagId }: { + dagId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseDagServiceGetDagDetailsKeyFn({ dagId }, queryKey), queryFn: () => DagService.getDagDetails({ dagId }) as TData, ...options }); /** - * Get Dag Tags - * Get all DAG tags. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.tagNamePattern - * @returns DAGTagCollectionResponse Successful Response - * @throws ApiError - */ -export const useDagServiceGetDagTagsSuspense = < - TData = Common.DagServiceGetDagTagsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - orderBy, - tagNamePattern, - }: { - limit?: number; - offset?: number; - orderBy?: string; - tagNamePattern?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseDagServiceGetDagTagsKeyFn({ limit, offset, orderBy, tagNamePattern }, queryKey), - queryFn: () => DagService.getDagTags({ limit, offset, orderBy, tagNamePattern }) as TData, - ...options, - }); +* Get Dag Tags +* Get all DAG tags. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.tagNamePattern +* @returns DAGTagCollectionResponse Successful Response +* @throws ApiError +*/ +export const useDagServiceGetDagTagsSuspense = = unknown[]>({ limit, offset, orderBy, tagNamePattern }: { + limit?: number; + offset?: number; + orderBy?: string; + tagNamePattern?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseDagServiceGetDagTagsKeyFn({ limit, offset, orderBy, tagNamePattern }, queryKey), queryFn: () => DagService.getDagTags({ limit, offset, orderBy, tagNamePattern }) as TData, ...options }); /** - * Get Event Log - * @param data The data for the request. - * @param data.eventLogId - * @returns EventLogResponse Successful Response - * @throws ApiError - */ -export const useEventLogServiceGetEventLogSuspense = < - TData = Common.EventLogServiceGetEventLogDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - eventLogId, - }: { - eventLogId: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseEventLogServiceGetEventLogKeyFn({ eventLogId }, queryKey), - queryFn: () => EventLogService.getEventLog({ eventLogId }) as TData, - ...options, - }); +* Get Event Log +* @param data The data for the request. +* @param data.eventLogId +* @returns EventLogResponse Successful Response +* @throws ApiError +*/ +export const useEventLogServiceGetEventLogSuspense = = unknown[]>({ eventLogId }: { + eventLogId: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseEventLogServiceGetEventLogKeyFn({ eventLogId }, queryKey), queryFn: () => EventLogService.getEventLog({ eventLogId }) as TData, ...options }); /** - * Get Event Logs - * Get all Event Logs. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.dagId - * @param data.taskId - * @param data.runId - * @param data.mapIndex - * @param data.tryNumber - * @param data.owner - * @param data.event - * @param data.excludedEvents - * @param data.includedEvents - * @param data.before - * @param data.after - * @returns EventLogCollectionResponse Successful Response - * @throws ApiError - */ -export const useEventLogServiceGetEventLogsSuspense = < - TData = Common.EventLogServiceGetEventLogsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - after, - before, - dagId, - event, - excludedEvents, - includedEvents, - limit, - mapIndex, - offset, - orderBy, - owner, - runId, - taskId, - tryNumber, - }: { - after?: string; - before?: string; - dagId?: string; - event?: string; - excludedEvents?: string[]; - includedEvents?: string[]; - limit?: number; - mapIndex?: number; - offset?: number; - orderBy?: string; - owner?: string; - runId?: string; - taskId?: string; - tryNumber?: number; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseEventLogServiceGetEventLogsKeyFn( - { - after, - before, - dagId, - event, - excludedEvents, - includedEvents, - limit, - mapIndex, - offset, - orderBy, - owner, - runId, - taskId, - tryNumber, - }, - queryKey, - ), - queryFn: () => - EventLogService.getEventLogs({ - after, - before, - dagId, - event, - excludedEvents, - includedEvents, - limit, - mapIndex, - offset, - orderBy, - owner, - runId, - taskId, - tryNumber, - }) as TData, - ...options, - }); +* Get Event Logs +* Get all Event Logs. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.dagId +* @param data.taskId +* @param data.runId +* @param data.mapIndex +* @param data.tryNumber +* @param data.owner +* @param data.event +* @param data.excludedEvents +* @param data.includedEvents +* @param data.before +* @param data.after +* @returns EventLogCollectionResponse Successful Response +* @throws ApiError +*/ +export const useEventLogServiceGetEventLogsSuspense = = unknown[]>({ after, before, dagId, event, excludedEvents, includedEvents, limit, mapIndex, offset, orderBy, owner, runId, taskId, tryNumber }: { + after?: string; + before?: string; + dagId?: string; + event?: string; + excludedEvents?: string[]; + includedEvents?: string[]; + limit?: number; + mapIndex?: number; + offset?: number; + orderBy?: string; + owner?: string; + runId?: string; + taskId?: string; + tryNumber?: number; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseEventLogServiceGetEventLogsKeyFn({ after, before, dagId, event, excludedEvents, includedEvents, limit, mapIndex, offset, orderBy, owner, runId, taskId, tryNumber }, queryKey), queryFn: () => EventLogService.getEventLogs({ after, before, dagId, event, excludedEvents, includedEvents, limit, mapIndex, offset, orderBy, owner, runId, taskId, tryNumber }) as TData, ...options }); /** - * Get Extra Links - * Get extra links for task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @returns ExtraLinksResponse Successful Response - * @throws ApiError - */ -export const useExtraLinksServiceGetExtraLinksSuspense = < - TData = Common.ExtraLinksServiceGetExtraLinksDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - taskId, - }: { - dagId: string; - dagRunId: string; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseExtraLinksServiceGetExtraLinksKeyFn({ dagId, dagRunId, taskId }, queryKey), - queryFn: () => ExtraLinksService.getExtraLinks({ dagId, dagRunId, taskId }) as TData, - ...options, - }); +* Get Extra Links +* Get extra links for task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @returns ExtraLinksResponse Successful Response +* @throws ApiError +*/ +export const useExtraLinksServiceGetExtraLinksSuspense = = unknown[]>({ dagId, dagRunId, taskId }: { + dagId: string; + dagRunId: string; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseExtraLinksServiceGetExtraLinksKeyFn({ dagId, dagRunId, taskId }, queryKey), queryFn: () => ExtraLinksService.getExtraLinks({ dagId, dagRunId, taskId }) as TData, ...options }); /** - * Get Extra Links - * Get extra links for task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @returns ExtraLinksResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetExtraLinksSuspense = < - TData = Common.TaskInstanceServiceGetExtraLinksDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - taskId, - }: { - dagId: string; - dagRunId: string; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskInstanceServiceGetExtraLinksKeyFn({ dagId, dagRunId, taskId }, queryKey), - queryFn: () => TaskInstanceService.getExtraLinks({ dagId, dagRunId, taskId }) as TData, - ...options, - }); +* Get Extra Links +* Get extra links for task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @returns ExtraLinksResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetExtraLinksSuspense = = unknown[]>({ dagId, dagRunId, taskId }: { + dagId: string; + dagRunId: string; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskInstanceServiceGetExtraLinksKeyFn({ dagId, dagRunId, taskId }, queryKey), queryFn: () => TaskInstanceService.getExtraLinks({ dagId, dagRunId, taskId }) as TData, ...options }); /** - * Get Task Instance - * Get task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @returns TaskInstanceResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstanceSuspense = < - TData = Common.TaskInstanceServiceGetTaskInstanceDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - taskId, - }: { - dagId: string; - dagRunId: string; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceKeyFn({ dagId, dagRunId, taskId }, queryKey), - queryFn: () => TaskInstanceService.getTaskInstance({ dagId, dagRunId, taskId }) as TData, - ...options, - }); +* Get Task Instance +* Get task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @returns TaskInstanceResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstanceSuspense = = unknown[]>({ dagId, dagRunId, taskId }: { + dagId: string; + dagRunId: string; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceKeyFn({ dagId, dagRunId, taskId }, queryKey), queryFn: () => TaskInstanceService.getTaskInstance({ dagId, dagRunId, taskId }) as TData, ...options }); /** - * Get Mapped Task Instances - * Get list of mapped task instances. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.logicalDateGte - * @param data.logicalDateLte - * @param data.startDateGte - * @param data.startDateLte - * @param data.endDateGte - * @param data.endDateLte - * @param data.updatedAtGte - * @param data.updatedAtLte - * @param data.durationGte - * @param data.durationLte - * @param data.state - * @param data.pool - * @param data.queue - * @param data.executor - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns TaskInstanceCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetMappedTaskInstancesSuspense = < - TData = Common.TaskInstanceServiceGetMappedTaskInstancesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskId, - updatedAtGte, - updatedAtLte, - }: { - dagId: string; - dagRunId: string; - durationGte?: number; - durationLte?: number; - endDateGte?: string; - endDateLte?: string; - executor?: string[]; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - pool?: string[]; - queue?: string[]; - startDateGte?: string; - startDateLte?: string; - state?: string[]; - taskId: string; - updatedAtGte?: string; - updatedAtLte?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstancesKeyFn( - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskId, - updatedAtGte, - updatedAtLte, - }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getMappedTaskInstances({ - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskId, - updatedAtGte, - updatedAtLte, - }) as TData, - ...options, - }); +* Get Mapped Task Instances +* Get list of mapped task instances. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.logicalDateGte +* @param data.logicalDateLte +* @param data.startDateGte +* @param data.startDateLte +* @param data.endDateGte +* @param data.endDateLte +* @param data.updatedAtGte +* @param data.updatedAtLte +* @param data.durationGte +* @param data.durationLte +* @param data.state +* @param data.pool +* @param data.queue +* @param data.executor +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns TaskInstanceCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetMappedTaskInstancesSuspense = = unknown[]>({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskId, updatedAtGte, updatedAtLte }: { + dagId: string; + dagRunId: string; + durationGte?: number; + durationLte?: number; + endDateGte?: string; + endDateLte?: string; + executor?: string[]; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + pool?: string[]; + queue?: string[]; + startDateGte?: string; + startDateLte?: string; + state?: string[]; + taskId: string; + updatedAtGte?: string; + updatedAtLte?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstancesKeyFn({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskId, updatedAtGte, updatedAtLte }, queryKey), queryFn: () => TaskInstanceService.getMappedTaskInstances({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskId, updatedAtGte, updatedAtLte }) as TData, ...options }); /** - * Get Task Instance Dependencies - * Get dependencies blocking task from getting scheduled. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskDependencyCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstanceDependenciesSuspense = < - TData = Common.TaskInstanceServiceGetTaskInstanceDependenciesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceDependenciesKeyFn( - { dagId, dagRunId, mapIndex, taskId }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getTaskInstanceDependencies({ dagId, dagRunId, mapIndex, taskId }) as TData, - ...options, - }); +* Get Task Instance Dependencies +* Get dependencies blocking task from getting scheduled. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskDependencyCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstanceDependenciesSuspense = = unknown[]>({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceDependenciesKeyFn({ dagId, dagRunId, mapIndex, taskId }, queryKey), queryFn: () => TaskInstanceService.getTaskInstanceDependencies({ dagId, dagRunId, mapIndex, taskId }) as TData, ...options }); /** - * Get Task Instance Dependencies - * Get dependencies blocking task from getting scheduled. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskDependencyCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstanceDependencies1Suspense = < - TData = Common.TaskInstanceServiceGetTaskInstanceDependencies1DefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex?: number; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceDependencies1KeyFn( - { dagId, dagRunId, mapIndex, taskId }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getTaskInstanceDependencies1({ dagId, dagRunId, mapIndex, taskId }) as TData, - ...options, - }); +* Get Task Instance Dependencies +* Get dependencies blocking task from getting scheduled. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskDependencyCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstanceDependencies1Suspense = = unknown[]>({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex?: number; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceDependencies1KeyFn({ dagId, dagRunId, mapIndex, taskId }, queryKey), queryFn: () => TaskInstanceService.getTaskInstanceDependencies1({ dagId, dagRunId, mapIndex, taskId }) as TData, ...options }); /** - * Get Task Instance Tries - * Get list of task instances history. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskInstanceHistoryCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstanceTriesSuspense = < - TData = Common.TaskInstanceServiceGetTaskInstanceTriesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex?: number; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceTriesKeyFn( - { dagId, dagRunId, mapIndex, taskId }, - queryKey, - ), - queryFn: () => TaskInstanceService.getTaskInstanceTries({ dagId, dagRunId, mapIndex, taskId }) as TData, - ...options, - }); +* Get Task Instance Tries +* Get list of task instances history. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskInstanceHistoryCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstanceTriesSuspense = = unknown[]>({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex?: number; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceTriesKeyFn({ dagId, dagRunId, mapIndex, taskId }, queryKey), queryFn: () => TaskInstanceService.getTaskInstanceTries({ dagId, dagRunId, mapIndex, taskId }) as TData, ...options }); /** - * Get Mapped Task Instance Tries - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskInstanceHistoryCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetMappedTaskInstanceTriesSuspense = < - TData = Common.TaskInstanceServiceGetMappedTaskInstanceTriesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceTriesKeyFn( - { dagId, dagRunId, mapIndex, taskId }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getMappedTaskInstanceTries({ dagId, dagRunId, mapIndex, taskId }) as TData, - ...options, - }); +* Get Mapped Task Instance Tries +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskInstanceHistoryCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetMappedTaskInstanceTriesSuspense = = unknown[]>({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceTriesKeyFn({ dagId, dagRunId, mapIndex, taskId }, queryKey), queryFn: () => TaskInstanceService.getMappedTaskInstanceTries({ dagId, dagRunId, mapIndex, taskId }) as TData, ...options }); /** - * Get Mapped Task Instance - * Get task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.mapIndex - * @returns TaskInstanceResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetMappedTaskInstanceSuspense = < - TData = Common.TaskInstanceServiceGetMappedTaskInstanceDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceKeyFn( - { dagId, dagRunId, mapIndex, taskId }, - queryKey, - ), - queryFn: () => TaskInstanceService.getMappedTaskInstance({ dagId, dagRunId, mapIndex, taskId }) as TData, - ...options, - }); +* Get Mapped Task Instance +* Get task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.mapIndex +* @returns TaskInstanceResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetMappedTaskInstanceSuspense = = unknown[]>({ dagId, dagRunId, mapIndex, taskId }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceKeyFn({ dagId, dagRunId, mapIndex, taskId }, queryKey), queryFn: () => TaskInstanceService.getMappedTaskInstance({ dagId, dagRunId, mapIndex, taskId }) as TData, ...options }); /** - * Get Task Instances - * Get list of task instances. - * - * This endpoint allows specifying `~` as the dag_id, dag_run_id to retrieve Task Instances for all DAGs - * and DAG runs. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.logicalDateGte - * @param data.logicalDateLte - * @param data.startDateGte - * @param data.startDateLte - * @param data.endDateGte - * @param data.endDateLte - * @param data.updatedAtGte - * @param data.updatedAtLte - * @param data.durationGte - * @param data.durationLte - * @param data.taskDisplayNamePattern - * @param data.state - * @param data.pool - * @param data.queue - * @param data.executor - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns TaskInstanceCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstancesSuspense = < - TData = Common.TaskInstanceServiceGetTaskInstancesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskDisplayNamePattern, - taskId, - updatedAtGte, - updatedAtLte, - }: { - dagId: string; - dagRunId: string; - durationGte?: number; - durationLte?: number; - endDateGte?: string; - endDateLte?: string; - executor?: string[]; - limit?: number; - logicalDateGte?: string; - logicalDateLte?: string; - offset?: number; - orderBy?: string; - pool?: string[]; - queue?: string[]; - startDateGte?: string; - startDateLte?: string; - state?: string[]; - taskDisplayNamePattern?: string; - taskId?: string; - updatedAtGte?: string; - updatedAtLte?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstancesKeyFn( - { - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskDisplayNamePattern, - taskId, - updatedAtGte, - updatedAtLte, - }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getTaskInstances({ - dagId, - dagRunId, - durationGte, - durationLte, - endDateGte, - endDateLte, - executor, - limit, - logicalDateGte, - logicalDateLte, - offset, - orderBy, - pool, - queue, - startDateGte, - startDateLte, - state, - taskDisplayNamePattern, - taskId, - updatedAtGte, - updatedAtLte, - }) as TData, - ...options, - }); +* Get Task Instances +* Get list of task instances. +* +* This endpoint allows specifying `~` as the dag_id, dag_run_id to retrieve Task Instances for all DAGs +* and DAG runs. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.logicalDateGte +* @param data.logicalDateLte +* @param data.startDateGte +* @param data.startDateLte +* @param data.endDateGte +* @param data.endDateLte +* @param data.updatedAtGte +* @param data.updatedAtLte +* @param data.durationGte +* @param data.durationLte +* @param data.taskDisplayNamePattern +* @param data.state +* @param data.pool +* @param data.queue +* @param data.executor +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns TaskInstanceCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstancesSuspense = = unknown[]>({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskDisplayNamePattern, taskId, updatedAtGte, updatedAtLte }: { + dagId: string; + dagRunId: string; + durationGte?: number; + durationLte?: number; + endDateGte?: string; + endDateLte?: string; + executor?: string[]; + limit?: number; + logicalDateGte?: string; + logicalDateLte?: string; + offset?: number; + orderBy?: string; + pool?: string[]; + queue?: string[]; + startDateGte?: string; + startDateLte?: string; + state?: string[]; + taskDisplayNamePattern?: string; + taskId?: string; + updatedAtGte?: string; + updatedAtLte?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstancesKeyFn({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskDisplayNamePattern, taskId, updatedAtGte, updatedAtLte }, queryKey), queryFn: () => TaskInstanceService.getTaskInstances({ dagId, dagRunId, durationGte, durationLte, endDateGte, endDateLte, executor, limit, logicalDateGte, logicalDateLte, offset, orderBy, pool, queue, startDateGte, startDateLte, state, taskDisplayNamePattern, taskId, updatedAtGte, updatedAtLte }) as TData, ...options }); /** - * Get Task Instance Try Details - * Get task instance details by try number. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.taskTryNumber - * @param data.mapIndex - * @returns TaskInstanceHistoryResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetTaskInstanceTryDetailsSuspense = < - TData = Common.TaskInstanceServiceGetTaskInstanceTryDetailsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }: { - dagId: string; - dagRunId: string; - mapIndex?: number; - taskId: string; - taskTryNumber: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskInstanceServiceGetTaskInstanceTryDetailsKeyFn( - { dagId, dagRunId, mapIndex, taskId, taskTryNumber }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getTaskInstanceTryDetails({ - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }) as TData, - ...options, - }); +* Get Task Instance Try Details +* Get task instance details by try number. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.taskTryNumber +* @param data.mapIndex +* @returns TaskInstanceHistoryResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetTaskInstanceTryDetailsSuspense = = unknown[]>({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }: { + dagId: string; + dagRunId: string; + mapIndex?: number; + taskId: string; + taskTryNumber: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskInstanceServiceGetTaskInstanceTryDetailsKeyFn({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }, queryKey), queryFn: () => TaskInstanceService.getTaskInstanceTryDetails({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }) as TData, ...options }); /** - * Get Mapped Task Instance Try Details - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.taskTryNumber - * @param data.mapIndex - * @returns TaskInstanceHistoryResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetMappedTaskInstanceTryDetailsSuspense = < - TData = Common.TaskInstanceServiceGetMappedTaskInstanceTryDetailsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }: { - dagId: string; - dagRunId: string; - mapIndex: number; - taskId: string; - taskTryNumber: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceTryDetailsKeyFn( - { dagId, dagRunId, mapIndex, taskId, taskTryNumber }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getMappedTaskInstanceTryDetails({ - dagId, - dagRunId, - mapIndex, - taskId, - taskTryNumber, - }) as TData, - ...options, - }); +* Get Mapped Task Instance Try Details +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.taskTryNumber +* @param data.mapIndex +* @returns TaskInstanceHistoryResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetMappedTaskInstanceTryDetailsSuspense = = unknown[]>({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }: { + dagId: string; + dagRunId: string; + mapIndex: number; + taskId: string; + taskTryNumber: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskInstanceServiceGetMappedTaskInstanceTryDetailsKeyFn({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }, queryKey), queryFn: () => TaskInstanceService.getMappedTaskInstanceTryDetails({ dagId, dagRunId, mapIndex, taskId, taskTryNumber }) as TData, ...options }); /** - * Get Log - * Get logs for a specific task instance. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.tryNumber - * @param data.fullContent - * @param data.mapIndex - * @param data.token - * @param data.accept - * @returns TaskInstancesLogResponse Successful Response - * @throws ApiError - */ -export const useTaskInstanceServiceGetLogSuspense = < - TData = Common.TaskInstanceServiceGetLogDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - accept, - dagId, - dagRunId, - fullContent, - mapIndex, - taskId, - token, - tryNumber, - }: { - accept?: "application/json" | "text/plain" | "*/*"; - dagId: string; - dagRunId: string; - fullContent?: boolean; - mapIndex?: number; - taskId: string; - token?: string; - tryNumber: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskInstanceServiceGetLogKeyFn( - { accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }, - queryKey, - ), - queryFn: () => - TaskInstanceService.getLog({ - accept, - dagId, - dagRunId, - fullContent, - mapIndex, - taskId, - token, - tryNumber, - }) as TData, - ...options, - }); +* Get Log +* Get logs for a specific task instance. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.tryNumber +* @param data.fullContent +* @param data.mapIndex +* @param data.token +* @param data.accept +* @returns TaskInstancesLogResponse Successful Response +* @throws ApiError +*/ +export const useTaskInstanceServiceGetLogSuspense = = unknown[]>({ accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }: { + accept?: "application/json" | "text/plain" | "*/*"; + dagId: string; + dagRunId: string; + fullContent?: boolean; + mapIndex?: number; + taskId: string; + token?: string; + tryNumber: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskInstanceServiceGetLogKeyFn({ accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }, queryKey), queryFn: () => TaskInstanceService.getLog({ accept, dagId, dagRunId, fullContent, mapIndex, taskId, token, tryNumber }) as TData, ...options }); /** - * Get Import Error - * Get an import error. - * @param data The data for the request. - * @param data.importErrorId - * @returns ImportErrorResponse Successful Response - * @throws ApiError - */ -export const useImportErrorServiceGetImportErrorSuspense = < - TData = Common.ImportErrorServiceGetImportErrorDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - importErrorId, - }: { - importErrorId: number; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseImportErrorServiceGetImportErrorKeyFn({ importErrorId }, queryKey), - queryFn: () => ImportErrorService.getImportError({ importErrorId }) as TData, - ...options, - }); +* Get Import Error +* Get an import error. +* @param data The data for the request. +* @param data.importErrorId +* @returns ImportErrorResponse Successful Response +* @throws ApiError +*/ +export const useImportErrorServiceGetImportErrorSuspense = = unknown[]>({ importErrorId }: { + importErrorId: number; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseImportErrorServiceGetImportErrorKeyFn({ importErrorId }, queryKey), queryFn: () => ImportErrorService.getImportError({ importErrorId }) as TData, ...options }); /** - * Get Import Errors - * Get all import errors. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns ImportErrorCollectionResponse Successful Response - * @throws ApiError - */ -export const useImportErrorServiceGetImportErrorsSuspense = < - TData = Common.ImportErrorServiceGetImportErrorsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - orderBy, - }: { - limit?: number; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseImportErrorServiceGetImportErrorsKeyFn({ limit, offset, orderBy }, queryKey), - queryFn: () => ImportErrorService.getImportErrors({ limit, offset, orderBy }) as TData, - ...options, - }); +* Get Import Errors +* Get all import errors. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns ImportErrorCollectionResponse Successful Response +* @throws ApiError +*/ +export const useImportErrorServiceGetImportErrorsSuspense = = unknown[]>({ limit, offset, orderBy }: { + limit?: number; + offset?: number; + orderBy?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseImportErrorServiceGetImportErrorsKeyFn({ limit, offset, orderBy }, queryKey), queryFn: () => ImportErrorService.getImportErrors({ limit, offset, orderBy }) as TData, ...options }); /** - * Get Jobs - * Get all jobs. - * @param data The data for the request. - * @param data.isAlive - * @param data.startDateGte - * @param data.startDateLte - * @param data.endDateGte - * @param data.endDateLte - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.jobState - * @param data.jobType - * @param data.hostname - * @param data.executorClass - * @returns JobCollectionResponse Successful Response - * @throws ApiError - */ -export const useJobServiceGetJobsSuspense = < - TData = Common.JobServiceGetJobsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - endDateGte, - endDateLte, - executorClass, - hostname, - isAlive, - jobState, - jobType, - limit, - offset, - orderBy, - startDateGte, - startDateLte, - }: { - endDateGte?: string; - endDateLte?: string; - executorClass?: string; - hostname?: string; - isAlive?: boolean; - jobState?: string; - jobType?: string; - limit?: number; - offset?: number; - orderBy?: string; - startDateGte?: string; - startDateLte?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseJobServiceGetJobsKeyFn( - { - endDateGte, - endDateLte, - executorClass, - hostname, - isAlive, - jobState, - jobType, - limit, - offset, - orderBy, - startDateGte, - startDateLte, - }, - queryKey, - ), - queryFn: () => - JobService.getJobs({ - endDateGte, - endDateLte, - executorClass, - hostname, - isAlive, - jobState, - jobType, - limit, - offset, - orderBy, - startDateGte, - startDateLte, - }) as TData, - ...options, - }); +* Get Jobs +* Get all jobs. +* @param data The data for the request. +* @param data.isAlive +* @param data.startDateGte +* @param data.startDateLte +* @param data.endDateGte +* @param data.endDateLte +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.jobState +* @param data.jobType +* @param data.hostname +* @param data.executorClass +* @returns JobCollectionResponse Successful Response +* @throws ApiError +*/ +export const useJobServiceGetJobsSuspense = = unknown[]>({ endDateGte, endDateLte, executorClass, hostname, isAlive, jobState, jobType, limit, offset, orderBy, startDateGte, startDateLte }: { + endDateGte?: string; + endDateLte?: string; + executorClass?: string; + hostname?: string; + isAlive?: boolean; + jobState?: string; + jobType?: string; + limit?: number; + offset?: number; + orderBy?: string; + startDateGte?: string; + startDateLte?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseJobServiceGetJobsKeyFn({ endDateGte, endDateLte, executorClass, hostname, isAlive, jobState, jobType, limit, offset, orderBy, startDateGte, startDateLte }, queryKey), queryFn: () => JobService.getJobs({ endDateGte, endDateLte, executorClass, hostname, isAlive, jobState, jobType, limit, offset, orderBy, startDateGte, startDateLte }) as TData, ...options }); /** - * Get Plugins - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @returns PluginCollectionResponse Successful Response - * @throws ApiError - */ -export const usePluginServiceGetPluginsSuspense = < - TData = Common.PluginServiceGetPluginsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - }: { - limit?: number; - offset?: number; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UsePluginServiceGetPluginsKeyFn({ limit, offset }, queryKey), - queryFn: () => PluginService.getPlugins({ limit, offset }) as TData, - ...options, - }); +* Get Plugins +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @returns PluginCollectionResponse Successful Response +* @throws ApiError +*/ +export const usePluginServiceGetPluginsSuspense = = unknown[]>({ limit, offset }: { + limit?: number; + offset?: number; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UsePluginServiceGetPluginsKeyFn({ limit, offset }, queryKey), queryFn: () => PluginService.getPlugins({ limit, offset }) as TData, ...options }); /** - * Get Pool - * Get a pool. - * @param data The data for the request. - * @param data.poolName - * @returns PoolResponse Successful Response - * @throws ApiError - */ -export const usePoolServiceGetPoolSuspense = < - TData = Common.PoolServiceGetPoolDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - poolName, - }: { - poolName: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UsePoolServiceGetPoolKeyFn({ poolName }, queryKey), - queryFn: () => PoolService.getPool({ poolName }) as TData, - ...options, - }); +* Get Pool +* Get a pool. +* @param data The data for the request. +* @param data.poolName +* @returns PoolResponse Successful Response +* @throws ApiError +*/ +export const usePoolServiceGetPoolSuspense = = unknown[]>({ poolName }: { + poolName: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UsePoolServiceGetPoolKeyFn({ poolName }, queryKey), queryFn: () => PoolService.getPool({ poolName }) as TData, ...options }); /** - * Get Pools - * Get all pools entries. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @returns PoolCollectionResponse Successful Response - * @throws ApiError - */ -export const usePoolServiceGetPoolsSuspense = < - TData = Common.PoolServiceGetPoolsDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - orderBy, - }: { - limit?: number; - offset?: number; - orderBy?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UsePoolServiceGetPoolsKeyFn({ limit, offset, orderBy }, queryKey), - queryFn: () => PoolService.getPools({ limit, offset, orderBy }) as TData, - ...options, - }); +* Get Pools +* Get all pools entries. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @returns PoolCollectionResponse Successful Response +* @throws ApiError +*/ +export const usePoolServiceGetPoolsSuspense = = unknown[]>({ limit, offset, orderBy }: { + limit?: number; + offset?: number; + orderBy?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UsePoolServiceGetPoolsKeyFn({ limit, offset, orderBy }, queryKey), queryFn: () => PoolService.getPools({ limit, offset, orderBy }) as TData, ...options }); /** - * Get Providers - * Get providers. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @returns ProviderCollectionResponse Successful Response - * @throws ApiError - */ -export const useProviderServiceGetProvidersSuspense = < - TData = Common.ProviderServiceGetProvidersDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - }: { - limit?: number; - offset?: number; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseProviderServiceGetProvidersKeyFn({ limit, offset }, queryKey), - queryFn: () => ProviderService.getProviders({ limit, offset }) as TData, - ...options, - }); +* Get Providers +* Get providers. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @returns ProviderCollectionResponse Successful Response +* @throws ApiError +*/ +export const useProviderServiceGetProvidersSuspense = = unknown[]>({ limit, offset }: { + limit?: number; + offset?: number; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseProviderServiceGetProvidersKeyFn({ limit, offset }, queryKey), queryFn: () => ProviderService.getProviders({ limit, offset }) as TData, ...options }); /** - * Get Xcom Entry - * Get an XCom entry. - * @param data The data for the request. - * @param data.dagId - * @param data.taskId - * @param data.dagRunId - * @param data.xcomKey - * @param data.mapIndex - * @param data.deserialize - * @param data.stringify - * @returns unknown Successful Response - * @throws ApiError - */ -export const useXcomServiceGetXcomEntrySuspense = < - TData = Common.XcomServiceGetXcomEntryDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - deserialize, - mapIndex, - stringify, - taskId, - xcomKey, - }: { - dagId: string; - dagRunId: string; - deserialize?: boolean; - mapIndex?: number; - stringify?: boolean; - taskId: string; - xcomKey: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseXcomServiceGetXcomEntryKeyFn( - { dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }, - queryKey, - ), - queryFn: () => - XcomService.getXcomEntry({ - dagId, - dagRunId, - deserialize, - mapIndex, - stringify, - taskId, - xcomKey, - }) as TData, - ...options, - }); +* Get Xcom Entry +* Get an XCom entry. +* @param data The data for the request. +* @param data.dagId +* @param data.taskId +* @param data.dagRunId +* @param data.xcomKey +* @param data.mapIndex +* @param data.deserialize +* @param data.stringify +* @returns unknown Successful Response +* @throws ApiError +*/ +export const useXcomServiceGetXcomEntrySuspense = = unknown[]>({ dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }: { + dagId: string; + dagRunId: string; + deserialize?: boolean; + mapIndex?: number; + stringify?: boolean; + taskId: string; + xcomKey: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseXcomServiceGetXcomEntryKeyFn({ dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }, queryKey), queryFn: () => XcomService.getXcomEntry({ dagId, dagRunId, deserialize, mapIndex, stringify, taskId, xcomKey }) as TData, ...options }); /** - * Get Xcom Entries - * Get all XCom entries. - * - * This endpoint allows specifying `~` as the dag_id, dag_run_id, task_id to retrieve XCom entries for all DAGs. - * @param data The data for the request. - * @param data.dagId - * @param data.dagRunId - * @param data.taskId - * @param data.xcomKey - * @param data.mapIndex - * @param data.limit - * @param data.offset - * @returns XComCollection Successful Response - * @throws ApiError - */ -export const useXcomServiceGetXcomEntriesSuspense = < - TData = Common.XcomServiceGetXcomEntriesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - dagRunId, - limit, - mapIndex, - offset, - taskId, - xcomKey, - }: { - dagId: string; - dagRunId: string; - limit?: number; - mapIndex?: number; - offset?: number; - taskId: string; - xcomKey?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseXcomServiceGetXcomEntriesKeyFn( - { dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }, - queryKey, - ), - queryFn: () => - XcomService.getXcomEntries({ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }) as TData, - ...options, - }); +* Get Xcom Entries +* Get all XCom entries. +* +* This endpoint allows specifying `~` as the dag_id, dag_run_id, task_id to retrieve XCom entries for all DAGs. +* @param data The data for the request. +* @param data.dagId +* @param data.dagRunId +* @param data.taskId +* @param data.xcomKey +* @param data.mapIndex +* @param data.limit +* @param data.offset +* @returns XComCollection Successful Response +* @throws ApiError +*/ +export const useXcomServiceGetXcomEntriesSuspense = = unknown[]>({ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }: { + dagId: string; + dagRunId: string; + limit?: number; + mapIndex?: number; + offset?: number; + taskId: string; + xcomKey?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseXcomServiceGetXcomEntriesKeyFn({ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }, queryKey), queryFn: () => XcomService.getXcomEntries({ dagId, dagRunId, limit, mapIndex, offset, taskId, xcomKey }) as TData, ...options }); /** - * Get Tasks - * Get tasks for DAG. - * @param data The data for the request. - * @param data.dagId - * @param data.orderBy - * @returns TaskCollectionResponse Successful Response - * @throws ApiError - */ -export const useTaskServiceGetTasksSuspense = < - TData = Common.TaskServiceGetTasksDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - orderBy, - }: { - dagId: string; - orderBy?: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskServiceGetTasksKeyFn({ dagId, orderBy }, queryKey), - queryFn: () => TaskService.getTasks({ dagId, orderBy }) as TData, - ...options, - }); +* Get Tasks +* Get tasks for DAG. +* @param data The data for the request. +* @param data.dagId +* @param data.orderBy +* @returns TaskCollectionResponse Successful Response +* @throws ApiError +*/ +export const useTaskServiceGetTasksSuspense = = unknown[]>({ dagId, orderBy }: { + dagId: string; + orderBy?: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskServiceGetTasksKeyFn({ dagId, orderBy }, queryKey), queryFn: () => TaskService.getTasks({ dagId, orderBy }) as TData, ...options }); /** - * Get Task - * Get simplified representation of a task. - * @param data The data for the request. - * @param data.dagId - * @param data.taskId - * @returns TaskResponse Successful Response - * @throws ApiError - */ -export const useTaskServiceGetTaskSuspense = < - TData = Common.TaskServiceGetTaskDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - dagId, - taskId, - }: { - dagId: string; - taskId: unknown; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseTaskServiceGetTaskKeyFn({ dagId, taskId }, queryKey), - queryFn: () => TaskService.getTask({ dagId, taskId }) as TData, - ...options, - }); +* Get Task +* Get simplified representation of a task. +* @param data The data for the request. +* @param data.dagId +* @param data.taskId +* @returns TaskResponse Successful Response +* @throws ApiError +*/ +export const useTaskServiceGetTaskSuspense = = unknown[]>({ dagId, taskId }: { + dagId: string; + taskId: unknown; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseTaskServiceGetTaskKeyFn({ dagId, taskId }, queryKey), queryFn: () => TaskService.getTask({ dagId, taskId }) as TData, ...options }); /** - * Get Variable - * Get a variable entry. - * @param data The data for the request. - * @param data.variableKey - * @returns VariableResponse Successful Response - * @throws ApiError - */ -export const useVariableServiceGetVariableSuspense = < - TData = Common.VariableServiceGetVariableDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - variableKey, - }: { - variableKey: string; - }, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseVariableServiceGetVariableKeyFn({ variableKey }, queryKey), - queryFn: () => VariableService.getVariable({ variableKey }) as TData, - ...options, - }); +* Get Variable +* Get a variable entry. +* @param data The data for the request. +* @param data.variableKey +* @returns VariableResponse Successful Response +* @throws ApiError +*/ +export const useVariableServiceGetVariableSuspense = = unknown[]>({ variableKey }: { + variableKey: string; +}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseVariableServiceGetVariableKeyFn({ variableKey }, queryKey), queryFn: () => VariableService.getVariable({ variableKey }) as TData, ...options }); /** - * Get Variables - * Get all Variables entries. - * @param data The data for the request. - * @param data.limit - * @param data.offset - * @param data.orderBy - * @param data.variableKeyPattern - * @returns VariableCollectionResponse Successful Response - * @throws ApiError - */ -export const useVariableServiceGetVariablesSuspense = < - TData = Common.VariableServiceGetVariablesDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - { - limit, - offset, - orderBy, - variableKeyPattern, - }: { - limit?: number; - offset?: number; - orderBy?: string; - variableKeyPattern?: string; - } = {}, - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseVariableServiceGetVariablesKeyFn( - { limit, offset, orderBy, variableKeyPattern }, - queryKey, - ), - queryFn: () => VariableService.getVariables({ limit, offset, orderBy, variableKeyPattern }) as TData, - ...options, - }); +* Get Variables +* Get all Variables entries. +* @param data The data for the request. +* @param data.limit +* @param data.offset +* @param data.orderBy +* @param data.variableKeyPattern +* @returns VariableCollectionResponse Successful Response +* @throws ApiError +*/ +export const useVariableServiceGetVariablesSuspense = = unknown[]>({ limit, offset, orderBy, variableKeyPattern }: { + limit?: number; + offset?: number; + orderBy?: string; + variableKeyPattern?: string; +} = {}, queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseVariableServiceGetVariablesKeyFn({ limit, offset, orderBy, variableKeyPattern }, queryKey), queryFn: () => VariableService.getVariables({ limit, offset, orderBy, variableKeyPattern }) as TData, ...options }); /** - * Get Health - * @returns HealthInfoResponse Successful Response - * @throws ApiError - */ -export const useMonitorServiceGetHealthSuspense = < - TData = Common.MonitorServiceGetHealthDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseMonitorServiceGetHealthKeyFn(queryKey), - queryFn: () => MonitorService.getHealth() as TData, - ...options, - }); +* Get Health +* @returns HealthInfoResponse Successful Response +* @throws ApiError +*/ +export const useMonitorServiceGetHealthSuspense = = unknown[]>(queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseMonitorServiceGetHealthKeyFn(queryKey), queryFn: () => MonitorService.getHealth() as TData, ...options }); /** - * Get Version - * Get version information. - * @returns VersionInfo Successful Response - * @throws ApiError - */ -export const useVersionServiceGetVersionSuspense = < - TData = Common.VersionServiceGetVersionDefaultResponse, - TError = unknown, - TQueryKey extends Array = unknown[], ->( - queryKey?: TQueryKey, - options?: Omit, "queryKey" | "queryFn">, -) => - useSuspenseQuery({ - queryKey: Common.UseVersionServiceGetVersionKeyFn(queryKey), - queryFn: () => VersionService.getVersion() as TData, - ...options, - }); +* Get Version +* Get version information. +* @returns VersionInfo Successful Response +* @throws ApiError +*/ +export const useVersionServiceGetVersionSuspense = = unknown[]>(queryKey?: TQueryKey, options?: Omit, "queryKey" | "queryFn">) => useSuspenseQuery({ queryKey: Common.UseVersionServiceGetVersionKeyFn(queryKey), queryFn: () => VersionService.getVersion() as TData, ...options }); diff --git a/airflow/ui/openapi-gen/requests/schemas.gen.ts b/airflow/ui/openapi-gen/requests/schemas.gen.ts index df5c29f51e6de..cbf9b37f48cd3 100644 --- a/airflow/ui/openapi-gen/requests/schemas.gen.ts +++ b/airflow/ui/openapi-gen/requests/schemas.gen.ts @@ -191,6 +191,28 @@ export const $AssetEventResponse = { ], title: "Uri", }, + name: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Name", + }, + group: { + anyOf: [ + { + type: "string", + }, + { + type: "null", + }, + ], + title: "Group", + }, extra: { anyOf: [ { @@ -253,13 +275,7 @@ export const $AssetEventResponse = { }, }, type: "object", - required: [ - "id", - "asset_id", - "source_map_index", - "created_dagruns", - "timestamp", - ], + required: ["id", "asset_id", "source_map_index", "created_dagruns", "timestamp"], title: "AssetEventResponse", description: "Asset event serializer for responses.", } as const; diff --git a/airflow/ui/openapi-gen/requests/types.gen.ts b/airflow/ui/openapi-gen/requests/types.gen.ts index c0f2ee8c5d2a6..216a3343e8ce6 100644 --- a/airflow/ui/openapi-gen/requests/types.gen.ts +++ b/airflow/ui/openapi-gen/requests/types.gen.ts @@ -61,6 +61,8 @@ export type AssetEventResponse = { id: number; asset_id: number; uri?: string | null; + name?: string | null; + group?: string | null; extra?: { [key: string]: unknown; } | null; diff --git a/airflow/ui/src/pages/Dashboard/HistoricalMetrics/AssetEvent.tsx b/airflow/ui/src/pages/Dashboard/HistoricalMetrics/AssetEvent.tsx index e144c5faa8ee5..51dd47ecacfdf 100644 --- a/airflow/ui/src/pages/Dashboard/HistoricalMetrics/AssetEvent.tsx +++ b/airflow/ui/src/pages/Dashboard/HistoricalMetrics/AssetEvent.tsx @@ -23,12 +23,9 @@ import { Link } from "react-router-dom"; import type { AssetEventResponse } from "openapi/requests/types.gen"; import Time from "src/components/Time"; +import { Tooltip } from "src/components/ui"; -export const AssetEvent = ({ - event, -}: { - readonly event: AssetEventResponse; -}) => { +export const AssetEvent = ({ event }: { readonly event: AssetEventResponse }) => { const hasDagRuns = event.created_dagruns.length > 0; const source = event.extra?.from_rest_api === true ? "API" : ""; @@ -38,7 +35,18 @@ export const AssetEvent = ({