@segment/public-api-sdk-typescript 32.0.2-b5006 → 33.0.2-b5330

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.
Files changed (753) hide show
  1. package/README.md +31 -27
  2. package/api/aPICallsApi.ts +23 -815
  3. package/api/auditTrailApi.ts +12 -462
  4. package/api/catalogApi.ts +103 -2182
  5. package/api/deletionAndSuppressionApi.ts +174 -3281
  6. package/api/destinationFiltersApi.ts +112 -2449
  7. package/api/destinationsApi.ts +238 -2166
  8. package/api/edgeFunctionsApi.ts +13 -9
  9. package/api/eventsApi.ts +19 -625
  10. package/api/functionsApi.ts +120 -2289
  11. package/api/iAMGroupsApi.ts +232 -4750
  12. package/api/iAMRolesApi.ts +8 -347
  13. package/api/iAMUsersApi.ts +190 -3433
  14. package/api/labelsApi.ts +59 -1079
  15. package/api/monthlyTrackedUsersApi.ts +23 -815
  16. package/api/selectiveSyncApi.ts +156 -2538
  17. package/api/sourcesApi.ts +211 -4276
  18. package/api/spacesApi.ts +10 -7
  19. package/api/testingApi.ts +14 -317
  20. package/api/trackingPlansApi.ts +257 -4799
  21. package/api/transformationsApi.ts +60 -650
  22. package/api/warehousesApi.ts +200 -3827
  23. package/api/workspacesApi.ts +6 -306
  24. package/dist/api/aPICallsApi.d.ts +2 -50
  25. package/dist/api/aPICallsApi.js +18 -560
  26. package/dist/api/aPICallsApi.js.map +1 -1
  27. package/dist/api/apis.js +1 -1
  28. package/dist/api/auditTrailApi.d.ts +1 -25
  29. package/dist/api/auditTrailApi.js +8 -300
  30. package/dist/api/auditTrailApi.js.map +1 -1
  31. package/dist/api/catalogApi.d.ts +6 -150
  32. package/dist/api/catalogApi.js +65 -1568
  33. package/dist/api/catalogApi.js.map +1 -1
  34. package/dist/api/deletionAndSuppressionApi.d.ts +8 -200
  35. package/dist/api/deletionAndSuppressionApi.js +105 -2195
  36. package/dist/api/deletionAndSuppressionApi.js.map +1 -1
  37. package/dist/api/destinationFiltersApi.d.ts +6 -150
  38. package/dist/api/destinationFiltersApi.js +71 -1658
  39. package/dist/api/destinationFiltersApi.js.map +1 -1
  40. package/dist/api/destinationsApi.d.ts +6 -134
  41. package/dist/api/destinationsApi.js +155 -1518
  42. package/dist/api/destinationsApi.js.map +1 -1
  43. package/dist/api/edgeFunctionsApi.js +9 -9
  44. package/dist/api/edgeFunctionsApi.js.map +1 -1
  45. package/dist/api/eventsApi.d.ts +1 -25
  46. package/dist/api/eventsApi.js +10 -353
  47. package/dist/api/eventsApi.js.map +1 -1
  48. package/dist/api/functionsApi.d.ts +6 -150
  49. package/dist/api/functionsApi.js +75 -1608
  50. package/dist/api/functionsApi.js.map +1 -1
  51. package/dist/api/iAMGroupsApi.d.ts +12 -300
  52. package/dist/api/iAMGroupsApi.js +158 -3278
  53. package/dist/api/iAMGroupsApi.js.map +1 -1
  54. package/dist/api/iAMRolesApi.d.ts +1 -25
  55. package/dist/api/iAMRolesApi.js +8 -261
  56. package/dist/api/iAMRolesApi.js.map +1 -1
  57. package/dist/api/iAMUsersApi.d.ts +9 -225
  58. package/dist/api/iAMUsersApi.js +115 -2422
  59. package/dist/api/iAMUsersApi.js.map +1 -1
  60. package/dist/api/labelsApi.d.ts +3 -79
  61. package/dist/api/labelsApi.js +33 -781
  62. package/dist/api/labelsApi.js.map +1 -1
  63. package/dist/api/monthlyTrackedUsersApi.d.ts +2 -50
  64. package/dist/api/monthlyTrackedUsersApi.js +18 -560
  65. package/dist/api/monthlyTrackedUsersApi.js.map +1 -1
  66. package/dist/api/selectiveSyncApi.d.ts +6 -150
  67. package/dist/api/selectiveSyncApi.js +92 -1694
  68. package/dist/api/selectiveSyncApi.js.map +1 -1
  69. package/dist/api/sourcesApi.d.ts +11 -288
  70. package/dist/api/sourcesApi.js +143 -2976
  71. package/dist/api/sourcesApi.js.map +1 -1
  72. package/dist/api/spacesApi.js +7 -7
  73. package/dist/api/spacesApi.js.map +1 -1
  74. package/dist/api/testingApi.d.ts +1 -18
  75. package/dist/api/testingApi.js +7 -211
  76. package/dist/api/testingApi.js.map +1 -1
  77. package/dist/api/trackingPlansApi.d.ts +12 -300
  78. package/dist/api/trackingPlansApi.js +167 -3296
  79. package/dist/api/trackingPlansApi.js.map +1 -1
  80. package/dist/api/transformationsApi.d.ts +5 -45
  81. package/dist/api/transformationsApi.js +34 -457
  82. package/dist/api/transformationsApi.js.map +1 -1
  83. package/dist/api/warehousesApi.d.ts +10 -250
  84. package/dist/api/warehousesApi.js +132 -2686
  85. package/dist/api/warehousesApi.js.map +1 -1
  86. package/dist/api/workspacesApi.d.ts +1 -25
  87. package/dist/api/workspacesApi.js +7 -242
  88. package/dist/api/workspacesApi.js.map +1 -1
  89. package/dist/model/addLabelsToSource200Response.d.ts +2 -2
  90. package/dist/model/addLabelsToSource200Response.js +1 -1
  91. package/dist/model/addLabelsToSource200Response.js.map +1 -1
  92. package/dist/model/addLabelsToSource200Response1.d.ts +2 -2
  93. package/dist/model/addLabelsToSource200Response1.js +1 -1
  94. package/dist/model/addLabelsToSource200Response1.js.map +1 -1
  95. package/dist/model/createCloudSourceRegulationV1Input.d.ts +0 -1
  96. package/dist/model/createCloudSourceRegulationV1Input.js +0 -1
  97. package/dist/model/createCloudSourceRegulationV1Input.js.map +1 -1
  98. package/dist/model/createDestinationSubscriptionAlphaInput.d.ts +1 -1
  99. package/dist/model/createLabel200Response.d.ts +2 -2
  100. package/dist/model/createLabel200Response.js +1 -1
  101. package/dist/model/createLabel200Response.js.map +1 -1
  102. package/dist/model/createLabel200Response1.d.ts +2 -2
  103. package/dist/model/createLabel200Response1.js +1 -1
  104. package/dist/model/createLabel200Response1.js.map +1 -1
  105. package/dist/model/createSource200Response.d.ts +2 -2
  106. package/dist/model/createSource200Response.js +1 -1
  107. package/dist/model/createSource200Response.js.map +1 -1
  108. package/dist/model/createSource200Response1.d.ts +2 -2
  109. package/dist/model/createSource200Response1.js +1 -1
  110. package/dist/model/createSource200Response1.js.map +1 -1
  111. package/dist/model/createSourceAlphaInput.d.ts +1 -1
  112. package/dist/model/createSourceRegulationV1Input.d.ts +0 -1
  113. package/dist/model/createSourceRegulationV1Input.js +0 -1
  114. package/dist/model/createSourceRegulationV1Input.js.map +1 -1
  115. package/dist/model/createSourceV1Input.d.ts +1 -1
  116. package/dist/model/createTransformationBetaInput.d.ts +2 -0
  117. package/dist/model/createTransformationBetaInput.js +5 -0
  118. package/dist/model/createTransformationBetaInput.js.map +1 -1
  119. package/dist/model/createValidationInWarehouseV1Input.d.ts +1 -1
  120. package/dist/model/createWarehouseV1Input.d.ts +1 -1
  121. package/dist/model/createWorkspaceRegulationV1Input.d.ts +0 -1
  122. package/dist/model/createWorkspaceRegulationV1Input.js +0 -1
  123. package/dist/model/createWorkspaceRegulationV1Input.js.map +1 -1
  124. package/dist/model/deleteLabel200Response.d.ts +2 -2
  125. package/dist/model/deleteLabel200Response.js +1 -1
  126. package/dist/model/deleteLabel200Response.js.map +1 -1
  127. package/dist/model/deleteLabel200Response1.d.ts +2 -2
  128. package/dist/model/deleteLabel200Response1.js +1 -1
  129. package/dist/model/deleteLabel200Response1.js.map +1 -1
  130. package/dist/model/deleteSource200Response.d.ts +2 -2
  131. package/dist/model/deleteSource200Response.js +1 -1
  132. package/dist/model/deleteSource200Response.js.map +1 -1
  133. package/dist/model/deleteSource200Response1.d.ts +2 -2
  134. package/dist/model/deleteSource200Response1.js +1 -1
  135. package/dist/model/deleteSource200Response1.js.map +1 -1
  136. package/dist/model/deliveryMetricsSummary.js.map +1 -1
  137. package/dist/model/destination.js.map +1 -1
  138. package/dist/model/destination1.js.map +1 -1
  139. package/dist/model/destination2.js.map +1 -1
  140. package/dist/model/destinationMetadata.js.map +1 -1
  141. package/dist/model/destinationSubscription.d.ts +1 -1
  142. package/dist/model/destinationSubscriptionUpdateInput.d.ts +1 -1
  143. package/dist/model/echo200Response.d.ts +2 -2
  144. package/dist/model/echo200Response.js +1 -1
  145. package/dist/model/echo200Response.js.map +1 -1
  146. package/dist/model/echo200Response1.d.ts +2 -2
  147. package/dist/model/echo200Response1.js +1 -1
  148. package/dist/model/echo200Response1.js.map +1 -1
  149. package/dist/model/edgeFunctions.js.map +1 -1
  150. package/dist/model/edgeFunctions1.js.map +1 -1
  151. package/dist/model/filter.js.map +1 -1
  152. package/dist/model/filter1.js.map +1 -1
  153. package/dist/model/filter2.js.map +1 -1
  154. package/dist/model/filter3.js.map +1 -1
  155. package/dist/model/function.js.map +1 -1
  156. package/dist/model/function1.js.map +1 -1
  157. package/dist/model/function2.js.map +1 -1
  158. package/dist/model/getSource200Response.d.ts +2 -2
  159. package/dist/model/getSource200Response.js +1 -1
  160. package/dist/model/getSource200Response.js.map +1 -1
  161. package/dist/model/getSource200Response1.d.ts +2 -2
  162. package/dist/model/getSource200Response1.js +1 -1
  163. package/dist/model/getSource200Response1.js.map +1 -1
  164. package/dist/model/group.js.map +1 -1
  165. package/dist/model/identify.js.map +1 -1
  166. package/dist/model/input.d.ts +1 -1
  167. package/dist/model/input.js.map +1 -1
  168. package/dist/model/label.js.map +1 -1
  169. package/dist/model/label1.js.map +1 -1
  170. package/dist/model/label2.js.map +1 -1
  171. package/dist/model/listConnectedDestinationsFromSource200Response.d.ts +2 -2
  172. package/dist/model/listConnectedDestinationsFromSource200Response.js +1 -1
  173. package/dist/model/listConnectedDestinationsFromSource200Response.js.map +1 -1
  174. package/dist/model/listConnectedDestinationsFromSource200Response1.d.ts +2 -2
  175. package/dist/model/listConnectedDestinationsFromSource200Response1.js +1 -1
  176. package/dist/model/listConnectedDestinationsFromSource200Response1.js.map +1 -1
  177. package/dist/model/listConnectedWarehousesFromSource200Response.d.ts +2 -2
  178. package/dist/model/listConnectedWarehousesFromSource200Response.js +1 -1
  179. package/dist/model/listConnectedWarehousesFromSource200Response.js.map +1 -1
  180. package/dist/model/listConnectedWarehousesFromSource200Response1.d.ts +2 -2
  181. package/dist/model/listConnectedWarehousesFromSource200Response1.js +1 -1
  182. package/dist/model/listConnectedWarehousesFromSource200Response1.js.map +1 -1
  183. package/dist/model/listLabels200Response.d.ts +2 -2
  184. package/dist/model/listLabels200Response.js +1 -1
  185. package/dist/model/listLabels200Response.js.map +1 -1
  186. package/dist/model/listLabels200Response1.d.ts +2 -2
  187. package/dist/model/listLabels200Response1.js +1 -1
  188. package/dist/model/listLabels200Response1.js.map +1 -1
  189. package/dist/model/listSources200Response.d.ts +2 -2
  190. package/dist/model/listSources200Response.js +1 -1
  191. package/dist/model/listSources200Response.js.map +1 -1
  192. package/dist/model/listSources200Response1.d.ts +2 -2
  193. package/dist/model/listSources200Response1.js +1 -1
  194. package/dist/model/listSources200Response1.js.map +1 -1
  195. package/dist/model/logos.js.map +1 -1
  196. package/dist/model/logos1.js.map +1 -1
  197. package/dist/model/logos2.js.map +1 -1
  198. package/dist/model/metadata.js.map +1 -1
  199. package/dist/model/metadata1.js.map +1 -1
  200. package/dist/model/metadata2.js.map +1 -1
  201. package/dist/model/models.d.ts +3 -2
  202. package/dist/model/models.js +3 -0
  203. package/dist/model/models.js.map +1 -1
  204. package/dist/model/pagination.js.map +1 -1
  205. package/dist/model/previewDestinationFilterV1Output.d.ts +1 -1
  206. package/dist/model/previewDestinationFilterV1Output.js +1 -1
  207. package/dist/model/previewDestinationFilterV1Output.js.map +1 -1
  208. package/dist/model/propertyValueTransformationBeta.d.ts +15 -0
  209. package/dist/model/propertyValueTransformationBeta.js +26 -0
  210. package/dist/model/propertyValueTransformationBeta.js.map +1 -0
  211. package/dist/model/replaceLabelsInSource200Response.d.ts +2 -2
  212. package/dist/model/replaceLabelsInSource200Response.js +1 -1
  213. package/dist/model/replaceLabelsInSource200Response.js.map +1 -1
  214. package/dist/model/replaceLabelsInSource200Response1.d.ts +2 -2
  215. package/dist/model/replaceLabelsInSource200Response1.js +1 -1
  216. package/dist/model/replaceLabelsInSource200Response1.js.map +1 -1
  217. package/dist/model/schedule.js.map +1 -1
  218. package/dist/model/schedule1.js.map +1 -1
  219. package/dist/model/schedule2.js.map +1 -1
  220. package/dist/model/settings.js.map +1 -1
  221. package/dist/model/settings1.js.map +1 -1
  222. package/dist/model/source.js.map +1 -1
  223. package/dist/model/source1.d.ts +1 -1
  224. package/dist/model/source1.js.map +1 -1
  225. package/dist/model/source2.d.ts +1 -1
  226. package/dist/model/source2.js.map +1 -1
  227. package/dist/model/source3.d.ts +1 -1
  228. package/dist/model/source3.js.map +1 -1
  229. package/dist/model/source4.d.ts +1 -1
  230. package/dist/model/source4.js.map +1 -1
  231. package/dist/model/source5.d.ts +1 -1
  232. package/dist/model/source5.js.map +1 -1
  233. package/dist/model/source6.d.ts +1 -1
  234. package/dist/model/source6.js.map +1 -1
  235. package/dist/model/sourceAlpha.d.ts +1 -1
  236. package/dist/model/sourceMetadata.js.map +1 -1
  237. package/dist/model/sourceV1.d.ts +1 -1
  238. package/dist/model/subscription.d.ts +1 -1
  239. package/dist/model/subscription.js.map +1 -1
  240. package/dist/model/supportedFeatures.js.map +1 -1
  241. package/dist/model/supportedMethods.js.map +1 -1
  242. package/dist/model/supportedPlatforms.js.map +1 -1
  243. package/dist/model/track.js.map +1 -1
  244. package/dist/model/trackingPlan.js.map +1 -1
  245. package/dist/model/trackingPlan1.js.map +1 -1
  246. package/dist/model/transformation.d.ts +2 -0
  247. package/dist/model/transformation.js +5 -0
  248. package/dist/model/transformation.js.map +1 -1
  249. package/dist/model/transformation1.d.ts +2 -0
  250. package/dist/model/transformation1.js +5 -0
  251. package/dist/model/transformation1.js.map +1 -1
  252. package/dist/model/transformation2.d.ts +2 -0
  253. package/dist/model/transformation2.js +5 -0
  254. package/dist/model/transformation2.js.map +1 -1
  255. package/dist/model/transformationBeta.d.ts +2 -0
  256. package/dist/model/transformationBeta.js +5 -0
  257. package/dist/model/transformationBeta.js.map +1 -1
  258. package/dist/model/updateSource200Response.d.ts +2 -2
  259. package/dist/model/updateSource200Response.js +1 -1
  260. package/dist/model/updateSource200Response.js.map +1 -1
  261. package/dist/model/updateSource200Response1.d.ts +2 -2
  262. package/dist/model/updateSource200Response1.js +1 -1
  263. package/dist/model/updateSource200Response1.js.map +1 -1
  264. package/dist/model/updateSourceAlphaInput.d.ts +1 -1
  265. package/dist/model/updateSourceV1Input.d.ts +1 -1
  266. package/dist/model/updateTransformationBetaInput.d.ts +2 -0
  267. package/dist/model/updateTransformationBetaInput.js +5 -0
  268. package/dist/model/updateTransformationBetaInput.js.map +1 -1
  269. package/dist/model/updateWarehouseV1Input.d.ts +1 -1
  270. package/dist/model/user.js.map +1 -1
  271. package/dist/model/userGroup.js.map +1 -1
  272. package/dist/model/userGroup1.js.map +1 -1
  273. package/dist/model/userGroup2.js.map +1 -1
  274. package/dist/model/userGroup3.js.map +1 -1
  275. package/dist/model/warehouse.d.ts +1 -1
  276. package/dist/model/warehouse.js.map +1 -1
  277. package/dist/model/warehouse1.d.ts +1 -1
  278. package/dist/model/warehouse1.js.map +1 -1
  279. package/dist/model/warehouse2.d.ts +1 -1
  280. package/dist/model/warehouse2.js.map +1 -1
  281. package/dist/model/warehouseMetadata.js.map +1 -1
  282. package/dist/model/warehouseV1.d.ts +1 -1
  283. package/dist/model/workspace.js.map +1 -1
  284. package/dist/tests/smoke.test.js +7 -7
  285. package/dist/tests/smoke.test.js.map +1 -1
  286. package/model/aPICallSnapshotV1.ts +1 -1
  287. package/model/accessPermissionV1.ts +1 -1
  288. package/model/addConnectionFromSourceToWarehouse200Response.ts +1 -1
  289. package/model/addConnectionFromSourceToWarehouseV1Output.ts +1 -1
  290. package/model/addLabelsToSource200Response.ts +4 -4
  291. package/model/addLabelsToSource200Response1.ts +4 -4
  292. package/model/addLabelsToSourceAlphaInput.ts +1 -1
  293. package/model/addLabelsToSourceAlphaOutput.ts +1 -1
  294. package/model/addLabelsToSourceV1Input.ts +1 -1
  295. package/model/addLabelsToSourceV1Output.ts +1 -1
  296. package/model/addPermissionsToUser200Response.ts +1 -1
  297. package/model/addPermissionsToUserGroup200Response.ts +1 -1
  298. package/model/addPermissionsToUserGroupV1Input.ts +1 -1
  299. package/model/addPermissionsToUserGroupV1Output.ts +1 -1
  300. package/model/addPermissionsToUserV1Input.ts +1 -1
  301. package/model/addPermissionsToUserV1Output.ts +1 -1
  302. package/model/addSourceToTrackingPlan200Response.ts +1 -1
  303. package/model/addSourceToTrackingPlanV1Input.ts +1 -1
  304. package/model/addSourceToTrackingPlanV1Output.ts +1 -1
  305. package/model/addUsersToUserGroup200Response.ts +1 -1
  306. package/model/addUsersToUserGroupV1Input.ts +1 -1
  307. package/model/addUsersToUserGroupV1Output.ts +1 -1
  308. package/model/advancedWarehouseSyncScheduleV1Input.ts +1 -1
  309. package/model/advancedWarehouseSyncScheduleV1Output.ts +1 -1
  310. package/model/allowedLabelBeta.ts +1 -1
  311. package/model/auditEventV1.ts +1 -1
  312. package/model/batchQueryMessagingSubscriptionsForSpace200Response.ts +1 -1
  313. package/model/batchQueryMessagingSubscriptionsForSpaceAlphaInput.ts +1 -1
  314. package/model/batchQueryMessagingSubscriptionsForSpaceAlphaOutput.ts +1 -1
  315. package/model/breakdownBeta.ts +1 -1
  316. package/model/commonSourceSettingsV1.ts +1 -1
  317. package/model/contact.ts +1 -1
  318. package/model/createCloudSourceRegulation200Response.ts +1 -1
  319. package/model/createCloudSourceRegulationV1Input.ts +1 -2
  320. package/model/createCloudSourceRegulationV1Output.ts +1 -1
  321. package/model/createDestination200Response.ts +1 -1
  322. package/model/createDestinationSubscription200Response.ts +1 -1
  323. package/model/createDestinationSubscriptionAlphaInput.ts +2 -2
  324. package/model/createDestinationSubscriptionAlphaOutput.ts +1 -1
  325. package/model/createDestinationV1Input.ts +1 -1
  326. package/model/createDestinationV1Output.ts +1 -1
  327. package/model/createEdgeFunctions200Response.ts +1 -1
  328. package/model/createEdgeFunctionsAlphaInput.ts +1 -1
  329. package/model/createEdgeFunctionsAlphaOutput.ts +1 -1
  330. package/model/createFilterForDestination200Response.ts +1 -1
  331. package/model/createFilterForDestinationV1Input.ts +1 -1
  332. package/model/createFilterForDestinationV1Output.ts +1 -1
  333. package/model/createFunction200Response.ts +1 -1
  334. package/model/createFunctionDeployment200Response.ts +1 -1
  335. package/model/createFunctionDeploymentV1Output.ts +1 -1
  336. package/model/createFunctionV1Input.ts +1 -1
  337. package/model/createFunctionV1Output.ts +1 -1
  338. package/model/createInvites200Response.ts +1 -1
  339. package/model/createInvitesV1Input.ts +1 -1
  340. package/model/createInvitesV1Output.ts +1 -1
  341. package/model/createLabel200Response.ts +4 -4
  342. package/model/createLabel200Response1.ts +4 -4
  343. package/model/createLabelAlphaInput.ts +1 -1
  344. package/model/createLabelAlphaOutput.ts +1 -1
  345. package/model/createLabelV1Input.ts +1 -1
  346. package/model/createLabelV1Output.ts +1 -1
  347. package/model/createSource200Response.ts +4 -4
  348. package/model/createSource200Response1.ts +4 -4
  349. package/model/createSourceAlphaInput.ts +2 -2
  350. package/model/createSourceAlphaOutput.ts +1 -1
  351. package/model/createSourceRegulation200Response.ts +1 -1
  352. package/model/createSourceRegulationV1Input.ts +1 -2
  353. package/model/createSourceRegulationV1Output.ts +1 -1
  354. package/model/createSourceV1Input.ts +2 -2
  355. package/model/createSourceV1Output.ts +1 -1
  356. package/model/createTrackingPlan200Response.ts +1 -1
  357. package/model/createTrackingPlanV1Input.ts +1 -1
  358. package/model/createTrackingPlanV1Output.ts +1 -1
  359. package/model/createTransformation200Response.ts +1 -1
  360. package/model/createTransformationBetaInput.ts +11 -1
  361. package/model/createTransformationBetaOutput.ts +1 -1
  362. package/model/createUserGroup200Response.ts +1 -1
  363. package/model/createUserGroupV1Input.ts +1 -1
  364. package/model/createUserGroupV1Output.ts +1 -1
  365. package/model/createValidationInWarehouse200Response.ts +1 -1
  366. package/model/createValidationInWarehouseV1Input.ts +2 -2
  367. package/model/createValidationInWarehouseV1Output.ts +1 -1
  368. package/model/createWarehouse200Response.ts +1 -1
  369. package/model/createWarehouseV1Input.ts +2 -2
  370. package/model/createWarehouseV1Output.ts +1 -1
  371. package/model/createWorkspaceRegulation200Response.ts +1 -1
  372. package/model/createWorkspaceRegulationV1Input.ts +1 -2
  373. package/model/createWorkspaceRegulationV1Output.ts +1 -1
  374. package/model/deleteDestination200Response.ts +1 -1
  375. package/model/deleteDestinationV1Output.ts +1 -1
  376. package/model/deleteFunction200Response.ts +1 -1
  377. package/model/deleteFunctionV1Output.ts +1 -1
  378. package/model/deleteInvites200Response.ts +1 -1
  379. package/model/deleteInvitesV1Output.ts +1 -1
  380. package/model/deleteLabel200Response.ts +4 -4
  381. package/model/deleteLabel200Response1.ts +4 -4
  382. package/model/deleteLabelAlphaOutput.ts +1 -1
  383. package/model/deleteLabelV1Output.ts +1 -1
  384. package/model/deleteRegulation200Response.ts +1 -1
  385. package/model/deleteRegulationV1Output.ts +1 -1
  386. package/model/deleteSource200Response.ts +4 -4
  387. package/model/deleteSource200Response1.ts +4 -4
  388. package/model/deleteSourceAlphaOutput.ts +1 -1
  389. package/model/deleteSourceV1Output.ts +1 -1
  390. package/model/deleteTrackingPlan200Response.ts +1 -1
  391. package/model/deleteTrackingPlanV1Output.ts +1 -1
  392. package/model/deleteTransformation200Response.ts +1 -1
  393. package/model/deleteTransformationBetaOutput.ts +1 -1
  394. package/model/deleteUserGroup200Response.ts +1 -1
  395. package/model/deleteUserGroupV1Output.ts +1 -1
  396. package/model/deleteUsers200Response.ts +1 -1
  397. package/model/deleteUsersV1Output.ts +1 -1
  398. package/model/deleteWarehouse200Response.ts +1 -1
  399. package/model/deleteWarehouseV1Output.ts +1 -1
  400. package/model/deliveryMetricsSummary.ts +2 -1
  401. package/model/deliveryMetricsSummaryBeta.ts +1 -1
  402. package/model/destination.ts +2 -1
  403. package/model/destination1.ts +2 -1
  404. package/model/destination2.ts +2 -1
  405. package/model/destinationFilterActionV1.ts +1 -1
  406. package/model/destinationFilterV1.ts +1 -1
  407. package/model/destinationMetadata.ts +2 -1
  408. package/model/destinationMetadataActionFieldV1.ts +1 -1
  409. package/model/destinationMetadataActionV1.ts +1 -1
  410. package/model/destinationMetadataComponentV1.ts +1 -1
  411. package/model/destinationMetadataFeaturesV1.ts +1 -1
  412. package/model/destinationMetadataMethodsV1.ts +1 -1
  413. package/model/destinationMetadataPlatformsV1.ts +1 -1
  414. package/model/destinationMetadataSubscriptionPresetV1.ts +1 -1
  415. package/model/destinationMetadataV1.ts +1 -1
  416. package/model/destinationStatusV1.ts +1 -1
  417. package/model/destinationSubscription.ts +2 -2
  418. package/model/destinationSubscriptionUpdateInput.ts +2 -2
  419. package/model/destinationV1.ts +1 -1
  420. package/model/disableEdgeFunctions200Response.ts +1 -1
  421. package/model/disableEdgeFunctionsAlphaOutput.ts +1 -1
  422. package/model/echo200Response.ts +4 -4
  423. package/model/echo200Response1.ts +4 -4
  424. package/model/echoAlphaOutput.ts +1 -1
  425. package/model/echoV1Output.ts +1 -1
  426. package/model/edgeFunctions.ts +2 -1
  427. package/model/edgeFunctions1.ts +2 -1
  428. package/model/edgeFunctionsAlpha.ts +1 -1
  429. package/model/eventSourceV1.ts +1 -1
  430. package/model/filter.ts +2 -1
  431. package/model/filter1.ts +2 -1
  432. package/model/filter2.ts +2 -1
  433. package/model/filter3.ts +2 -1
  434. package/model/function.ts +2 -1
  435. package/model/function1.ts +2 -1
  436. package/model/function2.ts +2 -1
  437. package/model/functionDeployment.ts +1 -1
  438. package/model/functionSettingV1.ts +1 -1
  439. package/model/functionV1.ts +1 -1
  440. package/model/generateUploadURLForEdgeFunctions200Response.ts +1 -1
  441. package/model/generateUploadURLForEdgeFunctionsAlphaOutput.ts +1 -1
  442. package/model/getAdvancedSyncScheduleFromWarehouse200Response.ts +1 -1
  443. package/model/getAdvancedSyncScheduleFromWarehouseV1Output.ts +1 -1
  444. package/model/getConnectionStateFromWarehouse200Response.ts +1 -1
  445. package/model/getConnectionStateFromWarehouseV1Output.ts +1 -1
  446. package/model/getDailyPerSourceAPICallsUsage200Response.ts +1 -1
  447. package/model/getDailyPerSourceAPICallsUsageV1Output.ts +1 -1
  448. package/model/getDailyPerSourceMTUUsage200Response.ts +1 -1
  449. package/model/getDailyPerSourceMTUUsageV1Output.ts +1 -1
  450. package/model/getDailyWorkspaceAPICallsUsage200Response.ts +1 -1
  451. package/model/getDailyWorkspaceAPICallsUsageV1Output.ts +1 -1
  452. package/model/getDailyWorkspaceMTUUsage200Response.ts +1 -1
  453. package/model/getDailyWorkspaceMTUUsageV1Output.ts +1 -1
  454. package/model/getDestination200Response.ts +1 -1
  455. package/model/getDestinationMetadata200Response.ts +1 -1
  456. package/model/getDestinationMetadataV1Output.ts +1 -1
  457. package/model/getDestinationV1Output.ts +1 -1
  458. package/model/getDestinationsCatalog200Response.ts +1 -1
  459. package/model/getDestinationsCatalogV1Output.ts +1 -1
  460. package/model/getEventsVolumeFromWorkspace200Response.ts +1 -1
  461. package/model/getEventsVolumeFromWorkspaceV1Output.ts +1 -1
  462. package/model/getFilterInDestination200Response.ts +1 -1
  463. package/model/getFilterInDestinationV1Output.ts +1 -1
  464. package/model/getFunction200Response.ts +1 -1
  465. package/model/getFunctionV1Output.ts +1 -1
  466. package/model/getLatestFromEdgeFunctions200Response.ts +1 -1
  467. package/model/getLatestFromEdgeFunctionsAlphaOutput.ts +1 -1
  468. package/model/getMessagingSubscriptionFailureResponse.ts +1 -1
  469. package/model/getMessagingSubscriptionSuccessResponse.ts +1 -1
  470. package/model/getRegulation200Response.ts +1 -1
  471. package/model/getRegulationV1Output.ts +1 -1
  472. package/model/getSource200Response.ts +4 -4
  473. package/model/getSource200Response1.ts +4 -4
  474. package/model/getSourceAlphaOutput.ts +1 -1
  475. package/model/getSourceMetadata200Response.ts +1 -1
  476. package/model/getSourceMetadataV1Output.ts +1 -1
  477. package/model/getSourceV1Output.ts +1 -1
  478. package/model/getSourcesCatalog200Response.ts +1 -1
  479. package/model/getSourcesCatalogV1Output.ts +1 -1
  480. package/model/getSpace200Response.ts +1 -1
  481. package/model/getSpaceAlphaOutput.ts +1 -1
  482. package/model/getSubscriptionFromDestination200Response.ts +1 -1
  483. package/model/getSubscriptionFromDestinationAlphaOutput.ts +1 -1
  484. package/model/getSubscriptionRequest.ts +1 -1
  485. package/model/getTrackingPlan200Response.ts +1 -1
  486. package/model/getTrackingPlanV1Output.ts +1 -1
  487. package/model/getTransformation200Response.ts +1 -1
  488. package/model/getTransformationBetaOutput.ts +1 -1
  489. package/model/getUser200Response.ts +1 -1
  490. package/model/getUserGroup200Response.ts +1 -1
  491. package/model/getUserGroupV1Output.ts +1 -1
  492. package/model/getUserV1Output.ts +1 -1
  493. package/model/getWarehouse200Response.ts +1 -1
  494. package/model/getWarehouseMetadata200Response.ts +1 -1
  495. package/model/getWarehouseMetadataV1Output.ts +1 -1
  496. package/model/getWarehouseV1Output.ts +1 -1
  497. package/model/getWarehousesCatalog200Response.ts +1 -1
  498. package/model/getWarehousesCatalogV1Output.ts +1 -1
  499. package/model/getWorkspace200Response.ts +1 -1
  500. package/model/getWorkspaceV1Output.ts +1 -1
  501. package/model/group.ts +2 -1
  502. package/model/groupSourceSettingsV1.ts +1 -1
  503. package/model/identify.ts +2 -1
  504. package/model/identifySourceSettingsV1.ts +1 -1
  505. package/model/input.ts +3 -2
  506. package/model/integrationOptionBeta.ts +1 -1
  507. package/model/invitePermissionV1.ts +1 -1
  508. package/model/inviteV1.ts +1 -1
  509. package/model/label.ts +2 -1
  510. package/model/label1.ts +2 -1
  511. package/model/label2.ts +2 -1
  512. package/model/labelAlpha.ts +1 -1
  513. package/model/labelV1.ts +1 -1
  514. package/model/listAuditEvents200Response.ts +1 -1
  515. package/model/listAuditEventsV1Output.ts +1 -1
  516. package/model/listConnectedDestinationsFromSource200Response.ts +4 -4
  517. package/model/listConnectedDestinationsFromSource200Response1.ts +4 -4
  518. package/model/listConnectedDestinationsFromSourceAlphaOutput.ts +1 -1
  519. package/model/listConnectedDestinationsFromSourceV1Output.ts +1 -1
  520. package/model/listConnectedSourcesFromWarehouse200Response.ts +1 -1
  521. package/model/listConnectedSourcesFromWarehouseV1Output.ts +1 -1
  522. package/model/listConnectedWarehousesFromSource200Response.ts +4 -4
  523. package/model/listConnectedWarehousesFromSource200Response1.ts +4 -4
  524. package/model/listConnectedWarehousesFromSourceAlphaOutput.ts +1 -1
  525. package/model/listConnectedWarehousesFromSourceV1Output.ts +1 -1
  526. package/model/listDeliveryMetricsSummaryFromDestination200Response.ts +1 -1
  527. package/model/listDeliveryMetricsSummaryFromDestinationBetaOutput.ts +1 -1
  528. package/model/listDestinations200Response.ts +1 -1
  529. package/model/listDestinationsV1Output.ts +1 -1
  530. package/model/listFiltersFromDestination200Response.ts +1 -1
  531. package/model/listFiltersFromDestinationV1Output.ts +1 -1
  532. package/model/listFunctionItemV1.ts +1 -1
  533. package/model/listFunctions200Response.ts +1 -1
  534. package/model/listFunctionsV1Output.ts +1 -1
  535. package/model/listInvites200Response.ts +1 -1
  536. package/model/listInvitesFromUserGroup200Response.ts +1 -1
  537. package/model/listInvitesFromUserGroupV1Output.ts +1 -1
  538. package/model/listInvitesV1Output.ts +1 -1
  539. package/model/listLabels200Response.ts +4 -4
  540. package/model/listLabels200Response1.ts +4 -4
  541. package/model/listLabelsAlphaOutput.ts +1 -1
  542. package/model/listLabelsV1Output.ts +1 -1
  543. package/model/listRegulationsFromSource200Response.ts +1 -1
  544. package/model/listRegulationsFromSourceV1Output.ts +1 -1
  545. package/model/listRoles200Response.ts +1 -1
  546. package/model/listRolesV1Output.ts +1 -1
  547. package/model/listRulesFromTrackingPlan200Response.ts +1 -1
  548. package/model/listRulesFromTrackingPlanV1Output.ts +1 -1
  549. package/model/listSchemaSettingsInSource200Response.ts +1 -1
  550. package/model/listSchemaSettingsInSourceV1Output.ts +1 -1
  551. package/model/listSelectiveSyncsFromWarehouseAndSource200Response.ts +1 -1
  552. package/model/listSelectiveSyncsFromWarehouseAndSourceV1Output.ts +1 -1
  553. package/model/listSources200Response.ts +4 -4
  554. package/model/listSources200Response1.ts +4 -4
  555. package/model/listSourcesAlphaOutput.ts +1 -1
  556. package/model/listSourcesFromTrackingPlan200Response.ts +1 -1
  557. package/model/listSourcesFromTrackingPlanV1Output.ts +1 -1
  558. package/model/listSourcesV1Output.ts +1 -1
  559. package/model/listSubscriptionsFromDestination200Response.ts +1 -1
  560. package/model/listSubscriptionsFromDestinationAlphaOutput.ts +1 -1
  561. package/model/listSuppressions200Response.ts +1 -1
  562. package/model/listSuppressionsV1Output.ts +1 -1
  563. package/model/listSyncsFromWarehouse200Response.ts +1 -1
  564. package/model/listSyncsFromWarehouseAndSource200Response.ts +1 -1
  565. package/model/listSyncsFromWarehouseAndSourceV1Output.ts +1 -1
  566. package/model/listSyncsFromWarehouseV1Output.ts +1 -1
  567. package/model/listTrackingPlans200Response.ts +1 -1
  568. package/model/listTrackingPlansV1Output.ts +1 -1
  569. package/model/listTransformations200Response.ts +1 -1
  570. package/model/listTransformationsBetaOutput.ts +1 -1
  571. package/model/listUserGroups200Response.ts +1 -1
  572. package/model/listUserGroupsFromUser200Response.ts +1 -1
  573. package/model/listUserGroupsFromUserV1Output.ts +1 -1
  574. package/model/listUserGroupsV1Output.ts +1 -1
  575. package/model/listUsers200Response.ts +1 -1
  576. package/model/listUsersFromUserGroup200Response.ts +1 -1
  577. package/model/listUsersFromUserGroupV1Output.ts +1 -1
  578. package/model/listUsersV1Output.ts +1 -1
  579. package/model/listWarehouses200Response.ts +1 -1
  580. package/model/listWarehousesV1Output.ts +1 -1
  581. package/model/listWorkspaceRegulations200Response.ts +1 -1
  582. package/model/listWorkspaceRegulationsV1Output.ts +1 -1
  583. package/model/logos.ts +2 -1
  584. package/model/logos1.ts +2 -1
  585. package/model/logos2.ts +2 -1
  586. package/model/logosBeta.ts +1 -1
  587. package/model/messageSubscriptionResponse.ts +1 -1
  588. package/model/messageSubscriptionResponseError.ts +1 -1
  589. package/model/messagesSubscriptionRequest.ts +1 -1
  590. package/model/metadata.ts +2 -1
  591. package/model/metadata1.ts +2 -1
  592. package/model/metadata2.ts +2 -1
  593. package/model/metricBeta.ts +1 -1
  594. package/model/minimalUserGroupV1.ts +1 -1
  595. package/model/minimalUserV1.ts +1 -1
  596. package/model/models.ts +3 -0
  597. package/model/mtuSnapshotV1.ts +1 -1
  598. package/model/pagination.ts +2 -1
  599. package/model/paginationInput.ts +1 -1
  600. package/model/paginationOutput.ts +1 -1
  601. package/model/permissionInputV1.ts +1 -1
  602. package/model/permissionResourceV1.ts +1 -1
  603. package/model/permissionV1.ts +1 -1
  604. package/model/previewDestinationFilter200Response.ts +1 -1
  605. package/model/previewDestinationFilterV1.ts +1 -1
  606. package/model/previewDestinationFilterV1Input.ts +1 -1
  607. package/model/previewDestinationFilterV1Output.ts +3 -3
  608. package/model/propertyRenameBeta.ts +1 -1
  609. package/model/propertyValueTransformationBeta.ts +47 -0
  610. package/model/regulation.ts +1 -1
  611. package/model/regulationListEntryV1.ts +1 -1
  612. package/model/removeFilterFromDestination200Response.ts +1 -1
  613. package/model/removeFilterFromDestinationV1Output.ts +1 -1
  614. package/model/removeRuleV1.ts +1 -1
  615. package/model/removeRulesFromTrackingPlan200Response.ts +1 -1
  616. package/model/removeRulesFromTrackingPlanV1Output.ts +1 -1
  617. package/model/removeSourceConnectionFromWarehouse200Response.ts +1 -1
  618. package/model/removeSourceConnectionFromWarehouseV1Output.ts +1 -1
  619. package/model/removeSourceFromTrackingPlan200Response.ts +1 -1
  620. package/model/removeSourceFromTrackingPlanV1Output.ts +1 -1
  621. package/model/removeSubscriptionFromDestination200Response.ts +1 -1
  622. package/model/removeSubscriptionFromDestinationAlphaOutput.ts +1 -1
  623. package/model/removeUsersFromUserGroup200Response.ts +1 -1
  624. package/model/removeUsersFromUserGroupV1Output.ts +1 -1
  625. package/model/replaceAdvancedSyncScheduleForWarehouse200Response.ts +1 -1
  626. package/model/replaceAdvancedSyncScheduleForWarehouseV1Input.ts +1 -1
  627. package/model/replaceAdvancedSyncScheduleForWarehouseV1Output.ts +1 -1
  628. package/model/replaceLabelsInSource200Response.ts +4 -4
  629. package/model/replaceLabelsInSource200Response1.ts +4 -4
  630. package/model/replaceLabelsInSourceAlphaInput.ts +1 -1
  631. package/model/replaceLabelsInSourceAlphaOutput.ts +1 -1
  632. package/model/replaceLabelsInSourceV1Input.ts +1 -1
  633. package/model/replaceLabelsInSourceV1Output.ts +1 -1
  634. package/model/replaceMessagingSubscriptionsInSpaces200Response.ts +1 -1
  635. package/model/replaceMessagingSubscriptionsInSpacesAlphaInput.ts +1 -1
  636. package/model/replaceMessagingSubscriptionsInSpacesAlphaOutput.ts +1 -1
  637. package/model/replacePermissionsForUser200Response.ts +1 -1
  638. package/model/replacePermissionsForUserGroup200Response.ts +1 -1
  639. package/model/replacePermissionsForUserGroupV1Input.ts +1 -1
  640. package/model/replacePermissionsForUserGroupV1Output.ts +1 -1
  641. package/model/replacePermissionsForUserV1Input.ts +1 -1
  642. package/model/replacePermissionsForUserV1Output.ts +1 -1
  643. package/model/replaceRulesInTrackingPlan200Response.ts +1 -1
  644. package/model/replaceRulesInTrackingPlanV1Input.ts +1 -1
  645. package/model/replaceRulesInTrackingPlanV1Output.ts +1 -1
  646. package/model/replaceUsersInUserGroup200Response.ts +1 -1
  647. package/model/replaceUsersInUserGroupV1Input.ts +1 -1
  648. package/model/replaceUsersInUserGroupV1Output.ts +1 -1
  649. package/model/requestError.ts +1 -1
  650. package/model/requestErrorEnvelope.ts +1 -1
  651. package/model/resourceV1.ts +1 -1
  652. package/model/roleV1.ts +1 -1
  653. package/model/ruleV1.ts +1 -1
  654. package/model/schedule.ts +2 -1
  655. package/model/schedule1.ts +2 -1
  656. package/model/schedule2.ts +2 -1
  657. package/model/settings.ts +2 -1
  658. package/model/settings1.ts +2 -1
  659. package/model/source.ts +2 -1
  660. package/model/source1.ts +3 -2
  661. package/model/source2.ts +3 -2
  662. package/model/source3.ts +3 -2
  663. package/model/source4.ts +3 -2
  664. package/model/source5.ts +3 -2
  665. package/model/source6.ts +3 -2
  666. package/model/sourceAPICallSnapshotV1.ts +1 -1
  667. package/model/sourceAlpha.ts +2 -2
  668. package/model/sourceEventVolumeDatapointV1.ts +1 -1
  669. package/model/sourceEventVolumeV1.ts +1 -1
  670. package/model/sourceMetadata.ts +2 -1
  671. package/model/sourceMetadataV1.ts +1 -1
  672. package/model/sourceSettingsOutputV1.ts +1 -1
  673. package/model/sourceV1.ts +2 -2
  674. package/model/space.ts +1 -1
  675. package/model/streamStatusV1.ts +1 -1
  676. package/model/subscription.ts +3 -2
  677. package/model/supportedFeatures.ts +2 -1
  678. package/model/supportedMethods.ts +2 -1
  679. package/model/supportedPlatforms.ts +2 -1
  680. package/model/suppressedInner.ts +1 -1
  681. package/model/syncNoticeV1.ts +1 -1
  682. package/model/syncV1.ts +1 -1
  683. package/model/track.ts +2 -1
  684. package/model/trackSourceSettingsV1.ts +1 -1
  685. package/model/trackingPlan.ts +2 -1
  686. package/model/trackingPlan1.ts +2 -1
  687. package/model/trackingPlanV1.ts +1 -1
  688. package/model/transformation.ts +12 -1
  689. package/model/transformation1.ts +12 -1
  690. package/model/transformation2.ts +12 -1
  691. package/model/transformationBeta.ts +11 -1
  692. package/model/updateDestination200Response.ts +1 -1
  693. package/model/updateDestinationV1Input.ts +1 -1
  694. package/model/updateDestinationV1Output.ts +1 -1
  695. package/model/updateFilterForDestination200Response.ts +1 -1
  696. package/model/updateFilterForDestinationV1Input.ts +1 -1
  697. package/model/updateFilterForDestinationV1Output.ts +1 -1
  698. package/model/updateFunction200Response.ts +1 -1
  699. package/model/updateFunctionV1Input.ts +1 -1
  700. package/model/updateFunctionV1Output.ts +1 -1
  701. package/model/updateRulesInTrackingPlan200Response.ts +1 -1
  702. package/model/updateRulesInTrackingPlanV1Input.ts +1 -1
  703. package/model/updateRulesInTrackingPlanV1Output.ts +1 -1
  704. package/model/updateSchemaSettingsInSource200Response.ts +1 -1
  705. package/model/updateSchemaSettingsInSourceV1Input.ts +1 -1
  706. package/model/updateSchemaSettingsInSourceV1Output.ts +1 -1
  707. package/model/updateSelectiveSyncForWarehouse200Response.ts +1 -1
  708. package/model/updateSelectiveSyncForWarehouseV1Input.ts +1 -1
  709. package/model/updateSelectiveSyncForWarehouseV1Output.ts +1 -1
  710. package/model/updateSource200Response.ts +4 -4
  711. package/model/updateSource200Response1.ts +4 -4
  712. package/model/updateSourceAlphaInput.ts +2 -2
  713. package/model/updateSourceAlphaOutput.ts +1 -1
  714. package/model/updateSourceV1Input.ts +2 -2
  715. package/model/updateSourceV1Output.ts +1 -1
  716. package/model/updateSubscriptionForDestination200Response.ts +1 -1
  717. package/model/updateSubscriptionForDestinationAlphaInput.ts +1 -1
  718. package/model/updateSubscriptionForDestinationAlphaOutput.ts +1 -1
  719. package/model/updateTrackingPlan200Response.ts +1 -1
  720. package/model/updateTrackingPlanV1Input.ts +1 -1
  721. package/model/updateTrackingPlanV1Output.ts +1 -1
  722. package/model/updateTransformation200Response.ts +1 -1
  723. package/model/updateTransformationBetaInput.ts +11 -1
  724. package/model/updateTransformationBetaOutput.ts +1 -1
  725. package/model/updateUserGroup200Response.ts +1 -1
  726. package/model/updateUserGroupV1Input.ts +1 -1
  727. package/model/updateUserGroupV1Output.ts +1 -1
  728. package/model/updateWarehouse200Response.ts +1 -1
  729. package/model/updateWarehouseV1Input.ts +2 -2
  730. package/model/updateWarehouseV1Output.ts +1 -1
  731. package/model/upsertRuleV1.ts +1 -1
  732. package/model/user.ts +2 -1
  733. package/model/userGroup.ts +2 -1
  734. package/model/userGroup1.ts +2 -1
  735. package/model/userGroup2.ts +2 -1
  736. package/model/userGroup3.ts +2 -1
  737. package/model/userGroupV1.ts +1 -1
  738. package/model/userV1.ts +1 -1
  739. package/model/usersPerSourceSnapshotV1.ts +1 -1
  740. package/model/warehouse.ts +3 -2
  741. package/model/warehouse1.ts +3 -2
  742. package/model/warehouse2.ts +3 -2
  743. package/model/warehouseAdvancedSyncV1.ts +1 -1
  744. package/model/warehouseMetadata.ts +2 -1
  745. package/model/warehouseMetadataV1.ts +1 -1
  746. package/model/warehouseSelectiveSyncItemV1.ts +1 -1
  747. package/model/warehouseSyncOverrideV1.ts +1 -1
  748. package/model/warehouseV1.ts +2 -2
  749. package/model/workspace.ts +2 -1
  750. package/model/workspaceV1.ts +1 -1
  751. package/package.json +1 -1
  752. package/tests/__snapshots__/smoke.test.ts.snap +9 -9
  753. package/tests/smoke.test.ts +6 -6
@@ -14,7 +14,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
14
14
  function verb(n) { return function (v) { return step([n, v]); }; }
15
15
  function step(op) {
16
16
  if (f) throw new TypeError("Generator is already executing.");
17
- while (_) try {
17
+ while (g && (g = 0, op[0] && (_ = 0)), _) try {
18
18
  if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
19
19
  if (y = 0, t) op = [op[0] & 2, t.value];
20
20
  switch (op[0]) {
@@ -112,7 +112,7 @@ var SourcesApi = (function () {
112
112
  SourcesApi.prototype.addInterceptor = function (interceptor) {
113
113
  this.interceptors.push(interceptor);
114
114
  };
115
- SourcesApi.prototype.addLabelsToSourceAlpha = function (sourceId, AddLabelsToSourceAlphaInput, options) {
115
+ SourcesApi.prototype.addLabelsToSource = function (sourceId, AddLabelsToSourceV1Input, options) {
116
116
  if (options === void 0) { options = { headers: {} }; }
117
117
  return __awaiter(this, void 0, void 0, function () {
118
118
  var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_1, _i, _a, interceptor;
@@ -123,22 +123,24 @@ var SourcesApi = (function () {
123
123
  localVarQueryParameters = {};
124
124
  localVarHeaderParams = Object.assign({}, this._defaultHeaders);
125
125
  produces = [
126
- 'application/vnd.segment.v1alpha+json',
126
+ 'application/vnd.segment.v1+json',
127
127
  'application/json',
128
+ 'application/vnd.segment.v1beta+json',
129
+ 'application/vnd.segment.v1alpha+json',
128
130
  ];
129
131
  if (produces.indexOf('application/json') >= 0) {
130
- localVarHeaderParams.Accept = produces[0];
132
+ localVarHeaderParams.Accept = 'application/json';
131
133
  }
132
134
  else {
133
- localVarHeaderParams.Accept = 'application/json';
135
+ localVarHeaderParams.Accept = produces.join(',');
134
136
  }
135
137
  localVarFormParams = {};
136
138
  if (sourceId === null || sourceId === undefined) {
137
- throw new Error('Required parameter sourceId was null or undefined when calling addLabelsToSourceAlpha.');
139
+ throw new Error('Required parameter sourceId was null or undefined when calling addLabelsToSource.');
138
140
  }
139
- if (AddLabelsToSourceAlphaInput === null ||
140
- AddLabelsToSourceAlphaInput === undefined) {
141
- throw new Error('Required parameter AddLabelsToSourceAlphaInput was null or undefined when calling addLabelsToSourceAlpha.');
141
+ if (AddLabelsToSourceV1Input === null ||
142
+ AddLabelsToSourceV1Input === undefined) {
143
+ throw new Error('Required parameter AddLabelsToSourceV1Input was null or undefined when calling addLabelsToSource.');
142
144
  }
143
145
  Object.assign(localVarHeaderParams, options.headers);
144
146
  localVarUseFormData = false;
@@ -149,7 +151,7 @@ var SourcesApi = (function () {
149
151
  uri: localVarPath,
150
152
  useQuerystring: this._useQuerystring,
151
153
  json: true,
152
- body: models_1.ObjectSerializer.serialize(AddLabelsToSourceAlphaInput, 'AddLabelsToSourceAlphaInput'),
154
+ body: models_1.ObjectSerializer.serialize(AddLabelsToSourceV1Input, 'AddLabelsToSourceV1Input'),
153
155
  };
154
156
  authenticationPromise = Promise.resolve();
155
157
  if (this.authentications.token.accessToken) {
@@ -201,33 +203,30 @@ var SourcesApi = (function () {
201
203
  });
202
204
  });
203
205
  };
204
- SourcesApi.prototype.addLabelsToSourceBeta = function (sourceId, AddLabelsToSourceV1Input, options) {
206
+ SourcesApi.prototype.createSource = function (CreateSourceV1Input, options) {
205
207
  if (options === void 0) { options = { headers: {} }; }
206
208
  return __awaiter(this, void 0, void 0, function () {
207
209
  var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_2, _i, _a, interceptor;
208
210
  var _this = this;
209
211
  return __generator(this, function (_b) {
210
- localVarPath = this.basePath +
211
- '/sources/{sourceId}/labels'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
212
+ localVarPath = this.basePath + '/sources';
212
213
  localVarQueryParameters = {};
213
214
  localVarHeaderParams = Object.assign({}, this._defaultHeaders);
214
215
  produces = [
215
- 'application/vnd.segment.v1beta+json',
216
+ 'application/vnd.segment.v1+json',
216
217
  'application/json',
218
+ 'application/vnd.segment.v1beta+json',
219
+ 'application/vnd.segment.v1alpha+json',
217
220
  ];
218
221
  if (produces.indexOf('application/json') >= 0) {
219
- localVarHeaderParams.Accept = produces[0];
222
+ localVarHeaderParams.Accept = 'application/json';
220
223
  }
221
224
  else {
222
- localVarHeaderParams.Accept = 'application/json';
225
+ localVarHeaderParams.Accept = produces.join(',');
223
226
  }
224
227
  localVarFormParams = {};
225
- if (sourceId === null || sourceId === undefined) {
226
- throw new Error('Required parameter sourceId was null or undefined when calling addLabelsToSourceBeta.');
227
- }
228
- if (AddLabelsToSourceV1Input === null ||
229
- AddLabelsToSourceV1Input === undefined) {
230
- throw new Error('Required parameter AddLabelsToSourceV1Input was null or undefined when calling addLabelsToSourceBeta.');
228
+ if (CreateSourceV1Input === null || CreateSourceV1Input === undefined) {
229
+ throw new Error('Required parameter CreateSourceV1Input was null or undefined when calling createSource.');
231
230
  }
232
231
  Object.assign(localVarHeaderParams, options.headers);
233
232
  localVarUseFormData = false;
@@ -238,7 +237,7 @@ var SourcesApi = (function () {
238
237
  uri: localVarPath,
239
238
  useQuerystring: this._useQuerystring,
240
239
  json: true,
241
- body: models_1.ObjectSerializer.serialize(AddLabelsToSourceV1Input, 'AddLabelsToSourceV1Input'),
240
+ body: models_1.ObjectSerializer.serialize(CreateSourceV1Input, 'CreateSourceV1Input'),
242
241
  };
243
242
  authenticationPromise = Promise.resolve();
244
243
  if (this.authentications.token.accessToken) {
@@ -277,7 +276,7 @@ var SourcesApi = (function () {
277
276
  if (response.statusCode &&
278
277
  response.statusCode >= 200 &&
279
278
  response.statusCode <= 299) {
280
- body = models_1.ObjectSerializer.deserialize(body, 'AddLabelsToSource200Response1');
279
+ body = models_1.ObjectSerializer.deserialize(body, 'CreateSource200Response');
281
280
  resolve({ response: response, body: body });
282
281
  }
283
282
  else {
@@ -290,44 +289,41 @@ var SourcesApi = (function () {
290
289
  });
291
290
  });
292
291
  };
293
- SourcesApi.prototype.addLabelsToSourceCurrent = function (sourceId, AddLabelsToSourceV1Input, options) {
292
+ SourcesApi.prototype.deleteSource = function (sourceId, options) {
294
293
  if (options === void 0) { options = { headers: {} }; }
295
294
  return __awaiter(this, void 0, void 0, function () {
296
295
  var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_3, _i, _a, interceptor;
297
296
  var _this = this;
298
297
  return __generator(this, function (_b) {
299
298
  localVarPath = this.basePath +
300
- '/sources/{sourceId}/labels'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
299
+ '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
301
300
  localVarQueryParameters = {};
302
301
  localVarHeaderParams = Object.assign({}, this._defaultHeaders);
303
302
  produces = [
304
303
  'application/vnd.segment.v1+json',
305
304
  'application/json',
305
+ 'application/vnd.segment.v1beta+json',
306
+ 'application/vnd.segment.v1alpha+json',
306
307
  ];
307
308
  if (produces.indexOf('application/json') >= 0) {
308
- localVarHeaderParams.Accept = produces[0];
309
+ localVarHeaderParams.Accept = 'application/json';
309
310
  }
310
311
  else {
311
- localVarHeaderParams.Accept = 'application/json';
312
+ localVarHeaderParams.Accept = produces.join(',');
312
313
  }
313
314
  localVarFormParams = {};
314
315
  if (sourceId === null || sourceId === undefined) {
315
- throw new Error('Required parameter sourceId was null or undefined when calling addLabelsToSourceCurrent.');
316
- }
317
- if (AddLabelsToSourceV1Input === null ||
318
- AddLabelsToSourceV1Input === undefined) {
319
- throw new Error('Required parameter AddLabelsToSourceV1Input was null or undefined when calling addLabelsToSourceCurrent.');
316
+ throw new Error('Required parameter sourceId was null or undefined when calling deleteSource.');
320
317
  }
321
318
  Object.assign(localVarHeaderParams, options.headers);
322
319
  localVarUseFormData = false;
323
320
  localVarRequestOptions = {
324
- method: 'POST',
321
+ method: 'DELETE',
325
322
  qs: localVarQueryParameters,
326
323
  headers: localVarHeaderParams,
327
324
  uri: localVarPath,
328
325
  useQuerystring: this._useQuerystring,
329
326
  json: true,
330
- body: models_1.ObjectSerializer.serialize(AddLabelsToSourceV1Input, 'AddLabelsToSourceV1Input'),
331
327
  };
332
328
  authenticationPromise = Promise.resolve();
333
329
  if (this.authentications.token.accessToken) {
@@ -366,7 +362,7 @@ var SourcesApi = (function () {
366
362
  if (response.statusCode &&
367
363
  response.statusCode >= 200 &&
368
364
  response.statusCode <= 299) {
369
- body = models_1.ObjectSerializer.deserialize(body, 'AddLabelsToSource200Response1');
365
+ body = models_1.ObjectSerializer.deserialize(body, 'DeleteSource200Response');
370
366
  resolve({ response: response, body: body });
371
367
  }
372
368
  else {
@@ -379,44 +375,41 @@ var SourcesApi = (function () {
379
375
  });
380
376
  });
381
377
  };
382
- SourcesApi.prototype.addLabelsToSourceV1 = function (sourceId, AddLabelsToSourceV1Input, options) {
378
+ SourcesApi.prototype.getSource = function (sourceId, options) {
383
379
  if (options === void 0) { options = { headers: {} }; }
384
380
  return __awaiter(this, void 0, void 0, function () {
385
381
  var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_4, _i, _a, interceptor;
386
382
  var _this = this;
387
383
  return __generator(this, function (_b) {
388
384
  localVarPath = this.basePath +
389
- '/sources/{sourceId}/labels'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
385
+ '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
390
386
  localVarQueryParameters = {};
391
387
  localVarHeaderParams = Object.assign({}, this._defaultHeaders);
392
388
  produces = [
393
389
  'application/vnd.segment.v1+json',
394
390
  'application/json',
391
+ 'application/vnd.segment.v1beta+json',
392
+ 'application/vnd.segment.v1alpha+json',
395
393
  ];
396
394
  if (produces.indexOf('application/json') >= 0) {
397
- localVarHeaderParams.Accept = produces[0];
395
+ localVarHeaderParams.Accept = 'application/json';
398
396
  }
399
397
  else {
400
- localVarHeaderParams.Accept = 'application/json';
398
+ localVarHeaderParams.Accept = produces.join(',');
401
399
  }
402
400
  localVarFormParams = {};
403
401
  if (sourceId === null || sourceId === undefined) {
404
- throw new Error('Required parameter sourceId was null or undefined when calling addLabelsToSourceV1.');
405
- }
406
- if (AddLabelsToSourceV1Input === null ||
407
- AddLabelsToSourceV1Input === undefined) {
408
- throw new Error('Required parameter AddLabelsToSourceV1Input was null or undefined when calling addLabelsToSourceV1.');
402
+ throw new Error('Required parameter sourceId was null or undefined when calling getSource.');
409
403
  }
410
404
  Object.assign(localVarHeaderParams, options.headers);
411
405
  localVarUseFormData = false;
412
406
  localVarRequestOptions = {
413
- method: 'POST',
407
+ method: 'GET',
414
408
  qs: localVarQueryParameters,
415
409
  headers: localVarHeaderParams,
416
410
  uri: localVarPath,
417
411
  useQuerystring: this._useQuerystring,
418
412
  json: true,
419
- body: models_1.ObjectSerializer.serialize(AddLabelsToSourceV1Input, 'AddLabelsToSourceV1Input'),
420
413
  };
421
414
  authenticationPromise = Promise.resolve();
422
415
  if (this.authentications.token.accessToken) {
@@ -455,7 +448,7 @@ var SourcesApi = (function () {
455
448
  if (response.statusCode &&
456
449
  response.statusCode >= 200 &&
457
450
  response.statusCode <= 299) {
458
- body = models_1.ObjectSerializer.deserialize(body, 'AddLabelsToSource200Response1');
451
+ body = models_1.ObjectSerializer.deserialize(body, 'GetSource200Response');
459
452
  resolve({ response: response, body: body });
460
453
  }
461
454
  else {
@@ -468,40 +461,47 @@ var SourcesApi = (function () {
468
461
  });
469
462
  });
470
463
  };
471
- SourcesApi.prototype.createSourceAlpha = function (CreateSourceAlphaInput, options) {
464
+ SourcesApi.prototype.listConnectedDestinationsFromSource = function (sourceId, pagination, options) {
472
465
  if (options === void 0) { options = { headers: {} }; }
473
466
  return __awaiter(this, void 0, void 0, function () {
474
467
  var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_5, _i, _a, interceptor;
475
468
  var _this = this;
476
469
  return __generator(this, function (_b) {
477
- localVarPath = this.basePath + '/sources';
470
+ localVarPath = this.basePath +
471
+ '/sources/{sourceId}/connected-destinations'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
478
472
  localVarQueryParameters = {};
479
473
  localVarHeaderParams = Object.assign({}, this._defaultHeaders);
480
474
  produces = [
481
- 'application/vnd.segment.v1alpha+json',
475
+ 'application/vnd.segment.v1+json',
482
476
  'application/json',
477
+ 'application/vnd.segment.v1beta+json',
478
+ 'application/vnd.segment.v1alpha+json',
483
479
  ];
484
480
  if (produces.indexOf('application/json') >= 0) {
485
- localVarHeaderParams.Accept = produces[0];
481
+ localVarHeaderParams.Accept = 'application/json';
486
482
  }
487
483
  else {
488
- localVarHeaderParams.Accept = 'application/json';
484
+ localVarHeaderParams.Accept = produces.join(',');
489
485
  }
490
486
  localVarFormParams = {};
491
- if (CreateSourceAlphaInput === null ||
492
- CreateSourceAlphaInput === undefined) {
493
- throw new Error('Required parameter CreateSourceAlphaInput was null or undefined when calling createSourceAlpha.');
487
+ if (sourceId === null || sourceId === undefined) {
488
+ throw new Error('Required parameter sourceId was null or undefined when calling listConnectedDestinationsFromSource.');
489
+ }
490
+ if (pagination === null || pagination === undefined) {
491
+ throw new Error('Required parameter pagination was null or undefined when calling listConnectedDestinationsFromSource.');
492
+ }
493
+ if (pagination !== undefined) {
494
+ localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
494
495
  }
495
496
  Object.assign(localVarHeaderParams, options.headers);
496
497
  localVarUseFormData = false;
497
498
  localVarRequestOptions = {
498
- method: 'POST',
499
+ method: 'GET',
499
500
  qs: localVarQueryParameters,
500
501
  headers: localVarHeaderParams,
501
502
  uri: localVarPath,
502
503
  useQuerystring: this._useQuerystring,
503
504
  json: true,
504
- body: models_1.ObjectSerializer.serialize(CreateSourceAlphaInput, 'CreateSourceAlphaInput'),
505
505
  };
506
506
  authenticationPromise = Promise.resolve();
507
507
  if (this.authentications.token.accessToken) {
@@ -540,7 +540,7 @@ var SourcesApi = (function () {
540
540
  if (response.statusCode &&
541
541
  response.statusCode >= 200 &&
542
542
  response.statusCode <= 299) {
543
- body = models_1.ObjectSerializer.deserialize(body, 'CreateSource200Response');
543
+ body = models_1.ObjectSerializer.deserialize(body, 'ListConnectedDestinationsFromSource200Response');
544
544
  resolve({ response: response, body: body });
545
545
  }
546
546
  else {
@@ -553,39 +553,47 @@ var SourcesApi = (function () {
553
553
  });
554
554
  });
555
555
  };
556
- SourcesApi.prototype.createSourceBeta = function (CreateSourceV1Input, options) {
556
+ SourcesApi.prototype.listConnectedWarehousesFromSource = function (sourceId, pagination, options) {
557
557
  if (options === void 0) { options = { headers: {} }; }
558
558
  return __awaiter(this, void 0, void 0, function () {
559
559
  var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_6, _i, _a, interceptor;
560
560
  var _this = this;
561
561
  return __generator(this, function (_b) {
562
- localVarPath = this.basePath + '/sources';
562
+ localVarPath = this.basePath +
563
+ '/sources/{sourceId}/connected-warehouses'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
563
564
  localVarQueryParameters = {};
564
565
  localVarHeaderParams = Object.assign({}, this._defaultHeaders);
565
566
  produces = [
566
- 'application/vnd.segment.v1beta+json',
567
+ 'application/vnd.segment.v1+json',
567
568
  'application/json',
569
+ 'application/vnd.segment.v1beta+json',
570
+ 'application/vnd.segment.v1alpha+json',
568
571
  ];
569
572
  if (produces.indexOf('application/json') >= 0) {
570
- localVarHeaderParams.Accept = produces[0];
573
+ localVarHeaderParams.Accept = 'application/json';
571
574
  }
572
575
  else {
573
- localVarHeaderParams.Accept = 'application/json';
576
+ localVarHeaderParams.Accept = produces.join(',');
574
577
  }
575
578
  localVarFormParams = {};
576
- if (CreateSourceV1Input === null || CreateSourceV1Input === undefined) {
577
- throw new Error('Required parameter CreateSourceV1Input was null or undefined when calling createSourceBeta.');
579
+ if (sourceId === null || sourceId === undefined) {
580
+ throw new Error('Required parameter sourceId was null or undefined when calling listConnectedWarehousesFromSource.');
581
+ }
582
+ if (pagination === null || pagination === undefined) {
583
+ throw new Error('Required parameter pagination was null or undefined when calling listConnectedWarehousesFromSource.');
584
+ }
585
+ if (pagination !== undefined) {
586
+ localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
578
587
  }
579
588
  Object.assign(localVarHeaderParams, options.headers);
580
589
  localVarUseFormData = false;
581
590
  localVarRequestOptions = {
582
- method: 'POST',
591
+ method: 'GET',
583
592
  qs: localVarQueryParameters,
584
593
  headers: localVarHeaderParams,
585
594
  uri: localVarPath,
586
595
  useQuerystring: this._useQuerystring,
587
596
  json: true,
588
- body: models_1.ObjectSerializer.serialize(CreateSourceV1Input, 'CreateSourceV1Input'),
589
597
  };
590
598
  authenticationPromise = Promise.resolve();
591
599
  if (this.authentications.token.accessToken) {
@@ -624,7 +632,7 @@ var SourcesApi = (function () {
624
632
  if (response.statusCode &&
625
633
  response.statusCode >= 200 &&
626
634
  response.statusCode <= 299) {
627
- body = models_1.ObjectSerializer.deserialize(body, 'CreateSource200Response1');
635
+ body = models_1.ObjectSerializer.deserialize(body, 'ListConnectedWarehousesFromSource200Response');
628
636
  resolve({ response: response, body: body });
629
637
  }
630
638
  else {
@@ -637,39 +645,41 @@ var SourcesApi = (function () {
637
645
  });
638
646
  });
639
647
  };
640
- SourcesApi.prototype.createSourceCurrent = function (CreateSourceV1Input, options) {
648
+ SourcesApi.prototype.listSchemaSettingsInSource = function (sourceId, options) {
641
649
  if (options === void 0) { options = { headers: {} }; }
642
650
  return __awaiter(this, void 0, void 0, function () {
643
651
  var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_7, _i, _a, interceptor;
644
652
  var _this = this;
645
653
  return __generator(this, function (_b) {
646
- localVarPath = this.basePath + '/sources';
654
+ localVarPath = this.basePath +
655
+ '/sources/{sourceId}/settings'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
647
656
  localVarQueryParameters = {};
648
657
  localVarHeaderParams = Object.assign({}, this._defaultHeaders);
649
658
  produces = [
650
659
  'application/vnd.segment.v1+json',
651
660
  'application/json',
661
+ 'application/vnd.segment.v1beta+json',
662
+ 'application/vnd.segment.v1alpha+json',
652
663
  ];
653
664
  if (produces.indexOf('application/json') >= 0) {
654
- localVarHeaderParams.Accept = produces[0];
665
+ localVarHeaderParams.Accept = 'application/json';
655
666
  }
656
667
  else {
657
- localVarHeaderParams.Accept = 'application/json';
668
+ localVarHeaderParams.Accept = produces.join(',');
658
669
  }
659
670
  localVarFormParams = {};
660
- if (CreateSourceV1Input === null || CreateSourceV1Input === undefined) {
661
- throw new Error('Required parameter CreateSourceV1Input was null or undefined when calling createSourceCurrent.');
671
+ if (sourceId === null || sourceId === undefined) {
672
+ throw new Error('Required parameter sourceId was null or undefined when calling listSchemaSettingsInSource.');
662
673
  }
663
674
  Object.assign(localVarHeaderParams, options.headers);
664
675
  localVarUseFormData = false;
665
676
  localVarRequestOptions = {
666
- method: 'POST',
677
+ method: 'GET',
667
678
  qs: localVarQueryParameters,
668
679
  headers: localVarHeaderParams,
669
680
  uri: localVarPath,
670
681
  useQuerystring: this._useQuerystring,
671
682
  json: true,
672
- body: models_1.ObjectSerializer.serialize(CreateSourceV1Input, 'CreateSourceV1Input'),
673
683
  };
674
684
  authenticationPromise = Promise.resolve();
675
685
  if (this.authentications.token.accessToken) {
@@ -708,7 +718,7 @@ var SourcesApi = (function () {
708
718
  if (response.statusCode &&
709
719
  response.statusCode >= 200 &&
710
720
  response.statusCode <= 299) {
711
- body = models_1.ObjectSerializer.deserialize(body, 'CreateSource200Response1');
721
+ body = models_1.ObjectSerializer.deserialize(body, 'ListSchemaSettingsInSource200Response');
712
722
  resolve({ response: response, body: body });
713
723
  }
714
724
  else {
@@ -721,7 +731,7 @@ var SourcesApi = (function () {
721
731
  });
722
732
  });
723
733
  };
724
- SourcesApi.prototype.createSourceV1 = function (CreateSourceV1Input, options) {
734
+ SourcesApi.prototype.listSources = function (pagination, options) {
725
735
  if (options === void 0) { options = { headers: {} }; }
726
736
  return __awaiter(this, void 0, void 0, function () {
727
737
  var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_8, _i, _a, interceptor;
@@ -733,27 +743,31 @@ var SourcesApi = (function () {
733
743
  produces = [
734
744
  'application/vnd.segment.v1+json',
735
745
  'application/json',
746
+ 'application/vnd.segment.v1beta+json',
747
+ 'application/vnd.segment.v1alpha+json',
736
748
  ];
737
749
  if (produces.indexOf('application/json') >= 0) {
738
- localVarHeaderParams.Accept = produces[0];
750
+ localVarHeaderParams.Accept = 'application/json';
739
751
  }
740
752
  else {
741
- localVarHeaderParams.Accept = 'application/json';
753
+ localVarHeaderParams.Accept = produces.join(',');
742
754
  }
743
755
  localVarFormParams = {};
744
- if (CreateSourceV1Input === null || CreateSourceV1Input === undefined) {
745
- throw new Error('Required parameter CreateSourceV1Input was null or undefined when calling createSourceV1.');
756
+ if (pagination === null || pagination === undefined) {
757
+ throw new Error('Required parameter pagination was null or undefined when calling listSources.');
758
+ }
759
+ if (pagination !== undefined) {
760
+ localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
746
761
  }
747
762
  Object.assign(localVarHeaderParams, options.headers);
748
763
  localVarUseFormData = false;
749
764
  localVarRequestOptions = {
750
- method: 'POST',
765
+ method: 'GET',
751
766
  qs: localVarQueryParameters,
752
767
  headers: localVarHeaderParams,
753
768
  uri: localVarPath,
754
769
  useQuerystring: this._useQuerystring,
755
770
  json: true,
756
- body: models_1.ObjectSerializer.serialize(CreateSourceV1Input, 'CreateSourceV1Input'),
757
771
  };
758
772
  authenticationPromise = Promise.resolve();
759
773
  if (this.authentications.token.accessToken) {
@@ -792,7 +806,7 @@ var SourcesApi = (function () {
792
806
  if (response.statusCode &&
793
807
  response.statusCode >= 200 &&
794
808
  response.statusCode <= 299) {
795
- body = models_1.ObjectSerializer.deserialize(body, 'CreateSource200Response1');
809
+ body = models_1.ObjectSerializer.deserialize(body, 'ListSources200Response');
796
810
  resolve({ response: response, body: body });
797
811
  }
798
812
  else {
@@ -805,39 +819,46 @@ var SourcesApi = (function () {
805
819
  });
806
820
  });
807
821
  };
808
- SourcesApi.prototype.deleteSourceAlpha = function (sourceId, options) {
822
+ SourcesApi.prototype.replaceLabelsInSource = function (sourceId, ReplaceLabelsInSourceV1Input, options) {
809
823
  if (options === void 0) { options = { headers: {} }; }
810
824
  return __awaiter(this, void 0, void 0, function () {
811
825
  var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_9, _i, _a, interceptor;
812
826
  var _this = this;
813
827
  return __generator(this, function (_b) {
814
828
  localVarPath = this.basePath +
815
- '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
829
+ '/sources/{sourceId}/labels'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
816
830
  localVarQueryParameters = {};
817
831
  localVarHeaderParams = Object.assign({}, this._defaultHeaders);
818
832
  produces = [
819
- 'application/vnd.segment.v1alpha+json',
833
+ 'application/vnd.segment.v1+json',
820
834
  'application/json',
835
+ 'application/vnd.segment.v1beta+json',
836
+ 'application/vnd.segment.v1alpha+json',
821
837
  ];
822
838
  if (produces.indexOf('application/json') >= 0) {
823
- localVarHeaderParams.Accept = produces[0];
839
+ localVarHeaderParams.Accept = 'application/json';
824
840
  }
825
841
  else {
826
- localVarHeaderParams.Accept = 'application/json';
842
+ localVarHeaderParams.Accept = produces.join(',');
827
843
  }
828
844
  localVarFormParams = {};
829
845
  if (sourceId === null || sourceId === undefined) {
830
- throw new Error('Required parameter sourceId was null or undefined when calling deleteSourceAlpha.');
846
+ throw new Error('Required parameter sourceId was null or undefined when calling replaceLabelsInSource.');
847
+ }
848
+ if (ReplaceLabelsInSourceV1Input === null ||
849
+ ReplaceLabelsInSourceV1Input === undefined) {
850
+ throw new Error('Required parameter ReplaceLabelsInSourceV1Input was null or undefined when calling replaceLabelsInSource.');
831
851
  }
832
852
  Object.assign(localVarHeaderParams, options.headers);
833
853
  localVarUseFormData = false;
834
854
  localVarRequestOptions = {
835
- method: 'DELETE',
855
+ method: 'PUT',
836
856
  qs: localVarQueryParameters,
837
857
  headers: localVarHeaderParams,
838
858
  uri: localVarPath,
839
859
  useQuerystring: this._useQuerystring,
840
860
  json: true,
861
+ body: models_1.ObjectSerializer.serialize(ReplaceLabelsInSourceV1Input, 'ReplaceLabelsInSourceV1Input'),
841
862
  };
842
863
  authenticationPromise = Promise.resolve();
843
864
  if (this.authentications.token.accessToken) {
@@ -876,7 +897,7 @@ var SourcesApi = (function () {
876
897
  if (response.statusCode &&
877
898
  response.statusCode >= 200 &&
878
899
  response.statusCode <= 299) {
879
- body = models_1.ObjectSerializer.deserialize(body, 'DeleteSource200Response');
900
+ body = models_1.ObjectSerializer.deserialize(body, 'ReplaceLabelsInSource200Response');
880
901
  resolve({ response: response, body: body });
881
902
  }
882
903
  else {
@@ -889,39 +910,46 @@ var SourcesApi = (function () {
889
910
  });
890
911
  });
891
912
  };
892
- SourcesApi.prototype.deleteSourceBeta = function (sourceId, options) {
913
+ SourcesApi.prototype.updateSchemaSettingsInSource = function (sourceId, UpdateSchemaSettingsInSourceV1Input, options) {
893
914
  if (options === void 0) { options = { headers: {} }; }
894
915
  return __awaiter(this, void 0, void 0, function () {
895
916
  var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_10, _i, _a, interceptor;
896
917
  var _this = this;
897
918
  return __generator(this, function (_b) {
898
919
  localVarPath = this.basePath +
899
- '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
920
+ '/sources/{sourceId}/settings'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
900
921
  localVarQueryParameters = {};
901
922
  localVarHeaderParams = Object.assign({}, this._defaultHeaders);
902
923
  produces = [
903
- 'application/vnd.segment.v1beta+json',
924
+ 'application/vnd.segment.v1+json',
904
925
  'application/json',
926
+ 'application/vnd.segment.v1beta+json',
927
+ 'application/vnd.segment.v1alpha+json',
905
928
  ];
906
929
  if (produces.indexOf('application/json') >= 0) {
907
- localVarHeaderParams.Accept = produces[0];
930
+ localVarHeaderParams.Accept = 'application/json';
908
931
  }
909
932
  else {
910
- localVarHeaderParams.Accept = 'application/json';
933
+ localVarHeaderParams.Accept = produces.join(',');
911
934
  }
912
935
  localVarFormParams = {};
913
936
  if (sourceId === null || sourceId === undefined) {
914
- throw new Error('Required parameter sourceId was null or undefined when calling deleteSourceBeta.');
937
+ throw new Error('Required parameter sourceId was null or undefined when calling updateSchemaSettingsInSource.');
938
+ }
939
+ if (UpdateSchemaSettingsInSourceV1Input === null ||
940
+ UpdateSchemaSettingsInSourceV1Input === undefined) {
941
+ throw new Error('Required parameter UpdateSchemaSettingsInSourceV1Input was null or undefined when calling updateSchemaSettingsInSource.');
915
942
  }
916
943
  Object.assign(localVarHeaderParams, options.headers);
917
944
  localVarUseFormData = false;
918
945
  localVarRequestOptions = {
919
- method: 'DELETE',
946
+ method: 'PATCH',
920
947
  qs: localVarQueryParameters,
921
948
  headers: localVarHeaderParams,
922
949
  uri: localVarPath,
923
950
  useQuerystring: this._useQuerystring,
924
951
  json: true,
952
+ body: models_1.ObjectSerializer.serialize(UpdateSchemaSettingsInSourceV1Input, 'UpdateSchemaSettingsInSourceV1Input'),
925
953
  };
926
954
  authenticationPromise = Promise.resolve();
927
955
  if (this.authentications.token.accessToken) {
@@ -960,7 +988,7 @@ var SourcesApi = (function () {
960
988
  if (response.statusCode &&
961
989
  response.statusCode >= 200 &&
962
990
  response.statusCode <= 299) {
963
- body = models_1.ObjectSerializer.deserialize(body, 'DeleteSource200Response1');
991
+ body = models_1.ObjectSerializer.deserialize(body, 'UpdateSchemaSettingsInSource200Response');
964
992
  resolve({ response: response, body: body });
965
993
  }
966
994
  else {
@@ -973,92 +1001,11 @@ var SourcesApi = (function () {
973
1001
  });
974
1002
  });
975
1003
  };
976
- SourcesApi.prototype.deleteSourceCurrent = function (sourceId, options) {
1004
+ SourcesApi.prototype.updateSource = function (sourceId, UpdateSourceV1Input, options) {
977
1005
  if (options === void 0) { options = { headers: {} }; }
978
1006
  return __awaiter(this, void 0, void 0, function () {
979
1007
  var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_11, _i, _a, interceptor;
980
1008
  var _this = this;
981
- return __generator(this, function (_b) {
982
- localVarPath = this.basePath +
983
- '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
984
- localVarQueryParameters = {};
985
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
986
- produces = ['application/json'];
987
- if (produces.indexOf('application/json') >= 0) {
988
- localVarHeaderParams.Accept = produces[0];
989
- }
990
- else {
991
- localVarHeaderParams.Accept = 'application/json';
992
- }
993
- localVarFormParams = {};
994
- if (sourceId === null || sourceId === undefined) {
995
- throw new Error('Required parameter sourceId was null or undefined when calling deleteSourceCurrent.');
996
- }
997
- Object.assign(localVarHeaderParams, options.headers);
998
- localVarUseFormData = false;
999
- localVarRequestOptions = {
1000
- method: 'DELETE',
1001
- qs: localVarQueryParameters,
1002
- headers: localVarHeaderParams,
1003
- uri: localVarPath,
1004
- useQuerystring: this._useQuerystring,
1005
- json: true,
1006
- };
1007
- authenticationPromise = Promise.resolve();
1008
- if (this.authentications.token.accessToken) {
1009
- authenticationPromise = authenticationPromise.then(function () {
1010
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
1011
- });
1012
- }
1013
- authenticationPromise = authenticationPromise.then(function () {
1014
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
1015
- });
1016
- interceptorPromise = authenticationPromise;
1017
- _loop_11 = function (interceptor) {
1018
- interceptorPromise = interceptorPromise.then(function () {
1019
- return interceptor(localVarRequestOptions);
1020
- });
1021
- };
1022
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
1023
- interceptor = _a[_i];
1024
- _loop_11(interceptor);
1025
- }
1026
- return [2, interceptorPromise.then(function () {
1027
- if (Object.keys(localVarFormParams).length) {
1028
- if (localVarUseFormData) {
1029
- localVarRequestOptions.formData = localVarFormParams;
1030
- }
1031
- else {
1032
- localVarRequestOptions.form = localVarFormParams;
1033
- }
1034
- }
1035
- return new Promise(function (resolve, reject) {
1036
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
1037
- if (error) {
1038
- reject(error);
1039
- }
1040
- else {
1041
- if (response.statusCode &&
1042
- response.statusCode >= 200 &&
1043
- response.statusCode <= 299) {
1044
- body = models_1.ObjectSerializer.deserialize(body, 'DeleteSource200Response1');
1045
- resolve({ response: response, body: body });
1046
- }
1047
- else {
1048
- reject(new apis_1.HttpError(response, body, response.statusCode));
1049
- }
1050
- }
1051
- });
1052
- });
1053
- })];
1054
- });
1055
- });
1056
- };
1057
- SourcesApi.prototype.deleteSourceV1 = function (sourceId, options) {
1058
- if (options === void 0) { options = { headers: {} }; }
1059
- return __awaiter(this, void 0, void 0, function () {
1060
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_12, _i, _a, interceptor;
1061
- var _this = this;
1062
1009
  return __generator(this, function (_b) {
1063
1010
  localVarPath = this.basePath +
1064
1011
  '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
@@ -1067,26 +1014,32 @@ var SourcesApi = (function () {
1067
1014
  produces = [
1068
1015
  'application/vnd.segment.v1+json',
1069
1016
  'application/json',
1017
+ 'application/vnd.segment.v1beta+json',
1018
+ 'application/vnd.segment.v1alpha+json',
1070
1019
  ];
1071
1020
  if (produces.indexOf('application/json') >= 0) {
1072
- localVarHeaderParams.Accept = produces[0];
1021
+ localVarHeaderParams.Accept = 'application/json';
1073
1022
  }
1074
1023
  else {
1075
- localVarHeaderParams.Accept = 'application/json';
1024
+ localVarHeaderParams.Accept = produces.join(',');
1076
1025
  }
1077
1026
  localVarFormParams = {};
1078
1027
  if (sourceId === null || sourceId === undefined) {
1079
- throw new Error('Required parameter sourceId was null or undefined when calling deleteSourceV1.');
1028
+ throw new Error('Required parameter sourceId was null or undefined when calling updateSource.');
1029
+ }
1030
+ if (UpdateSourceV1Input === null || UpdateSourceV1Input === undefined) {
1031
+ throw new Error('Required parameter UpdateSourceV1Input was null or undefined when calling updateSource.');
1080
1032
  }
1081
1033
  Object.assign(localVarHeaderParams, options.headers);
1082
1034
  localVarUseFormData = false;
1083
1035
  localVarRequestOptions = {
1084
- method: 'DELETE',
1036
+ method: 'PATCH',
1085
1037
  qs: localVarQueryParameters,
1086
1038
  headers: localVarHeaderParams,
1087
1039
  uri: localVarPath,
1088
1040
  useQuerystring: this._useQuerystring,
1089
1041
  json: true,
1042
+ body: models_1.ObjectSerializer.serialize(UpdateSourceV1Input, 'UpdateSourceV1Input'),
1090
1043
  };
1091
1044
  authenticationPromise = Promise.resolve();
1092
1045
  if (this.authentications.token.accessToken) {
@@ -1098,2536 +1051,14 @@ var SourcesApi = (function () {
1098
1051
  return _this.authentications.default.applyToRequest(localVarRequestOptions);
1099
1052
  });
1100
1053
  interceptorPromise = authenticationPromise;
1101
- _loop_12 = function (interceptor) {
1054
+ _loop_11 = function (interceptor) {
1102
1055
  interceptorPromise = interceptorPromise.then(function () {
1103
1056
  return interceptor(localVarRequestOptions);
1104
1057
  });
1105
1058
  };
1106
1059
  for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
1107
1060
  interceptor = _a[_i];
1108
- _loop_12(interceptor);
1109
- }
1110
- return [2, interceptorPromise.then(function () {
1111
- if (Object.keys(localVarFormParams).length) {
1112
- if (localVarUseFormData) {
1113
- localVarRequestOptions.formData = localVarFormParams;
1114
- }
1115
- else {
1116
- localVarRequestOptions.form = localVarFormParams;
1117
- }
1118
- }
1119
- return new Promise(function (resolve, reject) {
1120
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
1121
- if (error) {
1122
- reject(error);
1123
- }
1124
- else {
1125
- if (response.statusCode &&
1126
- response.statusCode >= 200 &&
1127
- response.statusCode <= 299) {
1128
- body = models_1.ObjectSerializer.deserialize(body, 'DeleteSource200Response1');
1129
- resolve({ response: response, body: body });
1130
- }
1131
- else {
1132
- reject(new apis_1.HttpError(response, body, response.statusCode));
1133
- }
1134
- }
1135
- });
1136
- });
1137
- })];
1138
- });
1139
- });
1140
- };
1141
- SourcesApi.prototype.getSourceAlpha = function (sourceId, options) {
1142
- if (options === void 0) { options = { headers: {} }; }
1143
- return __awaiter(this, void 0, void 0, function () {
1144
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_13, _i, _a, interceptor;
1145
- var _this = this;
1146
- return __generator(this, function (_b) {
1147
- localVarPath = this.basePath +
1148
- '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
1149
- localVarQueryParameters = {};
1150
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
1151
- produces = [
1152
- 'application/vnd.segment.v1alpha+json',
1153
- 'application/json',
1154
- ];
1155
- if (produces.indexOf('application/json') >= 0) {
1156
- localVarHeaderParams.Accept = produces[0];
1157
- }
1158
- else {
1159
- localVarHeaderParams.Accept = 'application/json';
1160
- }
1161
- localVarFormParams = {};
1162
- if (sourceId === null || sourceId === undefined) {
1163
- throw new Error('Required parameter sourceId was null or undefined when calling getSourceAlpha.');
1164
- }
1165
- Object.assign(localVarHeaderParams, options.headers);
1166
- localVarUseFormData = false;
1167
- localVarRequestOptions = {
1168
- method: 'GET',
1169
- qs: localVarQueryParameters,
1170
- headers: localVarHeaderParams,
1171
- uri: localVarPath,
1172
- useQuerystring: this._useQuerystring,
1173
- json: true,
1174
- };
1175
- authenticationPromise = Promise.resolve();
1176
- if (this.authentications.token.accessToken) {
1177
- authenticationPromise = authenticationPromise.then(function () {
1178
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
1179
- });
1180
- }
1181
- authenticationPromise = authenticationPromise.then(function () {
1182
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
1183
- });
1184
- interceptorPromise = authenticationPromise;
1185
- _loop_13 = function (interceptor) {
1186
- interceptorPromise = interceptorPromise.then(function () {
1187
- return interceptor(localVarRequestOptions);
1188
- });
1189
- };
1190
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
1191
- interceptor = _a[_i];
1192
- _loop_13(interceptor);
1193
- }
1194
- return [2, interceptorPromise.then(function () {
1195
- if (Object.keys(localVarFormParams).length) {
1196
- if (localVarUseFormData) {
1197
- localVarRequestOptions.formData = localVarFormParams;
1198
- }
1199
- else {
1200
- localVarRequestOptions.form = localVarFormParams;
1201
- }
1202
- }
1203
- return new Promise(function (resolve, reject) {
1204
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
1205
- if (error) {
1206
- reject(error);
1207
- }
1208
- else {
1209
- if (response.statusCode &&
1210
- response.statusCode >= 200 &&
1211
- response.statusCode <= 299) {
1212
- body = models_1.ObjectSerializer.deserialize(body, 'GetSource200Response');
1213
- resolve({ response: response, body: body });
1214
- }
1215
- else {
1216
- reject(new apis_1.HttpError(response, body, response.statusCode));
1217
- }
1218
- }
1219
- });
1220
- });
1221
- })];
1222
- });
1223
- });
1224
- };
1225
- SourcesApi.prototype.getSourceBeta = function (sourceId, options) {
1226
- if (options === void 0) { options = { headers: {} }; }
1227
- return __awaiter(this, void 0, void 0, function () {
1228
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_14, _i, _a, interceptor;
1229
- var _this = this;
1230
- return __generator(this, function (_b) {
1231
- localVarPath = this.basePath +
1232
- '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
1233
- localVarQueryParameters = {};
1234
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
1235
- produces = [
1236
- 'application/vnd.segment.v1beta+json',
1237
- 'application/json',
1238
- ];
1239
- if (produces.indexOf('application/json') >= 0) {
1240
- localVarHeaderParams.Accept = produces[0];
1241
- }
1242
- else {
1243
- localVarHeaderParams.Accept = 'application/json';
1244
- }
1245
- localVarFormParams = {};
1246
- if (sourceId === null || sourceId === undefined) {
1247
- throw new Error('Required parameter sourceId was null or undefined when calling getSourceBeta.');
1248
- }
1249
- Object.assign(localVarHeaderParams, options.headers);
1250
- localVarUseFormData = false;
1251
- localVarRequestOptions = {
1252
- method: 'GET',
1253
- qs: localVarQueryParameters,
1254
- headers: localVarHeaderParams,
1255
- uri: localVarPath,
1256
- useQuerystring: this._useQuerystring,
1257
- json: true,
1258
- };
1259
- authenticationPromise = Promise.resolve();
1260
- if (this.authentications.token.accessToken) {
1261
- authenticationPromise = authenticationPromise.then(function () {
1262
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
1263
- });
1264
- }
1265
- authenticationPromise = authenticationPromise.then(function () {
1266
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
1267
- });
1268
- interceptorPromise = authenticationPromise;
1269
- _loop_14 = function (interceptor) {
1270
- interceptorPromise = interceptorPromise.then(function () {
1271
- return interceptor(localVarRequestOptions);
1272
- });
1273
- };
1274
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
1275
- interceptor = _a[_i];
1276
- _loop_14(interceptor);
1277
- }
1278
- return [2, interceptorPromise.then(function () {
1279
- if (Object.keys(localVarFormParams).length) {
1280
- if (localVarUseFormData) {
1281
- localVarRequestOptions.formData = localVarFormParams;
1282
- }
1283
- else {
1284
- localVarRequestOptions.form = localVarFormParams;
1285
- }
1286
- }
1287
- return new Promise(function (resolve, reject) {
1288
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
1289
- if (error) {
1290
- reject(error);
1291
- }
1292
- else {
1293
- if (response.statusCode &&
1294
- response.statusCode >= 200 &&
1295
- response.statusCode <= 299) {
1296
- body = models_1.ObjectSerializer.deserialize(body, 'GetSource200Response1');
1297
- resolve({ response: response, body: body });
1298
- }
1299
- else {
1300
- reject(new apis_1.HttpError(response, body, response.statusCode));
1301
- }
1302
- }
1303
- });
1304
- });
1305
- })];
1306
- });
1307
- });
1308
- };
1309
- SourcesApi.prototype.getSourceCurrent = function (sourceId, options) {
1310
- if (options === void 0) { options = { headers: {} }; }
1311
- return __awaiter(this, void 0, void 0, function () {
1312
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_15, _i, _a, interceptor;
1313
- var _this = this;
1314
- return __generator(this, function (_b) {
1315
- localVarPath = this.basePath +
1316
- '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
1317
- localVarQueryParameters = {};
1318
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
1319
- produces = ['application/json'];
1320
- if (produces.indexOf('application/json') >= 0) {
1321
- localVarHeaderParams.Accept = produces[0];
1322
- }
1323
- else {
1324
- localVarHeaderParams.Accept = 'application/json';
1325
- }
1326
- localVarFormParams = {};
1327
- if (sourceId === null || sourceId === undefined) {
1328
- throw new Error('Required parameter sourceId was null or undefined when calling getSourceCurrent.');
1329
- }
1330
- Object.assign(localVarHeaderParams, options.headers);
1331
- localVarUseFormData = false;
1332
- localVarRequestOptions = {
1333
- method: 'GET',
1334
- qs: localVarQueryParameters,
1335
- headers: localVarHeaderParams,
1336
- uri: localVarPath,
1337
- useQuerystring: this._useQuerystring,
1338
- json: true,
1339
- };
1340
- authenticationPromise = Promise.resolve();
1341
- if (this.authentications.token.accessToken) {
1342
- authenticationPromise = authenticationPromise.then(function () {
1343
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
1344
- });
1345
- }
1346
- authenticationPromise = authenticationPromise.then(function () {
1347
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
1348
- });
1349
- interceptorPromise = authenticationPromise;
1350
- _loop_15 = function (interceptor) {
1351
- interceptorPromise = interceptorPromise.then(function () {
1352
- return interceptor(localVarRequestOptions);
1353
- });
1354
- };
1355
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
1356
- interceptor = _a[_i];
1357
- _loop_15(interceptor);
1358
- }
1359
- return [2, interceptorPromise.then(function () {
1360
- if (Object.keys(localVarFormParams).length) {
1361
- if (localVarUseFormData) {
1362
- localVarRequestOptions.formData = localVarFormParams;
1363
- }
1364
- else {
1365
- localVarRequestOptions.form = localVarFormParams;
1366
- }
1367
- }
1368
- return new Promise(function (resolve, reject) {
1369
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
1370
- if (error) {
1371
- reject(error);
1372
- }
1373
- else {
1374
- if (response.statusCode &&
1375
- response.statusCode >= 200 &&
1376
- response.statusCode <= 299) {
1377
- body = models_1.ObjectSerializer.deserialize(body, 'GetSource200Response1');
1378
- resolve({ response: response, body: body });
1379
- }
1380
- else {
1381
- reject(new apis_1.HttpError(response, body, response.statusCode));
1382
- }
1383
- }
1384
- });
1385
- });
1386
- })];
1387
- });
1388
- });
1389
- };
1390
- SourcesApi.prototype.getSourceV1 = function (sourceId, options) {
1391
- if (options === void 0) { options = { headers: {} }; }
1392
- return __awaiter(this, void 0, void 0, function () {
1393
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_16, _i, _a, interceptor;
1394
- var _this = this;
1395
- return __generator(this, function (_b) {
1396
- localVarPath = this.basePath +
1397
- '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
1398
- localVarQueryParameters = {};
1399
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
1400
- produces = [
1401
- 'application/vnd.segment.v1+json',
1402
- 'application/json',
1403
- ];
1404
- if (produces.indexOf('application/json') >= 0) {
1405
- localVarHeaderParams.Accept = produces[0];
1406
- }
1407
- else {
1408
- localVarHeaderParams.Accept = 'application/json';
1409
- }
1410
- localVarFormParams = {};
1411
- if (sourceId === null || sourceId === undefined) {
1412
- throw new Error('Required parameter sourceId was null or undefined when calling getSourceV1.');
1413
- }
1414
- Object.assign(localVarHeaderParams, options.headers);
1415
- localVarUseFormData = false;
1416
- localVarRequestOptions = {
1417
- method: 'GET',
1418
- qs: localVarQueryParameters,
1419
- headers: localVarHeaderParams,
1420
- uri: localVarPath,
1421
- useQuerystring: this._useQuerystring,
1422
- json: true,
1423
- };
1424
- authenticationPromise = Promise.resolve();
1425
- if (this.authentications.token.accessToken) {
1426
- authenticationPromise = authenticationPromise.then(function () {
1427
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
1428
- });
1429
- }
1430
- authenticationPromise = authenticationPromise.then(function () {
1431
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
1432
- });
1433
- interceptorPromise = authenticationPromise;
1434
- _loop_16 = function (interceptor) {
1435
- interceptorPromise = interceptorPromise.then(function () {
1436
- return interceptor(localVarRequestOptions);
1437
- });
1438
- };
1439
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
1440
- interceptor = _a[_i];
1441
- _loop_16(interceptor);
1442
- }
1443
- return [2, interceptorPromise.then(function () {
1444
- if (Object.keys(localVarFormParams).length) {
1445
- if (localVarUseFormData) {
1446
- localVarRequestOptions.formData = localVarFormParams;
1447
- }
1448
- else {
1449
- localVarRequestOptions.form = localVarFormParams;
1450
- }
1451
- }
1452
- return new Promise(function (resolve, reject) {
1453
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
1454
- if (error) {
1455
- reject(error);
1456
- }
1457
- else {
1458
- if (response.statusCode &&
1459
- response.statusCode >= 200 &&
1460
- response.statusCode <= 299) {
1461
- body = models_1.ObjectSerializer.deserialize(body, 'GetSource200Response1');
1462
- resolve({ response: response, body: body });
1463
- }
1464
- else {
1465
- reject(new apis_1.HttpError(response, body, response.statusCode));
1466
- }
1467
- }
1468
- });
1469
- });
1470
- })];
1471
- });
1472
- });
1473
- };
1474
- SourcesApi.prototype.listConnectedDestinationsFromSourceAlpha = function (sourceId, pagination, options) {
1475
- if (options === void 0) { options = { headers: {} }; }
1476
- return __awaiter(this, void 0, void 0, function () {
1477
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_17, _i, _a, interceptor;
1478
- var _this = this;
1479
- return __generator(this, function (_b) {
1480
- localVarPath = this.basePath +
1481
- '/sources/{sourceId}/connected-destinations'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
1482
- localVarQueryParameters = {};
1483
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
1484
- produces = [
1485
- 'application/vnd.segment.v1alpha+json',
1486
- 'application/json',
1487
- ];
1488
- if (produces.indexOf('application/json') >= 0) {
1489
- localVarHeaderParams.Accept = produces[0];
1490
- }
1491
- else {
1492
- localVarHeaderParams.Accept = 'application/json';
1493
- }
1494
- localVarFormParams = {};
1495
- if (sourceId === null || sourceId === undefined) {
1496
- throw new Error('Required parameter sourceId was null or undefined when calling listConnectedDestinationsFromSourceAlpha.');
1497
- }
1498
- if (pagination === null || pagination === undefined) {
1499
- throw new Error('Required parameter pagination was null or undefined when calling listConnectedDestinationsFromSourceAlpha.');
1500
- }
1501
- if (pagination !== undefined) {
1502
- localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
1503
- }
1504
- Object.assign(localVarHeaderParams, options.headers);
1505
- localVarUseFormData = false;
1506
- localVarRequestOptions = {
1507
- method: 'GET',
1508
- qs: localVarQueryParameters,
1509
- headers: localVarHeaderParams,
1510
- uri: localVarPath,
1511
- useQuerystring: this._useQuerystring,
1512
- json: true,
1513
- };
1514
- authenticationPromise = Promise.resolve();
1515
- if (this.authentications.token.accessToken) {
1516
- authenticationPromise = authenticationPromise.then(function () {
1517
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
1518
- });
1519
- }
1520
- authenticationPromise = authenticationPromise.then(function () {
1521
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
1522
- });
1523
- interceptorPromise = authenticationPromise;
1524
- _loop_17 = function (interceptor) {
1525
- interceptorPromise = interceptorPromise.then(function () {
1526
- return interceptor(localVarRequestOptions);
1527
- });
1528
- };
1529
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
1530
- interceptor = _a[_i];
1531
- _loop_17(interceptor);
1532
- }
1533
- return [2, interceptorPromise.then(function () {
1534
- if (Object.keys(localVarFormParams).length) {
1535
- if (localVarUseFormData) {
1536
- localVarRequestOptions.formData = localVarFormParams;
1537
- }
1538
- else {
1539
- localVarRequestOptions.form = localVarFormParams;
1540
- }
1541
- }
1542
- return new Promise(function (resolve, reject) {
1543
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
1544
- if (error) {
1545
- reject(error);
1546
- }
1547
- else {
1548
- if (response.statusCode &&
1549
- response.statusCode >= 200 &&
1550
- response.statusCode <= 299) {
1551
- body = models_1.ObjectSerializer.deserialize(body, 'ListConnectedDestinationsFromSource200Response');
1552
- resolve({ response: response, body: body });
1553
- }
1554
- else {
1555
- reject(new apis_1.HttpError(response, body, response.statusCode));
1556
- }
1557
- }
1558
- });
1559
- });
1560
- })];
1561
- });
1562
- });
1563
- };
1564
- SourcesApi.prototype.listConnectedDestinationsFromSourceBeta = function (sourceId, pagination, options) {
1565
- if (options === void 0) { options = { headers: {} }; }
1566
- return __awaiter(this, void 0, void 0, function () {
1567
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_18, _i, _a, interceptor;
1568
- var _this = this;
1569
- return __generator(this, function (_b) {
1570
- localVarPath = this.basePath +
1571
- '/sources/{sourceId}/connected-destinations'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
1572
- localVarQueryParameters = {};
1573
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
1574
- produces = [
1575
- 'application/vnd.segment.v1beta+json',
1576
- 'application/json',
1577
- ];
1578
- if (produces.indexOf('application/json') >= 0) {
1579
- localVarHeaderParams.Accept = produces[0];
1580
- }
1581
- else {
1582
- localVarHeaderParams.Accept = 'application/json';
1583
- }
1584
- localVarFormParams = {};
1585
- if (sourceId === null || sourceId === undefined) {
1586
- throw new Error('Required parameter sourceId was null or undefined when calling listConnectedDestinationsFromSourceBeta.');
1587
- }
1588
- if (pagination === null || pagination === undefined) {
1589
- throw new Error('Required parameter pagination was null or undefined when calling listConnectedDestinationsFromSourceBeta.');
1590
- }
1591
- if (pagination !== undefined) {
1592
- localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
1593
- }
1594
- Object.assign(localVarHeaderParams, options.headers);
1595
- localVarUseFormData = false;
1596
- localVarRequestOptions = {
1597
- method: 'GET',
1598
- qs: localVarQueryParameters,
1599
- headers: localVarHeaderParams,
1600
- uri: localVarPath,
1601
- useQuerystring: this._useQuerystring,
1602
- json: true,
1603
- };
1604
- authenticationPromise = Promise.resolve();
1605
- if (this.authentications.token.accessToken) {
1606
- authenticationPromise = authenticationPromise.then(function () {
1607
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
1608
- });
1609
- }
1610
- authenticationPromise = authenticationPromise.then(function () {
1611
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
1612
- });
1613
- interceptorPromise = authenticationPromise;
1614
- _loop_18 = function (interceptor) {
1615
- interceptorPromise = interceptorPromise.then(function () {
1616
- return interceptor(localVarRequestOptions);
1617
- });
1618
- };
1619
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
1620
- interceptor = _a[_i];
1621
- _loop_18(interceptor);
1622
- }
1623
- return [2, interceptorPromise.then(function () {
1624
- if (Object.keys(localVarFormParams).length) {
1625
- if (localVarUseFormData) {
1626
- localVarRequestOptions.formData = localVarFormParams;
1627
- }
1628
- else {
1629
- localVarRequestOptions.form = localVarFormParams;
1630
- }
1631
- }
1632
- return new Promise(function (resolve, reject) {
1633
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
1634
- if (error) {
1635
- reject(error);
1636
- }
1637
- else {
1638
- if (response.statusCode &&
1639
- response.statusCode >= 200 &&
1640
- response.statusCode <= 299) {
1641
- body = models_1.ObjectSerializer.deserialize(body, 'ListConnectedDestinationsFromSource200Response1');
1642
- resolve({ response: response, body: body });
1643
- }
1644
- else {
1645
- reject(new apis_1.HttpError(response, body, response.statusCode));
1646
- }
1647
- }
1648
- });
1649
- });
1650
- })];
1651
- });
1652
- });
1653
- };
1654
- SourcesApi.prototype.listConnectedDestinationsFromSourceCurrent = function (sourceId, pagination, options) {
1655
- if (options === void 0) { options = { headers: {} }; }
1656
- return __awaiter(this, void 0, void 0, function () {
1657
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_19, _i, _a, interceptor;
1658
- var _this = this;
1659
- return __generator(this, function (_b) {
1660
- localVarPath = this.basePath +
1661
- '/sources/{sourceId}/connected-destinations'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
1662
- localVarQueryParameters = {};
1663
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
1664
- produces = ['application/json'];
1665
- if (produces.indexOf('application/json') >= 0) {
1666
- localVarHeaderParams.Accept = produces[0];
1667
- }
1668
- else {
1669
- localVarHeaderParams.Accept = 'application/json';
1670
- }
1671
- localVarFormParams = {};
1672
- if (sourceId === null || sourceId === undefined) {
1673
- throw new Error('Required parameter sourceId was null or undefined when calling listConnectedDestinationsFromSourceCurrent.');
1674
- }
1675
- if (pagination === null || pagination === undefined) {
1676
- throw new Error('Required parameter pagination was null or undefined when calling listConnectedDestinationsFromSourceCurrent.');
1677
- }
1678
- if (pagination !== undefined) {
1679
- localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
1680
- }
1681
- Object.assign(localVarHeaderParams, options.headers);
1682
- localVarUseFormData = false;
1683
- localVarRequestOptions = {
1684
- method: 'GET',
1685
- qs: localVarQueryParameters,
1686
- headers: localVarHeaderParams,
1687
- uri: localVarPath,
1688
- useQuerystring: this._useQuerystring,
1689
- json: true,
1690
- };
1691
- authenticationPromise = Promise.resolve();
1692
- if (this.authentications.token.accessToken) {
1693
- authenticationPromise = authenticationPromise.then(function () {
1694
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
1695
- });
1696
- }
1697
- authenticationPromise = authenticationPromise.then(function () {
1698
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
1699
- });
1700
- interceptorPromise = authenticationPromise;
1701
- _loop_19 = function (interceptor) {
1702
- interceptorPromise = interceptorPromise.then(function () {
1703
- return interceptor(localVarRequestOptions);
1704
- });
1705
- };
1706
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
1707
- interceptor = _a[_i];
1708
- _loop_19(interceptor);
1709
- }
1710
- return [2, interceptorPromise.then(function () {
1711
- if (Object.keys(localVarFormParams).length) {
1712
- if (localVarUseFormData) {
1713
- localVarRequestOptions.formData = localVarFormParams;
1714
- }
1715
- else {
1716
- localVarRequestOptions.form = localVarFormParams;
1717
- }
1718
- }
1719
- return new Promise(function (resolve, reject) {
1720
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
1721
- if (error) {
1722
- reject(error);
1723
- }
1724
- else {
1725
- if (response.statusCode &&
1726
- response.statusCode >= 200 &&
1727
- response.statusCode <= 299) {
1728
- body = models_1.ObjectSerializer.deserialize(body, 'ListConnectedDestinationsFromSource200Response1');
1729
- resolve({ response: response, body: body });
1730
- }
1731
- else {
1732
- reject(new apis_1.HttpError(response, body, response.statusCode));
1733
- }
1734
- }
1735
- });
1736
- });
1737
- })];
1738
- });
1739
- });
1740
- };
1741
- SourcesApi.prototype.listConnectedDestinationsFromSourceV1 = function (sourceId, pagination, options) {
1742
- if (options === void 0) { options = { headers: {} }; }
1743
- return __awaiter(this, void 0, void 0, function () {
1744
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_20, _i, _a, interceptor;
1745
- var _this = this;
1746
- return __generator(this, function (_b) {
1747
- localVarPath = this.basePath +
1748
- '/sources/{sourceId}/connected-destinations'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
1749
- localVarQueryParameters = {};
1750
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
1751
- produces = [
1752
- 'application/vnd.segment.v1+json',
1753
- 'application/json',
1754
- ];
1755
- if (produces.indexOf('application/json') >= 0) {
1756
- localVarHeaderParams.Accept = produces[0];
1757
- }
1758
- else {
1759
- localVarHeaderParams.Accept = 'application/json';
1760
- }
1761
- localVarFormParams = {};
1762
- if (sourceId === null || sourceId === undefined) {
1763
- throw new Error('Required parameter sourceId was null or undefined when calling listConnectedDestinationsFromSourceV1.');
1764
- }
1765
- if (pagination === null || pagination === undefined) {
1766
- throw new Error('Required parameter pagination was null or undefined when calling listConnectedDestinationsFromSourceV1.');
1767
- }
1768
- if (pagination !== undefined) {
1769
- localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
1770
- }
1771
- Object.assign(localVarHeaderParams, options.headers);
1772
- localVarUseFormData = false;
1773
- localVarRequestOptions = {
1774
- method: 'GET',
1775
- qs: localVarQueryParameters,
1776
- headers: localVarHeaderParams,
1777
- uri: localVarPath,
1778
- useQuerystring: this._useQuerystring,
1779
- json: true,
1780
- };
1781
- authenticationPromise = Promise.resolve();
1782
- if (this.authentications.token.accessToken) {
1783
- authenticationPromise = authenticationPromise.then(function () {
1784
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
1785
- });
1786
- }
1787
- authenticationPromise = authenticationPromise.then(function () {
1788
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
1789
- });
1790
- interceptorPromise = authenticationPromise;
1791
- _loop_20 = function (interceptor) {
1792
- interceptorPromise = interceptorPromise.then(function () {
1793
- return interceptor(localVarRequestOptions);
1794
- });
1795
- };
1796
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
1797
- interceptor = _a[_i];
1798
- _loop_20(interceptor);
1799
- }
1800
- return [2, interceptorPromise.then(function () {
1801
- if (Object.keys(localVarFormParams).length) {
1802
- if (localVarUseFormData) {
1803
- localVarRequestOptions.formData = localVarFormParams;
1804
- }
1805
- else {
1806
- localVarRequestOptions.form = localVarFormParams;
1807
- }
1808
- }
1809
- return new Promise(function (resolve, reject) {
1810
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
1811
- if (error) {
1812
- reject(error);
1813
- }
1814
- else {
1815
- if (response.statusCode &&
1816
- response.statusCode >= 200 &&
1817
- response.statusCode <= 299) {
1818
- body = models_1.ObjectSerializer.deserialize(body, 'ListConnectedDestinationsFromSource200Response1');
1819
- resolve({ response: response, body: body });
1820
- }
1821
- else {
1822
- reject(new apis_1.HttpError(response, body, response.statusCode));
1823
- }
1824
- }
1825
- });
1826
- });
1827
- })];
1828
- });
1829
- });
1830
- };
1831
- SourcesApi.prototype.listConnectedWarehousesFromSourceAlpha = function (sourceId, pagination, options) {
1832
- if (options === void 0) { options = { headers: {} }; }
1833
- return __awaiter(this, void 0, void 0, function () {
1834
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_21, _i, _a, interceptor;
1835
- var _this = this;
1836
- return __generator(this, function (_b) {
1837
- localVarPath = this.basePath +
1838
- '/sources/{sourceId}/connected-warehouses'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
1839
- localVarQueryParameters = {};
1840
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
1841
- produces = [
1842
- 'application/vnd.segment.v1alpha+json',
1843
- 'application/json',
1844
- ];
1845
- if (produces.indexOf('application/json') >= 0) {
1846
- localVarHeaderParams.Accept = produces[0];
1847
- }
1848
- else {
1849
- localVarHeaderParams.Accept = 'application/json';
1850
- }
1851
- localVarFormParams = {};
1852
- if (sourceId === null || sourceId === undefined) {
1853
- throw new Error('Required parameter sourceId was null or undefined when calling listConnectedWarehousesFromSourceAlpha.');
1854
- }
1855
- if (pagination === null || pagination === undefined) {
1856
- throw new Error('Required parameter pagination was null or undefined when calling listConnectedWarehousesFromSourceAlpha.');
1857
- }
1858
- if (pagination !== undefined) {
1859
- localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
1860
- }
1861
- Object.assign(localVarHeaderParams, options.headers);
1862
- localVarUseFormData = false;
1863
- localVarRequestOptions = {
1864
- method: 'GET',
1865
- qs: localVarQueryParameters,
1866
- headers: localVarHeaderParams,
1867
- uri: localVarPath,
1868
- useQuerystring: this._useQuerystring,
1869
- json: true,
1870
- };
1871
- authenticationPromise = Promise.resolve();
1872
- if (this.authentications.token.accessToken) {
1873
- authenticationPromise = authenticationPromise.then(function () {
1874
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
1875
- });
1876
- }
1877
- authenticationPromise = authenticationPromise.then(function () {
1878
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
1879
- });
1880
- interceptorPromise = authenticationPromise;
1881
- _loop_21 = function (interceptor) {
1882
- interceptorPromise = interceptorPromise.then(function () {
1883
- return interceptor(localVarRequestOptions);
1884
- });
1885
- };
1886
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
1887
- interceptor = _a[_i];
1888
- _loop_21(interceptor);
1889
- }
1890
- return [2, interceptorPromise.then(function () {
1891
- if (Object.keys(localVarFormParams).length) {
1892
- if (localVarUseFormData) {
1893
- localVarRequestOptions.formData = localVarFormParams;
1894
- }
1895
- else {
1896
- localVarRequestOptions.form = localVarFormParams;
1897
- }
1898
- }
1899
- return new Promise(function (resolve, reject) {
1900
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
1901
- if (error) {
1902
- reject(error);
1903
- }
1904
- else {
1905
- if (response.statusCode &&
1906
- response.statusCode >= 200 &&
1907
- response.statusCode <= 299) {
1908
- body = models_1.ObjectSerializer.deserialize(body, 'ListConnectedWarehousesFromSource200Response');
1909
- resolve({ response: response, body: body });
1910
- }
1911
- else {
1912
- reject(new apis_1.HttpError(response, body, response.statusCode));
1913
- }
1914
- }
1915
- });
1916
- });
1917
- })];
1918
- });
1919
- });
1920
- };
1921
- SourcesApi.prototype.listConnectedWarehousesFromSourceBeta = function (sourceId, pagination, options) {
1922
- if (options === void 0) { options = { headers: {} }; }
1923
- return __awaiter(this, void 0, void 0, function () {
1924
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_22, _i, _a, interceptor;
1925
- var _this = this;
1926
- return __generator(this, function (_b) {
1927
- localVarPath = this.basePath +
1928
- '/sources/{sourceId}/connected-warehouses'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
1929
- localVarQueryParameters = {};
1930
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
1931
- produces = [
1932
- 'application/vnd.segment.v1beta+json',
1933
- 'application/json',
1934
- ];
1935
- if (produces.indexOf('application/json') >= 0) {
1936
- localVarHeaderParams.Accept = produces[0];
1937
- }
1938
- else {
1939
- localVarHeaderParams.Accept = 'application/json';
1940
- }
1941
- localVarFormParams = {};
1942
- if (sourceId === null || sourceId === undefined) {
1943
- throw new Error('Required parameter sourceId was null or undefined when calling listConnectedWarehousesFromSourceBeta.');
1944
- }
1945
- if (pagination === null || pagination === undefined) {
1946
- throw new Error('Required parameter pagination was null or undefined when calling listConnectedWarehousesFromSourceBeta.');
1947
- }
1948
- if (pagination !== undefined) {
1949
- localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
1950
- }
1951
- Object.assign(localVarHeaderParams, options.headers);
1952
- localVarUseFormData = false;
1953
- localVarRequestOptions = {
1954
- method: 'GET',
1955
- qs: localVarQueryParameters,
1956
- headers: localVarHeaderParams,
1957
- uri: localVarPath,
1958
- useQuerystring: this._useQuerystring,
1959
- json: true,
1960
- };
1961
- authenticationPromise = Promise.resolve();
1962
- if (this.authentications.token.accessToken) {
1963
- authenticationPromise = authenticationPromise.then(function () {
1964
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
1965
- });
1966
- }
1967
- authenticationPromise = authenticationPromise.then(function () {
1968
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
1969
- });
1970
- interceptorPromise = authenticationPromise;
1971
- _loop_22 = function (interceptor) {
1972
- interceptorPromise = interceptorPromise.then(function () {
1973
- return interceptor(localVarRequestOptions);
1974
- });
1975
- };
1976
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
1977
- interceptor = _a[_i];
1978
- _loop_22(interceptor);
1979
- }
1980
- return [2, interceptorPromise.then(function () {
1981
- if (Object.keys(localVarFormParams).length) {
1982
- if (localVarUseFormData) {
1983
- localVarRequestOptions.formData = localVarFormParams;
1984
- }
1985
- else {
1986
- localVarRequestOptions.form = localVarFormParams;
1987
- }
1988
- }
1989
- return new Promise(function (resolve, reject) {
1990
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
1991
- if (error) {
1992
- reject(error);
1993
- }
1994
- else {
1995
- if (response.statusCode &&
1996
- response.statusCode >= 200 &&
1997
- response.statusCode <= 299) {
1998
- body = models_1.ObjectSerializer.deserialize(body, 'ListConnectedWarehousesFromSource200Response1');
1999
- resolve({ response: response, body: body });
2000
- }
2001
- else {
2002
- reject(new apis_1.HttpError(response, body, response.statusCode));
2003
- }
2004
- }
2005
- });
2006
- });
2007
- })];
2008
- });
2009
- });
2010
- };
2011
- SourcesApi.prototype.listConnectedWarehousesFromSourceCurrent = function (sourceId, pagination, options) {
2012
- if (options === void 0) { options = { headers: {} }; }
2013
- return __awaiter(this, void 0, void 0, function () {
2014
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_23, _i, _a, interceptor;
2015
- var _this = this;
2016
- return __generator(this, function (_b) {
2017
- localVarPath = this.basePath +
2018
- '/sources/{sourceId}/connected-warehouses'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
2019
- localVarQueryParameters = {};
2020
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
2021
- produces = ['application/json'];
2022
- if (produces.indexOf('application/json') >= 0) {
2023
- localVarHeaderParams.Accept = produces[0];
2024
- }
2025
- else {
2026
- localVarHeaderParams.Accept = 'application/json';
2027
- }
2028
- localVarFormParams = {};
2029
- if (sourceId === null || sourceId === undefined) {
2030
- throw new Error('Required parameter sourceId was null or undefined when calling listConnectedWarehousesFromSourceCurrent.');
2031
- }
2032
- if (pagination === null || pagination === undefined) {
2033
- throw new Error('Required parameter pagination was null or undefined when calling listConnectedWarehousesFromSourceCurrent.');
2034
- }
2035
- if (pagination !== undefined) {
2036
- localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
2037
- }
2038
- Object.assign(localVarHeaderParams, options.headers);
2039
- localVarUseFormData = false;
2040
- localVarRequestOptions = {
2041
- method: 'GET',
2042
- qs: localVarQueryParameters,
2043
- headers: localVarHeaderParams,
2044
- uri: localVarPath,
2045
- useQuerystring: this._useQuerystring,
2046
- json: true,
2047
- };
2048
- authenticationPromise = Promise.resolve();
2049
- if (this.authentications.token.accessToken) {
2050
- authenticationPromise = authenticationPromise.then(function () {
2051
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
2052
- });
2053
- }
2054
- authenticationPromise = authenticationPromise.then(function () {
2055
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
2056
- });
2057
- interceptorPromise = authenticationPromise;
2058
- _loop_23 = function (interceptor) {
2059
- interceptorPromise = interceptorPromise.then(function () {
2060
- return interceptor(localVarRequestOptions);
2061
- });
2062
- };
2063
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
2064
- interceptor = _a[_i];
2065
- _loop_23(interceptor);
2066
- }
2067
- return [2, interceptorPromise.then(function () {
2068
- if (Object.keys(localVarFormParams).length) {
2069
- if (localVarUseFormData) {
2070
- localVarRequestOptions.formData = localVarFormParams;
2071
- }
2072
- else {
2073
- localVarRequestOptions.form = localVarFormParams;
2074
- }
2075
- }
2076
- return new Promise(function (resolve, reject) {
2077
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
2078
- if (error) {
2079
- reject(error);
2080
- }
2081
- else {
2082
- if (response.statusCode &&
2083
- response.statusCode >= 200 &&
2084
- response.statusCode <= 299) {
2085
- body = models_1.ObjectSerializer.deserialize(body, 'ListConnectedWarehousesFromSource200Response1');
2086
- resolve({ response: response, body: body });
2087
- }
2088
- else {
2089
- reject(new apis_1.HttpError(response, body, response.statusCode));
2090
- }
2091
- }
2092
- });
2093
- });
2094
- })];
2095
- });
2096
- });
2097
- };
2098
- SourcesApi.prototype.listConnectedWarehousesFromSourceV1 = function (sourceId, pagination, options) {
2099
- if (options === void 0) { options = { headers: {} }; }
2100
- return __awaiter(this, void 0, void 0, function () {
2101
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_24, _i, _a, interceptor;
2102
- var _this = this;
2103
- return __generator(this, function (_b) {
2104
- localVarPath = this.basePath +
2105
- '/sources/{sourceId}/connected-warehouses'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
2106
- localVarQueryParameters = {};
2107
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
2108
- produces = [
2109
- 'application/vnd.segment.v1+json',
2110
- 'application/json',
2111
- ];
2112
- if (produces.indexOf('application/json') >= 0) {
2113
- localVarHeaderParams.Accept = produces[0];
2114
- }
2115
- else {
2116
- localVarHeaderParams.Accept = 'application/json';
2117
- }
2118
- localVarFormParams = {};
2119
- if (sourceId === null || sourceId === undefined) {
2120
- throw new Error('Required parameter sourceId was null or undefined when calling listConnectedWarehousesFromSourceV1.');
2121
- }
2122
- if (pagination === null || pagination === undefined) {
2123
- throw new Error('Required parameter pagination was null or undefined when calling listConnectedWarehousesFromSourceV1.');
2124
- }
2125
- if (pagination !== undefined) {
2126
- localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
2127
- }
2128
- Object.assign(localVarHeaderParams, options.headers);
2129
- localVarUseFormData = false;
2130
- localVarRequestOptions = {
2131
- method: 'GET',
2132
- qs: localVarQueryParameters,
2133
- headers: localVarHeaderParams,
2134
- uri: localVarPath,
2135
- useQuerystring: this._useQuerystring,
2136
- json: true,
2137
- };
2138
- authenticationPromise = Promise.resolve();
2139
- if (this.authentications.token.accessToken) {
2140
- authenticationPromise = authenticationPromise.then(function () {
2141
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
2142
- });
2143
- }
2144
- authenticationPromise = authenticationPromise.then(function () {
2145
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
2146
- });
2147
- interceptorPromise = authenticationPromise;
2148
- _loop_24 = function (interceptor) {
2149
- interceptorPromise = interceptorPromise.then(function () {
2150
- return interceptor(localVarRequestOptions);
2151
- });
2152
- };
2153
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
2154
- interceptor = _a[_i];
2155
- _loop_24(interceptor);
2156
- }
2157
- return [2, interceptorPromise.then(function () {
2158
- if (Object.keys(localVarFormParams).length) {
2159
- if (localVarUseFormData) {
2160
- localVarRequestOptions.formData = localVarFormParams;
2161
- }
2162
- else {
2163
- localVarRequestOptions.form = localVarFormParams;
2164
- }
2165
- }
2166
- return new Promise(function (resolve, reject) {
2167
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
2168
- if (error) {
2169
- reject(error);
2170
- }
2171
- else {
2172
- if (response.statusCode &&
2173
- response.statusCode >= 200 &&
2174
- response.statusCode <= 299) {
2175
- body = models_1.ObjectSerializer.deserialize(body, 'ListConnectedWarehousesFromSource200Response1');
2176
- resolve({ response: response, body: body });
2177
- }
2178
- else {
2179
- reject(new apis_1.HttpError(response, body, response.statusCode));
2180
- }
2181
- }
2182
- });
2183
- });
2184
- })];
2185
- });
2186
- });
2187
- };
2188
- SourcesApi.prototype.listSchemaSettingsInSourceAlpha = function (sourceId, options) {
2189
- if (options === void 0) { options = { headers: {} }; }
2190
- return __awaiter(this, void 0, void 0, function () {
2191
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_25, _i, _a, interceptor;
2192
- var _this = this;
2193
- return __generator(this, function (_b) {
2194
- localVarPath = this.basePath +
2195
- '/sources/{sourceId}/settings'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
2196
- localVarQueryParameters = {};
2197
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
2198
- produces = [
2199
- 'application/vnd.segment.v1alpha+json',
2200
- 'application/json',
2201
- ];
2202
- if (produces.indexOf('application/json') >= 0) {
2203
- localVarHeaderParams.Accept = produces[0];
2204
- }
2205
- else {
2206
- localVarHeaderParams.Accept = 'application/json';
2207
- }
2208
- localVarFormParams = {};
2209
- if (sourceId === null || sourceId === undefined) {
2210
- throw new Error('Required parameter sourceId was null or undefined when calling listSchemaSettingsInSourceAlpha.');
2211
- }
2212
- Object.assign(localVarHeaderParams, options.headers);
2213
- localVarUseFormData = false;
2214
- localVarRequestOptions = {
2215
- method: 'GET',
2216
- qs: localVarQueryParameters,
2217
- headers: localVarHeaderParams,
2218
- uri: localVarPath,
2219
- useQuerystring: this._useQuerystring,
2220
- json: true,
2221
- };
2222
- authenticationPromise = Promise.resolve();
2223
- if (this.authentications.token.accessToken) {
2224
- authenticationPromise = authenticationPromise.then(function () {
2225
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
2226
- });
2227
- }
2228
- authenticationPromise = authenticationPromise.then(function () {
2229
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
2230
- });
2231
- interceptorPromise = authenticationPromise;
2232
- _loop_25 = function (interceptor) {
2233
- interceptorPromise = interceptorPromise.then(function () {
2234
- return interceptor(localVarRequestOptions);
2235
- });
2236
- };
2237
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
2238
- interceptor = _a[_i];
2239
- _loop_25(interceptor);
2240
- }
2241
- return [2, interceptorPromise.then(function () {
2242
- if (Object.keys(localVarFormParams).length) {
2243
- if (localVarUseFormData) {
2244
- localVarRequestOptions.formData = localVarFormParams;
2245
- }
2246
- else {
2247
- localVarRequestOptions.form = localVarFormParams;
2248
- }
2249
- }
2250
- return new Promise(function (resolve, reject) {
2251
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
2252
- if (error) {
2253
- reject(error);
2254
- }
2255
- else {
2256
- if (response.statusCode &&
2257
- response.statusCode >= 200 &&
2258
- response.statusCode <= 299) {
2259
- body = models_1.ObjectSerializer.deserialize(body, 'ListSchemaSettingsInSource200Response');
2260
- resolve({ response: response, body: body });
2261
- }
2262
- else {
2263
- reject(new apis_1.HttpError(response, body, response.statusCode));
2264
- }
2265
- }
2266
- });
2267
- });
2268
- })];
2269
- });
2270
- });
2271
- };
2272
- SourcesApi.prototype.listSchemaSettingsInSourceBeta = function (sourceId, options) {
2273
- if (options === void 0) { options = { headers: {} }; }
2274
- return __awaiter(this, void 0, void 0, function () {
2275
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_26, _i, _a, interceptor;
2276
- var _this = this;
2277
- return __generator(this, function (_b) {
2278
- localVarPath = this.basePath +
2279
- '/sources/{sourceId}/settings'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
2280
- localVarQueryParameters = {};
2281
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
2282
- produces = [
2283
- 'application/vnd.segment.v1beta+json',
2284
- 'application/json',
2285
- ];
2286
- if (produces.indexOf('application/json') >= 0) {
2287
- localVarHeaderParams.Accept = produces[0];
2288
- }
2289
- else {
2290
- localVarHeaderParams.Accept = 'application/json';
2291
- }
2292
- localVarFormParams = {};
2293
- if (sourceId === null || sourceId === undefined) {
2294
- throw new Error('Required parameter sourceId was null or undefined when calling listSchemaSettingsInSourceBeta.');
2295
- }
2296
- Object.assign(localVarHeaderParams, options.headers);
2297
- localVarUseFormData = false;
2298
- localVarRequestOptions = {
2299
- method: 'GET',
2300
- qs: localVarQueryParameters,
2301
- headers: localVarHeaderParams,
2302
- uri: localVarPath,
2303
- useQuerystring: this._useQuerystring,
2304
- json: true,
2305
- };
2306
- authenticationPromise = Promise.resolve();
2307
- if (this.authentications.token.accessToken) {
2308
- authenticationPromise = authenticationPromise.then(function () {
2309
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
2310
- });
2311
- }
2312
- authenticationPromise = authenticationPromise.then(function () {
2313
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
2314
- });
2315
- interceptorPromise = authenticationPromise;
2316
- _loop_26 = function (interceptor) {
2317
- interceptorPromise = interceptorPromise.then(function () {
2318
- return interceptor(localVarRequestOptions);
2319
- });
2320
- };
2321
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
2322
- interceptor = _a[_i];
2323
- _loop_26(interceptor);
2324
- }
2325
- return [2, interceptorPromise.then(function () {
2326
- if (Object.keys(localVarFormParams).length) {
2327
- if (localVarUseFormData) {
2328
- localVarRequestOptions.formData = localVarFormParams;
2329
- }
2330
- else {
2331
- localVarRequestOptions.form = localVarFormParams;
2332
- }
2333
- }
2334
- return new Promise(function (resolve, reject) {
2335
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
2336
- if (error) {
2337
- reject(error);
2338
- }
2339
- else {
2340
- if (response.statusCode &&
2341
- response.statusCode >= 200 &&
2342
- response.statusCode <= 299) {
2343
- body = models_1.ObjectSerializer.deserialize(body, 'ListSchemaSettingsInSource200Response');
2344
- resolve({ response: response, body: body });
2345
- }
2346
- else {
2347
- reject(new apis_1.HttpError(response, body, response.statusCode));
2348
- }
2349
- }
2350
- });
2351
- });
2352
- })];
2353
- });
2354
- });
2355
- };
2356
- SourcesApi.prototype.listSchemaSettingsInSourceCurrent = function (sourceId, options) {
2357
- if (options === void 0) { options = { headers: {} }; }
2358
- return __awaiter(this, void 0, void 0, function () {
2359
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_27, _i, _a, interceptor;
2360
- var _this = this;
2361
- return __generator(this, function (_b) {
2362
- localVarPath = this.basePath +
2363
- '/sources/{sourceId}/settings'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
2364
- localVarQueryParameters = {};
2365
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
2366
- produces = ['application/json'];
2367
- if (produces.indexOf('application/json') >= 0) {
2368
- localVarHeaderParams.Accept = produces[0];
2369
- }
2370
- else {
2371
- localVarHeaderParams.Accept = 'application/json';
2372
- }
2373
- localVarFormParams = {};
2374
- if (sourceId === null || sourceId === undefined) {
2375
- throw new Error('Required parameter sourceId was null or undefined when calling listSchemaSettingsInSourceCurrent.');
2376
- }
2377
- Object.assign(localVarHeaderParams, options.headers);
2378
- localVarUseFormData = false;
2379
- localVarRequestOptions = {
2380
- method: 'GET',
2381
- qs: localVarQueryParameters,
2382
- headers: localVarHeaderParams,
2383
- uri: localVarPath,
2384
- useQuerystring: this._useQuerystring,
2385
- json: true,
2386
- };
2387
- authenticationPromise = Promise.resolve();
2388
- if (this.authentications.token.accessToken) {
2389
- authenticationPromise = authenticationPromise.then(function () {
2390
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
2391
- });
2392
- }
2393
- authenticationPromise = authenticationPromise.then(function () {
2394
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
2395
- });
2396
- interceptorPromise = authenticationPromise;
2397
- _loop_27 = function (interceptor) {
2398
- interceptorPromise = interceptorPromise.then(function () {
2399
- return interceptor(localVarRequestOptions);
2400
- });
2401
- };
2402
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
2403
- interceptor = _a[_i];
2404
- _loop_27(interceptor);
2405
- }
2406
- return [2, interceptorPromise.then(function () {
2407
- if (Object.keys(localVarFormParams).length) {
2408
- if (localVarUseFormData) {
2409
- localVarRequestOptions.formData = localVarFormParams;
2410
- }
2411
- else {
2412
- localVarRequestOptions.form = localVarFormParams;
2413
- }
2414
- }
2415
- return new Promise(function (resolve, reject) {
2416
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
2417
- if (error) {
2418
- reject(error);
2419
- }
2420
- else {
2421
- if (response.statusCode &&
2422
- response.statusCode >= 200 &&
2423
- response.statusCode <= 299) {
2424
- body = models_1.ObjectSerializer.deserialize(body, 'ListSchemaSettingsInSource200Response');
2425
- resolve({ response: response, body: body });
2426
- }
2427
- else {
2428
- reject(new apis_1.HttpError(response, body, response.statusCode));
2429
- }
2430
- }
2431
- });
2432
- });
2433
- })];
2434
- });
2435
- });
2436
- };
2437
- SourcesApi.prototype.listSchemaSettingsInSourceV1 = function (sourceId, options) {
2438
- if (options === void 0) { options = { headers: {} }; }
2439
- return __awaiter(this, void 0, void 0, function () {
2440
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_28, _i, _a, interceptor;
2441
- var _this = this;
2442
- return __generator(this, function (_b) {
2443
- localVarPath = this.basePath +
2444
- '/sources/{sourceId}/settings'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
2445
- localVarQueryParameters = {};
2446
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
2447
- produces = [
2448
- 'application/vnd.segment.v1+json',
2449
- 'application/json',
2450
- ];
2451
- if (produces.indexOf('application/json') >= 0) {
2452
- localVarHeaderParams.Accept = produces[0];
2453
- }
2454
- else {
2455
- localVarHeaderParams.Accept = 'application/json';
2456
- }
2457
- localVarFormParams = {};
2458
- if (sourceId === null || sourceId === undefined) {
2459
- throw new Error('Required parameter sourceId was null or undefined when calling listSchemaSettingsInSourceV1.');
2460
- }
2461
- Object.assign(localVarHeaderParams, options.headers);
2462
- localVarUseFormData = false;
2463
- localVarRequestOptions = {
2464
- method: 'GET',
2465
- qs: localVarQueryParameters,
2466
- headers: localVarHeaderParams,
2467
- uri: localVarPath,
2468
- useQuerystring: this._useQuerystring,
2469
- json: true,
2470
- };
2471
- authenticationPromise = Promise.resolve();
2472
- if (this.authentications.token.accessToken) {
2473
- authenticationPromise = authenticationPromise.then(function () {
2474
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
2475
- });
2476
- }
2477
- authenticationPromise = authenticationPromise.then(function () {
2478
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
2479
- });
2480
- interceptorPromise = authenticationPromise;
2481
- _loop_28 = function (interceptor) {
2482
- interceptorPromise = interceptorPromise.then(function () {
2483
- return interceptor(localVarRequestOptions);
2484
- });
2485
- };
2486
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
2487
- interceptor = _a[_i];
2488
- _loop_28(interceptor);
2489
- }
2490
- return [2, interceptorPromise.then(function () {
2491
- if (Object.keys(localVarFormParams).length) {
2492
- if (localVarUseFormData) {
2493
- localVarRequestOptions.formData = localVarFormParams;
2494
- }
2495
- else {
2496
- localVarRequestOptions.form = localVarFormParams;
2497
- }
2498
- }
2499
- return new Promise(function (resolve, reject) {
2500
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
2501
- if (error) {
2502
- reject(error);
2503
- }
2504
- else {
2505
- if (response.statusCode &&
2506
- response.statusCode >= 200 &&
2507
- response.statusCode <= 299) {
2508
- body = models_1.ObjectSerializer.deserialize(body, 'ListSchemaSettingsInSource200Response');
2509
- resolve({ response: response, body: body });
2510
- }
2511
- else {
2512
- reject(new apis_1.HttpError(response, body, response.statusCode));
2513
- }
2514
- }
2515
- });
2516
- });
2517
- })];
2518
- });
2519
- });
2520
- };
2521
- SourcesApi.prototype.listSourcesAlpha = function (pagination, options) {
2522
- if (options === void 0) { options = { headers: {} }; }
2523
- return __awaiter(this, void 0, void 0, function () {
2524
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_29, _i, _a, interceptor;
2525
- var _this = this;
2526
- return __generator(this, function (_b) {
2527
- localVarPath = this.basePath + '/sources';
2528
- localVarQueryParameters = {};
2529
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
2530
- produces = [
2531
- 'application/vnd.segment.v1alpha+json',
2532
- 'application/json',
2533
- ];
2534
- if (produces.indexOf('application/json') >= 0) {
2535
- localVarHeaderParams.Accept = produces[0];
2536
- }
2537
- else {
2538
- localVarHeaderParams.Accept = 'application/json';
2539
- }
2540
- localVarFormParams = {};
2541
- if (pagination === null || pagination === undefined) {
2542
- throw new Error('Required parameter pagination was null or undefined when calling listSourcesAlpha.');
2543
- }
2544
- if (pagination !== undefined) {
2545
- localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
2546
- }
2547
- Object.assign(localVarHeaderParams, options.headers);
2548
- localVarUseFormData = false;
2549
- localVarRequestOptions = {
2550
- method: 'GET',
2551
- qs: localVarQueryParameters,
2552
- headers: localVarHeaderParams,
2553
- uri: localVarPath,
2554
- useQuerystring: this._useQuerystring,
2555
- json: true,
2556
- };
2557
- authenticationPromise = Promise.resolve();
2558
- if (this.authentications.token.accessToken) {
2559
- authenticationPromise = authenticationPromise.then(function () {
2560
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
2561
- });
2562
- }
2563
- authenticationPromise = authenticationPromise.then(function () {
2564
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
2565
- });
2566
- interceptorPromise = authenticationPromise;
2567
- _loop_29 = function (interceptor) {
2568
- interceptorPromise = interceptorPromise.then(function () {
2569
- return interceptor(localVarRequestOptions);
2570
- });
2571
- };
2572
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
2573
- interceptor = _a[_i];
2574
- _loop_29(interceptor);
2575
- }
2576
- return [2, interceptorPromise.then(function () {
2577
- if (Object.keys(localVarFormParams).length) {
2578
- if (localVarUseFormData) {
2579
- localVarRequestOptions.formData = localVarFormParams;
2580
- }
2581
- else {
2582
- localVarRequestOptions.form = localVarFormParams;
2583
- }
2584
- }
2585
- return new Promise(function (resolve, reject) {
2586
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
2587
- if (error) {
2588
- reject(error);
2589
- }
2590
- else {
2591
- if (response.statusCode &&
2592
- response.statusCode >= 200 &&
2593
- response.statusCode <= 299) {
2594
- body = models_1.ObjectSerializer.deserialize(body, 'ListSources200Response');
2595
- resolve({ response: response, body: body });
2596
- }
2597
- else {
2598
- reject(new apis_1.HttpError(response, body, response.statusCode));
2599
- }
2600
- }
2601
- });
2602
- });
2603
- })];
2604
- });
2605
- });
2606
- };
2607
- SourcesApi.prototype.listSourcesBeta = function (pagination, options) {
2608
- if (options === void 0) { options = { headers: {} }; }
2609
- return __awaiter(this, void 0, void 0, function () {
2610
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_30, _i, _a, interceptor;
2611
- var _this = this;
2612
- return __generator(this, function (_b) {
2613
- localVarPath = this.basePath + '/sources';
2614
- localVarQueryParameters = {};
2615
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
2616
- produces = [
2617
- 'application/vnd.segment.v1beta+json',
2618
- 'application/json',
2619
- ];
2620
- if (produces.indexOf('application/json') >= 0) {
2621
- localVarHeaderParams.Accept = produces[0];
2622
- }
2623
- else {
2624
- localVarHeaderParams.Accept = 'application/json';
2625
- }
2626
- localVarFormParams = {};
2627
- if (pagination === null || pagination === undefined) {
2628
- throw new Error('Required parameter pagination was null or undefined when calling listSourcesBeta.');
2629
- }
2630
- if (pagination !== undefined) {
2631
- localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
2632
- }
2633
- Object.assign(localVarHeaderParams, options.headers);
2634
- localVarUseFormData = false;
2635
- localVarRequestOptions = {
2636
- method: 'GET',
2637
- qs: localVarQueryParameters,
2638
- headers: localVarHeaderParams,
2639
- uri: localVarPath,
2640
- useQuerystring: this._useQuerystring,
2641
- json: true,
2642
- };
2643
- authenticationPromise = Promise.resolve();
2644
- if (this.authentications.token.accessToken) {
2645
- authenticationPromise = authenticationPromise.then(function () {
2646
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
2647
- });
2648
- }
2649
- authenticationPromise = authenticationPromise.then(function () {
2650
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
2651
- });
2652
- interceptorPromise = authenticationPromise;
2653
- _loop_30 = function (interceptor) {
2654
- interceptorPromise = interceptorPromise.then(function () {
2655
- return interceptor(localVarRequestOptions);
2656
- });
2657
- };
2658
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
2659
- interceptor = _a[_i];
2660
- _loop_30(interceptor);
2661
- }
2662
- return [2, interceptorPromise.then(function () {
2663
- if (Object.keys(localVarFormParams).length) {
2664
- if (localVarUseFormData) {
2665
- localVarRequestOptions.formData = localVarFormParams;
2666
- }
2667
- else {
2668
- localVarRequestOptions.form = localVarFormParams;
2669
- }
2670
- }
2671
- return new Promise(function (resolve, reject) {
2672
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
2673
- if (error) {
2674
- reject(error);
2675
- }
2676
- else {
2677
- if (response.statusCode &&
2678
- response.statusCode >= 200 &&
2679
- response.statusCode <= 299) {
2680
- body = models_1.ObjectSerializer.deserialize(body, 'ListSources200Response1');
2681
- resolve({ response: response, body: body });
2682
- }
2683
- else {
2684
- reject(new apis_1.HttpError(response, body, response.statusCode));
2685
- }
2686
- }
2687
- });
2688
- });
2689
- })];
2690
- });
2691
- });
2692
- };
2693
- SourcesApi.prototype.listSourcesCurrent = function (pagination, options) {
2694
- if (options === void 0) { options = { headers: {} }; }
2695
- return __awaiter(this, void 0, void 0, function () {
2696
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_31, _i, _a, interceptor;
2697
- var _this = this;
2698
- return __generator(this, function (_b) {
2699
- localVarPath = this.basePath + '/sources';
2700
- localVarQueryParameters = {};
2701
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
2702
- produces = ['application/json'];
2703
- if (produces.indexOf('application/json') >= 0) {
2704
- localVarHeaderParams.Accept = produces[0];
2705
- }
2706
- else {
2707
- localVarHeaderParams.Accept = 'application/json';
2708
- }
2709
- localVarFormParams = {};
2710
- if (pagination === null || pagination === undefined) {
2711
- throw new Error('Required parameter pagination was null or undefined when calling listSourcesCurrent.');
2712
- }
2713
- if (pagination !== undefined) {
2714
- localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
2715
- }
2716
- Object.assign(localVarHeaderParams, options.headers);
2717
- localVarUseFormData = false;
2718
- localVarRequestOptions = {
2719
- method: 'GET',
2720
- qs: localVarQueryParameters,
2721
- headers: localVarHeaderParams,
2722
- uri: localVarPath,
2723
- useQuerystring: this._useQuerystring,
2724
- json: true,
2725
- };
2726
- authenticationPromise = Promise.resolve();
2727
- if (this.authentications.token.accessToken) {
2728
- authenticationPromise = authenticationPromise.then(function () {
2729
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
2730
- });
2731
- }
2732
- authenticationPromise = authenticationPromise.then(function () {
2733
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
2734
- });
2735
- interceptorPromise = authenticationPromise;
2736
- _loop_31 = function (interceptor) {
2737
- interceptorPromise = interceptorPromise.then(function () {
2738
- return interceptor(localVarRequestOptions);
2739
- });
2740
- };
2741
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
2742
- interceptor = _a[_i];
2743
- _loop_31(interceptor);
2744
- }
2745
- return [2, interceptorPromise.then(function () {
2746
- if (Object.keys(localVarFormParams).length) {
2747
- if (localVarUseFormData) {
2748
- localVarRequestOptions.formData = localVarFormParams;
2749
- }
2750
- else {
2751
- localVarRequestOptions.form = localVarFormParams;
2752
- }
2753
- }
2754
- return new Promise(function (resolve, reject) {
2755
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
2756
- if (error) {
2757
- reject(error);
2758
- }
2759
- else {
2760
- if (response.statusCode &&
2761
- response.statusCode >= 200 &&
2762
- response.statusCode <= 299) {
2763
- body = models_1.ObjectSerializer.deserialize(body, 'ListSources200Response1');
2764
- resolve({ response: response, body: body });
2765
- }
2766
- else {
2767
- reject(new apis_1.HttpError(response, body, response.statusCode));
2768
- }
2769
- }
2770
- });
2771
- });
2772
- })];
2773
- });
2774
- });
2775
- };
2776
- SourcesApi.prototype.listSourcesV1 = function (pagination, options) {
2777
- if (options === void 0) { options = { headers: {} }; }
2778
- return __awaiter(this, void 0, void 0, function () {
2779
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_32, _i, _a, interceptor;
2780
- var _this = this;
2781
- return __generator(this, function (_b) {
2782
- localVarPath = this.basePath + '/sources';
2783
- localVarQueryParameters = {};
2784
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
2785
- produces = [
2786
- 'application/vnd.segment.v1+json',
2787
- 'application/json',
2788
- ];
2789
- if (produces.indexOf('application/json') >= 0) {
2790
- localVarHeaderParams.Accept = produces[0];
2791
- }
2792
- else {
2793
- localVarHeaderParams.Accept = 'application/json';
2794
- }
2795
- localVarFormParams = {};
2796
- if (pagination === null || pagination === undefined) {
2797
- throw new Error('Required parameter pagination was null or undefined when calling listSourcesV1.');
2798
- }
2799
- if (pagination !== undefined) {
2800
- localVarQueryParameters['pagination'] = models_1.ObjectSerializer.serialize(pagination, 'PaginationInput');
2801
- }
2802
- Object.assign(localVarHeaderParams, options.headers);
2803
- localVarUseFormData = false;
2804
- localVarRequestOptions = {
2805
- method: 'GET',
2806
- qs: localVarQueryParameters,
2807
- headers: localVarHeaderParams,
2808
- uri: localVarPath,
2809
- useQuerystring: this._useQuerystring,
2810
- json: true,
2811
- };
2812
- authenticationPromise = Promise.resolve();
2813
- if (this.authentications.token.accessToken) {
2814
- authenticationPromise = authenticationPromise.then(function () {
2815
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
2816
- });
2817
- }
2818
- authenticationPromise = authenticationPromise.then(function () {
2819
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
2820
- });
2821
- interceptorPromise = authenticationPromise;
2822
- _loop_32 = function (interceptor) {
2823
- interceptorPromise = interceptorPromise.then(function () {
2824
- return interceptor(localVarRequestOptions);
2825
- });
2826
- };
2827
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
2828
- interceptor = _a[_i];
2829
- _loop_32(interceptor);
2830
- }
2831
- return [2, interceptorPromise.then(function () {
2832
- if (Object.keys(localVarFormParams).length) {
2833
- if (localVarUseFormData) {
2834
- localVarRequestOptions.formData = localVarFormParams;
2835
- }
2836
- else {
2837
- localVarRequestOptions.form = localVarFormParams;
2838
- }
2839
- }
2840
- return new Promise(function (resolve, reject) {
2841
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
2842
- if (error) {
2843
- reject(error);
2844
- }
2845
- else {
2846
- if (response.statusCode &&
2847
- response.statusCode >= 200 &&
2848
- response.statusCode <= 299) {
2849
- body = models_1.ObjectSerializer.deserialize(body, 'ListSources200Response1');
2850
- resolve({ response: response, body: body });
2851
- }
2852
- else {
2853
- reject(new apis_1.HttpError(response, body, response.statusCode));
2854
- }
2855
- }
2856
- });
2857
- });
2858
- })];
2859
- });
2860
- });
2861
- };
2862
- SourcesApi.prototype.replaceLabelsInSourceAlpha = function (sourceId, ReplaceLabelsInSourceAlphaInput, options) {
2863
- if (options === void 0) { options = { headers: {} }; }
2864
- return __awaiter(this, void 0, void 0, function () {
2865
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_33, _i, _a, interceptor;
2866
- var _this = this;
2867
- return __generator(this, function (_b) {
2868
- localVarPath = this.basePath +
2869
- '/sources/{sourceId}/labels'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
2870
- localVarQueryParameters = {};
2871
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
2872
- produces = [
2873
- 'application/vnd.segment.v1alpha+json',
2874
- 'application/json',
2875
- ];
2876
- if (produces.indexOf('application/json') >= 0) {
2877
- localVarHeaderParams.Accept = produces[0];
2878
- }
2879
- else {
2880
- localVarHeaderParams.Accept = 'application/json';
2881
- }
2882
- localVarFormParams = {};
2883
- if (sourceId === null || sourceId === undefined) {
2884
- throw new Error('Required parameter sourceId was null or undefined when calling replaceLabelsInSourceAlpha.');
2885
- }
2886
- if (ReplaceLabelsInSourceAlphaInput === null ||
2887
- ReplaceLabelsInSourceAlphaInput === undefined) {
2888
- throw new Error('Required parameter ReplaceLabelsInSourceAlphaInput was null or undefined when calling replaceLabelsInSourceAlpha.');
2889
- }
2890
- Object.assign(localVarHeaderParams, options.headers);
2891
- localVarUseFormData = false;
2892
- localVarRequestOptions = {
2893
- method: 'PUT',
2894
- qs: localVarQueryParameters,
2895
- headers: localVarHeaderParams,
2896
- uri: localVarPath,
2897
- useQuerystring: this._useQuerystring,
2898
- json: true,
2899
- body: models_1.ObjectSerializer.serialize(ReplaceLabelsInSourceAlphaInput, 'ReplaceLabelsInSourceAlphaInput'),
2900
- };
2901
- authenticationPromise = Promise.resolve();
2902
- if (this.authentications.token.accessToken) {
2903
- authenticationPromise = authenticationPromise.then(function () {
2904
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
2905
- });
2906
- }
2907
- authenticationPromise = authenticationPromise.then(function () {
2908
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
2909
- });
2910
- interceptorPromise = authenticationPromise;
2911
- _loop_33 = function (interceptor) {
2912
- interceptorPromise = interceptorPromise.then(function () {
2913
- return interceptor(localVarRequestOptions);
2914
- });
2915
- };
2916
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
2917
- interceptor = _a[_i];
2918
- _loop_33(interceptor);
2919
- }
2920
- return [2, interceptorPromise.then(function () {
2921
- if (Object.keys(localVarFormParams).length) {
2922
- if (localVarUseFormData) {
2923
- localVarRequestOptions.formData = localVarFormParams;
2924
- }
2925
- else {
2926
- localVarRequestOptions.form = localVarFormParams;
2927
- }
2928
- }
2929
- return new Promise(function (resolve, reject) {
2930
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
2931
- if (error) {
2932
- reject(error);
2933
- }
2934
- else {
2935
- if (response.statusCode &&
2936
- response.statusCode >= 200 &&
2937
- response.statusCode <= 299) {
2938
- body = models_1.ObjectSerializer.deserialize(body, 'ReplaceLabelsInSource200Response');
2939
- resolve({ response: response, body: body });
2940
- }
2941
- else {
2942
- reject(new apis_1.HttpError(response, body, response.statusCode));
2943
- }
2944
- }
2945
- });
2946
- });
2947
- })];
2948
- });
2949
- });
2950
- };
2951
- SourcesApi.prototype.replaceLabelsInSourceBeta = function (sourceId, ReplaceLabelsInSourceV1Input, options) {
2952
- if (options === void 0) { options = { headers: {} }; }
2953
- return __awaiter(this, void 0, void 0, function () {
2954
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_34, _i, _a, interceptor;
2955
- var _this = this;
2956
- return __generator(this, function (_b) {
2957
- localVarPath = this.basePath +
2958
- '/sources/{sourceId}/labels'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
2959
- localVarQueryParameters = {};
2960
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
2961
- produces = [
2962
- 'application/vnd.segment.v1beta+json',
2963
- 'application/json',
2964
- ];
2965
- if (produces.indexOf('application/json') >= 0) {
2966
- localVarHeaderParams.Accept = produces[0];
2967
- }
2968
- else {
2969
- localVarHeaderParams.Accept = 'application/json';
2970
- }
2971
- localVarFormParams = {};
2972
- if (sourceId === null || sourceId === undefined) {
2973
- throw new Error('Required parameter sourceId was null or undefined when calling replaceLabelsInSourceBeta.');
2974
- }
2975
- if (ReplaceLabelsInSourceV1Input === null ||
2976
- ReplaceLabelsInSourceV1Input === undefined) {
2977
- throw new Error('Required parameter ReplaceLabelsInSourceV1Input was null or undefined when calling replaceLabelsInSourceBeta.');
2978
- }
2979
- Object.assign(localVarHeaderParams, options.headers);
2980
- localVarUseFormData = false;
2981
- localVarRequestOptions = {
2982
- method: 'PUT',
2983
- qs: localVarQueryParameters,
2984
- headers: localVarHeaderParams,
2985
- uri: localVarPath,
2986
- useQuerystring: this._useQuerystring,
2987
- json: true,
2988
- body: models_1.ObjectSerializer.serialize(ReplaceLabelsInSourceV1Input, 'ReplaceLabelsInSourceV1Input'),
2989
- };
2990
- authenticationPromise = Promise.resolve();
2991
- if (this.authentications.token.accessToken) {
2992
- authenticationPromise = authenticationPromise.then(function () {
2993
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
2994
- });
2995
- }
2996
- authenticationPromise = authenticationPromise.then(function () {
2997
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
2998
- });
2999
- interceptorPromise = authenticationPromise;
3000
- _loop_34 = function (interceptor) {
3001
- interceptorPromise = interceptorPromise.then(function () {
3002
- return interceptor(localVarRequestOptions);
3003
- });
3004
- };
3005
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
3006
- interceptor = _a[_i];
3007
- _loop_34(interceptor);
3008
- }
3009
- return [2, interceptorPromise.then(function () {
3010
- if (Object.keys(localVarFormParams).length) {
3011
- if (localVarUseFormData) {
3012
- localVarRequestOptions.formData = localVarFormParams;
3013
- }
3014
- else {
3015
- localVarRequestOptions.form = localVarFormParams;
3016
- }
3017
- }
3018
- return new Promise(function (resolve, reject) {
3019
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
3020
- if (error) {
3021
- reject(error);
3022
- }
3023
- else {
3024
- if (response.statusCode &&
3025
- response.statusCode >= 200 &&
3026
- response.statusCode <= 299) {
3027
- body = models_1.ObjectSerializer.deserialize(body, 'ReplaceLabelsInSource200Response1');
3028
- resolve({ response: response, body: body });
3029
- }
3030
- else {
3031
- reject(new apis_1.HttpError(response, body, response.statusCode));
3032
- }
3033
- }
3034
- });
3035
- });
3036
- })];
3037
- });
3038
- });
3039
- };
3040
- SourcesApi.prototype.replaceLabelsInSourceCurrent = function (sourceId, ReplaceLabelsInSourceV1Input, options) {
3041
- if (options === void 0) { options = { headers: {} }; }
3042
- return __awaiter(this, void 0, void 0, function () {
3043
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_35, _i, _a, interceptor;
3044
- var _this = this;
3045
- return __generator(this, function (_b) {
3046
- localVarPath = this.basePath +
3047
- '/sources/{sourceId}/labels'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
3048
- localVarQueryParameters = {};
3049
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
3050
- produces = [
3051
- 'application/vnd.segment.v1+json',
3052
- 'application/json',
3053
- ];
3054
- if (produces.indexOf('application/json') >= 0) {
3055
- localVarHeaderParams.Accept = produces[0];
3056
- }
3057
- else {
3058
- localVarHeaderParams.Accept = 'application/json';
3059
- }
3060
- localVarFormParams = {};
3061
- if (sourceId === null || sourceId === undefined) {
3062
- throw new Error('Required parameter sourceId was null or undefined when calling replaceLabelsInSourceCurrent.');
3063
- }
3064
- if (ReplaceLabelsInSourceV1Input === null ||
3065
- ReplaceLabelsInSourceV1Input === undefined) {
3066
- throw new Error('Required parameter ReplaceLabelsInSourceV1Input was null or undefined when calling replaceLabelsInSourceCurrent.');
3067
- }
3068
- Object.assign(localVarHeaderParams, options.headers);
3069
- localVarUseFormData = false;
3070
- localVarRequestOptions = {
3071
- method: 'PUT',
3072
- qs: localVarQueryParameters,
3073
- headers: localVarHeaderParams,
3074
- uri: localVarPath,
3075
- useQuerystring: this._useQuerystring,
3076
- json: true,
3077
- body: models_1.ObjectSerializer.serialize(ReplaceLabelsInSourceV1Input, 'ReplaceLabelsInSourceV1Input'),
3078
- };
3079
- authenticationPromise = Promise.resolve();
3080
- if (this.authentications.token.accessToken) {
3081
- authenticationPromise = authenticationPromise.then(function () {
3082
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
3083
- });
3084
- }
3085
- authenticationPromise = authenticationPromise.then(function () {
3086
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
3087
- });
3088
- interceptorPromise = authenticationPromise;
3089
- _loop_35 = function (interceptor) {
3090
- interceptorPromise = interceptorPromise.then(function () {
3091
- return interceptor(localVarRequestOptions);
3092
- });
3093
- };
3094
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
3095
- interceptor = _a[_i];
3096
- _loop_35(interceptor);
3097
- }
3098
- return [2, interceptorPromise.then(function () {
3099
- if (Object.keys(localVarFormParams).length) {
3100
- if (localVarUseFormData) {
3101
- localVarRequestOptions.formData = localVarFormParams;
3102
- }
3103
- else {
3104
- localVarRequestOptions.form = localVarFormParams;
3105
- }
3106
- }
3107
- return new Promise(function (resolve, reject) {
3108
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
3109
- if (error) {
3110
- reject(error);
3111
- }
3112
- else {
3113
- if (response.statusCode &&
3114
- response.statusCode >= 200 &&
3115
- response.statusCode <= 299) {
3116
- body = models_1.ObjectSerializer.deserialize(body, 'ReplaceLabelsInSource200Response1');
3117
- resolve({ response: response, body: body });
3118
- }
3119
- else {
3120
- reject(new apis_1.HttpError(response, body, response.statusCode));
3121
- }
3122
- }
3123
- });
3124
- });
3125
- })];
3126
- });
3127
- });
3128
- };
3129
- SourcesApi.prototype.replaceLabelsInSourceV1 = function (sourceId, ReplaceLabelsInSourceV1Input, options) {
3130
- if (options === void 0) { options = { headers: {} }; }
3131
- return __awaiter(this, void 0, void 0, function () {
3132
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_36, _i, _a, interceptor;
3133
- var _this = this;
3134
- return __generator(this, function (_b) {
3135
- localVarPath = this.basePath +
3136
- '/sources/{sourceId}/labels'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
3137
- localVarQueryParameters = {};
3138
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
3139
- produces = [
3140
- 'application/vnd.segment.v1+json',
3141
- 'application/json',
3142
- ];
3143
- if (produces.indexOf('application/json') >= 0) {
3144
- localVarHeaderParams.Accept = produces[0];
3145
- }
3146
- else {
3147
- localVarHeaderParams.Accept = 'application/json';
3148
- }
3149
- localVarFormParams = {};
3150
- if (sourceId === null || sourceId === undefined) {
3151
- throw new Error('Required parameter sourceId was null or undefined when calling replaceLabelsInSourceV1.');
3152
- }
3153
- if (ReplaceLabelsInSourceV1Input === null ||
3154
- ReplaceLabelsInSourceV1Input === undefined) {
3155
- throw new Error('Required parameter ReplaceLabelsInSourceV1Input was null or undefined when calling replaceLabelsInSourceV1.');
3156
- }
3157
- Object.assign(localVarHeaderParams, options.headers);
3158
- localVarUseFormData = false;
3159
- localVarRequestOptions = {
3160
- method: 'PUT',
3161
- qs: localVarQueryParameters,
3162
- headers: localVarHeaderParams,
3163
- uri: localVarPath,
3164
- useQuerystring: this._useQuerystring,
3165
- json: true,
3166
- body: models_1.ObjectSerializer.serialize(ReplaceLabelsInSourceV1Input, 'ReplaceLabelsInSourceV1Input'),
3167
- };
3168
- authenticationPromise = Promise.resolve();
3169
- if (this.authentications.token.accessToken) {
3170
- authenticationPromise = authenticationPromise.then(function () {
3171
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
3172
- });
3173
- }
3174
- authenticationPromise = authenticationPromise.then(function () {
3175
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
3176
- });
3177
- interceptorPromise = authenticationPromise;
3178
- _loop_36 = function (interceptor) {
3179
- interceptorPromise = interceptorPromise.then(function () {
3180
- return interceptor(localVarRequestOptions);
3181
- });
3182
- };
3183
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
3184
- interceptor = _a[_i];
3185
- _loop_36(interceptor);
3186
- }
3187
- return [2, interceptorPromise.then(function () {
3188
- if (Object.keys(localVarFormParams).length) {
3189
- if (localVarUseFormData) {
3190
- localVarRequestOptions.formData = localVarFormParams;
3191
- }
3192
- else {
3193
- localVarRequestOptions.form = localVarFormParams;
3194
- }
3195
- }
3196
- return new Promise(function (resolve, reject) {
3197
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
3198
- if (error) {
3199
- reject(error);
3200
- }
3201
- else {
3202
- if (response.statusCode &&
3203
- response.statusCode >= 200 &&
3204
- response.statusCode <= 299) {
3205
- body = models_1.ObjectSerializer.deserialize(body, 'ReplaceLabelsInSource200Response1');
3206
- resolve({ response: response, body: body });
3207
- }
3208
- else {
3209
- reject(new apis_1.HttpError(response, body, response.statusCode));
3210
- }
3211
- }
3212
- });
3213
- });
3214
- })];
3215
- });
3216
- });
3217
- };
3218
- SourcesApi.prototype.updateSchemaSettingsInSourceAlpha = function (sourceId, UpdateSchemaSettingsInSourceV1Input, options) {
3219
- if (options === void 0) { options = { headers: {} }; }
3220
- return __awaiter(this, void 0, void 0, function () {
3221
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_37, _i, _a, interceptor;
3222
- var _this = this;
3223
- return __generator(this, function (_b) {
3224
- localVarPath = this.basePath +
3225
- '/sources/{sourceId}/settings'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
3226
- localVarQueryParameters = {};
3227
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
3228
- produces = [
3229
- 'application/vnd.segment.v1alpha+json',
3230
- 'application/json',
3231
- ];
3232
- if (produces.indexOf('application/json') >= 0) {
3233
- localVarHeaderParams.Accept = produces[0];
3234
- }
3235
- else {
3236
- localVarHeaderParams.Accept = 'application/json';
3237
- }
3238
- localVarFormParams = {};
3239
- if (sourceId === null || sourceId === undefined) {
3240
- throw new Error('Required parameter sourceId was null or undefined when calling updateSchemaSettingsInSourceAlpha.');
3241
- }
3242
- if (UpdateSchemaSettingsInSourceV1Input === null ||
3243
- UpdateSchemaSettingsInSourceV1Input === undefined) {
3244
- throw new Error('Required parameter UpdateSchemaSettingsInSourceV1Input was null or undefined when calling updateSchemaSettingsInSourceAlpha.');
3245
- }
3246
- Object.assign(localVarHeaderParams, options.headers);
3247
- localVarUseFormData = false;
3248
- localVarRequestOptions = {
3249
- method: 'PATCH',
3250
- qs: localVarQueryParameters,
3251
- headers: localVarHeaderParams,
3252
- uri: localVarPath,
3253
- useQuerystring: this._useQuerystring,
3254
- json: true,
3255
- body: models_1.ObjectSerializer.serialize(UpdateSchemaSettingsInSourceV1Input, 'UpdateSchemaSettingsInSourceV1Input'),
3256
- };
3257
- authenticationPromise = Promise.resolve();
3258
- if (this.authentications.token.accessToken) {
3259
- authenticationPromise = authenticationPromise.then(function () {
3260
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
3261
- });
3262
- }
3263
- authenticationPromise = authenticationPromise.then(function () {
3264
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
3265
- });
3266
- interceptorPromise = authenticationPromise;
3267
- _loop_37 = function (interceptor) {
3268
- interceptorPromise = interceptorPromise.then(function () {
3269
- return interceptor(localVarRequestOptions);
3270
- });
3271
- };
3272
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
3273
- interceptor = _a[_i];
3274
- _loop_37(interceptor);
3275
- }
3276
- return [2, interceptorPromise.then(function () {
3277
- if (Object.keys(localVarFormParams).length) {
3278
- if (localVarUseFormData) {
3279
- localVarRequestOptions.formData = localVarFormParams;
3280
- }
3281
- else {
3282
- localVarRequestOptions.form = localVarFormParams;
3283
- }
3284
- }
3285
- return new Promise(function (resolve, reject) {
3286
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
3287
- if (error) {
3288
- reject(error);
3289
- }
3290
- else {
3291
- if (response.statusCode &&
3292
- response.statusCode >= 200 &&
3293
- response.statusCode <= 299) {
3294
- body = models_1.ObjectSerializer.deserialize(body, 'UpdateSchemaSettingsInSource200Response');
3295
- resolve({ response: response, body: body });
3296
- }
3297
- else {
3298
- reject(new apis_1.HttpError(response, body, response.statusCode));
3299
- }
3300
- }
3301
- });
3302
- });
3303
- })];
3304
- });
3305
- });
3306
- };
3307
- SourcesApi.prototype.updateSchemaSettingsInSourceBeta = function (sourceId, UpdateSchemaSettingsInSourceV1Input, options) {
3308
- if (options === void 0) { options = { headers: {} }; }
3309
- return __awaiter(this, void 0, void 0, function () {
3310
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_38, _i, _a, interceptor;
3311
- var _this = this;
3312
- return __generator(this, function (_b) {
3313
- localVarPath = this.basePath +
3314
- '/sources/{sourceId}/settings'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
3315
- localVarQueryParameters = {};
3316
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
3317
- produces = [
3318
- 'application/vnd.segment.v1beta+json',
3319
- 'application/json',
3320
- ];
3321
- if (produces.indexOf('application/json') >= 0) {
3322
- localVarHeaderParams.Accept = produces[0];
3323
- }
3324
- else {
3325
- localVarHeaderParams.Accept = 'application/json';
3326
- }
3327
- localVarFormParams = {};
3328
- if (sourceId === null || sourceId === undefined) {
3329
- throw new Error('Required parameter sourceId was null or undefined when calling updateSchemaSettingsInSourceBeta.');
3330
- }
3331
- if (UpdateSchemaSettingsInSourceV1Input === null ||
3332
- UpdateSchemaSettingsInSourceV1Input === undefined) {
3333
- throw new Error('Required parameter UpdateSchemaSettingsInSourceV1Input was null or undefined when calling updateSchemaSettingsInSourceBeta.');
3334
- }
3335
- Object.assign(localVarHeaderParams, options.headers);
3336
- localVarUseFormData = false;
3337
- localVarRequestOptions = {
3338
- method: 'PATCH',
3339
- qs: localVarQueryParameters,
3340
- headers: localVarHeaderParams,
3341
- uri: localVarPath,
3342
- useQuerystring: this._useQuerystring,
3343
- json: true,
3344
- body: models_1.ObjectSerializer.serialize(UpdateSchemaSettingsInSourceV1Input, 'UpdateSchemaSettingsInSourceV1Input'),
3345
- };
3346
- authenticationPromise = Promise.resolve();
3347
- if (this.authentications.token.accessToken) {
3348
- authenticationPromise = authenticationPromise.then(function () {
3349
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
3350
- });
3351
- }
3352
- authenticationPromise = authenticationPromise.then(function () {
3353
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
3354
- });
3355
- interceptorPromise = authenticationPromise;
3356
- _loop_38 = function (interceptor) {
3357
- interceptorPromise = interceptorPromise.then(function () {
3358
- return interceptor(localVarRequestOptions);
3359
- });
3360
- };
3361
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
3362
- interceptor = _a[_i];
3363
- _loop_38(interceptor);
3364
- }
3365
- return [2, interceptorPromise.then(function () {
3366
- if (Object.keys(localVarFormParams).length) {
3367
- if (localVarUseFormData) {
3368
- localVarRequestOptions.formData = localVarFormParams;
3369
- }
3370
- else {
3371
- localVarRequestOptions.form = localVarFormParams;
3372
- }
3373
- }
3374
- return new Promise(function (resolve, reject) {
3375
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
3376
- if (error) {
3377
- reject(error);
3378
- }
3379
- else {
3380
- if (response.statusCode &&
3381
- response.statusCode >= 200 &&
3382
- response.statusCode <= 299) {
3383
- body = models_1.ObjectSerializer.deserialize(body, 'UpdateSchemaSettingsInSource200Response');
3384
- resolve({ response: response, body: body });
3385
- }
3386
- else {
3387
- reject(new apis_1.HttpError(response, body, response.statusCode));
3388
- }
3389
- }
3390
- });
3391
- });
3392
- })];
3393
- });
3394
- });
3395
- };
3396
- SourcesApi.prototype.updateSchemaSettingsInSourceCurrent = function (sourceId, UpdateSchemaSettingsInSourceV1Input, options) {
3397
- if (options === void 0) { options = { headers: {} }; }
3398
- return __awaiter(this, void 0, void 0, function () {
3399
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_39, _i, _a, interceptor;
3400
- var _this = this;
3401
- return __generator(this, function (_b) {
3402
- localVarPath = this.basePath +
3403
- '/sources/{sourceId}/settings'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
3404
- localVarQueryParameters = {};
3405
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
3406
- produces = [
3407
- 'application/vnd.segment.v1+json',
3408
- 'application/json',
3409
- ];
3410
- if (produces.indexOf('application/json') >= 0) {
3411
- localVarHeaderParams.Accept = produces[0];
3412
- }
3413
- else {
3414
- localVarHeaderParams.Accept = 'application/json';
3415
- }
3416
- localVarFormParams = {};
3417
- if (sourceId === null || sourceId === undefined) {
3418
- throw new Error('Required parameter sourceId was null or undefined when calling updateSchemaSettingsInSourceCurrent.');
3419
- }
3420
- if (UpdateSchemaSettingsInSourceV1Input === null ||
3421
- UpdateSchemaSettingsInSourceV1Input === undefined) {
3422
- throw new Error('Required parameter UpdateSchemaSettingsInSourceV1Input was null or undefined when calling updateSchemaSettingsInSourceCurrent.');
3423
- }
3424
- Object.assign(localVarHeaderParams, options.headers);
3425
- localVarUseFormData = false;
3426
- localVarRequestOptions = {
3427
- method: 'PATCH',
3428
- qs: localVarQueryParameters,
3429
- headers: localVarHeaderParams,
3430
- uri: localVarPath,
3431
- useQuerystring: this._useQuerystring,
3432
- json: true,
3433
- body: models_1.ObjectSerializer.serialize(UpdateSchemaSettingsInSourceV1Input, 'UpdateSchemaSettingsInSourceV1Input'),
3434
- };
3435
- authenticationPromise = Promise.resolve();
3436
- if (this.authentications.token.accessToken) {
3437
- authenticationPromise = authenticationPromise.then(function () {
3438
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
3439
- });
3440
- }
3441
- authenticationPromise = authenticationPromise.then(function () {
3442
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
3443
- });
3444
- interceptorPromise = authenticationPromise;
3445
- _loop_39 = function (interceptor) {
3446
- interceptorPromise = interceptorPromise.then(function () {
3447
- return interceptor(localVarRequestOptions);
3448
- });
3449
- };
3450
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
3451
- interceptor = _a[_i];
3452
- _loop_39(interceptor);
3453
- }
3454
- return [2, interceptorPromise.then(function () {
3455
- if (Object.keys(localVarFormParams).length) {
3456
- if (localVarUseFormData) {
3457
- localVarRequestOptions.formData = localVarFormParams;
3458
- }
3459
- else {
3460
- localVarRequestOptions.form = localVarFormParams;
3461
- }
3462
- }
3463
- return new Promise(function (resolve, reject) {
3464
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
3465
- if (error) {
3466
- reject(error);
3467
- }
3468
- else {
3469
- if (response.statusCode &&
3470
- response.statusCode >= 200 &&
3471
- response.statusCode <= 299) {
3472
- body = models_1.ObjectSerializer.deserialize(body, 'UpdateSchemaSettingsInSource200Response');
3473
- resolve({ response: response, body: body });
3474
- }
3475
- else {
3476
- reject(new apis_1.HttpError(response, body, response.statusCode));
3477
- }
3478
- }
3479
- });
3480
- });
3481
- })];
3482
- });
3483
- });
3484
- };
3485
- SourcesApi.prototype.updateSchemaSettingsInSourceV1 = function (sourceId, UpdateSchemaSettingsInSourceV1Input, options) {
3486
- if (options === void 0) { options = { headers: {} }; }
3487
- return __awaiter(this, void 0, void 0, function () {
3488
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_40, _i, _a, interceptor;
3489
- var _this = this;
3490
- return __generator(this, function (_b) {
3491
- localVarPath = this.basePath +
3492
- '/sources/{sourceId}/settings'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
3493
- localVarQueryParameters = {};
3494
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
3495
- produces = [
3496
- 'application/vnd.segment.v1+json',
3497
- 'application/json',
3498
- ];
3499
- if (produces.indexOf('application/json') >= 0) {
3500
- localVarHeaderParams.Accept = produces[0];
3501
- }
3502
- else {
3503
- localVarHeaderParams.Accept = 'application/json';
3504
- }
3505
- localVarFormParams = {};
3506
- if (sourceId === null || sourceId === undefined) {
3507
- throw new Error('Required parameter sourceId was null or undefined when calling updateSchemaSettingsInSourceV1.');
3508
- }
3509
- if (UpdateSchemaSettingsInSourceV1Input === null ||
3510
- UpdateSchemaSettingsInSourceV1Input === undefined) {
3511
- throw new Error('Required parameter UpdateSchemaSettingsInSourceV1Input was null or undefined when calling updateSchemaSettingsInSourceV1.');
3512
- }
3513
- Object.assign(localVarHeaderParams, options.headers);
3514
- localVarUseFormData = false;
3515
- localVarRequestOptions = {
3516
- method: 'PATCH',
3517
- qs: localVarQueryParameters,
3518
- headers: localVarHeaderParams,
3519
- uri: localVarPath,
3520
- useQuerystring: this._useQuerystring,
3521
- json: true,
3522
- body: models_1.ObjectSerializer.serialize(UpdateSchemaSettingsInSourceV1Input, 'UpdateSchemaSettingsInSourceV1Input'),
3523
- };
3524
- authenticationPromise = Promise.resolve();
3525
- if (this.authentications.token.accessToken) {
3526
- authenticationPromise = authenticationPromise.then(function () {
3527
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
3528
- });
3529
- }
3530
- authenticationPromise = authenticationPromise.then(function () {
3531
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
3532
- });
3533
- interceptorPromise = authenticationPromise;
3534
- _loop_40 = function (interceptor) {
3535
- interceptorPromise = interceptorPromise.then(function () {
3536
- return interceptor(localVarRequestOptions);
3537
- });
3538
- };
3539
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
3540
- interceptor = _a[_i];
3541
- _loop_40(interceptor);
3542
- }
3543
- return [2, interceptorPromise.then(function () {
3544
- if (Object.keys(localVarFormParams).length) {
3545
- if (localVarUseFormData) {
3546
- localVarRequestOptions.formData = localVarFormParams;
3547
- }
3548
- else {
3549
- localVarRequestOptions.form = localVarFormParams;
3550
- }
3551
- }
3552
- return new Promise(function (resolve, reject) {
3553
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
3554
- if (error) {
3555
- reject(error);
3556
- }
3557
- else {
3558
- if (response.statusCode &&
3559
- response.statusCode >= 200 &&
3560
- response.statusCode <= 299) {
3561
- body = models_1.ObjectSerializer.deserialize(body, 'UpdateSchemaSettingsInSource200Response');
3562
- resolve({ response: response, body: body });
3563
- }
3564
- else {
3565
- reject(new apis_1.HttpError(response, body, response.statusCode));
3566
- }
3567
- }
3568
- });
3569
- });
3570
- })];
3571
- });
3572
- });
3573
- };
3574
- SourcesApi.prototype.updateSourceAlpha = function (sourceId, UpdateSourceAlphaInput, options) {
3575
- if (options === void 0) { options = { headers: {} }; }
3576
- return __awaiter(this, void 0, void 0, function () {
3577
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_41, _i, _a, interceptor;
3578
- var _this = this;
3579
- return __generator(this, function (_b) {
3580
- localVarPath = this.basePath +
3581
- '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
3582
- localVarQueryParameters = {};
3583
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
3584
- produces = [
3585
- 'application/vnd.segment.v1alpha+json',
3586
- 'application/json',
3587
- ];
3588
- if (produces.indexOf('application/json') >= 0) {
3589
- localVarHeaderParams.Accept = produces[0];
3590
- }
3591
- else {
3592
- localVarHeaderParams.Accept = 'application/json';
3593
- }
3594
- localVarFormParams = {};
3595
- if (sourceId === null || sourceId === undefined) {
3596
- throw new Error('Required parameter sourceId was null or undefined when calling updateSourceAlpha.');
3597
- }
3598
- if (UpdateSourceAlphaInput === null ||
3599
- UpdateSourceAlphaInput === undefined) {
3600
- throw new Error('Required parameter UpdateSourceAlphaInput was null or undefined when calling updateSourceAlpha.');
3601
- }
3602
- Object.assign(localVarHeaderParams, options.headers);
3603
- localVarUseFormData = false;
3604
- localVarRequestOptions = {
3605
- method: 'PATCH',
3606
- qs: localVarQueryParameters,
3607
- headers: localVarHeaderParams,
3608
- uri: localVarPath,
3609
- useQuerystring: this._useQuerystring,
3610
- json: true,
3611
- body: models_1.ObjectSerializer.serialize(UpdateSourceAlphaInput, 'UpdateSourceAlphaInput'),
3612
- };
3613
- authenticationPromise = Promise.resolve();
3614
- if (this.authentications.token.accessToken) {
3615
- authenticationPromise = authenticationPromise.then(function () {
3616
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
3617
- });
3618
- }
3619
- authenticationPromise = authenticationPromise.then(function () {
3620
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
3621
- });
3622
- interceptorPromise = authenticationPromise;
3623
- _loop_41 = function (interceptor) {
3624
- interceptorPromise = interceptorPromise.then(function () {
3625
- return interceptor(localVarRequestOptions);
3626
- });
3627
- };
3628
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
3629
- interceptor = _a[_i];
3630
- _loop_41(interceptor);
1061
+ _loop_11(interceptor);
3631
1062
  }
3632
1063
  return [2, interceptorPromise.then(function () {
3633
1064
  if (Object.keys(localVarFormParams).length) {
@@ -3660,270 +1091,6 @@ var SourcesApi = (function () {
3660
1091
  });
3661
1092
  });
3662
1093
  };
3663
- SourcesApi.prototype.updateSourceBeta = function (sourceId, UpdateSourceV1Input, options) {
3664
- if (options === void 0) { options = { headers: {} }; }
3665
- return __awaiter(this, void 0, void 0, function () {
3666
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_42, _i, _a, interceptor;
3667
- var _this = this;
3668
- return __generator(this, function (_b) {
3669
- localVarPath = this.basePath +
3670
- '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
3671
- localVarQueryParameters = {};
3672
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
3673
- produces = [
3674
- 'application/vnd.segment.v1beta+json',
3675
- 'application/json',
3676
- ];
3677
- if (produces.indexOf('application/json') >= 0) {
3678
- localVarHeaderParams.Accept = produces[0];
3679
- }
3680
- else {
3681
- localVarHeaderParams.Accept = 'application/json';
3682
- }
3683
- localVarFormParams = {};
3684
- if (sourceId === null || sourceId === undefined) {
3685
- throw new Error('Required parameter sourceId was null or undefined when calling updateSourceBeta.');
3686
- }
3687
- if (UpdateSourceV1Input === null || UpdateSourceV1Input === undefined) {
3688
- throw new Error('Required parameter UpdateSourceV1Input was null or undefined when calling updateSourceBeta.');
3689
- }
3690
- Object.assign(localVarHeaderParams, options.headers);
3691
- localVarUseFormData = false;
3692
- localVarRequestOptions = {
3693
- method: 'PATCH',
3694
- qs: localVarQueryParameters,
3695
- headers: localVarHeaderParams,
3696
- uri: localVarPath,
3697
- useQuerystring: this._useQuerystring,
3698
- json: true,
3699
- body: models_1.ObjectSerializer.serialize(UpdateSourceV1Input, 'UpdateSourceV1Input'),
3700
- };
3701
- authenticationPromise = Promise.resolve();
3702
- if (this.authentications.token.accessToken) {
3703
- authenticationPromise = authenticationPromise.then(function () {
3704
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
3705
- });
3706
- }
3707
- authenticationPromise = authenticationPromise.then(function () {
3708
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
3709
- });
3710
- interceptorPromise = authenticationPromise;
3711
- _loop_42 = function (interceptor) {
3712
- interceptorPromise = interceptorPromise.then(function () {
3713
- return interceptor(localVarRequestOptions);
3714
- });
3715
- };
3716
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
3717
- interceptor = _a[_i];
3718
- _loop_42(interceptor);
3719
- }
3720
- return [2, interceptorPromise.then(function () {
3721
- if (Object.keys(localVarFormParams).length) {
3722
- if (localVarUseFormData) {
3723
- localVarRequestOptions.formData = localVarFormParams;
3724
- }
3725
- else {
3726
- localVarRequestOptions.form = localVarFormParams;
3727
- }
3728
- }
3729
- return new Promise(function (resolve, reject) {
3730
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
3731
- if (error) {
3732
- reject(error);
3733
- }
3734
- else {
3735
- if (response.statusCode &&
3736
- response.statusCode >= 200 &&
3737
- response.statusCode <= 299) {
3738
- body = models_1.ObjectSerializer.deserialize(body, 'UpdateSource200Response1');
3739
- resolve({ response: response, body: body });
3740
- }
3741
- else {
3742
- reject(new apis_1.HttpError(response, body, response.statusCode));
3743
- }
3744
- }
3745
- });
3746
- });
3747
- })];
3748
- });
3749
- });
3750
- };
3751
- SourcesApi.prototype.updateSourceCurrent = function (sourceId, UpdateSourceV1Input, options) {
3752
- if (options === void 0) { options = { headers: {} }; }
3753
- return __awaiter(this, void 0, void 0, function () {
3754
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_43, _i, _a, interceptor;
3755
- var _this = this;
3756
- return __generator(this, function (_b) {
3757
- localVarPath = this.basePath +
3758
- '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
3759
- localVarQueryParameters = {};
3760
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
3761
- produces = [
3762
- 'application/vnd.segment.v1+json',
3763
- 'application/json',
3764
- ];
3765
- if (produces.indexOf('application/json') >= 0) {
3766
- localVarHeaderParams.Accept = produces[0];
3767
- }
3768
- else {
3769
- localVarHeaderParams.Accept = 'application/json';
3770
- }
3771
- localVarFormParams = {};
3772
- if (sourceId === null || sourceId === undefined) {
3773
- throw new Error('Required parameter sourceId was null or undefined when calling updateSourceCurrent.');
3774
- }
3775
- if (UpdateSourceV1Input === null || UpdateSourceV1Input === undefined) {
3776
- throw new Error('Required parameter UpdateSourceV1Input was null or undefined when calling updateSourceCurrent.');
3777
- }
3778
- Object.assign(localVarHeaderParams, options.headers);
3779
- localVarUseFormData = false;
3780
- localVarRequestOptions = {
3781
- method: 'PATCH',
3782
- qs: localVarQueryParameters,
3783
- headers: localVarHeaderParams,
3784
- uri: localVarPath,
3785
- useQuerystring: this._useQuerystring,
3786
- json: true,
3787
- body: models_1.ObjectSerializer.serialize(UpdateSourceV1Input, 'UpdateSourceV1Input'),
3788
- };
3789
- authenticationPromise = Promise.resolve();
3790
- if (this.authentications.token.accessToken) {
3791
- authenticationPromise = authenticationPromise.then(function () {
3792
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
3793
- });
3794
- }
3795
- authenticationPromise = authenticationPromise.then(function () {
3796
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
3797
- });
3798
- interceptorPromise = authenticationPromise;
3799
- _loop_43 = function (interceptor) {
3800
- interceptorPromise = interceptorPromise.then(function () {
3801
- return interceptor(localVarRequestOptions);
3802
- });
3803
- };
3804
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
3805
- interceptor = _a[_i];
3806
- _loop_43(interceptor);
3807
- }
3808
- return [2, interceptorPromise.then(function () {
3809
- if (Object.keys(localVarFormParams).length) {
3810
- if (localVarUseFormData) {
3811
- localVarRequestOptions.formData = localVarFormParams;
3812
- }
3813
- else {
3814
- localVarRequestOptions.form = localVarFormParams;
3815
- }
3816
- }
3817
- return new Promise(function (resolve, reject) {
3818
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
3819
- if (error) {
3820
- reject(error);
3821
- }
3822
- else {
3823
- if (response.statusCode &&
3824
- response.statusCode >= 200 &&
3825
- response.statusCode <= 299) {
3826
- body = models_1.ObjectSerializer.deserialize(body, 'UpdateSource200Response1');
3827
- resolve({ response: response, body: body });
3828
- }
3829
- else {
3830
- reject(new apis_1.HttpError(response, body, response.statusCode));
3831
- }
3832
- }
3833
- });
3834
- });
3835
- })];
3836
- });
3837
- });
3838
- };
3839
- SourcesApi.prototype.updateSourceV1 = function (sourceId, UpdateSourceV1Input, options) {
3840
- if (options === void 0) { options = { headers: {} }; }
3841
- return __awaiter(this, void 0, void 0, function () {
3842
- var localVarPath, localVarQueryParameters, localVarHeaderParams, produces, localVarFormParams, localVarUseFormData, localVarRequestOptions, authenticationPromise, interceptorPromise, _loop_44, _i, _a, interceptor;
3843
- var _this = this;
3844
- return __generator(this, function (_b) {
3845
- localVarPath = this.basePath +
3846
- '/sources/{sourceId}'.replace('{' + 'sourceId' + '}', encodeURIComponent(String(sourceId)));
3847
- localVarQueryParameters = {};
3848
- localVarHeaderParams = Object.assign({}, this._defaultHeaders);
3849
- produces = [
3850
- 'application/vnd.segment.v1+json',
3851
- 'application/json',
3852
- ];
3853
- if (produces.indexOf('application/json') >= 0) {
3854
- localVarHeaderParams.Accept = produces[0];
3855
- }
3856
- else {
3857
- localVarHeaderParams.Accept = 'application/json';
3858
- }
3859
- localVarFormParams = {};
3860
- if (sourceId === null || sourceId === undefined) {
3861
- throw new Error('Required parameter sourceId was null or undefined when calling updateSourceV1.');
3862
- }
3863
- if (UpdateSourceV1Input === null || UpdateSourceV1Input === undefined) {
3864
- throw new Error('Required parameter UpdateSourceV1Input was null or undefined when calling updateSourceV1.');
3865
- }
3866
- Object.assign(localVarHeaderParams, options.headers);
3867
- localVarUseFormData = false;
3868
- localVarRequestOptions = {
3869
- method: 'PATCH',
3870
- qs: localVarQueryParameters,
3871
- headers: localVarHeaderParams,
3872
- uri: localVarPath,
3873
- useQuerystring: this._useQuerystring,
3874
- json: true,
3875
- body: models_1.ObjectSerializer.serialize(UpdateSourceV1Input, 'UpdateSourceV1Input'),
3876
- };
3877
- authenticationPromise = Promise.resolve();
3878
- if (this.authentications.token.accessToken) {
3879
- authenticationPromise = authenticationPromise.then(function () {
3880
- return _this.authentications.token.applyToRequest(localVarRequestOptions);
3881
- });
3882
- }
3883
- authenticationPromise = authenticationPromise.then(function () {
3884
- return _this.authentications.default.applyToRequest(localVarRequestOptions);
3885
- });
3886
- interceptorPromise = authenticationPromise;
3887
- _loop_44 = function (interceptor) {
3888
- interceptorPromise = interceptorPromise.then(function () {
3889
- return interceptor(localVarRequestOptions);
3890
- });
3891
- };
3892
- for (_i = 0, _a = this.interceptors; _i < _a.length; _i++) {
3893
- interceptor = _a[_i];
3894
- _loop_44(interceptor);
3895
- }
3896
- return [2, interceptorPromise.then(function () {
3897
- if (Object.keys(localVarFormParams).length) {
3898
- if (localVarUseFormData) {
3899
- localVarRequestOptions.formData = localVarFormParams;
3900
- }
3901
- else {
3902
- localVarRequestOptions.form = localVarFormParams;
3903
- }
3904
- }
3905
- return new Promise(function (resolve, reject) {
3906
- (0, request_1.default)(localVarRequestOptions, function (error, response, body) {
3907
- if (error) {
3908
- reject(error);
3909
- }
3910
- else {
3911
- if (response.statusCode &&
3912
- response.statusCode >= 200 &&
3913
- response.statusCode <= 299) {
3914
- body = models_1.ObjectSerializer.deserialize(body, 'UpdateSource200Response1');
3915
- resolve({ response: response, body: body });
3916
- }
3917
- else {
3918
- reject(new apis_1.HttpError(response, body, response.statusCode));
3919
- }
3920
- }
3921
- });
3922
- });
3923
- })];
3924
- });
3925
- });
3926
- };
3927
1094
  return SourcesApi;
3928
1095
  }());
3929
1096
  exports.SourcesApi = SourcesApi;