@algolia/ingestion 5.2.4-beta.6 → 5.10.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +15 -7
- package/dist/browser.d.ts +1266 -634
- package/dist/builds/browser.js +223 -322
- package/dist/builds/browser.js.map +1 -1
- package/dist/builds/browser.min.js +1 -1
- package/dist/builds/browser.min.js.map +1 -1
- package/dist/builds/browser.umd.js +6 -6
- package/dist/builds/fetch.js +1943 -0
- package/dist/builds/fetch.js.map +1 -0
- package/dist/builds/node.cjs +220 -320
- package/dist/builds/node.cjs.map +1 -1
- package/dist/builds/node.js +221 -320
- package/dist/builds/node.js.map +1 -1
- package/dist/fetch.d.ts +3001 -0
- package/dist/node.d.cts +1267 -634
- package/dist/node.d.ts +1267 -634
- package/dist/src/ingestionClient.cjs +218 -319
- package/dist/src/ingestionClient.cjs.map +1 -1
- package/dist/src/ingestionClient.js +218 -319
- package/dist/src/ingestionClient.js.map +1 -1
- package/index.d.ts +0 -1
- package/index.js +1 -2
- package/package.json +16 -11
- package/model/action.ts +0 -13
- package/model/actionType.ts +0 -6
- package/model/authAPIKey.ts +0 -11
- package/model/authAPIKeyPartial.ts +0 -11
- package/model/authAlgolia.ts +0 -16
- package/model/authAlgoliaInsights.ts +0 -16
- package/model/authAlgoliaInsightsPartial.ts +0 -16
- package/model/authAlgoliaPartial.ts +0 -16
- package/model/authBasic.ts +0 -16
- package/model/authBasicPartial.ts +0 -16
- package/model/authGoogleServiceAccount.ts +0 -16
- package/model/authGoogleServiceAccountPartial.ts +0 -16
- package/model/authInput.ts +0 -16
- package/model/authInputPartial.ts +0 -16
- package/model/authOAuth.ts +0 -26
- package/model/authOAuthPartial.ts +0 -26
- package/model/authentication.ts +0 -36
- package/model/authenticationCreate.ts +0 -21
- package/model/authenticationCreateResponse.ts +0 -21
- package/model/authenticationSearch.ts +0 -8
- package/model/authenticationSortKeys.ts +0 -6
- package/model/authenticationType.ts +0 -6
- package/model/authenticationUpdate.ts +0 -21
- package/model/authenticationUpdateResponse.ts +0 -21
- package/model/bigCommerceChannel.ts +0 -13
- package/model/bigCommerceMetafield.ts +0 -13
- package/model/bigQueryDataType.ts +0 -3
- package/model/clientMethodProps.ts +0 -703
- package/model/commercetoolsCustomFields.ts +0 -21
- package/model/deleteResponse.ts +0 -8
- package/model/destination.ts +0 -40
- package/model/destinationCreate.ts +0 -25
- package/model/destinationCreateResponse.ts +0 -21
- package/model/destinationIndexName.ts +0 -17
- package/model/destinationInput.ts +0 -5
- package/model/destinationSearch.ts +0 -8
- package/model/destinationSortKeys.ts +0 -6
- package/model/destinationType.ts +0 -6
- package/model/destinationUpdate.ts +0 -25
- package/model/destinationUpdateResponse.ts +0 -21
- package/model/dockerImageType.ts +0 -6
- package/model/dockerRegistry.ts +0 -6
- package/model/dockerStreams.ts +0 -17
- package/model/dockerStreamsInput.ts +0 -10
- package/model/dockerStreamsSyncMode.ts +0 -6
- package/model/entityType.ts +0 -6
- package/model/errorBase.ts +0 -8
- package/model/event.ts +0 -40
- package/model/eventSortKeys.ts +0 -6
- package/model/eventStatus.ts +0 -3
- package/model/eventType.ts +0 -3
- package/model/generateTransformationCodePayload.ts +0 -9
- package/model/generateTransformationCodeResponse.ts +0 -5
- package/model/index.ts +0 -151
- package/model/listAuthenticationsResponse.ts +0 -10
- package/model/listDestinationsResponse.ts +0 -10
- package/model/listEventsResponse.ts +0 -13
- package/model/listSourcesResponse.ts +0 -10
- package/model/listTasksResponse.ts +0 -13
- package/model/listTasksResponseV1.ts +0 -13
- package/model/listTransformationsResponse.ts +0 -13
- package/model/mappingFieldDirective.ts +0 -16
- package/model/mappingFormatSchema.ts +0 -6
- package/model/mappingInput.ts +0 -13
- package/model/mappingKitAction.ts +0 -25
- package/model/mappingTypeCSV.ts +0 -3
- package/model/methodType.ts +0 -6
- package/model/model.ts +0 -13
- package/model/onDemandTrigger.ts +0 -15
- package/model/onDemandTriggerInput.ts +0 -10
- package/model/onDemandTriggerType.ts +0 -6
- package/model/orderKeys.ts +0 -6
- package/model/pagination.ts +0 -26
- package/model/platform.ts +0 -6
- package/model/platformNone.ts +0 -6
- package/model/platformWithNone.ts +0 -6
- package/model/pushTaskPayload.ts +0 -10
- package/model/pushTaskRecords.ts +0 -8
- package/model/recordType.ts +0 -6
- package/model/run.ts +0 -56
- package/model/runListResponse.ts +0 -13
- package/model/runOutcome.ts +0 -6
- package/model/runProgress.ts +0 -7
- package/model/runReasonCode.ts +0 -6
- package/model/runResponse.ts +0 -16
- package/model/runSortKeys.ts +0 -6
- package/model/runSourcePayload.ts +0 -22
- package/model/runSourceResponse.ts +0 -13
- package/model/runStatus.ts +0 -6
- package/model/runType.ts +0 -6
- package/model/scheduleTrigger.ts +0 -25
- package/model/scheduleTriggerInput.ts +0 -15
- package/model/scheduleTriggerType.ts +0 -6
- package/model/shopifyInput.ts +0 -13
- package/model/shopifyMarket.ts +0 -12
- package/model/shopifyMetafield.ts +0 -12
- package/model/sortKeys.ts +0 -6
- package/model/source.ts +0 -32
- package/model/sourceBigCommerce.ts +0 -19
- package/model/sourceBigQuery.ts +0 -37
- package/model/sourceCSV.ts +0 -28
- package/model/sourceCommercetools.ts +0 -23
- package/model/sourceCreate.ts +0 -20
- package/model/sourceCreateResponse.ts +0 -18
- package/model/sourceDocker.ts +0 -25
- package/model/sourceGA4BigQueryExport.ts +0 -18
- package/model/sourceInput.ts +0 -20
- package/model/sourceJSON.ts +0 -17
- package/model/sourceSearch.ts +0 -5
- package/model/sourceShopify.ts +0 -6
- package/model/sourceShopifyBase.ts +0 -8
- package/model/sourceSortKeys.ts +0 -6
- package/model/sourceType.ts +0 -13
- package/model/sourceUpdate.ts +0 -17
- package/model/sourceUpdateCommercetools.ts +0 -21
- package/model/sourceUpdateDocker.ts +0 -22
- package/model/sourceUpdateInput.ts +0 -18
- package/model/sourceUpdateResponse.ts +0 -18
- package/model/sourceUpdateShopify.ts +0 -8
- package/model/sourceWatchResponse.ts +0 -25
- package/model/streamingInput.ts +0 -10
- package/model/streamingTrigger.ts +0 -10
- package/model/streamingTriggerType.ts +0 -6
- package/model/subscriptionTrigger.ts +0 -10
- package/model/subscriptionTriggerType.ts +0 -6
- package/model/task.ts +0 -65
- package/model/taskCreate.ts +0 -43
- package/model/taskCreateResponse.ts +0 -16
- package/model/taskCreateTrigger.ts +0 -8
- package/model/taskCreateV1.ts +0 -41
- package/model/taskInput.ts +0 -10
- package/model/taskSearch.ts +0 -5
- package/model/taskSortKeys.ts +0 -6
- package/model/taskUpdate.ts +0 -30
- package/model/taskUpdateResponse.ts +0 -16
- package/model/taskUpdateV1.ts +0 -28
- package/model/taskV1.ts +0 -56
- package/model/transformation.ts +0 -38
- package/model/transformationCreate.ts +0 -26
- package/model/transformationCreateResponse.ts +0 -16
- package/model/transformationError.ts +0 -16
- package/model/transformationModels.ts +0 -10
- package/model/transformationSearch.ts +0 -5
- package/model/transformationTry.ts +0 -17
- package/model/transformationTryResponse.ts +0 -12
- package/model/transformationUpdateResponse.ts +0 -16
- package/model/trigger.ts +0 -11
- package/model/triggerType.ts +0 -6
- package/model/triggerUpdateInput.ts +0 -11
- package/model/window.ts +0 -16
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// src/ingestionClient.ts
|
|
2
2
|
import { createAuth, createTransporter, getAlgoliaAgent } from "@algolia/client-common";
|
|
3
|
-
var apiClientVersion = "
|
|
3
|
+
var apiClientVersion = "1.10.0";
|
|
4
4
|
var REGIONS = ["eu", "us"];
|
|
5
5
|
function getDefaultHosts(region) {
|
|
6
6
|
const url = "data.{region}.algolia.com".replace("{region}", region);
|
|
@@ -69,15 +69,27 @@ function createIngestionClient({
|
|
|
69
69
|
addAlgoliaAgent(segment, version) {
|
|
70
70
|
transporter.algoliaAgent.add({ segment, version });
|
|
71
71
|
},
|
|
72
|
+
/**
|
|
73
|
+
* Helper method to switch the API key used to authenticate the requests.
|
|
74
|
+
*
|
|
75
|
+
* @param params - Method params.
|
|
76
|
+
* @param params.apiKey - The new API Key to use.
|
|
77
|
+
*/
|
|
78
|
+
setClientApiKey({ apiKey }) {
|
|
79
|
+
if (!authMode || authMode === "WithinHeaders") {
|
|
80
|
+
transporter.baseHeaders["x-algolia-api-key"] = apiKey;
|
|
81
|
+
} else {
|
|
82
|
+
transporter.baseQueryParameters["x-algolia-api-key"] = apiKey;
|
|
83
|
+
}
|
|
84
|
+
},
|
|
72
85
|
/**
|
|
73
86
|
* Creates a new authentication resource.
|
|
74
87
|
*
|
|
75
88
|
* Required API Key ACLs:
|
|
76
|
-
*
|
|
77
|
-
*
|
|
78
|
-
*
|
|
79
|
-
*
|
|
80
|
-
* @param authenticationCreate -.
|
|
89
|
+
* - addObject
|
|
90
|
+
* - deleteIndex
|
|
91
|
+
* - editSettings
|
|
92
|
+
* @param authenticationCreate -
|
|
81
93
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
82
94
|
*/
|
|
83
95
|
createAuthentication(authenticationCreate, requestOptions) {
|
|
@@ -109,11 +121,10 @@ function createIngestionClient({
|
|
|
109
121
|
* Creates a new destination.
|
|
110
122
|
*
|
|
111
123
|
* Required API Key ACLs:
|
|
112
|
-
*
|
|
113
|
-
*
|
|
114
|
-
*
|
|
115
|
-
*
|
|
116
|
-
* @param destinationCreate -.
|
|
124
|
+
* - addObject
|
|
125
|
+
* - deleteIndex
|
|
126
|
+
* - editSettings
|
|
127
|
+
* @param destinationCreate -
|
|
117
128
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
118
129
|
*/
|
|
119
130
|
createDestination(destinationCreate, requestOptions) {
|
|
@@ -145,11 +156,10 @@ function createIngestionClient({
|
|
|
145
156
|
* Creates a new source.
|
|
146
157
|
*
|
|
147
158
|
* Required API Key ACLs:
|
|
148
|
-
*
|
|
149
|
-
*
|
|
150
|
-
*
|
|
151
|
-
*
|
|
152
|
-
* @param sourceCreate -.
|
|
159
|
+
* - addObject
|
|
160
|
+
* - deleteIndex
|
|
161
|
+
* - editSettings
|
|
162
|
+
* @param sourceCreate -
|
|
153
163
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
154
164
|
*/
|
|
155
165
|
createSource(sourceCreate, requestOptions) {
|
|
@@ -176,7 +186,6 @@ function createIngestionClient({
|
|
|
176
186
|
},
|
|
177
187
|
/**
|
|
178
188
|
* Creates a new task.
|
|
179
|
-
*
|
|
180
189
|
* @param taskCreate - Request body for creating a task.
|
|
181
190
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
182
191
|
*/
|
|
@@ -207,7 +216,6 @@ function createIngestionClient({
|
|
|
207
216
|
},
|
|
208
217
|
/**
|
|
209
218
|
* Creates a new task using the v1 endpoint, please use `createTask` instead.
|
|
210
|
-
*
|
|
211
219
|
* @param taskCreate - Request body for creating a task.
|
|
212
220
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
213
221
|
*/
|
|
@@ -241,7 +249,6 @@ function createIngestionClient({
|
|
|
241
249
|
},
|
|
242
250
|
/**
|
|
243
251
|
* Creates a new transformation.
|
|
244
|
-
*
|
|
245
252
|
* @param transformationCreate - Request body for creating a transformation.
|
|
246
253
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
247
254
|
*/
|
|
@@ -269,7 +276,6 @@ function createIngestionClient({
|
|
|
269
276
|
},
|
|
270
277
|
/**
|
|
271
278
|
* This method allow you to send requests to the Algolia REST API.
|
|
272
|
-
*
|
|
273
279
|
* @param customDelete - The customDelete object.
|
|
274
280
|
* @param customDelete.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
275
281
|
* @param customDelete.parameters - Query parameters to apply to the current query.
|
|
@@ -292,7 +298,6 @@ function createIngestionClient({
|
|
|
292
298
|
},
|
|
293
299
|
/**
|
|
294
300
|
* This method allow you to send requests to the Algolia REST API.
|
|
295
|
-
*
|
|
296
301
|
* @param customGet - The customGet object.
|
|
297
302
|
* @param customGet.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
298
303
|
* @param customGet.parameters - Query parameters to apply to the current query.
|
|
@@ -315,7 +320,6 @@ function createIngestionClient({
|
|
|
315
320
|
},
|
|
316
321
|
/**
|
|
317
322
|
* This method allow you to send requests to the Algolia REST API.
|
|
318
|
-
*
|
|
319
323
|
* @param customPost - The customPost object.
|
|
320
324
|
* @param customPost.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
321
325
|
* @param customPost.parameters - Query parameters to apply to the current query.
|
|
@@ -340,7 +344,6 @@ function createIngestionClient({
|
|
|
340
344
|
},
|
|
341
345
|
/**
|
|
342
346
|
* This method allow you to send requests to the Algolia REST API.
|
|
343
|
-
*
|
|
344
347
|
* @param customPut - The customPut object.
|
|
345
348
|
* @param customPut.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
346
349
|
* @param customPut.parameters - Query parameters to apply to the current query.
|
|
@@ -367,10 +370,9 @@ function createIngestionClient({
|
|
|
367
370
|
* Deletes an authentication resource. You can\'t delete authentication resources that are used by a source or a destination.
|
|
368
371
|
*
|
|
369
372
|
* Required API Key ACLs:
|
|
370
|
-
*
|
|
371
|
-
*
|
|
372
|
-
*
|
|
373
|
-
*
|
|
373
|
+
* - addObject
|
|
374
|
+
* - deleteIndex
|
|
375
|
+
* - editSettings
|
|
374
376
|
* @param deleteAuthentication - The deleteAuthentication object.
|
|
375
377
|
* @param deleteAuthentication.authenticationID - Unique identifier of an authentication resource.
|
|
376
378
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -397,10 +399,9 @@ function createIngestionClient({
|
|
|
397
399
|
* Deletes a destination by its ID. You can\'t delete destinations that are referenced in tasks.
|
|
398
400
|
*
|
|
399
401
|
* Required API Key ACLs:
|
|
400
|
-
*
|
|
401
|
-
*
|
|
402
|
-
*
|
|
403
|
-
*
|
|
402
|
+
* - addObject
|
|
403
|
+
* - deleteIndex
|
|
404
|
+
* - editSettings
|
|
404
405
|
* @param deleteDestination - The deleteDestination object.
|
|
405
406
|
* @param deleteDestination.destinationID - Unique identifier of a destination.
|
|
406
407
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -427,10 +428,9 @@ function createIngestionClient({
|
|
|
427
428
|
* Deletes a source by its ID. You can\'t delete sources that are referenced in tasks.
|
|
428
429
|
*
|
|
429
430
|
* Required API Key ACLs:
|
|
430
|
-
*
|
|
431
|
-
*
|
|
432
|
-
*
|
|
433
|
-
*
|
|
431
|
+
* - addObject
|
|
432
|
+
* - deleteIndex
|
|
433
|
+
* - editSettings
|
|
434
434
|
* @param deleteSource - The deleteSource object.
|
|
435
435
|
* @param deleteSource.sourceID - Unique identifier of a source.
|
|
436
436
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -452,7 +452,6 @@ function createIngestionClient({
|
|
|
452
452
|
},
|
|
453
453
|
/**
|
|
454
454
|
* Deletes a task by its ID.
|
|
455
|
-
*
|
|
456
455
|
* @param deleteTask - The deleteTask object.
|
|
457
456
|
* @param deleteTask.taskID - Unique identifier of a task.
|
|
458
457
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -474,7 +473,6 @@ function createIngestionClient({
|
|
|
474
473
|
},
|
|
475
474
|
/**
|
|
476
475
|
* Deletes a task by its ID using the v1 endpoint, please use `deleteTask` instead.
|
|
477
|
-
*
|
|
478
476
|
* @param deleteTaskV1 - The deleteTaskV1 object.
|
|
479
477
|
* @param deleteTaskV1.taskID - Unique identifier of a task.
|
|
480
478
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -496,7 +494,6 @@ function createIngestionClient({
|
|
|
496
494
|
},
|
|
497
495
|
/**
|
|
498
496
|
* Deletes a transformation by its ID.
|
|
499
|
-
*
|
|
500
497
|
* @param deleteTransformation - The deleteTransformation object.
|
|
501
498
|
* @param deleteTransformation.transformationID - Unique identifier of a transformation.
|
|
502
499
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -523,10 +520,9 @@ function createIngestionClient({
|
|
|
523
520
|
* Disables a task.
|
|
524
521
|
*
|
|
525
522
|
* Required API Key ACLs:
|
|
526
|
-
*
|
|
527
|
-
*
|
|
528
|
-
*
|
|
529
|
-
*
|
|
523
|
+
* - addObject
|
|
524
|
+
* - deleteIndex
|
|
525
|
+
* - editSettings
|
|
530
526
|
* @param disableTask - The disableTask object.
|
|
531
527
|
* @param disableTask.taskID - Unique identifier of a task.
|
|
532
528
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -550,10 +546,9 @@ function createIngestionClient({
|
|
|
550
546
|
* Disables a task using the v1 endpoint, please use `disableTask` instead.
|
|
551
547
|
*
|
|
552
548
|
* Required API Key ACLs:
|
|
553
|
-
*
|
|
554
|
-
*
|
|
555
|
-
*
|
|
556
|
-
*
|
|
549
|
+
* - addObject
|
|
550
|
+
* - deleteIndex
|
|
551
|
+
* - editSettings
|
|
557
552
|
* @param disableTaskV1 - The disableTaskV1 object.
|
|
558
553
|
* @param disableTaskV1.taskID - Unique identifier of a task.
|
|
559
554
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -577,10 +572,9 @@ function createIngestionClient({
|
|
|
577
572
|
* Enables a task.
|
|
578
573
|
*
|
|
579
574
|
* Required API Key ACLs:
|
|
580
|
-
*
|
|
581
|
-
*
|
|
582
|
-
*
|
|
583
|
-
*
|
|
575
|
+
* - addObject
|
|
576
|
+
* - deleteIndex
|
|
577
|
+
* - editSettings
|
|
584
578
|
* @param enableTask - The enableTask object.
|
|
585
579
|
* @param enableTask.taskID - Unique identifier of a task.
|
|
586
580
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -604,10 +598,9 @@ function createIngestionClient({
|
|
|
604
598
|
* Enables a task using the v1 endpoint, please use `enableTask` instead.
|
|
605
599
|
*
|
|
606
600
|
* Required API Key ACLs:
|
|
607
|
-
*
|
|
608
|
-
*
|
|
609
|
-
*
|
|
610
|
-
*
|
|
601
|
+
* - addObject
|
|
602
|
+
* - deleteIndex
|
|
603
|
+
* - editSettings
|
|
611
604
|
* @param enableTaskV1 - The enableTaskV1 object.
|
|
612
605
|
* @param enableTaskV1.taskID - Unique identifier of a task.
|
|
613
606
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -627,53 +620,13 @@ function createIngestionClient({
|
|
|
627
620
|
};
|
|
628
621
|
return transporter.request(request, requestOptions);
|
|
629
622
|
},
|
|
630
|
-
/**
|
|
631
|
-
* Generates code for the selected model based on the given prompt.
|
|
632
|
-
*
|
|
633
|
-
* Required API Key ACLs:
|
|
634
|
-
* - addObject
|
|
635
|
-
* - deleteIndex
|
|
636
|
-
* - editSettings.
|
|
637
|
-
*
|
|
638
|
-
* @param generateTransformationCodePayload - The generateTransformationCodePayload object.
|
|
639
|
-
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
640
|
-
*/
|
|
641
|
-
generateTransformationCode(generateTransformationCodePayload, requestOptions) {
|
|
642
|
-
if (!generateTransformationCodePayload) {
|
|
643
|
-
throw new Error(
|
|
644
|
-
"Parameter `generateTransformationCodePayload` is required when calling `generateTransformationCode`."
|
|
645
|
-
);
|
|
646
|
-
}
|
|
647
|
-
if (!generateTransformationCodePayload.id) {
|
|
648
|
-
throw new Error(
|
|
649
|
-
"Parameter `generateTransformationCodePayload.id` is required when calling `generateTransformationCode`."
|
|
650
|
-
);
|
|
651
|
-
}
|
|
652
|
-
if (!generateTransformationCodePayload.userPrompt) {
|
|
653
|
-
throw new Error(
|
|
654
|
-
"Parameter `generateTransformationCodePayload.userPrompt` is required when calling `generateTransformationCode`."
|
|
655
|
-
);
|
|
656
|
-
}
|
|
657
|
-
const requestPath = "/1/transformations/models";
|
|
658
|
-
const headers = {};
|
|
659
|
-
const queryParameters = {};
|
|
660
|
-
const request = {
|
|
661
|
-
method: "POST",
|
|
662
|
-
path: requestPath,
|
|
663
|
-
queryParameters,
|
|
664
|
-
headers,
|
|
665
|
-
data: generateTransformationCodePayload
|
|
666
|
-
};
|
|
667
|
-
return transporter.request(request, requestOptions);
|
|
668
|
-
},
|
|
669
623
|
/**
|
|
670
624
|
* Retrieves an authentication resource by its ID.
|
|
671
625
|
*
|
|
672
626
|
* Required API Key ACLs:
|
|
673
|
-
*
|
|
674
|
-
*
|
|
675
|
-
*
|
|
676
|
-
*
|
|
627
|
+
* - addObject
|
|
628
|
+
* - deleteIndex
|
|
629
|
+
* - editSettings
|
|
677
630
|
* @param getAuthentication - The getAuthentication object.
|
|
678
631
|
* @param getAuthentication.authenticationID - Unique identifier of an authentication resource.
|
|
679
632
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -700,10 +653,9 @@ function createIngestionClient({
|
|
|
700
653
|
* Retrieves a destination by its ID.
|
|
701
654
|
*
|
|
702
655
|
* Required API Key ACLs:
|
|
703
|
-
*
|
|
704
|
-
*
|
|
705
|
-
*
|
|
706
|
-
*
|
|
656
|
+
* - addObject
|
|
657
|
+
* - deleteIndex
|
|
658
|
+
* - editSettings
|
|
707
659
|
* @param getDestination - The getDestination object.
|
|
708
660
|
* @param getDestination.destinationID - Unique identifier of a destination.
|
|
709
661
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -730,10 +682,9 @@ function createIngestionClient({
|
|
|
730
682
|
* Retrieves a single task run event by its ID.
|
|
731
683
|
*
|
|
732
684
|
* Required API Key ACLs:
|
|
733
|
-
*
|
|
734
|
-
*
|
|
735
|
-
*
|
|
736
|
-
*
|
|
685
|
+
* - addObject
|
|
686
|
+
* - deleteIndex
|
|
687
|
+
* - editSettings
|
|
737
688
|
* @param getEvent - The getEvent object.
|
|
738
689
|
* @param getEvent.runID - Unique identifier of a task run.
|
|
739
690
|
* @param getEvent.eventID - Unique identifier of an event.
|
|
@@ -761,10 +712,9 @@ function createIngestionClient({
|
|
|
761
712
|
* Retrieve a single task run by its ID.
|
|
762
713
|
*
|
|
763
714
|
* Required API Key ACLs:
|
|
764
|
-
*
|
|
765
|
-
*
|
|
766
|
-
*
|
|
767
|
-
*
|
|
715
|
+
* - addObject
|
|
716
|
+
* - deleteIndex
|
|
717
|
+
* - editSettings
|
|
768
718
|
* @param getRun - The getRun object.
|
|
769
719
|
* @param getRun.runID - Unique identifier of a task run.
|
|
770
720
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -788,10 +738,9 @@ function createIngestionClient({
|
|
|
788
738
|
* Retrieve a source by its ID.
|
|
789
739
|
*
|
|
790
740
|
* Required API Key ACLs:
|
|
791
|
-
*
|
|
792
|
-
*
|
|
793
|
-
*
|
|
794
|
-
*
|
|
741
|
+
* - addObject
|
|
742
|
+
* - deleteIndex
|
|
743
|
+
* - editSettings
|
|
795
744
|
* @param getSource - The getSource object.
|
|
796
745
|
* @param getSource.sourceID - Unique identifier of a source.
|
|
797
746
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -815,10 +764,9 @@ function createIngestionClient({
|
|
|
815
764
|
* Retrieves a task by its ID.
|
|
816
765
|
*
|
|
817
766
|
* Required API Key ACLs:
|
|
818
|
-
*
|
|
819
|
-
*
|
|
820
|
-
*
|
|
821
|
-
*
|
|
767
|
+
* - addObject
|
|
768
|
+
* - deleteIndex
|
|
769
|
+
* - editSettings
|
|
822
770
|
* @param getTask - The getTask object.
|
|
823
771
|
* @param getTask.taskID - Unique identifier of a task.
|
|
824
772
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -842,10 +790,9 @@ function createIngestionClient({
|
|
|
842
790
|
* Retrieves a task by its ID using the v1 endpoint, please use `getTask` instead.
|
|
843
791
|
*
|
|
844
792
|
* Required API Key ACLs:
|
|
845
|
-
*
|
|
846
|
-
*
|
|
847
|
-
*
|
|
848
|
-
*
|
|
793
|
+
* - addObject
|
|
794
|
+
* - deleteIndex
|
|
795
|
+
* - editSettings
|
|
849
796
|
* @param getTaskV1 - The getTaskV1 object.
|
|
850
797
|
* @param getTaskV1.taskID - Unique identifier of a task.
|
|
851
798
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -869,10 +816,9 @@ function createIngestionClient({
|
|
|
869
816
|
* Retrieves a transformation by its ID.
|
|
870
817
|
*
|
|
871
818
|
* Required API Key ACLs:
|
|
872
|
-
*
|
|
873
|
-
*
|
|
874
|
-
*
|
|
875
|
-
*
|
|
819
|
+
* - addObject
|
|
820
|
+
* - deleteIndex
|
|
821
|
+
* - editSettings
|
|
876
822
|
* @param getTransformation - The getTransformation object.
|
|
877
823
|
* @param getTransformation.transformationID - Unique identifier of a transformation.
|
|
878
824
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -899,16 +845,15 @@ function createIngestionClient({
|
|
|
899
845
|
* Retrieves a list of all authentication resources.
|
|
900
846
|
*
|
|
901
847
|
* Required API Key ACLs:
|
|
902
|
-
*
|
|
903
|
-
*
|
|
904
|
-
*
|
|
905
|
-
*
|
|
848
|
+
* - addObject
|
|
849
|
+
* - deleteIndex
|
|
850
|
+
* - editSettings
|
|
906
851
|
* @param listAuthentications - The listAuthentications object.
|
|
907
852
|
* @param listAuthentications.itemsPerPage - Number of items per page.
|
|
908
853
|
* @param listAuthentications.page - Page number of the paginated API response.
|
|
909
854
|
* @param listAuthentications.type - Type of authentication resource to retrieve.
|
|
910
|
-
* @param listAuthentications.platform - Ecommerce platform for which to retrieve
|
|
911
|
-
* @param listAuthentications.sort - Property by which to sort the list of
|
|
855
|
+
* @param listAuthentications.platform - Ecommerce platform for which to retrieve authentications.
|
|
856
|
+
* @param listAuthentications.sort - Property by which to sort the list of authentications.
|
|
912
857
|
* @param listAuthentications.order - Sort order of the response, ascending or descending.
|
|
913
858
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
914
859
|
*/
|
|
@@ -917,22 +862,22 @@ function createIngestionClient({
|
|
|
917
862
|
const headers = {};
|
|
918
863
|
const queryParameters = {};
|
|
919
864
|
if (itemsPerPage !== void 0) {
|
|
920
|
-
queryParameters
|
|
865
|
+
queryParameters["itemsPerPage"] = itemsPerPage.toString();
|
|
921
866
|
}
|
|
922
867
|
if (page !== void 0) {
|
|
923
|
-
queryParameters
|
|
868
|
+
queryParameters["page"] = page.toString();
|
|
924
869
|
}
|
|
925
870
|
if (type !== void 0) {
|
|
926
|
-
queryParameters
|
|
871
|
+
queryParameters["type"] = type.toString();
|
|
927
872
|
}
|
|
928
873
|
if (platform !== void 0) {
|
|
929
|
-
queryParameters
|
|
874
|
+
queryParameters["platform"] = platform.toString();
|
|
930
875
|
}
|
|
931
876
|
if (sort !== void 0) {
|
|
932
|
-
queryParameters
|
|
877
|
+
queryParameters["sort"] = sort.toString();
|
|
933
878
|
}
|
|
934
879
|
if (order !== void 0) {
|
|
935
|
-
queryParameters
|
|
880
|
+
queryParameters["order"] = order.toString();
|
|
936
881
|
}
|
|
937
882
|
const request = {
|
|
938
883
|
method: "GET",
|
|
@@ -946,40 +891,43 @@ function createIngestionClient({
|
|
|
946
891
|
* Retrieves a list of destinations.
|
|
947
892
|
*
|
|
948
893
|
* Required API Key ACLs:
|
|
949
|
-
*
|
|
950
|
-
*
|
|
951
|
-
*
|
|
952
|
-
*
|
|
894
|
+
* - addObject
|
|
895
|
+
* - deleteIndex
|
|
896
|
+
* - editSettings
|
|
953
897
|
* @param listDestinations - The listDestinations object.
|
|
954
898
|
* @param listDestinations.itemsPerPage - Number of items per page.
|
|
955
899
|
* @param listDestinations.page - Page number of the paginated API response.
|
|
956
900
|
* @param listDestinations.type - Destination type.
|
|
957
901
|
* @param listDestinations.authenticationID - Authentication ID used by destinations.
|
|
902
|
+
* @param listDestinations.transformationID - Get the list of destinations used by a transformation.
|
|
958
903
|
* @param listDestinations.sort - Property by which to sort the destinations.
|
|
959
904
|
* @param listDestinations.order - Sort order of the response, ascending or descending.
|
|
960
905
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
961
906
|
*/
|
|
962
|
-
listDestinations({ itemsPerPage, page, type, authenticationID, sort, order } = {}, requestOptions = void 0) {
|
|
907
|
+
listDestinations({ itemsPerPage, page, type, authenticationID, transformationID, sort, order } = {}, requestOptions = void 0) {
|
|
963
908
|
const requestPath = "/1/destinations";
|
|
964
909
|
const headers = {};
|
|
965
910
|
const queryParameters = {};
|
|
966
911
|
if (itemsPerPage !== void 0) {
|
|
967
|
-
queryParameters
|
|
912
|
+
queryParameters["itemsPerPage"] = itemsPerPage.toString();
|
|
968
913
|
}
|
|
969
914
|
if (page !== void 0) {
|
|
970
|
-
queryParameters
|
|
915
|
+
queryParameters["page"] = page.toString();
|
|
971
916
|
}
|
|
972
917
|
if (type !== void 0) {
|
|
973
|
-
queryParameters
|
|
918
|
+
queryParameters["type"] = type.toString();
|
|
974
919
|
}
|
|
975
920
|
if (authenticationID !== void 0) {
|
|
976
|
-
queryParameters
|
|
921
|
+
queryParameters["authenticationID"] = authenticationID.toString();
|
|
922
|
+
}
|
|
923
|
+
if (transformationID !== void 0) {
|
|
924
|
+
queryParameters["transformationID"] = transformationID.toString();
|
|
977
925
|
}
|
|
978
926
|
if (sort !== void 0) {
|
|
979
|
-
queryParameters
|
|
927
|
+
queryParameters["sort"] = sort.toString();
|
|
980
928
|
}
|
|
981
929
|
if (order !== void 0) {
|
|
982
|
-
queryParameters
|
|
930
|
+
queryParameters["order"] = order.toString();
|
|
983
931
|
}
|
|
984
932
|
const request = {
|
|
985
933
|
method: "GET",
|
|
@@ -990,13 +938,12 @@ function createIngestionClient({
|
|
|
990
938
|
return transporter.request(request, requestOptions);
|
|
991
939
|
},
|
|
992
940
|
/**
|
|
993
|
-
* Retrieves a list of events for a task run, identified by
|
|
941
|
+
* Retrieves a list of events for a task run, identified by its ID.
|
|
994
942
|
*
|
|
995
943
|
* Required API Key ACLs:
|
|
996
|
-
*
|
|
997
|
-
*
|
|
998
|
-
*
|
|
999
|
-
*
|
|
944
|
+
* - addObject
|
|
945
|
+
* - deleteIndex
|
|
946
|
+
* - editSettings
|
|
1000
947
|
* @param listEvents - The listEvents object.
|
|
1001
948
|
* @param listEvents.runID - Unique identifier of a task run.
|
|
1002
949
|
* @param listEvents.itemsPerPage - Number of items per page.
|
|
@@ -1017,28 +964,28 @@ function createIngestionClient({
|
|
|
1017
964
|
const headers = {};
|
|
1018
965
|
const queryParameters = {};
|
|
1019
966
|
if (itemsPerPage !== void 0) {
|
|
1020
|
-
queryParameters
|
|
967
|
+
queryParameters["itemsPerPage"] = itemsPerPage.toString();
|
|
1021
968
|
}
|
|
1022
969
|
if (page !== void 0) {
|
|
1023
|
-
queryParameters
|
|
970
|
+
queryParameters["page"] = page.toString();
|
|
1024
971
|
}
|
|
1025
972
|
if (status !== void 0) {
|
|
1026
|
-
queryParameters
|
|
973
|
+
queryParameters["status"] = status.toString();
|
|
1027
974
|
}
|
|
1028
975
|
if (type !== void 0) {
|
|
1029
|
-
queryParameters
|
|
976
|
+
queryParameters["type"] = type.toString();
|
|
1030
977
|
}
|
|
1031
978
|
if (sort !== void 0) {
|
|
1032
|
-
queryParameters
|
|
979
|
+
queryParameters["sort"] = sort.toString();
|
|
1033
980
|
}
|
|
1034
981
|
if (order !== void 0) {
|
|
1035
|
-
queryParameters
|
|
982
|
+
queryParameters["order"] = order.toString();
|
|
1036
983
|
}
|
|
1037
984
|
if (startDate !== void 0) {
|
|
1038
|
-
queryParameters
|
|
985
|
+
queryParameters["startDate"] = startDate.toString();
|
|
1039
986
|
}
|
|
1040
987
|
if (endDate !== void 0) {
|
|
1041
|
-
queryParameters
|
|
988
|
+
queryParameters["endDate"] = endDate.toString();
|
|
1042
989
|
}
|
|
1043
990
|
const request = {
|
|
1044
991
|
method: "GET",
|
|
@@ -1052,10 +999,9 @@ function createIngestionClient({
|
|
|
1052
999
|
* Retrieve a list of task runs.
|
|
1053
1000
|
*
|
|
1054
1001
|
* Required API Key ACLs:
|
|
1055
|
-
*
|
|
1056
|
-
*
|
|
1057
|
-
*
|
|
1058
|
-
*
|
|
1002
|
+
* - addObject
|
|
1003
|
+
* - deleteIndex
|
|
1004
|
+
* - editSettings
|
|
1059
1005
|
* @param listRuns - The listRuns object.
|
|
1060
1006
|
* @param listRuns.itemsPerPage - Number of items per page.
|
|
1061
1007
|
* @param listRuns.page - Page number of the paginated API response.
|
|
@@ -1073,31 +1019,31 @@ function createIngestionClient({
|
|
|
1073
1019
|
const headers = {};
|
|
1074
1020
|
const queryParameters = {};
|
|
1075
1021
|
if (itemsPerPage !== void 0) {
|
|
1076
|
-
queryParameters
|
|
1022
|
+
queryParameters["itemsPerPage"] = itemsPerPage.toString();
|
|
1077
1023
|
}
|
|
1078
1024
|
if (page !== void 0) {
|
|
1079
|
-
queryParameters
|
|
1025
|
+
queryParameters["page"] = page.toString();
|
|
1080
1026
|
}
|
|
1081
1027
|
if (status !== void 0) {
|
|
1082
|
-
queryParameters
|
|
1028
|
+
queryParameters["status"] = status.toString();
|
|
1083
1029
|
}
|
|
1084
1030
|
if (type !== void 0) {
|
|
1085
|
-
queryParameters
|
|
1031
|
+
queryParameters["type"] = type.toString();
|
|
1086
1032
|
}
|
|
1087
1033
|
if (taskID !== void 0) {
|
|
1088
|
-
queryParameters
|
|
1034
|
+
queryParameters["taskID"] = taskID.toString();
|
|
1089
1035
|
}
|
|
1090
1036
|
if (sort !== void 0) {
|
|
1091
|
-
queryParameters
|
|
1037
|
+
queryParameters["sort"] = sort.toString();
|
|
1092
1038
|
}
|
|
1093
1039
|
if (order !== void 0) {
|
|
1094
|
-
queryParameters
|
|
1040
|
+
queryParameters["order"] = order.toString();
|
|
1095
1041
|
}
|
|
1096
1042
|
if (startDate !== void 0) {
|
|
1097
|
-
queryParameters
|
|
1043
|
+
queryParameters["startDate"] = startDate.toString();
|
|
1098
1044
|
}
|
|
1099
1045
|
if (endDate !== void 0) {
|
|
1100
|
-
queryParameters
|
|
1046
|
+
queryParameters["endDate"] = endDate.toString();
|
|
1101
1047
|
}
|
|
1102
1048
|
const request = {
|
|
1103
1049
|
method: "GET",
|
|
@@ -1111,15 +1057,14 @@ function createIngestionClient({
|
|
|
1111
1057
|
* Retrieves a list of sources.
|
|
1112
1058
|
*
|
|
1113
1059
|
* Required API Key ACLs:
|
|
1114
|
-
*
|
|
1115
|
-
*
|
|
1116
|
-
*
|
|
1117
|
-
*
|
|
1060
|
+
* - addObject
|
|
1061
|
+
* - deleteIndex
|
|
1062
|
+
* - editSettings
|
|
1118
1063
|
* @param listSources - The listSources object.
|
|
1119
1064
|
* @param listSources.itemsPerPage - Number of items per page.
|
|
1120
1065
|
* @param listSources.page - Page number of the paginated API response.
|
|
1121
1066
|
* @param listSources.type - Source type. Some sources require authentication.
|
|
1122
|
-
* @param listSources.authenticationID - Authentication IDs of the sources to retrieve. \'none\' returns sources that doesn\'t have an authentication
|
|
1067
|
+
* @param listSources.authenticationID - Authentication IDs of the sources to retrieve. \'none\' returns sources that doesn\'t have an authentication.
|
|
1123
1068
|
* @param listSources.sort - Property by which to sort the list of sources.
|
|
1124
1069
|
* @param listSources.order - Sort order of the response, ascending or descending.
|
|
1125
1070
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1129,22 +1074,22 @@ function createIngestionClient({
|
|
|
1129
1074
|
const headers = {};
|
|
1130
1075
|
const queryParameters = {};
|
|
1131
1076
|
if (itemsPerPage !== void 0) {
|
|
1132
|
-
queryParameters
|
|
1077
|
+
queryParameters["itemsPerPage"] = itemsPerPage.toString();
|
|
1133
1078
|
}
|
|
1134
1079
|
if (page !== void 0) {
|
|
1135
|
-
queryParameters
|
|
1080
|
+
queryParameters["page"] = page.toString();
|
|
1136
1081
|
}
|
|
1137
1082
|
if (type !== void 0) {
|
|
1138
|
-
queryParameters
|
|
1083
|
+
queryParameters["type"] = type.toString();
|
|
1139
1084
|
}
|
|
1140
1085
|
if (authenticationID !== void 0) {
|
|
1141
|
-
queryParameters
|
|
1086
|
+
queryParameters["authenticationID"] = authenticationID.toString();
|
|
1142
1087
|
}
|
|
1143
1088
|
if (sort !== void 0) {
|
|
1144
|
-
queryParameters
|
|
1089
|
+
queryParameters["sort"] = sort.toString();
|
|
1145
1090
|
}
|
|
1146
1091
|
if (order !== void 0) {
|
|
1147
|
-
queryParameters
|
|
1092
|
+
queryParameters["order"] = order.toString();
|
|
1148
1093
|
}
|
|
1149
1094
|
const request = {
|
|
1150
1095
|
method: "GET",
|
|
@@ -1158,10 +1103,9 @@ function createIngestionClient({
|
|
|
1158
1103
|
* Retrieves a list of tasks.
|
|
1159
1104
|
*
|
|
1160
1105
|
* Required API Key ACLs:
|
|
1161
|
-
*
|
|
1162
|
-
*
|
|
1163
|
-
*
|
|
1164
|
-
*
|
|
1106
|
+
* - addObject
|
|
1107
|
+
* - deleteIndex
|
|
1108
|
+
* - editSettings
|
|
1165
1109
|
* @param listTasks - The listTasks object.
|
|
1166
1110
|
* @param listTasks.itemsPerPage - Number of items per page.
|
|
1167
1111
|
* @param listTasks.page - Page number of the paginated API response.
|
|
@@ -1179,31 +1123,31 @@ function createIngestionClient({
|
|
|
1179
1123
|
const headers = {};
|
|
1180
1124
|
const queryParameters = {};
|
|
1181
1125
|
if (itemsPerPage !== void 0) {
|
|
1182
|
-
queryParameters
|
|
1126
|
+
queryParameters["itemsPerPage"] = itemsPerPage.toString();
|
|
1183
1127
|
}
|
|
1184
1128
|
if (page !== void 0) {
|
|
1185
|
-
queryParameters
|
|
1129
|
+
queryParameters["page"] = page.toString();
|
|
1186
1130
|
}
|
|
1187
1131
|
if (action !== void 0) {
|
|
1188
|
-
queryParameters
|
|
1132
|
+
queryParameters["action"] = action.toString();
|
|
1189
1133
|
}
|
|
1190
1134
|
if (enabled !== void 0) {
|
|
1191
|
-
queryParameters
|
|
1135
|
+
queryParameters["enabled"] = enabled.toString();
|
|
1192
1136
|
}
|
|
1193
1137
|
if (sourceID !== void 0) {
|
|
1194
|
-
queryParameters
|
|
1138
|
+
queryParameters["sourceID"] = sourceID.toString();
|
|
1195
1139
|
}
|
|
1196
1140
|
if (destinationID !== void 0) {
|
|
1197
|
-
queryParameters
|
|
1141
|
+
queryParameters["destinationID"] = destinationID.toString();
|
|
1198
1142
|
}
|
|
1199
1143
|
if (triggerType !== void 0) {
|
|
1200
|
-
queryParameters
|
|
1144
|
+
queryParameters["triggerType"] = triggerType.toString();
|
|
1201
1145
|
}
|
|
1202
1146
|
if (sort !== void 0) {
|
|
1203
|
-
queryParameters
|
|
1147
|
+
queryParameters["sort"] = sort.toString();
|
|
1204
1148
|
}
|
|
1205
1149
|
if (order !== void 0) {
|
|
1206
|
-
queryParameters
|
|
1150
|
+
queryParameters["order"] = order.toString();
|
|
1207
1151
|
}
|
|
1208
1152
|
const request = {
|
|
1209
1153
|
method: "GET",
|
|
@@ -1217,10 +1161,9 @@ function createIngestionClient({
|
|
|
1217
1161
|
* Retrieves a list of tasks using the v1 endpoint, please use `getTasks` instead.
|
|
1218
1162
|
*
|
|
1219
1163
|
* Required API Key ACLs:
|
|
1220
|
-
*
|
|
1221
|
-
*
|
|
1222
|
-
*
|
|
1223
|
-
*
|
|
1164
|
+
* - addObject
|
|
1165
|
+
* - deleteIndex
|
|
1166
|
+
* - editSettings
|
|
1224
1167
|
* @param listTasksV1 - The listTasksV1 object.
|
|
1225
1168
|
* @param listTasksV1.itemsPerPage - Number of items per page.
|
|
1226
1169
|
* @param listTasksV1.page - Page number of the paginated API response.
|
|
@@ -1238,31 +1181,31 @@ function createIngestionClient({
|
|
|
1238
1181
|
const headers = {};
|
|
1239
1182
|
const queryParameters = {};
|
|
1240
1183
|
if (itemsPerPage !== void 0) {
|
|
1241
|
-
queryParameters
|
|
1184
|
+
queryParameters["itemsPerPage"] = itemsPerPage.toString();
|
|
1242
1185
|
}
|
|
1243
1186
|
if (page !== void 0) {
|
|
1244
|
-
queryParameters
|
|
1187
|
+
queryParameters["page"] = page.toString();
|
|
1245
1188
|
}
|
|
1246
1189
|
if (action !== void 0) {
|
|
1247
|
-
queryParameters
|
|
1190
|
+
queryParameters["action"] = action.toString();
|
|
1248
1191
|
}
|
|
1249
1192
|
if (enabled !== void 0) {
|
|
1250
|
-
queryParameters
|
|
1193
|
+
queryParameters["enabled"] = enabled.toString();
|
|
1251
1194
|
}
|
|
1252
1195
|
if (sourceID !== void 0) {
|
|
1253
|
-
queryParameters
|
|
1196
|
+
queryParameters["sourceID"] = sourceID.toString();
|
|
1254
1197
|
}
|
|
1255
1198
|
if (destinationID !== void 0) {
|
|
1256
|
-
queryParameters
|
|
1199
|
+
queryParameters["destinationID"] = destinationID.toString();
|
|
1257
1200
|
}
|
|
1258
1201
|
if (triggerType !== void 0) {
|
|
1259
|
-
queryParameters
|
|
1202
|
+
queryParameters["triggerType"] = triggerType.toString();
|
|
1260
1203
|
}
|
|
1261
1204
|
if (sort !== void 0) {
|
|
1262
|
-
queryParameters
|
|
1205
|
+
queryParameters["sort"] = sort.toString();
|
|
1263
1206
|
}
|
|
1264
1207
|
if (order !== void 0) {
|
|
1265
|
-
queryParameters
|
|
1208
|
+
queryParameters["order"] = order.toString();
|
|
1266
1209
|
}
|
|
1267
1210
|
const request = {
|
|
1268
1211
|
method: "GET",
|
|
@@ -1272,40 +1215,17 @@ function createIngestionClient({
|
|
|
1272
1215
|
};
|
|
1273
1216
|
return transporter.request(request, requestOptions);
|
|
1274
1217
|
},
|
|
1275
|
-
/**
|
|
1276
|
-
* Retrieves a list of existing LLM transformation helpers.
|
|
1277
|
-
*
|
|
1278
|
-
* Required API Key ACLs:
|
|
1279
|
-
* - addObject
|
|
1280
|
-
* - deleteIndex
|
|
1281
|
-
* - editSettings.
|
|
1282
|
-
*
|
|
1283
|
-
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1284
|
-
*/
|
|
1285
|
-
listTransformationModels(requestOptions) {
|
|
1286
|
-
const requestPath = "/1/transformations/models";
|
|
1287
|
-
const headers = {};
|
|
1288
|
-
const queryParameters = {};
|
|
1289
|
-
const request = {
|
|
1290
|
-
method: "GET",
|
|
1291
|
-
path: requestPath,
|
|
1292
|
-
queryParameters,
|
|
1293
|
-
headers
|
|
1294
|
-
};
|
|
1295
|
-
return transporter.request(request, requestOptions);
|
|
1296
|
-
},
|
|
1297
1218
|
/**
|
|
1298
1219
|
* Retrieves a list of transformations.
|
|
1299
1220
|
*
|
|
1300
1221
|
* Required API Key ACLs:
|
|
1301
|
-
*
|
|
1302
|
-
*
|
|
1303
|
-
*
|
|
1304
|
-
*
|
|
1222
|
+
* - addObject
|
|
1223
|
+
* - deleteIndex
|
|
1224
|
+
* - editSettings
|
|
1305
1225
|
* @param listTransformations - The listTransformations object.
|
|
1306
1226
|
* @param listTransformations.itemsPerPage - Number of items per page.
|
|
1307
1227
|
* @param listTransformations.page - Page number of the paginated API response.
|
|
1308
|
-
* @param listTransformations.sort - Property by which to sort the list.
|
|
1228
|
+
* @param listTransformations.sort - Property by which to sort the list of transformations.
|
|
1309
1229
|
* @param listTransformations.order - Sort order of the response, ascending or descending.
|
|
1310
1230
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1311
1231
|
*/
|
|
@@ -1314,16 +1234,16 @@ function createIngestionClient({
|
|
|
1314
1234
|
const headers = {};
|
|
1315
1235
|
const queryParameters = {};
|
|
1316
1236
|
if (itemsPerPage !== void 0) {
|
|
1317
|
-
queryParameters
|
|
1237
|
+
queryParameters["itemsPerPage"] = itemsPerPage.toString();
|
|
1318
1238
|
}
|
|
1319
1239
|
if (page !== void 0) {
|
|
1320
|
-
queryParameters
|
|
1240
|
+
queryParameters["page"] = page.toString();
|
|
1321
1241
|
}
|
|
1322
1242
|
if (sort !== void 0) {
|
|
1323
|
-
queryParameters
|
|
1243
|
+
queryParameters["sort"] = sort.toString();
|
|
1324
1244
|
}
|
|
1325
1245
|
if (order !== void 0) {
|
|
1326
|
-
queryParameters
|
|
1246
|
+
queryParameters["order"] = order.toString();
|
|
1327
1247
|
}
|
|
1328
1248
|
const request = {
|
|
1329
1249
|
method: "GET",
|
|
@@ -1337,10 +1257,9 @@ function createIngestionClient({
|
|
|
1337
1257
|
* Push a `batch` request payload through the Pipeline. You can check the status of task pushes with the observability endpoints.
|
|
1338
1258
|
*
|
|
1339
1259
|
* Required API Key ACLs:
|
|
1340
|
-
*
|
|
1341
|
-
*
|
|
1342
|
-
*
|
|
1343
|
-
*
|
|
1260
|
+
* - addObject
|
|
1261
|
+
* - deleteIndex
|
|
1262
|
+
* - editSettings
|
|
1344
1263
|
* @param pushTask - The pushTask object.
|
|
1345
1264
|
* @param pushTask.taskID - Unique identifier of a task.
|
|
1346
1265
|
* @param pushTask.pushTaskPayload - Request body of a Search API `batch` request that will be pushed in the Connectors pipeline.
|
|
@@ -1375,13 +1294,12 @@ function createIngestionClient({
|
|
|
1375
1294
|
* Runs all tasks linked to a source, only available for Shopify sources. It will create 1 run per task.
|
|
1376
1295
|
*
|
|
1377
1296
|
* Required API Key ACLs:
|
|
1378
|
-
*
|
|
1379
|
-
*
|
|
1380
|
-
*
|
|
1381
|
-
*
|
|
1297
|
+
* - addObject
|
|
1298
|
+
* - deleteIndex
|
|
1299
|
+
* - editSettings
|
|
1382
1300
|
* @param runSource - The runSource object.
|
|
1383
1301
|
* @param runSource.sourceID - Unique identifier of a source.
|
|
1384
|
-
* @param runSource.runSourcePayload
|
|
1302
|
+
* @param runSource.runSourcePayload -
|
|
1385
1303
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1386
1304
|
*/
|
|
1387
1305
|
runSource({ sourceID, runSourcePayload }, requestOptions) {
|
|
@@ -1404,10 +1322,9 @@ function createIngestionClient({
|
|
|
1404
1322
|
* Runs a task. You can check the status of task runs with the observability endpoints.
|
|
1405
1323
|
*
|
|
1406
1324
|
* Required API Key ACLs:
|
|
1407
|
-
*
|
|
1408
|
-
*
|
|
1409
|
-
*
|
|
1410
|
-
*
|
|
1325
|
+
* - addObject
|
|
1326
|
+
* - deleteIndex
|
|
1327
|
+
* - editSettings
|
|
1411
1328
|
* @param runTask - The runTask object.
|
|
1412
1329
|
* @param runTask.taskID - Unique identifier of a task.
|
|
1413
1330
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1431,10 +1348,9 @@ function createIngestionClient({
|
|
|
1431
1348
|
* Runs a task using the v1 endpoint, please use `runTask` instead. You can check the status of task runs with the observability endpoints.
|
|
1432
1349
|
*
|
|
1433
1350
|
* Required API Key ACLs:
|
|
1434
|
-
*
|
|
1435
|
-
*
|
|
1436
|
-
*
|
|
1437
|
-
*
|
|
1351
|
+
* - addObject
|
|
1352
|
+
* - deleteIndex
|
|
1353
|
+
* - editSettings
|
|
1438
1354
|
* @param runTaskV1 - The runTaskV1 object.
|
|
1439
1355
|
* @param runTaskV1.taskID - Unique identifier of a task.
|
|
1440
1356
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1458,10 +1374,9 @@ function createIngestionClient({
|
|
|
1458
1374
|
* Searches for authentication resources.
|
|
1459
1375
|
*
|
|
1460
1376
|
* Required API Key ACLs:
|
|
1461
|
-
*
|
|
1462
|
-
*
|
|
1463
|
-
*
|
|
1464
|
-
*
|
|
1377
|
+
* - addObject
|
|
1378
|
+
* - deleteIndex
|
|
1379
|
+
* - editSettings
|
|
1465
1380
|
* @param authenticationSearch - The authenticationSearch object.
|
|
1466
1381
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1467
1382
|
*/
|
|
@@ -1490,10 +1405,9 @@ function createIngestionClient({
|
|
|
1490
1405
|
* Searches for destinations.
|
|
1491
1406
|
*
|
|
1492
1407
|
* Required API Key ACLs:
|
|
1493
|
-
*
|
|
1494
|
-
*
|
|
1495
|
-
*
|
|
1496
|
-
*
|
|
1408
|
+
* - addObject
|
|
1409
|
+
* - deleteIndex
|
|
1410
|
+
* - editSettings
|
|
1497
1411
|
* @param destinationSearch - The destinationSearch object.
|
|
1498
1412
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1499
1413
|
*/
|
|
@@ -1520,10 +1434,9 @@ function createIngestionClient({
|
|
|
1520
1434
|
* Searches for sources.
|
|
1521
1435
|
*
|
|
1522
1436
|
* Required API Key ACLs:
|
|
1523
|
-
*
|
|
1524
|
-
*
|
|
1525
|
-
*
|
|
1526
|
-
*
|
|
1437
|
+
* - addObject
|
|
1438
|
+
* - deleteIndex
|
|
1439
|
+
* - editSettings
|
|
1527
1440
|
* @param sourceSearch - The sourceSearch object.
|
|
1528
1441
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1529
1442
|
*/
|
|
@@ -1550,10 +1463,9 @@ function createIngestionClient({
|
|
|
1550
1463
|
* Searches for tasks.
|
|
1551
1464
|
*
|
|
1552
1465
|
* Required API Key ACLs:
|
|
1553
|
-
*
|
|
1554
|
-
*
|
|
1555
|
-
*
|
|
1556
|
-
*
|
|
1466
|
+
* - addObject
|
|
1467
|
+
* - deleteIndex
|
|
1468
|
+
* - editSettings
|
|
1557
1469
|
* @param taskSearch - The taskSearch object.
|
|
1558
1470
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1559
1471
|
*/
|
|
@@ -1580,10 +1492,9 @@ function createIngestionClient({
|
|
|
1580
1492
|
* Searches for tasks using the v1 endpoint, please use `searchTasks` instead.
|
|
1581
1493
|
*
|
|
1582
1494
|
* Required API Key ACLs:
|
|
1583
|
-
*
|
|
1584
|
-
*
|
|
1585
|
-
*
|
|
1586
|
-
*
|
|
1495
|
+
* - addObject
|
|
1496
|
+
* - deleteIndex
|
|
1497
|
+
* - editSettings
|
|
1587
1498
|
* @param taskSearch - The taskSearch object.
|
|
1588
1499
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1589
1500
|
*/
|
|
@@ -1610,10 +1521,9 @@ function createIngestionClient({
|
|
|
1610
1521
|
* Searches for transformations.
|
|
1611
1522
|
*
|
|
1612
1523
|
* Required API Key ACLs:
|
|
1613
|
-
*
|
|
1614
|
-
*
|
|
1615
|
-
*
|
|
1616
|
-
*
|
|
1524
|
+
* - addObject
|
|
1525
|
+
* - deleteIndex
|
|
1526
|
+
* - editSettings
|
|
1617
1527
|
* @param transformationSearch - The transformationSearch object.
|
|
1618
1528
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1619
1529
|
*/
|
|
@@ -1642,10 +1552,9 @@ function createIngestionClient({
|
|
|
1642
1552
|
* Triggers a stream-listing request for a source. Triggering stream-listing requests only works with sources with `type: docker` and `imageType: singer`.
|
|
1643
1553
|
*
|
|
1644
1554
|
* Required API Key ACLs:
|
|
1645
|
-
*
|
|
1646
|
-
*
|
|
1647
|
-
*
|
|
1648
|
-
*
|
|
1555
|
+
* - addObject
|
|
1556
|
+
* - deleteIndex
|
|
1557
|
+
* - editSettings
|
|
1649
1558
|
* @param triggerDockerSourceDiscover - The triggerDockerSourceDiscover object.
|
|
1650
1559
|
* @param triggerDockerSourceDiscover.sourceID - Unique identifier of a source.
|
|
1651
1560
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1669,10 +1578,9 @@ function createIngestionClient({
|
|
|
1669
1578
|
* Try a transformation before creating it.
|
|
1670
1579
|
*
|
|
1671
1580
|
* Required API Key ACLs:
|
|
1672
|
-
*
|
|
1673
|
-
*
|
|
1674
|
-
*
|
|
1675
|
-
*
|
|
1581
|
+
* - addObject
|
|
1582
|
+
* - deleteIndex
|
|
1583
|
+
* - editSettings
|
|
1676
1584
|
* @param transformationTry - The transformationTry object.
|
|
1677
1585
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1678
1586
|
*/
|
|
@@ -1702,10 +1610,9 @@ function createIngestionClient({
|
|
|
1702
1610
|
* Try a transformation before updating it.
|
|
1703
1611
|
*
|
|
1704
1612
|
* Required API Key ACLs:
|
|
1705
|
-
*
|
|
1706
|
-
*
|
|
1707
|
-
*
|
|
1708
|
-
*
|
|
1613
|
+
* - addObject
|
|
1614
|
+
* - deleteIndex
|
|
1615
|
+
* - editSettings
|
|
1709
1616
|
* @param tryTransformationBeforeUpdate - The tryTransformationBeforeUpdate object.
|
|
1710
1617
|
* @param tryTransformationBeforeUpdate.transformationID - Unique identifier of a transformation.
|
|
1711
1618
|
* @param tryTransformationBeforeUpdate.transformationTry - The transformationTry object.
|
|
@@ -1745,10 +1652,9 @@ function createIngestionClient({
|
|
|
1745
1652
|
* Updates an authentication resource.
|
|
1746
1653
|
*
|
|
1747
1654
|
* Required API Key ACLs:
|
|
1748
|
-
*
|
|
1749
|
-
*
|
|
1750
|
-
*
|
|
1751
|
-
*
|
|
1655
|
+
* - addObject
|
|
1656
|
+
* - deleteIndex
|
|
1657
|
+
* - editSettings
|
|
1752
1658
|
* @param updateAuthentication - The updateAuthentication object.
|
|
1753
1659
|
* @param updateAuthentication.authenticationID - Unique identifier of an authentication resource.
|
|
1754
1660
|
* @param updateAuthentication.authenticationUpdate - The authenticationUpdate object.
|
|
@@ -1780,10 +1686,9 @@ function createIngestionClient({
|
|
|
1780
1686
|
* Updates the destination by its ID.
|
|
1781
1687
|
*
|
|
1782
1688
|
* Required API Key ACLs:
|
|
1783
|
-
*
|
|
1784
|
-
*
|
|
1785
|
-
*
|
|
1786
|
-
*
|
|
1689
|
+
* - addObject
|
|
1690
|
+
* - deleteIndex
|
|
1691
|
+
* - editSettings
|
|
1787
1692
|
* @param updateDestination - The updateDestination object.
|
|
1788
1693
|
* @param updateDestination.destinationID - Unique identifier of a destination.
|
|
1789
1694
|
* @param updateDestination.destinationUpdate - The destinationUpdate object.
|
|
@@ -1815,10 +1720,9 @@ function createIngestionClient({
|
|
|
1815
1720
|
* Updates a source by its ID.
|
|
1816
1721
|
*
|
|
1817
1722
|
* Required API Key ACLs:
|
|
1818
|
-
*
|
|
1819
|
-
*
|
|
1820
|
-
*
|
|
1821
|
-
*
|
|
1723
|
+
* - addObject
|
|
1724
|
+
* - deleteIndex
|
|
1725
|
+
* - editSettings
|
|
1822
1726
|
* @param updateSource - The updateSource object.
|
|
1823
1727
|
* @param updateSource.sourceID - Unique identifier of a source.
|
|
1824
1728
|
* @param updateSource.sourceUpdate - The sourceUpdate object.
|
|
@@ -1845,7 +1749,6 @@ function createIngestionClient({
|
|
|
1845
1749
|
},
|
|
1846
1750
|
/**
|
|
1847
1751
|
* Updates a task by its ID.
|
|
1848
|
-
*
|
|
1849
1752
|
* @param updateTask - The updateTask object.
|
|
1850
1753
|
* @param updateTask.taskID - Unique identifier of a task.
|
|
1851
1754
|
* @param updateTask.taskUpdate - The taskUpdate object.
|
|
@@ -1872,7 +1775,6 @@ function createIngestionClient({
|
|
|
1872
1775
|
},
|
|
1873
1776
|
/**
|
|
1874
1777
|
* Updates a task by its ID using the v1 endpoint, please use `updateTask` instead.
|
|
1875
|
-
*
|
|
1876
1778
|
* @param updateTaskV1 - The updateTaskV1 object.
|
|
1877
1779
|
* @param updateTaskV1.taskID - Unique identifier of a task.
|
|
1878
1780
|
* @param updateTaskV1.taskUpdate - The taskUpdate object.
|
|
@@ -1899,7 +1801,6 @@ function createIngestionClient({
|
|
|
1899
1801
|
},
|
|
1900
1802
|
/**
|
|
1901
1803
|
* Updates a transformation by its ID.
|
|
1902
|
-
*
|
|
1903
1804
|
* @param updateTransformation - The updateTransformation object.
|
|
1904
1805
|
* @param updateTransformation.transformationID - Unique identifier of a transformation.
|
|
1905
1806
|
* @param updateTransformation.transformationCreate - The transformationCreate object.
|
|
@@ -1937,11 +1838,10 @@ function createIngestionClient({
|
|
|
1937
1838
|
* Validates a source payload to ensure it can be created and that the data source can be reached by Algolia.
|
|
1938
1839
|
*
|
|
1939
1840
|
* Required API Key ACLs:
|
|
1940
|
-
*
|
|
1941
|
-
*
|
|
1942
|
-
*
|
|
1943
|
-
*
|
|
1944
|
-
* @param sourceCreate -.
|
|
1841
|
+
* - addObject
|
|
1842
|
+
* - deleteIndex
|
|
1843
|
+
* - editSettings
|
|
1844
|
+
* @param sourceCreate -
|
|
1945
1845
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1946
1846
|
*/
|
|
1947
1847
|
validateSource(sourceCreate, requestOptions = void 0) {
|
|
@@ -1961,10 +1861,9 @@ function createIngestionClient({
|
|
|
1961
1861
|
* Validates an update of a source payload to ensure it can be created and that the data source can be reached by Algolia.
|
|
1962
1862
|
*
|
|
1963
1863
|
* Required API Key ACLs:
|
|
1964
|
-
*
|
|
1965
|
-
*
|
|
1966
|
-
*
|
|
1967
|
-
*
|
|
1864
|
+
* - addObject
|
|
1865
|
+
* - deleteIndex
|
|
1866
|
+
* - editSettings
|
|
1968
1867
|
* @param validateSourceBeforeUpdate - The validateSourceBeforeUpdate object.
|
|
1969
1868
|
* @param validateSourceBeforeUpdate.sourceID - Unique identifier of a source.
|
|
1970
1869
|
* @param validateSourceBeforeUpdate.sourceUpdate - The sourceUpdate object.
|