@segment/public-api-sdk-typescript 1.0.0 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (492) hide show
  1. package/package.json +2 -1
  2. package/api/aPICallsApi.ts +0 -1176
  3. package/api/apis.ts +0 -178
  4. package/api/auditTrailApi.ts +0 -714
  5. package/api/catalogApi.ts +0 -2916
  6. package/api/deletionAndSuppressionApi.ts +0 -4298
  7. package/api/destinationFiltersApi.ts +0 -3262
  8. package/api/destinationsApi.ts +0 -3494
  9. package/api/edgeFunctionsApi.ts +0 -593
  10. package/api/eventsApi.ts +0 -922
  11. package/api/functionsApi.ts +0 -3036
  12. package/api/iAMGroupsApi.ts +0 -6204
  13. package/api/iAMRolesApi.ts +0 -566
  14. package/api/iAMUsersApi.ts +0 -4486
  15. package/api/labelsApi.ts +0 -1488
  16. package/api/monthlyTrackedUsersApi.ts +0 -1178
  17. package/api/selectiveSyncApi.ts +0 -3321
  18. package/api/sourcesApi.ts +0 -5602
  19. package/api/spacesApi.ts +0 -489
  20. package/api/testingApi.ts +0 -568
  21. package/api/trackingPlansApi.ts +0 -6238
  22. package/api/transformationsApi.ts +0 -1316
  23. package/api/warehousesApi.ts +0 -5004
  24. package/api/workspacesApi.ts +0 -513
  25. package/api.ts +0 -3
  26. package/jest.config.js +0 -10
  27. package/model/aPICallSnapshotV1.ts +0 -50
  28. package/model/accessPermissionV1.ts +0 -60
  29. package/model/addConnectionFromSourceToWarehouse200Response.ts +0 -36
  30. package/model/addConnectionFromSourceToWarehouseV1Output.ts +0 -48
  31. package/model/addLabelsToSource200Response.ts +0 -36
  32. package/model/addLabelsToSource200Response1.ts +0 -36
  33. package/model/addLabelsToSourceAlphaInput.ts +0 -42
  34. package/model/addLabelsToSourceAlphaOutput.ts +0 -42
  35. package/model/addLabelsToSourceV1Input.ts +0 -42
  36. package/model/addLabelsToSourceV1Output.ts +0 -42
  37. package/model/addPermissionsToUser200Response.ts +0 -36
  38. package/model/addPermissionsToUserGroup200Response.ts +0 -36
  39. package/model/addPermissionsToUserGroupV1Input.ts +0 -42
  40. package/model/addPermissionsToUserGroupV1Output.ts +0 -42
  41. package/model/addPermissionsToUserV1Input.ts +0 -42
  42. package/model/addPermissionsToUserV1Output.ts +0 -42
  43. package/model/addSourceToTrackingPlan200Response.ts +0 -36
  44. package/model/addSourceToTrackingPlanV1Input.ts +0 -41
  45. package/model/addSourceToTrackingPlanV1Output.ts +0 -47
  46. package/model/addUsersToUserGroup200Response.ts +0 -36
  47. package/model/addUsersToUserGroupV1Input.ts +0 -41
  48. package/model/addUsersToUserGroupV1Output.ts +0 -39
  49. package/model/advancedWarehouseSyncScheduleV1Input.ts +0 -51
  50. package/model/advancedWarehouseSyncScheduleV1Output.ts +0 -51
  51. package/model/allowedLabelBeta.ts +0 -59
  52. package/model/auditEventV1.ts +0 -95
  53. package/model/batchQueryMessagingSubscriptionsForSpace200Response.ts +0 -36
  54. package/model/batchQueryMessagingSubscriptionsForSpaceAlphaInput.ts +0 -42
  55. package/model/batchQueryMessagingSubscriptionsForSpaceAlphaOutput.ts +0 -69
  56. package/model/breakdownBeta.ts +0 -50
  57. package/model/commonSourceSettingsV1.ts +0 -68
  58. package/model/createCloudSourceRegulation200Response.ts +0 -36
  59. package/model/createCloudSourceRegulationV1Input.ts +0 -82
  60. package/model/createCloudSourceRegulationV1Output.ts +0 -41
  61. package/model/createDestination200Response.ts +0 -36
  62. package/model/createDestinationSubscription200Response.ts +0 -36
  63. package/model/createDestinationSubscriptionAlphaInput.ts +0 -77
  64. package/model/createDestinationSubscriptionAlphaOutput.ts +0 -39
  65. package/model/createDestinationV1Input.ts +0 -77
  66. package/model/createDestinationV1Output.ts +0 -39
  67. package/model/createEdgeFunctions200Response.ts +0 -36
  68. package/model/createEdgeFunctionsAlphaInput.ts +0 -41
  69. package/model/createEdgeFunctionsAlphaOutput.ts +0 -39
  70. package/model/createFilterForDestination200Response.ts +0 -36
  71. package/model/createFilterForDestinationV1Input.ts +0 -87
  72. package/model/createFilterForDestinationV1Output.ts +0 -39
  73. package/model/createFunction200Response.ts +0 -36
  74. package/model/createFunctionDeployment200Response.ts +0 -36
  75. package/model/createFunctionDeploymentV1Output.ts +0 -39
  76. package/model/createFunctionV1Input.ts +0 -94
  77. package/model/createFunctionV1Output.ts +0 -39
  78. package/model/createInvites200Response.ts +0 -36
  79. package/model/createInvitesV1Input.ts +0 -42
  80. package/model/createInvitesV1Output.ts +0 -41
  81. package/model/createLabel200Response.ts +0 -36
  82. package/model/createLabel200Response1.ts +0 -36
  83. package/model/createLabelAlphaInput.ts +0 -39
  84. package/model/createLabelAlphaOutput.ts +0 -42
  85. package/model/createLabelV1Input.ts +0 -39
  86. package/model/createLabelV1Output.ts +0 -39
  87. package/model/createSource200Response.ts +0 -36
  88. package/model/createSource200Response1.ts +0 -36
  89. package/model/createSourceAlphaInput.ts +0 -77
  90. package/model/createSourceAlphaOutput.ts +0 -39
  91. package/model/createSourceRegulation200Response.ts +0 -36
  92. package/model/createSourceRegulationV1Input.ts +0 -73
  93. package/model/createSourceRegulationV1Output.ts +0 -41
  94. package/model/createSourceV1Input.ts +0 -68
  95. package/model/createSourceV1Output.ts +0 -39
  96. package/model/createTrackingPlan200Response.ts +0 -36
  97. package/model/createTrackingPlanV1Input.ts +0 -68
  98. package/model/createTrackingPlanV1Output.ts +0 -39
  99. package/model/createTransformation200Response.ts +0 -36
  100. package/model/createTransformationBetaInput.ts +0 -96
  101. package/model/createTransformationBetaOutput.ts +0 -39
  102. package/model/createUserGroup200Response.ts +0 -36
  103. package/model/createUserGroupV1Input.ts +0 -41
  104. package/model/createUserGroupV1Output.ts +0 -39
  105. package/model/createValidationInWarehouse200Response.ts +0 -36
  106. package/model/createValidationInWarehouseV1Input.ts +0 -50
  107. package/model/createValidationInWarehouseV1Output.ts +0 -48
  108. package/model/createWarehouse200Response.ts +0 -36
  109. package/model/createWarehouseV1Input.ts +0 -68
  110. package/model/createWarehouseV1Output.ts +0 -39
  111. package/model/createWorkspaceRegulation200Response.ts +0 -36
  112. package/model/createWorkspaceRegulationV1Input.ts +0 -74
  113. package/model/createWorkspaceRegulationV1Output.ts +0 -41
  114. package/model/deleteDestination200Response.ts +0 -36
  115. package/model/deleteDestinationV1Output.ts +0 -47
  116. package/model/deleteFunction200Response.ts +0 -36
  117. package/model/deleteFunctionV1Output.ts +0 -47
  118. package/model/deleteInvites200Response.ts +0 -36
  119. package/model/deleteInvitesV1Output.ts +0 -47
  120. package/model/deleteLabel200Response.ts +0 -36
  121. package/model/deleteLabel200Response1.ts +0 -36
  122. package/model/deleteLabelAlphaOutput.ts +0 -47
  123. package/model/deleteLabelV1Output.ts +0 -47
  124. package/model/deleteRegulation200Response.ts +0 -36
  125. package/model/deleteRegulationV1Output.ts +0 -47
  126. package/model/deleteSource200Response.ts +0 -36
  127. package/model/deleteSource200Response1.ts +0 -36
  128. package/model/deleteSourceAlphaOutput.ts +0 -47
  129. package/model/deleteSourceV1Output.ts +0 -47
  130. package/model/deleteTrackingPlan200Response.ts +0 -36
  131. package/model/deleteTrackingPlanV1Output.ts +0 -47
  132. package/model/deleteTransformation200Response.ts +0 -36
  133. package/model/deleteTransformationBetaOutput.ts +0 -47
  134. package/model/deleteUserGroup200Response.ts +0 -36
  135. package/model/deleteUserGroupV1Output.ts +0 -47
  136. package/model/deleteUsers200Response.ts +0 -36
  137. package/model/deleteUsersV1Output.ts +0 -47
  138. package/model/deleteWarehouse200Response.ts +0 -36
  139. package/model/deleteWarehouseV1Output.ts +0 -47
  140. package/model/deliveryMetricsSummary.ts +0 -60
  141. package/model/deliveryMetricsSummaryBeta.ts +0 -60
  142. package/model/destination.ts +0 -84
  143. package/model/destination1.ts +0 -84
  144. package/model/destination2.ts +0 -84
  145. package/model/destinationFilterActionV1.ts +0 -77
  146. package/model/destinationFilterV1.ts +0 -123
  147. package/model/destinationMetadata.ts +0 -184
  148. package/model/destinationMetadataActionFieldV1.ts +0 -163
  149. package/model/destinationMetadataActionV1.ts +0 -113
  150. package/model/destinationMetadataComponentV1.ts +0 -72
  151. package/model/destinationMetadataFeaturesV1.ts +0 -93
  152. package/model/destinationMetadataMethodsV1.ts +0 -77
  153. package/model/destinationMetadataPlatformsV1.ts +0 -59
  154. package/model/destinationMetadataSubscriptionPresetV1.ts +0 -68
  155. package/model/destinationMetadataV1.ts +0 -184
  156. package/model/destinationStatusV1.ts +0 -74
  157. package/model/destinationSubscription.ts +0 -104
  158. package/model/destinationSubscriptionUpdateInput.ts +0 -68
  159. package/model/destinationV1.ts +0 -84
  160. package/model/disableEdgeFunctions200Response.ts +0 -36
  161. package/model/disableEdgeFunctionsAlphaOutput.ts +0 -39
  162. package/model/echo200Response.ts +0 -36
  163. package/model/echo200Response1.ts +0 -36
  164. package/model/echoAlphaOutput.ts +0 -66
  165. package/model/echoV1Output.ts +0 -66
  166. package/model/edgeFunctions.ts +0 -86
  167. package/model/edgeFunctions1.ts +0 -86
  168. package/model/edgeFunctionsAlpha.ts +0 -86
  169. package/model/eventSourceV1.ts +0 -59
  170. package/model/filter.ts +0 -51
  171. package/model/filter1.ts +0 -123
  172. package/model/filter2.ts +0 -123
  173. package/model/filter3.ts +0 -123
  174. package/model/function.ts +0 -166
  175. package/model/function1.ts +0 -166
  176. package/model/function2.ts +0 -166
  177. package/model/functionDeployment.ts +0 -44
  178. package/model/functionSettingV1.ts +0 -92
  179. package/model/functionV1.ts +0 -166
  180. package/model/generateUploadURLForEdgeFunctions200Response.ts +0 -36
  181. package/model/generateUploadURLForEdgeFunctionsAlphaOutput.ts +0 -41
  182. package/model/getAdvancedSyncScheduleFromWarehouse200Response.ts +0 -36
  183. package/model/getAdvancedSyncScheduleFromWarehouseV1Output.ts +0 -48
  184. package/model/getConnectionStateFromWarehouse200Response.ts +0 -36
  185. package/model/getConnectionStateFromWarehouseV1Output.ts +0 -48
  186. package/model/getDailyPerSourceAPICallsUsage200Response.ts +0 -36
  187. package/model/getDailyPerSourceAPICallsUsageV1Output.ts +0 -49
  188. package/model/getDailyPerSourceMTUUsage200Response.ts +0 -36
  189. package/model/getDailyPerSourceMTUUsageV1Output.ts +0 -49
  190. package/model/getDailyWorkspaceAPICallsUsage200Response.ts +0 -36
  191. package/model/getDailyWorkspaceAPICallsUsageV1Output.ts +0 -49
  192. package/model/getDailyWorkspaceMTUUsage200Response.ts +0 -36
  193. package/model/getDailyWorkspaceMTUUsageV1Output.ts +0 -49
  194. package/model/getDestination200Response.ts +0 -36
  195. package/model/getDestinationMetadata200Response.ts +0 -36
  196. package/model/getDestinationMetadataV1Output.ts +0 -39
  197. package/model/getDestinationV1Output.ts +0 -39
  198. package/model/getDestinationsCatalog200Response.ts +0 -36
  199. package/model/getDestinationsCatalogV1Output.ts +0 -49
  200. package/model/getEventsVolumeFromWorkspace200Response.ts +0 -36
  201. package/model/getEventsVolumeFromWorkspaceV1Output.ts +0 -49
  202. package/model/getFilterInDestination200Response.ts +0 -36
  203. package/model/getFilterInDestinationV1Output.ts +0 -39
  204. package/model/getFunction200Response.ts +0 -36
  205. package/model/getFunctionV1Output.ts +0 -39
  206. package/model/getLatestFromEdgeFunctions200Response.ts +0 -36
  207. package/model/getLatestFromEdgeFunctionsAlphaOutput.ts +0 -39
  208. package/model/getMessagingSubscriptionFailureResponse.ts +0 -57
  209. package/model/getMessagingSubscriptionSuccessResponse.ts +0 -68
  210. package/model/getRegulation200Response.ts +0 -36
  211. package/model/getRegulationV1Output.ts +0 -39
  212. package/model/getSource200Response.ts +0 -36
  213. package/model/getSource200Response1.ts +0 -36
  214. package/model/getSourceAlphaOutput.ts +0 -39
  215. package/model/getSourceMetadata200Response.ts +0 -36
  216. package/model/getSourceMetadataV1Output.ts +0 -39
  217. package/model/getSourceV1Output.ts +0 -39
  218. package/model/getSourcesCatalog200Response.ts +0 -36
  219. package/model/getSourcesCatalogV1Output.ts +0 -49
  220. package/model/getSpace200Response.ts +0 -36
  221. package/model/getSpaceAlphaOutput.ts +0 -39
  222. package/model/getSubscriptionFromDestination200Response.ts +0 -36
  223. package/model/getSubscriptionFromDestinationAlphaOutput.ts +0 -39
  224. package/model/getSubscriptionRequest.ts +0 -54
  225. package/model/getTrackingPlan200Response.ts +0 -36
  226. package/model/getTrackingPlanV1Output.ts +0 -39
  227. package/model/getTransformation200Response.ts +0 -36
  228. package/model/getTransformationBetaOutput.ts +0 -39
  229. package/model/getUser200Response.ts +0 -36
  230. package/model/getUserGroup200Response.ts +0 -36
  231. package/model/getUserGroupV1Output.ts +0 -39
  232. package/model/getUserV1Output.ts +0 -39
  233. package/model/getWarehouse200Response.ts +0 -36
  234. package/model/getWarehouseMetadata200Response.ts +0 -36
  235. package/model/getWarehouseMetadataV1Output.ts +0 -39
  236. package/model/getWarehouseV1Output.ts +0 -39
  237. package/model/getWarehousesCatalog200Response.ts +0 -36
  238. package/model/getWarehousesCatalogV1Output.ts +0 -49
  239. package/model/getWorkspace200Response.ts +0 -36
  240. package/model/getWorkspaceV1Output.ts +0 -39
  241. package/model/group.ts +0 -67
  242. package/model/groupSourceSettingsV1.ts +0 -64
  243. package/model/identify.ts +0 -67
  244. package/model/identifySourceSettingsV1.ts +0 -64
  245. package/model/input.ts +0 -68
  246. package/model/integrationOptionBeta.ts +0 -86
  247. package/model/invitePermissionV1.ts +0 -61
  248. package/model/inviteV1.ts +0 -51
  249. package/model/label.ts +0 -59
  250. package/model/label1.ts +0 -59
  251. package/model/label2.ts +0 -59
  252. package/model/labelAlpha.ts +0 -59
  253. package/model/labelV1.ts +0 -59
  254. package/model/listAuditEvents200Response.ts +0 -36
  255. package/model/listAuditEventsV1Output.ts +0 -49
  256. package/model/listConnectedDestinationsFromSource200Response.ts +0 -36
  257. package/model/listConnectedDestinationsFromSource200Response1.ts +0 -36
  258. package/model/listConnectedDestinationsFromSourceAlphaOutput.ts +0 -49
  259. package/model/listConnectedDestinationsFromSourceV1Output.ts +0 -49
  260. package/model/listConnectedSourcesFromWarehouse200Response.ts +0 -36
  261. package/model/listConnectedSourcesFromWarehouseV1Output.ts +0 -49
  262. package/model/listConnectedWarehousesFromSource200Response.ts +0 -36
  263. package/model/listConnectedWarehousesFromSource200Response1.ts +0 -36
  264. package/model/listConnectedWarehousesFromSourceAlphaOutput.ts +0 -49
  265. package/model/listConnectedWarehousesFromSourceV1Output.ts +0 -49
  266. package/model/listDeliveryMetricsSummaryFromDestination200Response.ts +0 -36
  267. package/model/listDeliveryMetricsSummaryFromDestinationBetaOutput.ts +0 -39
  268. package/model/listDestinations200Response.ts +0 -36
  269. package/model/listDestinationsV1Output.ts +0 -49
  270. package/model/listFiltersFromDestination200Response.ts +0 -36
  271. package/model/listFiltersFromDestinationV1Output.ts +0 -49
  272. package/model/listFunctionItemV1.ts +0 -111
  273. package/model/listFunctions200Response.ts +0 -36
  274. package/model/listFunctionsV1Output.ts +0 -49
  275. package/model/listInvites200Response.ts +0 -36
  276. package/model/listInvitesFromUserGroup200Response.ts +0 -36
  277. package/model/listInvitesFromUserGroupV1Output.ts +0 -48
  278. package/model/listInvitesV1Output.ts +0 -48
  279. package/model/listLabels200Response.ts +0 -36
  280. package/model/listLabels200Response1.ts +0 -36
  281. package/model/listLabelsAlphaOutput.ts +0 -42
  282. package/model/listLabelsV1Output.ts +0 -42
  283. package/model/listRegulationsFromSource200Response.ts +0 -36
  284. package/model/listRegulationsFromSourceV1Output.ts +0 -42
  285. package/model/listRoles200Response.ts +0 -36
  286. package/model/listRolesV1Output.ts +0 -49
  287. package/model/listRulesFromTrackingPlan200Response.ts +0 -36
  288. package/model/listRulesFromTrackingPlanV1Output.ts +0 -49
  289. package/model/listSchemaSettingsInSource200Response.ts +0 -36
  290. package/model/listSchemaSettingsInSourceV1Output.ts +0 -48
  291. package/model/listSelectiveSyncsFromWarehouseAndSource200Response.ts +0 -36
  292. package/model/listSelectiveSyncsFromWarehouseAndSourceV1Output.ts +0 -49
  293. package/model/listSources200Response.ts +0 -36
  294. package/model/listSources200Response1.ts +0 -36
  295. package/model/listSourcesAlphaOutput.ts +0 -49
  296. package/model/listSourcesFromTrackingPlan200Response.ts +0 -36
  297. package/model/listSourcesFromTrackingPlanV1Output.ts +0 -49
  298. package/model/listSourcesV1Output.ts +0 -49
  299. package/model/listSubscriptionsFromDestination200Response.ts +0 -36
  300. package/model/listSubscriptionsFromDestinationAlphaOutput.ts +0 -49
  301. package/model/listSuppressions200Response.ts +0 -36
  302. package/model/listSuppressionsV1Output.ts +0 -49
  303. package/model/listSyncsFromWarehouse200Response.ts +0 -36
  304. package/model/listSyncsFromWarehouseAndSource200Response.ts +0 -36
  305. package/model/listSyncsFromWarehouseAndSourceV1Output.ts +0 -49
  306. package/model/listSyncsFromWarehouseV1Output.ts +0 -49
  307. package/model/listTrackingPlans200Response.ts +0 -36
  308. package/model/listTrackingPlansV1Output.ts +0 -49
  309. package/model/listTransformations200Response.ts +0 -36
  310. package/model/listTransformationsBetaOutput.ts +0 -49
  311. package/model/listUserGroups200Response.ts +0 -36
  312. package/model/listUserGroupsFromUser200Response.ts +0 -36
  313. package/model/listUserGroupsFromUserV1Output.ts +0 -49
  314. package/model/listUserGroupsV1Output.ts +0 -49
  315. package/model/listUsers200Response.ts +0 -36
  316. package/model/listUsersFromUserGroup200Response.ts +0 -36
  317. package/model/listUsersFromUserGroupV1Output.ts +0 -49
  318. package/model/listUsersV1Output.ts +0 -49
  319. package/model/listWarehouses200Response.ts +0 -36
  320. package/model/listWarehousesV1Output.ts +0 -49
  321. package/model/listWorkspaceRegulations200Response.ts +0 -36
  322. package/model/listWorkspaceRegulationsV1Output.ts +0 -49
  323. package/model/logos.ts +0 -59
  324. package/model/logos1.ts +0 -59
  325. package/model/logos2.ts +0 -59
  326. package/model/logosBeta.ts +0 -59
  327. package/model/messageSubscriptionResponse.ts +0 -78
  328. package/model/messageSubscriptionResponseError.ts +0 -47
  329. package/model/messagesSubscriptionRequest.ts +0 -68
  330. package/model/metadata.ts +0 -184
  331. package/model/metadata1.ts +0 -103
  332. package/model/metadata2.ts +0 -85
  333. package/model/metricBeta.ts +0 -60
  334. package/model/minimalUserGroupV1.ts +0 -50
  335. package/model/minimalUserV1.ts +0 -59
  336. package/model/models.ts +0 -1835
  337. package/model/mtuSnapshotV1.ts +0 -95
  338. package/model/pagination.ts +0 -68
  339. package/model/paginationInput.ts +0 -50
  340. package/model/paginationOutput.ts +0 -68
  341. package/model/permissionInputV1.ts +0 -51
  342. package/model/permissionResourceV1.ts +0 -70
  343. package/model/permissionV1.ts +0 -70
  344. package/model/previewDestinationFilter200Response.ts +0 -36
  345. package/model/previewDestinationFilterV1.ts +0 -51
  346. package/model/previewDestinationFilterV1Input.ts +0 -48
  347. package/model/previewDestinationFilterV1Output.ts +0 -50
  348. package/model/propertyRenameBeta.ts +0 -47
  349. package/model/regulation.ts +0 -99
  350. package/model/regulationListEntryV1.ts +0 -77
  351. package/model/removeFilterFromDestination200Response.ts +0 -36
  352. package/model/removeFilterFromDestinationV1Output.ts +0 -47
  353. package/model/removeRuleV1.ts +0 -61
  354. package/model/removeRulesFromTrackingPlan200Response.ts +0 -36
  355. package/model/removeRulesFromTrackingPlanV1Output.ts +0 -47
  356. package/model/removeSourceConnectionFromWarehouse200Response.ts +0 -36
  357. package/model/removeSourceConnectionFromWarehouseV1Output.ts +0 -47
  358. package/model/removeSourceFromTrackingPlan200Response.ts +0 -36
  359. package/model/removeSourceFromTrackingPlanV1Output.ts +0 -47
  360. package/model/removeSubscriptionFromDestination200Response.ts +0 -36
  361. package/model/removeSubscriptionFromDestinationAlphaOutput.ts +0 -47
  362. package/model/removeUsersFromUserGroup200Response.ts +0 -36
  363. package/model/removeUsersFromUserGroupV1Output.ts +0 -47
  364. package/model/replaceAdvancedSyncScheduleForWarehouse200Response.ts +0 -36
  365. package/model/replaceAdvancedSyncScheduleForWarehouseV1Input.ts +0 -48
  366. package/model/replaceAdvancedSyncScheduleForWarehouseV1Output.ts +0 -48
  367. package/model/replaceLabelsInSource200Response.ts +0 -36
  368. package/model/replaceLabelsInSource200Response1.ts +0 -36
  369. package/model/replaceLabelsInSourceAlphaInput.ts +0 -42
  370. package/model/replaceLabelsInSourceAlphaOutput.ts +0 -42
  371. package/model/replaceLabelsInSourceV1Input.ts +0 -42
  372. package/model/replaceLabelsInSourceV1Output.ts +0 -42
  373. package/model/replaceMessagingSubscriptionsInSpaces200Response.ts +0 -36
  374. package/model/replaceMessagingSubscriptionsInSpacesAlphaInput.ts +0 -42
  375. package/model/replaceMessagingSubscriptionsInSpacesAlphaOutput.ts +0 -58
  376. package/model/replacePermissionsForUser200Response.ts +0 -36
  377. package/model/replacePermissionsForUserGroup200Response.ts +0 -36
  378. package/model/replacePermissionsForUserGroupV1Input.ts +0 -42
  379. package/model/replacePermissionsForUserGroupV1Output.ts +0 -42
  380. package/model/replacePermissionsForUserV1Input.ts +0 -42
  381. package/model/replacePermissionsForUserV1Output.ts +0 -42
  382. package/model/replaceRulesInTrackingPlan200Response.ts +0 -36
  383. package/model/replaceRulesInTrackingPlanV1Input.ts +0 -42
  384. package/model/replaceRulesInTrackingPlanV1Output.ts +0 -47
  385. package/model/replaceUsersInUserGroup200Response.ts +0 -36
  386. package/model/replaceUsersInUserGroupV1Input.ts +0 -41
  387. package/model/replaceUsersInUserGroupV1Output.ts +0 -39
  388. package/model/requestError.ts +0 -77
  389. package/model/requestErrorEnvelope.ts +0 -39
  390. package/model/resourceV1.ts +0 -60
  391. package/model/roleV1.ts +0 -59
  392. package/model/ruleV1.ts +0 -106
  393. package/model/schedule.ts +0 -51
  394. package/model/schedule1.ts +0 -51
  395. package/model/schedule2.ts +0 -51
  396. package/model/settings.ts +0 -71
  397. package/model/settings1.ts +0 -71
  398. package/model/source.ts +0 -59
  399. package/model/source1.ts +0 -112
  400. package/model/source2.ts +0 -112
  401. package/model/source3.ts +0 -112
  402. package/model/source4.ts +0 -112
  403. package/model/source5.ts +0 -112
  404. package/model/source6.ts +0 -112
  405. package/model/sourceAPICallSnapshotV1.ts +0 -59
  406. package/model/sourceAlpha.ts +0 -112
  407. package/model/sourceEventVolumeDatapointV1.ts +0 -50
  408. package/model/sourceEventVolumeV1.ts +0 -76
  409. package/model/sourceMetadata.ts +0 -103
  410. package/model/sourceMetadataV1.ts +0 -103
  411. package/model/sourceSettingsOutputV1.ts +0 -71
  412. package/model/sourceV1.ts +0 -112
  413. package/model/space.ts +0 -50
  414. package/model/streamStatusV1.ts +0 -45
  415. package/model/subscription.ts +0 -104
  416. package/model/supportedFeatures.ts +0 -93
  417. package/model/supportedMethods.ts +0 -77
  418. package/model/supportedPlatforms.ts +0 -59
  419. package/model/suppressedInner.ts +0 -41
  420. package/model/syncNoticeV1.ts +0 -59
  421. package/model/syncV1.ts +0 -105
  422. package/model/track.ts +0 -85
  423. package/model/trackSourceSettingsV1.ts +0 -82
  424. package/model/trackingPlan.ts +0 -104
  425. package/model/trackingPlan1.ts +0 -104
  426. package/model/trackingPlanV1.ts +0 -104
  427. package/model/transformation.ts +0 -105
  428. package/model/transformation1.ts +0 -105
  429. package/model/transformation2.ts +0 -105
  430. package/model/transformationBeta.ts +0 -105
  431. package/model/updateDestination200Response.ts +0 -36
  432. package/model/updateDestinationV1Input.ts +0 -59
  433. package/model/updateDestinationV1Output.ts +0 -39
  434. package/model/updateFilterForDestination200Response.ts +0 -36
  435. package/model/updateFilterForDestinationV1Input.ts +0 -78
  436. package/model/updateFilterForDestinationV1Output.ts +0 -39
  437. package/model/updateFunction200Response.ts +0 -36
  438. package/model/updateFunctionV1Input.ts +0 -78
  439. package/model/updateFunctionV1Output.ts +0 -39
  440. package/model/updateRulesInTrackingPlan200Response.ts +0 -36
  441. package/model/updateRulesInTrackingPlanV1Input.ts +0 -42
  442. package/model/updateRulesInTrackingPlanV1Output.ts +0 -47
  443. package/model/updateSchemaSettingsInSource200Response.ts +0 -36
  444. package/model/updateSchemaSettingsInSourceV1Input.ts +0 -71
  445. package/model/updateSchemaSettingsInSourceV1Output.ts +0 -48
  446. package/model/updateSelectiveSyncForWarehouse200Response.ts +0 -36
  447. package/model/updateSelectiveSyncForWarehouseV1Input.ts +0 -42
  448. package/model/updateSelectiveSyncForWarehouseV1Output.ts +0 -57
  449. package/model/updateSource200Response.ts +0 -36
  450. package/model/updateSource200Response1.ts +0 -36
  451. package/model/updateSourceAlphaInput.ts +0 -68
  452. package/model/updateSourceAlphaOutput.ts +0 -39
  453. package/model/updateSourceV1Input.ts +0 -68
  454. package/model/updateSourceV1Output.ts +0 -39
  455. package/model/updateSubscriptionForDestination200Response.ts +0 -36
  456. package/model/updateSubscriptionForDestinationAlphaInput.ts +0 -39
  457. package/model/updateSubscriptionForDestinationAlphaOutput.ts +0 -39
  458. package/model/updateTrackingPlan200Response.ts +0 -36
  459. package/model/updateTrackingPlanV1Input.ts +0 -50
  460. package/model/updateTrackingPlanV1Output.ts +0 -47
  461. package/model/updateTransformation200Response.ts +0 -36
  462. package/model/updateTransformationBetaInput.ts +0 -96
  463. package/model/updateTransformationBetaOutput.ts +0 -39
  464. package/model/updateUserGroup200Response.ts +0 -36
  465. package/model/updateUserGroupV1Input.ts +0 -41
  466. package/model/updateUserGroupV1Output.ts +0 -39
  467. package/model/updateWarehouse200Response.ts +0 -36
  468. package/model/updateWarehouseV1Input.ts +0 -59
  469. package/model/updateWarehouseV1Output.ts +0 -39
  470. package/model/upsertRuleV1.ts +0 -112
  471. package/model/user.ts +0 -69
  472. package/model/userGroup.ts +0 -69
  473. package/model/userGroup1.ts +0 -69
  474. package/model/userGroup2.ts +0 -69
  475. package/model/userGroup3.ts +0 -69
  476. package/model/userGroupV1.ts +0 -69
  477. package/model/userV1.ts +0 -69
  478. package/model/usersPerSourceSnapshotV1.ts +0 -104
  479. package/model/warehouse.ts +0 -75
  480. package/model/warehouse1.ts +0 -75
  481. package/model/warehouse2.ts +0 -75
  482. package/model/warehouseAdvancedSyncV1.ts +0 -50
  483. package/model/warehouseMetadata.ts +0 -85
  484. package/model/warehouseMetadataV1.ts +0 -85
  485. package/model/warehouseSelectiveSyncItemV1.ts +0 -68
  486. package/model/warehouseSyncOverrideV1.ts +0 -68
  487. package/model/warehouseV1.ts +0 -75
  488. package/model/workspace.ts +0 -59
  489. package/model/workspaceV1.ts +0 -59
  490. package/tests/__snapshots__/smoke.test.ts.snap +0 -889
  491. package/tests/smoke.test.ts +0 -267
  492. package/tsconfig.json +0 -20
@@ -1,1316 +0,0 @@
1
- /**
2
- * Segment Public API
3
- * The Segment Public API helps you manage your Segment Workspaces and its resources. You can use the API to perform CRUD (create, read, update, delete) operations at no extra charge. This includes working with resources such as Sources, Destinations, Warehouses, Tracking Plans, and the Segment Destinations and Sources Catalogs. All CRUD endpoints in the API follow REST conventions and use standard HTTP methods. Different URL endpoints represent different resources in a Workspace. See the next sections for more information on how to use the Segment Public API.
4
- *
5
- * The version of the OpenAPI document: 32.0.1
6
- * Contact: friends@segment.com
7
- *
8
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
- * https://openapi-generator.tech
10
- * Do not edit the class manually.
11
- */
12
-
13
- import localVarRequest from 'request';
14
- import http from 'http';
15
-
16
- /* tslint:disable:no-unused-locals */
17
- import { CreateTransformation200Response } from '../model/createTransformation200Response';
18
- import { CreateTransformationBetaInput } from '../model/createTransformationBetaInput';
19
- import { DeleteTransformation200Response } from '../model/deleteTransformation200Response';
20
- import { GetTransformation200Response } from '../model/getTransformation200Response';
21
- import { ListTransformations200Response } from '../model/listTransformations200Response';
22
- import { PaginationInput } from '../model/paginationInput';
23
- import { RequestErrorEnvelope } from '../model/requestErrorEnvelope';
24
- import { UpdateTransformation200Response } from '../model/updateTransformation200Response';
25
- import { UpdateTransformationBetaInput } from '../model/updateTransformationBetaInput';
26
-
27
- import {
28
- ObjectSerializer,
29
- Authentication,
30
- VoidAuth,
31
- Interceptor,
32
- } from '../model/models';
33
- import {
34
- HttpBasicAuth,
35
- HttpBearerAuth,
36
- ApiKeyAuth,
37
- OAuth,
38
- } from '../model/models';
39
-
40
- import { HttpError, RequestFile } from './apis';
41
-
42
- let defaultBasePath = 'https://api.segmentapis.com';
43
-
44
- // ===============================================
45
- // This file is autogenerated - Please do not edit
46
- // ===============================================
47
-
48
- export enum TransformationsApiApiKeys {}
49
-
50
- export class TransformationsApi {
51
- protected _basePath = defaultBasePath;
52
- protected _defaultHeaders: any = {};
53
- protected _useQuerystring: boolean = false;
54
-
55
- protected authentications = {
56
- default: <Authentication>new VoidAuth(),
57
- token: new HttpBearerAuth(),
58
- };
59
-
60
- protected interceptors: Interceptor[] = [];
61
-
62
- constructor(basePath?: string);
63
- constructor(
64
- basePathOrUsername: string,
65
- password?: string,
66
- basePath?: string
67
- ) {
68
- if (password) {
69
- if (basePath) {
70
- this.basePath = basePath;
71
- }
72
- } else {
73
- if (basePathOrUsername) {
74
- this.basePath = basePathOrUsername;
75
- }
76
- }
77
- }
78
-
79
- set useQuerystring(value: boolean) {
80
- this._useQuerystring = value;
81
- }
82
-
83
- set basePath(basePath: string) {
84
- this._basePath = basePath;
85
- }
86
-
87
- set defaultHeaders(defaultHeaders: any) {
88
- this._defaultHeaders = defaultHeaders;
89
- }
90
-
91
- get defaultHeaders() {
92
- return this._defaultHeaders;
93
- }
94
-
95
- get basePath() {
96
- return this._basePath;
97
- }
98
-
99
- public setDefaultAuthentication(auth: Authentication) {
100
- this.authentications.default = auth;
101
- }
102
-
103
- public setApiKey(key: TransformationsApiApiKeys, value: string) {
104
- (this.authentications as any)[TransformationsApiApiKeys[key]].apiKey =
105
- value;
106
- }
107
-
108
- set accessToken(accessToken: string | (() => string)) {
109
- this.authentications.token.accessToken = accessToken;
110
- }
111
-
112
- public addInterceptor(interceptor: Interceptor) {
113
- this.interceptors.push(interceptor);
114
- }
115
-
116
- /**
117
- * Creates a new Transformation. When called, this endpoint may generate the `Transformation Created` [Audit Trail](/tag/Audit-Trail) event. **Note**: In order to successfully call this endpoint, the specified Workspace needs to have the Protocols feature enabled. Please reach out to your customer success manager for more information.
118
- * @summary Create Transformation
119
- * @param CreateTransformationBetaInput
120
- */
121
- public async createTransformationAlpha(
122
- CreateTransformationBetaInput: CreateTransformationBetaInput,
123
- options: { headers: { [name: string]: string } } = { headers: {} }
124
- ): Promise<{
125
- response: http.IncomingMessage;
126
- body: CreateTransformation200Response;
127
- }> {
128
- const localVarPath = this.basePath + '/transformations';
129
- let localVarQueryParameters: any = {};
130
- let localVarHeaderParams: any = (<any>Object).assign(
131
- {},
132
- this._defaultHeaders
133
- );
134
- const produces = [
135
- 'application/vnd.segment.v1alpha+json',
136
- 'application/json',
137
- ];
138
- if (produces.indexOf('application/json') >= 0) {
139
- localVarHeaderParams.Accept = produces[0];
140
- } else {
141
- localVarHeaderParams.Accept = 'application/json';
142
- }
143
- let localVarFormParams: any = {};
144
-
145
- // verify required parameter 'CreateTransformationBetaInput' is not null or undefined
146
- if (
147
- CreateTransformationBetaInput === null ||
148
- CreateTransformationBetaInput === undefined
149
- ) {
150
- throw new Error(
151
- 'Required parameter CreateTransformationBetaInput was null or undefined when calling createTransformationAlpha.'
152
- );
153
- }
154
-
155
- (<any>Object).assign(localVarHeaderParams, options.headers);
156
-
157
- let localVarUseFormData = false;
158
-
159
- let localVarRequestOptions: localVarRequest.Options = {
160
- method: 'POST',
161
- qs: localVarQueryParameters,
162
- headers: localVarHeaderParams,
163
- uri: localVarPath,
164
- useQuerystring: this._useQuerystring,
165
- json: true,
166
- body: ObjectSerializer.serialize(
167
- CreateTransformationBetaInput,
168
- 'CreateTransformationBetaInput'
169
- ),
170
- };
171
-
172
- let authenticationPromise = Promise.resolve();
173
- if (this.authentications.token.accessToken) {
174
- authenticationPromise = authenticationPromise.then(() =>
175
- this.authentications.token.applyToRequest(
176
- localVarRequestOptions
177
- )
178
- );
179
- }
180
- authenticationPromise = authenticationPromise.then(() =>
181
- this.authentications.default.applyToRequest(localVarRequestOptions)
182
- );
183
-
184
- let interceptorPromise = authenticationPromise;
185
- for (const interceptor of this.interceptors) {
186
- interceptorPromise = interceptorPromise.then(() =>
187
- interceptor(localVarRequestOptions)
188
- );
189
- }
190
-
191
- return interceptorPromise.then(() => {
192
- if (Object.keys(localVarFormParams).length) {
193
- if (localVarUseFormData) {
194
- (<any>localVarRequestOptions).formData = localVarFormParams;
195
- } else {
196
- localVarRequestOptions.form = localVarFormParams;
197
- }
198
- }
199
- return new Promise<{
200
- response: http.IncomingMessage;
201
- body: CreateTransformation200Response;
202
- }>((resolve, reject) => {
203
- localVarRequest(
204
- localVarRequestOptions,
205
- (error, response, body) => {
206
- if (error) {
207
- reject(error);
208
- } else {
209
- if (
210
- response.statusCode &&
211
- response.statusCode >= 200 &&
212
- response.statusCode <= 299
213
- ) {
214
- body = ObjectSerializer.deserialize(
215
- body,
216
- 'CreateTransformation200Response'
217
- );
218
- resolve({ response: response, body: body });
219
- } else {
220
- reject(
221
- new HttpError(
222
- response,
223
- body,
224
- response.statusCode
225
- )
226
- );
227
- }
228
- }
229
- }
230
- );
231
- });
232
- });
233
- }
234
- /**
235
- * Creates a new Transformation. When called, this endpoint may generate the `Transformation Created` [Audit Trail](/tag/Audit-Trail) event. **Note**: In order to successfully call this endpoint, the specified Workspace needs to have the Protocols feature enabled. Please reach out to your customer success manager for more information.
236
- * @summary Create Transformation
237
- * @param CreateTransformationBetaInput
238
- */
239
- public async createTransformationBeta(
240
- CreateTransformationBetaInput: CreateTransformationBetaInput,
241
- options: { headers: { [name: string]: string } } = { headers: {} }
242
- ): Promise<{
243
- response: http.IncomingMessage;
244
- body: CreateTransformation200Response;
245
- }> {
246
- const localVarPath = this.basePath + '/transformations';
247
- let localVarQueryParameters: any = {};
248
- let localVarHeaderParams: any = (<any>Object).assign(
249
- {},
250
- this._defaultHeaders
251
- );
252
- const produces = [
253
- 'application/vnd.segment.v1beta+json',
254
- 'application/json',
255
- ];
256
- if (produces.indexOf('application/json') >= 0) {
257
- localVarHeaderParams.Accept = produces[0];
258
- } else {
259
- localVarHeaderParams.Accept = 'application/json';
260
- }
261
- let localVarFormParams: any = {};
262
-
263
- // verify required parameter 'CreateTransformationBetaInput' is not null or undefined
264
- if (
265
- CreateTransformationBetaInput === null ||
266
- CreateTransformationBetaInput === undefined
267
- ) {
268
- throw new Error(
269
- 'Required parameter CreateTransformationBetaInput was null or undefined when calling createTransformationBeta.'
270
- );
271
- }
272
-
273
- (<any>Object).assign(localVarHeaderParams, options.headers);
274
-
275
- let localVarUseFormData = false;
276
-
277
- let localVarRequestOptions: localVarRequest.Options = {
278
- method: 'POST',
279
- qs: localVarQueryParameters,
280
- headers: localVarHeaderParams,
281
- uri: localVarPath,
282
- useQuerystring: this._useQuerystring,
283
- json: true,
284
- body: ObjectSerializer.serialize(
285
- CreateTransformationBetaInput,
286
- 'CreateTransformationBetaInput'
287
- ),
288
- };
289
-
290
- let authenticationPromise = Promise.resolve();
291
- if (this.authentications.token.accessToken) {
292
- authenticationPromise = authenticationPromise.then(() =>
293
- this.authentications.token.applyToRequest(
294
- localVarRequestOptions
295
- )
296
- );
297
- }
298
- authenticationPromise = authenticationPromise.then(() =>
299
- this.authentications.default.applyToRequest(localVarRequestOptions)
300
- );
301
-
302
- let interceptorPromise = authenticationPromise;
303
- for (const interceptor of this.interceptors) {
304
- interceptorPromise = interceptorPromise.then(() =>
305
- interceptor(localVarRequestOptions)
306
- );
307
- }
308
-
309
- return interceptorPromise.then(() => {
310
- if (Object.keys(localVarFormParams).length) {
311
- if (localVarUseFormData) {
312
- (<any>localVarRequestOptions).formData = localVarFormParams;
313
- } else {
314
- localVarRequestOptions.form = localVarFormParams;
315
- }
316
- }
317
- return new Promise<{
318
- response: http.IncomingMessage;
319
- body: CreateTransformation200Response;
320
- }>((resolve, reject) => {
321
- localVarRequest(
322
- localVarRequestOptions,
323
- (error, response, body) => {
324
- if (error) {
325
- reject(error);
326
- } else {
327
- if (
328
- response.statusCode &&
329
- response.statusCode >= 200 &&
330
- response.statusCode <= 299
331
- ) {
332
- body = ObjectSerializer.deserialize(
333
- body,
334
- 'CreateTransformation200Response'
335
- );
336
- resolve({ response: response, body: body });
337
- } else {
338
- reject(
339
- new HttpError(
340
- response,
341
- body,
342
- response.statusCode
343
- )
344
- );
345
- }
346
- }
347
- }
348
- );
349
- });
350
- });
351
- }
352
- /**
353
- * Deletes a Transformation. When called, this endpoint may generate the `Transformation Deleted` [Audit Trail](/tag/Audit-Trail) event. **Note**: In order to successfully call this endpoint, the specified Workspace needs to have the Protocols feature enabled. Please reach out to your customer success manager for more information.
354
- * @summary Delete Transformation
355
- * @param transformationId
356
- */
357
- public async deleteTransformationAlpha(
358
- transformationId: string,
359
- options: { headers: { [name: string]: string } } = { headers: {} }
360
- ): Promise<{
361
- response: http.IncomingMessage;
362
- body: DeleteTransformation200Response;
363
- }> {
364
- const localVarPath =
365
- this.basePath +
366
- '/transformations/{transformationId}'.replace(
367
- '{' + 'transformationId' + '}',
368
- encodeURIComponent(String(transformationId))
369
- );
370
- let localVarQueryParameters: any = {};
371
- let localVarHeaderParams: any = (<any>Object).assign(
372
- {},
373
- this._defaultHeaders
374
- );
375
- const produces = [
376
- 'application/vnd.segment.v1alpha+json',
377
- 'application/json',
378
- ];
379
- if (produces.indexOf('application/json') >= 0) {
380
- localVarHeaderParams.Accept = produces[0];
381
- } else {
382
- localVarHeaderParams.Accept = 'application/json';
383
- }
384
- let localVarFormParams: any = {};
385
-
386
- // verify required parameter 'transformationId' is not null or undefined
387
- if (transformationId === null || transformationId === undefined) {
388
- throw new Error(
389
- 'Required parameter transformationId was null or undefined when calling deleteTransformationAlpha.'
390
- );
391
- }
392
-
393
- (<any>Object).assign(localVarHeaderParams, options.headers);
394
-
395
- let localVarUseFormData = false;
396
-
397
- let localVarRequestOptions: localVarRequest.Options = {
398
- method: 'DELETE',
399
- qs: localVarQueryParameters,
400
- headers: localVarHeaderParams,
401
- uri: localVarPath,
402
- useQuerystring: this._useQuerystring,
403
- json: true,
404
- };
405
-
406
- let authenticationPromise = Promise.resolve();
407
- if (this.authentications.token.accessToken) {
408
- authenticationPromise = authenticationPromise.then(() =>
409
- this.authentications.token.applyToRequest(
410
- localVarRequestOptions
411
- )
412
- );
413
- }
414
- authenticationPromise = authenticationPromise.then(() =>
415
- this.authentications.default.applyToRequest(localVarRequestOptions)
416
- );
417
-
418
- let interceptorPromise = authenticationPromise;
419
- for (const interceptor of this.interceptors) {
420
- interceptorPromise = interceptorPromise.then(() =>
421
- interceptor(localVarRequestOptions)
422
- );
423
- }
424
-
425
- return interceptorPromise.then(() => {
426
- if (Object.keys(localVarFormParams).length) {
427
- if (localVarUseFormData) {
428
- (<any>localVarRequestOptions).formData = localVarFormParams;
429
- } else {
430
- localVarRequestOptions.form = localVarFormParams;
431
- }
432
- }
433
- return new Promise<{
434
- response: http.IncomingMessage;
435
- body: DeleteTransformation200Response;
436
- }>((resolve, reject) => {
437
- localVarRequest(
438
- localVarRequestOptions,
439
- (error, response, body) => {
440
- if (error) {
441
- reject(error);
442
- } else {
443
- if (
444
- response.statusCode &&
445
- response.statusCode >= 200 &&
446
- response.statusCode <= 299
447
- ) {
448
- body = ObjectSerializer.deserialize(
449
- body,
450
- 'DeleteTransformation200Response'
451
- );
452
- resolve({ response: response, body: body });
453
- } else {
454
- reject(
455
- new HttpError(
456
- response,
457
- body,
458
- response.statusCode
459
- )
460
- );
461
- }
462
- }
463
- }
464
- );
465
- });
466
- });
467
- }
468
- /**
469
- * Deletes a Transformation. When called, this endpoint may generate the `Transformation Deleted` [Audit Trail](/tag/Audit-Trail) event. **Note**: In order to successfully call this endpoint, the specified Workspace needs to have the Protocols feature enabled. Please reach out to your customer success manager for more information.
470
- * @summary Delete Transformation
471
- * @param transformationId
472
- */
473
- public async deleteTransformationBeta(
474
- transformationId: string,
475
- options: { headers: { [name: string]: string } } = { headers: {} }
476
- ): Promise<{
477
- response: http.IncomingMessage;
478
- body: DeleteTransformation200Response;
479
- }> {
480
- const localVarPath =
481
- this.basePath +
482
- '/transformations/{transformationId}'.replace(
483
- '{' + 'transformationId' + '}',
484
- encodeURIComponent(String(transformationId))
485
- );
486
- let localVarQueryParameters: any = {};
487
- let localVarHeaderParams: any = (<any>Object).assign(
488
- {},
489
- this._defaultHeaders
490
- );
491
- const produces = [
492
- 'application/vnd.segment.v1beta+json',
493
- 'application/json',
494
- ];
495
- if (produces.indexOf('application/json') >= 0) {
496
- localVarHeaderParams.Accept = produces[0];
497
- } else {
498
- localVarHeaderParams.Accept = 'application/json';
499
- }
500
- let localVarFormParams: any = {};
501
-
502
- // verify required parameter 'transformationId' is not null or undefined
503
- if (transformationId === null || transformationId === undefined) {
504
- throw new Error(
505
- 'Required parameter transformationId was null or undefined when calling deleteTransformationBeta.'
506
- );
507
- }
508
-
509
- (<any>Object).assign(localVarHeaderParams, options.headers);
510
-
511
- let localVarUseFormData = false;
512
-
513
- let localVarRequestOptions: localVarRequest.Options = {
514
- method: 'DELETE',
515
- qs: localVarQueryParameters,
516
- headers: localVarHeaderParams,
517
- uri: localVarPath,
518
- useQuerystring: this._useQuerystring,
519
- json: true,
520
- };
521
-
522
- let authenticationPromise = Promise.resolve();
523
- if (this.authentications.token.accessToken) {
524
- authenticationPromise = authenticationPromise.then(() =>
525
- this.authentications.token.applyToRequest(
526
- localVarRequestOptions
527
- )
528
- );
529
- }
530
- authenticationPromise = authenticationPromise.then(() =>
531
- this.authentications.default.applyToRequest(localVarRequestOptions)
532
- );
533
-
534
- let interceptorPromise = authenticationPromise;
535
- for (const interceptor of this.interceptors) {
536
- interceptorPromise = interceptorPromise.then(() =>
537
- interceptor(localVarRequestOptions)
538
- );
539
- }
540
-
541
- return interceptorPromise.then(() => {
542
- if (Object.keys(localVarFormParams).length) {
543
- if (localVarUseFormData) {
544
- (<any>localVarRequestOptions).formData = localVarFormParams;
545
- } else {
546
- localVarRequestOptions.form = localVarFormParams;
547
- }
548
- }
549
- return new Promise<{
550
- response: http.IncomingMessage;
551
- body: DeleteTransformation200Response;
552
- }>((resolve, reject) => {
553
- localVarRequest(
554
- localVarRequestOptions,
555
- (error, response, body) => {
556
- if (error) {
557
- reject(error);
558
- } else {
559
- if (
560
- response.statusCode &&
561
- response.statusCode >= 200 &&
562
- response.statusCode <= 299
563
- ) {
564
- body = ObjectSerializer.deserialize(
565
- body,
566
- 'DeleteTransformation200Response'
567
- );
568
- resolve({ response: response, body: body });
569
- } else {
570
- reject(
571
- new HttpError(
572
- response,
573
- body,
574
- response.statusCode
575
- )
576
- );
577
- }
578
- }
579
- }
580
- );
581
- });
582
- });
583
- }
584
- /**
585
- * Gets a Transformation. **Note**: In order to successfully call this endpoint, the specified Workspace needs to have the Protocols feature enabled. Please reach out to your customer success manager for more information.
586
- * @summary Get Transformation
587
- * @param transformationId
588
- */
589
- public async getTransformationAlpha(
590
- transformationId: string,
591
- options: { headers: { [name: string]: string } } = { headers: {} }
592
- ): Promise<{
593
- response: http.IncomingMessage;
594
- body: GetTransformation200Response;
595
- }> {
596
- const localVarPath =
597
- this.basePath +
598
- '/transformations/{transformationId}'.replace(
599
- '{' + 'transformationId' + '}',
600
- encodeURIComponent(String(transformationId))
601
- );
602
- let localVarQueryParameters: any = {};
603
- let localVarHeaderParams: any = (<any>Object).assign(
604
- {},
605
- this._defaultHeaders
606
- );
607
- const produces = [
608
- 'application/vnd.segment.v1alpha+json',
609
- 'application/json',
610
- ];
611
- if (produces.indexOf('application/json') >= 0) {
612
- localVarHeaderParams.Accept = produces[0];
613
- } else {
614
- localVarHeaderParams.Accept = 'application/json';
615
- }
616
- let localVarFormParams: any = {};
617
-
618
- // verify required parameter 'transformationId' is not null or undefined
619
- if (transformationId === null || transformationId === undefined) {
620
- throw new Error(
621
- 'Required parameter transformationId was null or undefined when calling getTransformationAlpha.'
622
- );
623
- }
624
-
625
- (<any>Object).assign(localVarHeaderParams, options.headers);
626
-
627
- let localVarUseFormData = false;
628
-
629
- let localVarRequestOptions: localVarRequest.Options = {
630
- method: 'GET',
631
- qs: localVarQueryParameters,
632
- headers: localVarHeaderParams,
633
- uri: localVarPath,
634
- useQuerystring: this._useQuerystring,
635
- json: true,
636
- };
637
-
638
- let authenticationPromise = Promise.resolve();
639
- if (this.authentications.token.accessToken) {
640
- authenticationPromise = authenticationPromise.then(() =>
641
- this.authentications.token.applyToRequest(
642
- localVarRequestOptions
643
- )
644
- );
645
- }
646
- authenticationPromise = authenticationPromise.then(() =>
647
- this.authentications.default.applyToRequest(localVarRequestOptions)
648
- );
649
-
650
- let interceptorPromise = authenticationPromise;
651
- for (const interceptor of this.interceptors) {
652
- interceptorPromise = interceptorPromise.then(() =>
653
- interceptor(localVarRequestOptions)
654
- );
655
- }
656
-
657
- return interceptorPromise.then(() => {
658
- if (Object.keys(localVarFormParams).length) {
659
- if (localVarUseFormData) {
660
- (<any>localVarRequestOptions).formData = localVarFormParams;
661
- } else {
662
- localVarRequestOptions.form = localVarFormParams;
663
- }
664
- }
665
- return new Promise<{
666
- response: http.IncomingMessage;
667
- body: GetTransformation200Response;
668
- }>((resolve, reject) => {
669
- localVarRequest(
670
- localVarRequestOptions,
671
- (error, response, body) => {
672
- if (error) {
673
- reject(error);
674
- } else {
675
- if (
676
- response.statusCode &&
677
- response.statusCode >= 200 &&
678
- response.statusCode <= 299
679
- ) {
680
- body = ObjectSerializer.deserialize(
681
- body,
682
- 'GetTransformation200Response'
683
- );
684
- resolve({ response: response, body: body });
685
- } else {
686
- reject(
687
- new HttpError(
688
- response,
689
- body,
690
- response.statusCode
691
- )
692
- );
693
- }
694
- }
695
- }
696
- );
697
- });
698
- });
699
- }
700
- /**
701
- * Gets a Transformation. **Note**: In order to successfully call this endpoint, the specified Workspace needs to have the Protocols feature enabled. Please reach out to your customer success manager for more information.
702
- * @summary Get Transformation
703
- * @param transformationId
704
- */
705
- public async getTransformationBeta(
706
- transformationId: string,
707
- options: { headers: { [name: string]: string } } = { headers: {} }
708
- ): Promise<{
709
- response: http.IncomingMessage;
710
- body: GetTransformation200Response;
711
- }> {
712
- const localVarPath =
713
- this.basePath +
714
- '/transformations/{transformationId}'.replace(
715
- '{' + 'transformationId' + '}',
716
- encodeURIComponent(String(transformationId))
717
- );
718
- let localVarQueryParameters: any = {};
719
- let localVarHeaderParams: any = (<any>Object).assign(
720
- {},
721
- this._defaultHeaders
722
- );
723
- const produces = [
724
- 'application/vnd.segment.v1beta+json',
725
- 'application/json',
726
- ];
727
- if (produces.indexOf('application/json') >= 0) {
728
- localVarHeaderParams.Accept = produces[0];
729
- } else {
730
- localVarHeaderParams.Accept = 'application/json';
731
- }
732
- let localVarFormParams: any = {};
733
-
734
- // verify required parameter 'transformationId' is not null or undefined
735
- if (transformationId === null || transformationId === undefined) {
736
- throw new Error(
737
- 'Required parameter transformationId was null or undefined when calling getTransformationBeta.'
738
- );
739
- }
740
-
741
- (<any>Object).assign(localVarHeaderParams, options.headers);
742
-
743
- let localVarUseFormData = false;
744
-
745
- let localVarRequestOptions: localVarRequest.Options = {
746
- method: 'GET',
747
- qs: localVarQueryParameters,
748
- headers: localVarHeaderParams,
749
- uri: localVarPath,
750
- useQuerystring: this._useQuerystring,
751
- json: true,
752
- };
753
-
754
- let authenticationPromise = Promise.resolve();
755
- if (this.authentications.token.accessToken) {
756
- authenticationPromise = authenticationPromise.then(() =>
757
- this.authentications.token.applyToRequest(
758
- localVarRequestOptions
759
- )
760
- );
761
- }
762
- authenticationPromise = authenticationPromise.then(() =>
763
- this.authentications.default.applyToRequest(localVarRequestOptions)
764
- );
765
-
766
- let interceptorPromise = authenticationPromise;
767
- for (const interceptor of this.interceptors) {
768
- interceptorPromise = interceptorPromise.then(() =>
769
- interceptor(localVarRequestOptions)
770
- );
771
- }
772
-
773
- return interceptorPromise.then(() => {
774
- if (Object.keys(localVarFormParams).length) {
775
- if (localVarUseFormData) {
776
- (<any>localVarRequestOptions).formData = localVarFormParams;
777
- } else {
778
- localVarRequestOptions.form = localVarFormParams;
779
- }
780
- }
781
- return new Promise<{
782
- response: http.IncomingMessage;
783
- body: GetTransformation200Response;
784
- }>((resolve, reject) => {
785
- localVarRequest(
786
- localVarRequestOptions,
787
- (error, response, body) => {
788
- if (error) {
789
- reject(error);
790
- } else {
791
- if (
792
- response.statusCode &&
793
- response.statusCode >= 200 &&
794
- response.statusCode <= 299
795
- ) {
796
- body = ObjectSerializer.deserialize(
797
- body,
798
- 'GetTransformation200Response'
799
- );
800
- resolve({ response: response, body: body });
801
- } else {
802
- reject(
803
- new HttpError(
804
- response,
805
- body,
806
- response.statusCode
807
- )
808
- );
809
- }
810
- }
811
- }
812
- );
813
- });
814
- });
815
- }
816
- /**
817
- * Lists all Transformations in the Workspace. **Note**: In order to successfully call this endpoint, the specified Workspace needs to have the Protocols feature enabled. Please reach out to your customer success manager for more information.
818
- * @summary List Transformations
819
- * @param pagination Pagination options. This parameter exists in alpha.
820
- */
821
- public async listTransformationsAlpha(
822
- pagination: PaginationInput,
823
- options: { headers: { [name: string]: string } } = { headers: {} }
824
- ): Promise<{
825
- response: http.IncomingMessage;
826
- body: ListTransformations200Response;
827
- }> {
828
- const localVarPath = this.basePath + '/transformations';
829
- let localVarQueryParameters: any = {};
830
- let localVarHeaderParams: any = (<any>Object).assign(
831
- {},
832
- this._defaultHeaders
833
- );
834
- const produces = [
835
- 'application/vnd.segment.v1alpha+json',
836
- 'application/json',
837
- ];
838
- if (produces.indexOf('application/json') >= 0) {
839
- localVarHeaderParams.Accept = produces[0];
840
- } else {
841
- localVarHeaderParams.Accept = 'application/json';
842
- }
843
- let localVarFormParams: any = {};
844
-
845
- // verify required parameter 'pagination' is not null or undefined
846
- if (pagination === null || pagination === undefined) {
847
- throw new Error(
848
- 'Required parameter pagination was null or undefined when calling listTransformationsAlpha.'
849
- );
850
- }
851
-
852
- if (pagination !== undefined) {
853
- localVarQueryParameters['pagination'] = ObjectSerializer.serialize(
854
- pagination,
855
- 'PaginationInput'
856
- );
857
- }
858
-
859
- (<any>Object).assign(localVarHeaderParams, options.headers);
860
-
861
- let localVarUseFormData = false;
862
-
863
- let localVarRequestOptions: localVarRequest.Options = {
864
- method: 'GET',
865
- qs: localVarQueryParameters,
866
- headers: localVarHeaderParams,
867
- uri: localVarPath,
868
- useQuerystring: this._useQuerystring,
869
- json: true,
870
- };
871
-
872
- let authenticationPromise = Promise.resolve();
873
- if (this.authentications.token.accessToken) {
874
- authenticationPromise = authenticationPromise.then(() =>
875
- this.authentications.token.applyToRequest(
876
- localVarRequestOptions
877
- )
878
- );
879
- }
880
- authenticationPromise = authenticationPromise.then(() =>
881
- this.authentications.default.applyToRequest(localVarRequestOptions)
882
- );
883
-
884
- let interceptorPromise = authenticationPromise;
885
- for (const interceptor of this.interceptors) {
886
- interceptorPromise = interceptorPromise.then(() =>
887
- interceptor(localVarRequestOptions)
888
- );
889
- }
890
-
891
- return interceptorPromise.then(() => {
892
- if (Object.keys(localVarFormParams).length) {
893
- if (localVarUseFormData) {
894
- (<any>localVarRequestOptions).formData = localVarFormParams;
895
- } else {
896
- localVarRequestOptions.form = localVarFormParams;
897
- }
898
- }
899
- return new Promise<{
900
- response: http.IncomingMessage;
901
- body: ListTransformations200Response;
902
- }>((resolve, reject) => {
903
- localVarRequest(
904
- localVarRequestOptions,
905
- (error, response, body) => {
906
- if (error) {
907
- reject(error);
908
- } else {
909
- if (
910
- response.statusCode &&
911
- response.statusCode >= 200 &&
912
- response.statusCode <= 299
913
- ) {
914
- body = ObjectSerializer.deserialize(
915
- body,
916
- 'ListTransformations200Response'
917
- );
918
- resolve({ response: response, body: body });
919
- } else {
920
- reject(
921
- new HttpError(
922
- response,
923
- body,
924
- response.statusCode
925
- )
926
- );
927
- }
928
- }
929
- }
930
- );
931
- });
932
- });
933
- }
934
- /**
935
- * Lists all Transformations in the Workspace. **Note**: In order to successfully call this endpoint, the specified Workspace needs to have the Protocols feature enabled. Please reach out to your customer success manager for more information.
936
- * @summary List Transformations
937
- * @param pagination Pagination options. This parameter exists in alpha.
938
- */
939
- public async listTransformationsBeta(
940
- pagination: PaginationInput,
941
- options: { headers: { [name: string]: string } } = { headers: {} }
942
- ): Promise<{
943
- response: http.IncomingMessage;
944
- body: ListTransformations200Response;
945
- }> {
946
- const localVarPath = this.basePath + '/transformations';
947
- let localVarQueryParameters: any = {};
948
- let localVarHeaderParams: any = (<any>Object).assign(
949
- {},
950
- this._defaultHeaders
951
- );
952
- const produces = [
953
- 'application/vnd.segment.v1beta+json',
954
- 'application/json',
955
- ];
956
- if (produces.indexOf('application/json') >= 0) {
957
- localVarHeaderParams.Accept = produces[0];
958
- } else {
959
- localVarHeaderParams.Accept = 'application/json';
960
- }
961
- let localVarFormParams: any = {};
962
-
963
- // verify required parameter 'pagination' is not null or undefined
964
- if (pagination === null || pagination === undefined) {
965
- throw new Error(
966
- 'Required parameter pagination was null or undefined when calling listTransformationsBeta.'
967
- );
968
- }
969
-
970
- if (pagination !== undefined) {
971
- localVarQueryParameters['pagination'] = ObjectSerializer.serialize(
972
- pagination,
973
- 'PaginationInput'
974
- );
975
- }
976
-
977
- (<any>Object).assign(localVarHeaderParams, options.headers);
978
-
979
- let localVarUseFormData = false;
980
-
981
- let localVarRequestOptions: localVarRequest.Options = {
982
- method: 'GET',
983
- qs: localVarQueryParameters,
984
- headers: localVarHeaderParams,
985
- uri: localVarPath,
986
- useQuerystring: this._useQuerystring,
987
- json: true,
988
- };
989
-
990
- let authenticationPromise = Promise.resolve();
991
- if (this.authentications.token.accessToken) {
992
- authenticationPromise = authenticationPromise.then(() =>
993
- this.authentications.token.applyToRequest(
994
- localVarRequestOptions
995
- )
996
- );
997
- }
998
- authenticationPromise = authenticationPromise.then(() =>
999
- this.authentications.default.applyToRequest(localVarRequestOptions)
1000
- );
1001
-
1002
- let interceptorPromise = authenticationPromise;
1003
- for (const interceptor of this.interceptors) {
1004
- interceptorPromise = interceptorPromise.then(() =>
1005
- interceptor(localVarRequestOptions)
1006
- );
1007
- }
1008
-
1009
- return interceptorPromise.then(() => {
1010
- if (Object.keys(localVarFormParams).length) {
1011
- if (localVarUseFormData) {
1012
- (<any>localVarRequestOptions).formData = localVarFormParams;
1013
- } else {
1014
- localVarRequestOptions.form = localVarFormParams;
1015
- }
1016
- }
1017
- return new Promise<{
1018
- response: http.IncomingMessage;
1019
- body: ListTransformations200Response;
1020
- }>((resolve, reject) => {
1021
- localVarRequest(
1022
- localVarRequestOptions,
1023
- (error, response, body) => {
1024
- if (error) {
1025
- reject(error);
1026
- } else {
1027
- if (
1028
- response.statusCode &&
1029
- response.statusCode >= 200 &&
1030
- response.statusCode <= 299
1031
- ) {
1032
- body = ObjectSerializer.deserialize(
1033
- body,
1034
- 'ListTransformations200Response'
1035
- );
1036
- resolve({ response: response, body: body });
1037
- } else {
1038
- reject(
1039
- new HttpError(
1040
- response,
1041
- body,
1042
- response.statusCode
1043
- )
1044
- );
1045
- }
1046
- }
1047
- }
1048
- );
1049
- });
1050
- });
1051
- }
1052
- /**
1053
- * Updates an existing Transformation. When called, this endpoint may generate the `Transformation Updated` [Audit Trail](/tag/Audit-Trail) event. **Note**: In order to successfully call this endpoint, the specified Workspace needs to have the Protocols feature enabled. Please reach out to your customer success manager for more information.
1054
- * @summary Update Transformation
1055
- * @param transformationId
1056
- * @param UpdateTransformationBetaInput
1057
- */
1058
- public async updateTransformationAlpha(
1059
- transformationId: string,
1060
- UpdateTransformationBetaInput: UpdateTransformationBetaInput,
1061
- options: { headers: { [name: string]: string } } = { headers: {} }
1062
- ): Promise<{
1063
- response: http.IncomingMessage;
1064
- body: UpdateTransformation200Response;
1065
- }> {
1066
- const localVarPath =
1067
- this.basePath +
1068
- '/transformations/{transformationId}'.replace(
1069
- '{' + 'transformationId' + '}',
1070
- encodeURIComponent(String(transformationId))
1071
- );
1072
- let localVarQueryParameters: any = {};
1073
- let localVarHeaderParams: any = (<any>Object).assign(
1074
- {},
1075
- this._defaultHeaders
1076
- );
1077
- const produces = [
1078
- 'application/vnd.segment.v1alpha+json',
1079
- 'application/json',
1080
- ];
1081
- if (produces.indexOf('application/json') >= 0) {
1082
- localVarHeaderParams.Accept = produces[0];
1083
- } else {
1084
- localVarHeaderParams.Accept = 'application/json';
1085
- }
1086
- let localVarFormParams: any = {};
1087
-
1088
- // verify required parameter 'transformationId' is not null or undefined
1089
- if (transformationId === null || transformationId === undefined) {
1090
- throw new Error(
1091
- 'Required parameter transformationId was null or undefined when calling updateTransformationAlpha.'
1092
- );
1093
- }
1094
-
1095
- // verify required parameter 'UpdateTransformationBetaInput' is not null or undefined
1096
- if (
1097
- UpdateTransformationBetaInput === null ||
1098
- UpdateTransformationBetaInput === undefined
1099
- ) {
1100
- throw new Error(
1101
- 'Required parameter UpdateTransformationBetaInput was null or undefined when calling updateTransformationAlpha.'
1102
- );
1103
- }
1104
-
1105
- (<any>Object).assign(localVarHeaderParams, options.headers);
1106
-
1107
- let localVarUseFormData = false;
1108
-
1109
- let localVarRequestOptions: localVarRequest.Options = {
1110
- method: 'PATCH',
1111
- qs: localVarQueryParameters,
1112
- headers: localVarHeaderParams,
1113
- uri: localVarPath,
1114
- useQuerystring: this._useQuerystring,
1115
- json: true,
1116
- body: ObjectSerializer.serialize(
1117
- UpdateTransformationBetaInput,
1118
- 'UpdateTransformationBetaInput'
1119
- ),
1120
- };
1121
-
1122
- let authenticationPromise = Promise.resolve();
1123
- if (this.authentications.token.accessToken) {
1124
- authenticationPromise = authenticationPromise.then(() =>
1125
- this.authentications.token.applyToRequest(
1126
- localVarRequestOptions
1127
- )
1128
- );
1129
- }
1130
- authenticationPromise = authenticationPromise.then(() =>
1131
- this.authentications.default.applyToRequest(localVarRequestOptions)
1132
- );
1133
-
1134
- let interceptorPromise = authenticationPromise;
1135
- for (const interceptor of this.interceptors) {
1136
- interceptorPromise = interceptorPromise.then(() =>
1137
- interceptor(localVarRequestOptions)
1138
- );
1139
- }
1140
-
1141
- return interceptorPromise.then(() => {
1142
- if (Object.keys(localVarFormParams).length) {
1143
- if (localVarUseFormData) {
1144
- (<any>localVarRequestOptions).formData = localVarFormParams;
1145
- } else {
1146
- localVarRequestOptions.form = localVarFormParams;
1147
- }
1148
- }
1149
- return new Promise<{
1150
- response: http.IncomingMessage;
1151
- body: UpdateTransformation200Response;
1152
- }>((resolve, reject) => {
1153
- localVarRequest(
1154
- localVarRequestOptions,
1155
- (error, response, body) => {
1156
- if (error) {
1157
- reject(error);
1158
- } else {
1159
- if (
1160
- response.statusCode &&
1161
- response.statusCode >= 200 &&
1162
- response.statusCode <= 299
1163
- ) {
1164
- body = ObjectSerializer.deserialize(
1165
- body,
1166
- 'UpdateTransformation200Response'
1167
- );
1168
- resolve({ response: response, body: body });
1169
- } else {
1170
- reject(
1171
- new HttpError(
1172
- response,
1173
- body,
1174
- response.statusCode
1175
- )
1176
- );
1177
- }
1178
- }
1179
- }
1180
- );
1181
- });
1182
- });
1183
- }
1184
- /**
1185
- * Updates an existing Transformation. When called, this endpoint may generate the `Transformation Updated` [Audit Trail](/tag/Audit-Trail) event. **Note**: In order to successfully call this endpoint, the specified Workspace needs to have the Protocols feature enabled. Please reach out to your customer success manager for more information.
1186
- * @summary Update Transformation
1187
- * @param transformationId
1188
- * @param UpdateTransformationBetaInput
1189
- */
1190
- public async updateTransformationBeta(
1191
- transformationId: string,
1192
- UpdateTransformationBetaInput: UpdateTransformationBetaInput,
1193
- options: { headers: { [name: string]: string } } = { headers: {} }
1194
- ): Promise<{
1195
- response: http.IncomingMessage;
1196
- body: UpdateTransformation200Response;
1197
- }> {
1198
- const localVarPath =
1199
- this.basePath +
1200
- '/transformations/{transformationId}'.replace(
1201
- '{' + 'transformationId' + '}',
1202
- encodeURIComponent(String(transformationId))
1203
- );
1204
- let localVarQueryParameters: any = {};
1205
- let localVarHeaderParams: any = (<any>Object).assign(
1206
- {},
1207
- this._defaultHeaders
1208
- );
1209
- const produces = [
1210
- 'application/vnd.segment.v1beta+json',
1211
- 'application/json',
1212
- ];
1213
- if (produces.indexOf('application/json') >= 0) {
1214
- localVarHeaderParams.Accept = produces[0];
1215
- } else {
1216
- localVarHeaderParams.Accept = 'application/json';
1217
- }
1218
- let localVarFormParams: any = {};
1219
-
1220
- // verify required parameter 'transformationId' is not null or undefined
1221
- if (transformationId === null || transformationId === undefined) {
1222
- throw new Error(
1223
- 'Required parameter transformationId was null or undefined when calling updateTransformationBeta.'
1224
- );
1225
- }
1226
-
1227
- // verify required parameter 'UpdateTransformationBetaInput' is not null or undefined
1228
- if (
1229
- UpdateTransformationBetaInput === null ||
1230
- UpdateTransformationBetaInput === undefined
1231
- ) {
1232
- throw new Error(
1233
- 'Required parameter UpdateTransformationBetaInput was null or undefined when calling updateTransformationBeta.'
1234
- );
1235
- }
1236
-
1237
- (<any>Object).assign(localVarHeaderParams, options.headers);
1238
-
1239
- let localVarUseFormData = false;
1240
-
1241
- let localVarRequestOptions: localVarRequest.Options = {
1242
- method: 'PATCH',
1243
- qs: localVarQueryParameters,
1244
- headers: localVarHeaderParams,
1245
- uri: localVarPath,
1246
- useQuerystring: this._useQuerystring,
1247
- json: true,
1248
- body: ObjectSerializer.serialize(
1249
- UpdateTransformationBetaInput,
1250
- 'UpdateTransformationBetaInput'
1251
- ),
1252
- };
1253
-
1254
- let authenticationPromise = Promise.resolve();
1255
- if (this.authentications.token.accessToken) {
1256
- authenticationPromise = authenticationPromise.then(() =>
1257
- this.authentications.token.applyToRequest(
1258
- localVarRequestOptions
1259
- )
1260
- );
1261
- }
1262
- authenticationPromise = authenticationPromise.then(() =>
1263
- this.authentications.default.applyToRequest(localVarRequestOptions)
1264
- );
1265
-
1266
- let interceptorPromise = authenticationPromise;
1267
- for (const interceptor of this.interceptors) {
1268
- interceptorPromise = interceptorPromise.then(() =>
1269
- interceptor(localVarRequestOptions)
1270
- );
1271
- }
1272
-
1273
- return interceptorPromise.then(() => {
1274
- if (Object.keys(localVarFormParams).length) {
1275
- if (localVarUseFormData) {
1276
- (<any>localVarRequestOptions).formData = localVarFormParams;
1277
- } else {
1278
- localVarRequestOptions.form = localVarFormParams;
1279
- }
1280
- }
1281
- return new Promise<{
1282
- response: http.IncomingMessage;
1283
- body: UpdateTransformation200Response;
1284
- }>((resolve, reject) => {
1285
- localVarRequest(
1286
- localVarRequestOptions,
1287
- (error, response, body) => {
1288
- if (error) {
1289
- reject(error);
1290
- } else {
1291
- if (
1292
- response.statusCode &&
1293
- response.statusCode >= 200 &&
1294
- response.statusCode <= 299
1295
- ) {
1296
- body = ObjectSerializer.deserialize(
1297
- body,
1298
- 'UpdateTransformation200Response'
1299
- );
1300
- resolve({ response: response, body: body });
1301
- } else {
1302
- reject(
1303
- new HttpError(
1304
- response,
1305
- body,
1306
- response.statusCode
1307
- )
1308
- );
1309
- }
1310
- }
1311
- }
1312
- );
1313
- });
1314
- });
1315
- }
1316
- }