@@ -52,7 +52,6 @@ import algoliasearch.ingestion.SourceSortKeys._
52
52
import algoliasearch .ingestion .SourceType ._
53
53
import algoliasearch .ingestion .SourceUpdate
54
54
import algoliasearch .ingestion .SourceUpdateResponse
55
- import algoliasearch .ingestion .SourceWatchResponse
56
55
import algoliasearch .ingestion .Task
57
56
import algoliasearch .ingestion .TaskCreate
58
57
import algoliasearch .ingestion .TaskCreateResponse
@@ -72,6 +71,7 @@ import algoliasearch.ingestion.TransformationTry
72
71
import algoliasearch .ingestion .TransformationTryResponse
73
72
import algoliasearch .ingestion .TransformationUpdateResponse
74
73
import algoliasearch .ingestion .TriggerType ._
74
+ import algoliasearch .ingestion .WatchResponse
75
75
import algoliasearch .ingestion ._
76
76
import algoliasearch .ApiClient
77
77
import algoliasearch .api .IngestionClient .hosts
@@ -1208,7 +1208,7 @@ class IngestionClient(
1208
1208
pushTaskPayload : PushTaskPayload ,
1209
1209
watch : Option [Boolean ] = None ,
1210
1210
requestOptions : Option [RequestOptions ] = None
1211
- )(implicit ec : ExecutionContext ): Future [RunResponse ] = Future {
1211
+ )(implicit ec : ExecutionContext ): Future [WatchResponse ] = Future {
1212
1212
requireNotNull(taskID, " Parameter `taskID` is required when calling `pushTask`." )
1213
1213
requireNotNull(pushTaskPayload, " Parameter `pushTaskPayload` is required when calling `pushTask`." )
1214
1214
@@ -1219,7 +1219,7 @@ class IngestionClient(
1219
1219
.withBody(pushTaskPayload)
1220
1220
.withQueryParameter(" watch" , watch)
1221
1221
.build()
1222
- execute[RunResponse ](request, requestOptions)
1222
+ execute[WatchResponse ](request, requestOptions)
1223
1223
}
1224
1224
1225
1225
/** Runs all tasks linked to a source, only available for Shopify sources. It will create 1 run per task.
@@ -1441,15 +1441,15 @@ class IngestionClient(
1441
1441
*/
1442
1442
def triggerDockerSourceDiscover (sourceID : String , requestOptions : Option [RequestOptions ] = None )(implicit
1443
1443
ec : ExecutionContext
1444
- ): Future [SourceWatchResponse ] = Future {
1444
+ ): Future [WatchResponse ] = Future {
1445
1445
requireNotNull(sourceID, " Parameter `sourceID` is required when calling `triggerDockerSourceDiscover`." )
1446
1446
1447
1447
val request = HttpRequest
1448
1448
.builder()
1449
1449
.withMethod(" POST" )
1450
1450
.withPath(s " /1/sources/ ${escape(sourceID)}/discover " )
1451
1451
.build()
1452
- execute[SourceWatchResponse ](request, requestOptions)
1452
+ execute[WatchResponse ](request, requestOptions)
1453
1453
}
1454
1454
1455
1455
/** Try a transformation before creating it.
@@ -1664,15 +1664,15 @@ class IngestionClient(
1664
1664
*/
1665
1665
def validateSource (sourceCreate : Option [SourceCreate ] = None , requestOptions : Option [RequestOptions ] = None )(implicit
1666
1666
ec : ExecutionContext
1667
- ): Future [SourceWatchResponse ] = Future {
1667
+ ): Future [WatchResponse ] = Future {
1668
1668
1669
1669
val request = HttpRequest
1670
1670
.builder()
1671
1671
.withMethod(" POST" )
1672
1672
.withPath(s " /1/sources/validate " )
1673
1673
.withBody(sourceCreate)
1674
1674
.build()
1675
- execute[SourceWatchResponse ](request, requestOptions)
1675
+ execute[WatchResponse ](request, requestOptions)
1676
1676
}
1677
1677
1678
1678
/** Validates an update of a source payload to ensure it can be created and that the data source can be reached by
@@ -1690,7 +1690,7 @@ class IngestionClient(
1690
1690
sourceID : String ,
1691
1691
sourceUpdate : SourceUpdate ,
1692
1692
requestOptions : Option [RequestOptions ] = None
1693
- )(implicit ec : ExecutionContext ): Future [SourceWatchResponse ] = Future {
1693
+ )(implicit ec : ExecutionContext ): Future [WatchResponse ] = Future {
1694
1694
requireNotNull(sourceID, " Parameter `sourceID` is required when calling `validateSourceBeforeUpdate`." )
1695
1695
requireNotNull(sourceUpdate, " Parameter `sourceUpdate` is required when calling `validateSourceBeforeUpdate`." )
1696
1696
@@ -1700,7 +1700,7 @@ class IngestionClient(
1700
1700
.withPath(s " /1/sources/ ${escape(sourceID)}/validate " )
1701
1701
.withBody(sourceUpdate)
1702
1702
.build()
1703
- execute[SourceWatchResponse ](request, requestOptions)
1703
+ execute[WatchResponse ](request, requestOptions)
1704
1704
}
1705
1705
1706
1706
}
0 commit comments