diff --git a/packages/ingestion/model/index.ts b/packages/ingestion/model/index.ts index dbd68ed11..326c43533 100644 --- a/packages/ingestion/model/index.ts +++ b/packages/ingestion/model/index.ts @@ -114,7 +114,6 @@ export * from './sourceUpdateDocker'; export * from './sourceUpdateInput'; export * from './sourceUpdateResponse'; export * from './sourceUpdateShopify'; -export * from './sourceWatchResponse'; export * from './streamingInput'; export * from './streamingTrigger'; export * from './streamingTriggerType'; @@ -144,4 +143,5 @@ export * from './transformationUpdateResponse'; export * from './trigger'; export * from './triggerType'; export * from './triggerUpdateInput'; +export * from './watchResponse'; export * from './window'; diff --git a/packages/ingestion/model/sourceWatchResponse.ts b/packages/ingestion/model/watchResponse.ts similarity index 79% rename from packages/ingestion/model/sourceWatchResponse.ts rename to packages/ingestion/model/watchResponse.ts index 19bfc063a..b98a09305 100644 --- a/packages/ingestion/model/sourceWatchResponse.ts +++ b/packages/ingestion/model/watchResponse.ts @@ -2,14 +2,14 @@ import type { Event } from './event'; -export type SourceWatchResponse = { +export type WatchResponse = { /** * Universally unique identifier (UUID) of a task run. */ runID?: string; /** - * depending on the source type, the validation returns sampling data of your source (JSON, CSV, BigQuery). + * when used with discovering or validating sources, the sampled data of your source is returned. */ data?: Array>; diff --git a/packages/ingestion/src/ingestionClient.ts b/packages/ingestion/src/ingestionClient.ts index 50cc88466..96f0b70af 100644 --- a/packages/ingestion/src/ingestionClient.ts +++ b/packages/ingestion/src/ingestionClient.ts @@ -46,7 +46,6 @@ import type { SourceCreateResponse } from '../model/sourceCreateResponse'; import type { SourceSearch } from '../model/sourceSearch'; import type { SourceUpdateResponse } from '../model/sourceUpdateResponse'; -import type { SourceWatchResponse } from '../model/sourceWatchResponse'; import type { Task } from '../model/task'; import type { TaskCreate } from '../model/taskCreate'; import type { TaskCreateResponse } from '../model/taskCreateResponse'; @@ -65,6 +64,8 @@ import type { TransformationTry } from '../model/transformationTry'; import type { TransformationTryResponse } from '../model/transformationTryResponse'; import type { TransformationUpdateResponse } from '../model/transformationUpdateResponse'; +import type { WatchResponse } from '../model/watchResponse'; + import type { CustomDeleteProps, CustomGetProps, @@ -1694,7 +1695,10 @@ export function createIngestionClient({ * @param pushTask.watch - When provided, the push operation will be synchronous and the API will wait for the ingestion to be finished before responding. * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions. */ - pushTask({ taskID, pushTaskPayload, watch }: PushTaskProps, requestOptions?: RequestOptions): Promise { + pushTask( + { taskID, pushTaskPayload, watch }: PushTaskProps, + requestOptions?: RequestOptions, + ): Promise { if (!taskID) { throw new Error('Parameter `taskID` is required when calling `pushTask`.'); } @@ -2055,7 +2059,7 @@ export function createIngestionClient({ triggerDockerSourceDiscover( { sourceID }: TriggerDockerSourceDiscoverProps, requestOptions?: RequestOptions, - ): Promise { + ): Promise { if (!sourceID) { throw new Error('Parameter `sourceID` is required when calling `triggerDockerSourceDiscover`.'); } @@ -2410,7 +2414,7 @@ export function createIngestionClient({ validateSource( sourceCreate: SourceCreate, requestOptions: RequestOptions | undefined = undefined, - ): Promise { + ): Promise { const requestPath = '/1/sources/validate'; const headers: Headers = {}; const queryParameters: QueryParameters = {}; @@ -2441,7 +2445,7 @@ export function createIngestionClient({ validateSourceBeforeUpdate( { sourceID, sourceUpdate }: ValidateSourceBeforeUpdateProps, requestOptions?: RequestOptions, - ): Promise { + ): Promise { if (!sourceID) { throw new Error('Parameter `sourceID` is required when calling `validateSourceBeforeUpdate`.'); }