@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.
- package/README.md +31 -27
- package/api/aPICallsApi.ts +23 -815
- package/api/auditTrailApi.ts +12 -462
- package/api/catalogApi.ts +103 -2182
- package/api/deletionAndSuppressionApi.ts +174 -3281
- package/api/destinationFiltersApi.ts +112 -2449
- package/api/destinationsApi.ts +238 -2166
- package/api/edgeFunctionsApi.ts +13 -9
- package/api/eventsApi.ts +19 -625
- package/api/functionsApi.ts +120 -2289
- package/api/iAMGroupsApi.ts +232 -4750
- package/api/iAMRolesApi.ts +8 -347
- package/api/iAMUsersApi.ts +190 -3433
- package/api/labelsApi.ts +59 -1079
- package/api/monthlyTrackedUsersApi.ts +23 -815
- package/api/selectiveSyncApi.ts +156 -2538
- package/api/sourcesApi.ts +211 -4276
- package/api/spacesApi.ts +10 -7
- package/api/testingApi.ts +14 -317
- package/api/trackingPlansApi.ts +257 -4799
- package/api/transformationsApi.ts +60 -650
- package/api/warehousesApi.ts +200 -3827
- package/api/workspacesApi.ts +6 -306
- package/dist/api/aPICallsApi.d.ts +2 -50
- package/dist/api/aPICallsApi.js +18 -560
- package/dist/api/aPICallsApi.js.map +1 -1
- package/dist/api/apis.js +1 -1
- package/dist/api/auditTrailApi.d.ts +1 -25
- package/dist/api/auditTrailApi.js +8 -300
- package/dist/api/auditTrailApi.js.map +1 -1
- package/dist/api/catalogApi.d.ts +6 -150
- package/dist/api/catalogApi.js +65 -1568
- package/dist/api/catalogApi.js.map +1 -1
- package/dist/api/deletionAndSuppressionApi.d.ts +8 -200
- package/dist/api/deletionAndSuppressionApi.js +105 -2195
- package/dist/api/deletionAndSuppressionApi.js.map +1 -1
- package/dist/api/destinationFiltersApi.d.ts +6 -150
- package/dist/api/destinationFiltersApi.js +71 -1658
- package/dist/api/destinationFiltersApi.js.map +1 -1
- package/dist/api/destinationsApi.d.ts +6 -134
- package/dist/api/destinationsApi.js +155 -1518
- package/dist/api/destinationsApi.js.map +1 -1
- package/dist/api/edgeFunctionsApi.js +9 -9
- package/dist/api/edgeFunctionsApi.js.map +1 -1
- package/dist/api/eventsApi.d.ts +1 -25
- package/dist/api/eventsApi.js +10 -353
- package/dist/api/eventsApi.js.map +1 -1
- package/dist/api/functionsApi.d.ts +6 -150
- package/dist/api/functionsApi.js +75 -1608
- package/dist/api/functionsApi.js.map +1 -1
- package/dist/api/iAMGroupsApi.d.ts +12 -300
- package/dist/api/iAMGroupsApi.js +158 -3278
- package/dist/api/iAMGroupsApi.js.map +1 -1
- package/dist/api/iAMRolesApi.d.ts +1 -25
- package/dist/api/iAMRolesApi.js +8 -261
- package/dist/api/iAMRolesApi.js.map +1 -1
- package/dist/api/iAMUsersApi.d.ts +9 -225
- package/dist/api/iAMUsersApi.js +115 -2422
- package/dist/api/iAMUsersApi.js.map +1 -1
- package/dist/api/labelsApi.d.ts +3 -79
- package/dist/api/labelsApi.js +33 -781
- package/dist/api/labelsApi.js.map +1 -1
- package/dist/api/monthlyTrackedUsersApi.d.ts +2 -50
- package/dist/api/monthlyTrackedUsersApi.js +18 -560
- package/dist/api/monthlyTrackedUsersApi.js.map +1 -1
- package/dist/api/selectiveSyncApi.d.ts +6 -150
- package/dist/api/selectiveSyncApi.js +92 -1694
- package/dist/api/selectiveSyncApi.js.map +1 -1
- package/dist/api/sourcesApi.d.ts +11 -288
- package/dist/api/sourcesApi.js +143 -2976
- package/dist/api/sourcesApi.js.map +1 -1
- package/dist/api/spacesApi.js +7 -7
- package/dist/api/spacesApi.js.map +1 -1
- package/dist/api/testingApi.d.ts +1 -18
- package/dist/api/testingApi.js +7 -211
- package/dist/api/testingApi.js.map +1 -1
- package/dist/api/trackingPlansApi.d.ts +12 -300
- package/dist/api/trackingPlansApi.js +167 -3296
- package/dist/api/trackingPlansApi.js.map +1 -1
- package/dist/api/transformationsApi.d.ts +5 -45
- package/dist/api/transformationsApi.js +34 -457
- package/dist/api/transformationsApi.js.map +1 -1
- package/dist/api/warehousesApi.d.ts +10 -250
- package/dist/api/warehousesApi.js +132 -2686
- package/dist/api/warehousesApi.js.map +1 -1
- package/dist/api/workspacesApi.d.ts +1 -25
- package/dist/api/workspacesApi.js +7 -242
- package/dist/api/workspacesApi.js.map +1 -1
- package/dist/model/addLabelsToSource200Response.d.ts +2 -2
- package/dist/model/addLabelsToSource200Response.js +1 -1
- package/dist/model/addLabelsToSource200Response.js.map +1 -1
- package/dist/model/addLabelsToSource200Response1.d.ts +2 -2
- package/dist/model/addLabelsToSource200Response1.js +1 -1
- package/dist/model/addLabelsToSource200Response1.js.map +1 -1
- package/dist/model/createCloudSourceRegulationV1Input.d.ts +0 -1
- package/dist/model/createCloudSourceRegulationV1Input.js +0 -1
- package/dist/model/createCloudSourceRegulationV1Input.js.map +1 -1
- package/dist/model/createDestinationSubscriptionAlphaInput.d.ts +1 -1
- package/dist/model/createLabel200Response.d.ts +2 -2
- package/dist/model/createLabel200Response.js +1 -1
- package/dist/model/createLabel200Response.js.map +1 -1
- package/dist/model/createLabel200Response1.d.ts +2 -2
- package/dist/model/createLabel200Response1.js +1 -1
- package/dist/model/createLabel200Response1.js.map +1 -1
- package/dist/model/createSource200Response.d.ts +2 -2
- package/dist/model/createSource200Response.js +1 -1
- package/dist/model/createSource200Response.js.map +1 -1
- package/dist/model/createSource200Response1.d.ts +2 -2
- package/dist/model/createSource200Response1.js +1 -1
- package/dist/model/createSource200Response1.js.map +1 -1
- package/dist/model/createSourceAlphaInput.d.ts +1 -1
- package/dist/model/createSourceRegulationV1Input.d.ts +0 -1
- package/dist/model/createSourceRegulationV1Input.js +0 -1
- package/dist/model/createSourceRegulationV1Input.js.map +1 -1
- package/dist/model/createSourceV1Input.d.ts +1 -1
- package/dist/model/createTransformationBetaInput.d.ts +2 -0
- package/dist/model/createTransformationBetaInput.js +5 -0
- package/dist/model/createTransformationBetaInput.js.map +1 -1
- package/dist/model/createValidationInWarehouseV1Input.d.ts +1 -1
- package/dist/model/createWarehouseV1Input.d.ts +1 -1
- package/dist/model/createWorkspaceRegulationV1Input.d.ts +0 -1
- package/dist/model/createWorkspaceRegulationV1Input.js +0 -1
- package/dist/model/createWorkspaceRegulationV1Input.js.map +1 -1
- package/dist/model/deleteLabel200Response.d.ts +2 -2
- package/dist/model/deleteLabel200Response.js +1 -1
- package/dist/model/deleteLabel200Response.js.map +1 -1
- package/dist/model/deleteLabel200Response1.d.ts +2 -2
- package/dist/model/deleteLabel200Response1.js +1 -1
- package/dist/model/deleteLabel200Response1.js.map +1 -1
- package/dist/model/deleteSource200Response.d.ts +2 -2
- package/dist/model/deleteSource200Response.js +1 -1
- package/dist/model/deleteSource200Response.js.map +1 -1
- package/dist/model/deleteSource200Response1.d.ts +2 -2
- package/dist/model/deleteSource200Response1.js +1 -1
- package/dist/model/deleteSource200Response1.js.map +1 -1
- package/dist/model/deliveryMetricsSummary.js.map +1 -1
- package/dist/model/destination.js.map +1 -1
- package/dist/model/destination1.js.map +1 -1
- package/dist/model/destination2.js.map +1 -1
- package/dist/model/destinationMetadata.js.map +1 -1
- package/dist/model/destinationSubscription.d.ts +1 -1
- package/dist/model/destinationSubscriptionUpdateInput.d.ts +1 -1
- package/dist/model/echo200Response.d.ts +2 -2
- package/dist/model/echo200Response.js +1 -1
- package/dist/model/echo200Response.js.map +1 -1
- package/dist/model/echo200Response1.d.ts +2 -2
- package/dist/model/echo200Response1.js +1 -1
- package/dist/model/echo200Response1.js.map +1 -1
- package/dist/model/edgeFunctions.js.map +1 -1
- package/dist/model/edgeFunctions1.js.map +1 -1
- package/dist/model/filter.js.map +1 -1
- package/dist/model/filter1.js.map +1 -1
- package/dist/model/filter2.js.map +1 -1
- package/dist/model/filter3.js.map +1 -1
- package/dist/model/function.js.map +1 -1
- package/dist/model/function1.js.map +1 -1
- package/dist/model/function2.js.map +1 -1
- package/dist/model/getSource200Response.d.ts +2 -2
- package/dist/model/getSource200Response.js +1 -1
- package/dist/model/getSource200Response.js.map +1 -1
- package/dist/model/getSource200Response1.d.ts +2 -2
- package/dist/model/getSource200Response1.js +1 -1
- package/dist/model/getSource200Response1.js.map +1 -1
- package/dist/model/group.js.map +1 -1
- package/dist/model/identify.js.map +1 -1
- package/dist/model/input.d.ts +1 -1
- package/dist/model/input.js.map +1 -1
- package/dist/model/label.js.map +1 -1
- package/dist/model/label1.js.map +1 -1
- package/dist/model/label2.js.map +1 -1
- package/dist/model/listConnectedDestinationsFromSource200Response.d.ts +2 -2
- package/dist/model/listConnectedDestinationsFromSource200Response.js +1 -1
- package/dist/model/listConnectedDestinationsFromSource200Response.js.map +1 -1
- package/dist/model/listConnectedDestinationsFromSource200Response1.d.ts +2 -2
- package/dist/model/listConnectedDestinationsFromSource200Response1.js +1 -1
- package/dist/model/listConnectedDestinationsFromSource200Response1.js.map +1 -1
- package/dist/model/listConnectedWarehousesFromSource200Response.d.ts +2 -2
- package/dist/model/listConnectedWarehousesFromSource200Response.js +1 -1
- package/dist/model/listConnectedWarehousesFromSource200Response.js.map +1 -1
- package/dist/model/listConnectedWarehousesFromSource200Response1.d.ts +2 -2
- package/dist/model/listConnectedWarehousesFromSource200Response1.js +1 -1
- package/dist/model/listConnectedWarehousesFromSource200Response1.js.map +1 -1
- package/dist/model/listLabels200Response.d.ts +2 -2
- package/dist/model/listLabels200Response.js +1 -1
- package/dist/model/listLabels200Response.js.map +1 -1
- package/dist/model/listLabels200Response1.d.ts +2 -2
- package/dist/model/listLabels200Response1.js +1 -1
- package/dist/model/listLabels200Response1.js.map +1 -1
- package/dist/model/listSources200Response.d.ts +2 -2
- package/dist/model/listSources200Response.js +1 -1
- package/dist/model/listSources200Response.js.map +1 -1
- package/dist/model/listSources200Response1.d.ts +2 -2
- package/dist/model/listSources200Response1.js +1 -1
- package/dist/model/listSources200Response1.js.map +1 -1
- package/dist/model/logos.js.map +1 -1
- package/dist/model/logos1.js.map +1 -1
- package/dist/model/logos2.js.map +1 -1
- package/dist/model/metadata.js.map +1 -1
- package/dist/model/metadata1.js.map +1 -1
- package/dist/model/metadata2.js.map +1 -1
- package/dist/model/models.d.ts +3 -2
- package/dist/model/models.js +3 -0
- package/dist/model/models.js.map +1 -1
- package/dist/model/pagination.js.map +1 -1
- package/dist/model/previewDestinationFilterV1Output.d.ts +1 -1
- package/dist/model/previewDestinationFilterV1Output.js +1 -1
- package/dist/model/previewDestinationFilterV1Output.js.map +1 -1
- package/dist/model/propertyValueTransformationBeta.d.ts +15 -0
- package/dist/model/propertyValueTransformationBeta.js +26 -0
- package/dist/model/propertyValueTransformationBeta.js.map +1 -0
- package/dist/model/replaceLabelsInSource200Response.d.ts +2 -2
- package/dist/model/replaceLabelsInSource200Response.js +1 -1
- package/dist/model/replaceLabelsInSource200Response.js.map +1 -1
- package/dist/model/replaceLabelsInSource200Response1.d.ts +2 -2
- package/dist/model/replaceLabelsInSource200Response1.js +1 -1
- package/dist/model/replaceLabelsInSource200Response1.js.map +1 -1
- package/dist/model/schedule.js.map +1 -1
- package/dist/model/schedule1.js.map +1 -1
- package/dist/model/schedule2.js.map +1 -1
- package/dist/model/settings.js.map +1 -1
- package/dist/model/settings1.js.map +1 -1
- package/dist/model/source.js.map +1 -1
- package/dist/model/source1.d.ts +1 -1
- package/dist/model/source1.js.map +1 -1
- package/dist/model/source2.d.ts +1 -1
- package/dist/model/source2.js.map +1 -1
- package/dist/model/source3.d.ts +1 -1
- package/dist/model/source3.js.map +1 -1
- package/dist/model/source4.d.ts +1 -1
- package/dist/model/source4.js.map +1 -1
- package/dist/model/source5.d.ts +1 -1
- package/dist/model/source5.js.map +1 -1
- package/dist/model/source6.d.ts +1 -1
- package/dist/model/source6.js.map +1 -1
- package/dist/model/sourceAlpha.d.ts +1 -1
- package/dist/model/sourceMetadata.js.map +1 -1
- package/dist/model/sourceV1.d.ts +1 -1
- package/dist/model/subscription.d.ts +1 -1
- package/dist/model/subscription.js.map +1 -1
- package/dist/model/supportedFeatures.js.map +1 -1
- package/dist/model/supportedMethods.js.map +1 -1
- package/dist/model/supportedPlatforms.js.map +1 -1
- package/dist/model/track.js.map +1 -1
- package/dist/model/trackingPlan.js.map +1 -1
- package/dist/model/trackingPlan1.js.map +1 -1
- package/dist/model/transformation.d.ts +2 -0
- package/dist/model/transformation.js +5 -0
- package/dist/model/transformation.js.map +1 -1
- package/dist/model/transformation1.d.ts +2 -0
- package/dist/model/transformation1.js +5 -0
- package/dist/model/transformation1.js.map +1 -1
- package/dist/model/transformation2.d.ts +2 -0
- package/dist/model/transformation2.js +5 -0
- package/dist/model/transformation2.js.map +1 -1
- package/dist/model/transformationBeta.d.ts +2 -0
- package/dist/model/transformationBeta.js +5 -0
- package/dist/model/transformationBeta.js.map +1 -1
- package/dist/model/updateSource200Response.d.ts +2 -2
- package/dist/model/updateSource200Response.js +1 -1
- package/dist/model/updateSource200Response.js.map +1 -1
- package/dist/model/updateSource200Response1.d.ts +2 -2
- package/dist/model/updateSource200Response1.js +1 -1
- package/dist/model/updateSource200Response1.js.map +1 -1
- package/dist/model/updateSourceAlphaInput.d.ts +1 -1
- package/dist/model/updateSourceV1Input.d.ts +1 -1
- package/dist/model/updateTransformationBetaInput.d.ts +2 -0
- package/dist/model/updateTransformationBetaInput.js +5 -0
- package/dist/model/updateTransformationBetaInput.js.map +1 -1
- package/dist/model/updateWarehouseV1Input.d.ts +1 -1
- package/dist/model/user.js.map +1 -1
- package/dist/model/userGroup.js.map +1 -1
- package/dist/model/userGroup1.js.map +1 -1
- package/dist/model/userGroup2.js.map +1 -1
- package/dist/model/userGroup3.js.map +1 -1
- package/dist/model/warehouse.d.ts +1 -1
- package/dist/model/warehouse.js.map +1 -1
- package/dist/model/warehouse1.d.ts +1 -1
- package/dist/model/warehouse1.js.map +1 -1
- package/dist/model/warehouse2.d.ts +1 -1
- package/dist/model/warehouse2.js.map +1 -1
- package/dist/model/warehouseMetadata.js.map +1 -1
- package/dist/model/warehouseV1.d.ts +1 -1
- package/dist/model/workspace.js.map +1 -1
- package/dist/tests/smoke.test.js +7 -7
- package/dist/tests/smoke.test.js.map +1 -1
- package/model/aPICallSnapshotV1.ts +1 -1
- package/model/accessPermissionV1.ts +1 -1
- package/model/addConnectionFromSourceToWarehouse200Response.ts +1 -1
- package/model/addConnectionFromSourceToWarehouseV1Output.ts +1 -1
- package/model/addLabelsToSource200Response.ts +4 -4
- package/model/addLabelsToSource200Response1.ts +4 -4
- package/model/addLabelsToSourceAlphaInput.ts +1 -1
- package/model/addLabelsToSourceAlphaOutput.ts +1 -1
- package/model/addLabelsToSourceV1Input.ts +1 -1
- package/model/addLabelsToSourceV1Output.ts +1 -1
- package/model/addPermissionsToUser200Response.ts +1 -1
- package/model/addPermissionsToUserGroup200Response.ts +1 -1
- package/model/addPermissionsToUserGroupV1Input.ts +1 -1
- package/model/addPermissionsToUserGroupV1Output.ts +1 -1
- package/model/addPermissionsToUserV1Input.ts +1 -1
- package/model/addPermissionsToUserV1Output.ts +1 -1
- package/model/addSourceToTrackingPlan200Response.ts +1 -1
- package/model/addSourceToTrackingPlanV1Input.ts +1 -1
- package/model/addSourceToTrackingPlanV1Output.ts +1 -1
- package/model/addUsersToUserGroup200Response.ts +1 -1
- package/model/addUsersToUserGroupV1Input.ts +1 -1
- package/model/addUsersToUserGroupV1Output.ts +1 -1
- package/model/advancedWarehouseSyncScheduleV1Input.ts +1 -1
- package/model/advancedWarehouseSyncScheduleV1Output.ts +1 -1
- package/model/allowedLabelBeta.ts +1 -1
- package/model/auditEventV1.ts +1 -1
- package/model/batchQueryMessagingSubscriptionsForSpace200Response.ts +1 -1
- package/model/batchQueryMessagingSubscriptionsForSpaceAlphaInput.ts +1 -1
- package/model/batchQueryMessagingSubscriptionsForSpaceAlphaOutput.ts +1 -1
- package/model/breakdownBeta.ts +1 -1
- package/model/commonSourceSettingsV1.ts +1 -1
- package/model/contact.ts +1 -1
- package/model/createCloudSourceRegulation200Response.ts +1 -1
- package/model/createCloudSourceRegulationV1Input.ts +1 -2
- package/model/createCloudSourceRegulationV1Output.ts +1 -1
- package/model/createDestination200Response.ts +1 -1
- package/model/createDestinationSubscription200Response.ts +1 -1
- package/model/createDestinationSubscriptionAlphaInput.ts +2 -2
- package/model/createDestinationSubscriptionAlphaOutput.ts +1 -1
- package/model/createDestinationV1Input.ts +1 -1
- package/model/createDestinationV1Output.ts +1 -1
- package/model/createEdgeFunctions200Response.ts +1 -1
- package/model/createEdgeFunctionsAlphaInput.ts +1 -1
- package/model/createEdgeFunctionsAlphaOutput.ts +1 -1
- package/model/createFilterForDestination200Response.ts +1 -1
- package/model/createFilterForDestinationV1Input.ts +1 -1
- package/model/createFilterForDestinationV1Output.ts +1 -1
- package/model/createFunction200Response.ts +1 -1
- package/model/createFunctionDeployment200Response.ts +1 -1
- package/model/createFunctionDeploymentV1Output.ts +1 -1
- package/model/createFunctionV1Input.ts +1 -1
- package/model/createFunctionV1Output.ts +1 -1
- package/model/createInvites200Response.ts +1 -1
- package/model/createInvitesV1Input.ts +1 -1
- package/model/createInvitesV1Output.ts +1 -1
- package/model/createLabel200Response.ts +4 -4
- package/model/createLabel200Response1.ts +4 -4
- package/model/createLabelAlphaInput.ts +1 -1
- package/model/createLabelAlphaOutput.ts +1 -1
- package/model/createLabelV1Input.ts +1 -1
- package/model/createLabelV1Output.ts +1 -1
- package/model/createSource200Response.ts +4 -4
- package/model/createSource200Response1.ts +4 -4
- package/model/createSourceAlphaInput.ts +2 -2
- package/model/createSourceAlphaOutput.ts +1 -1
- package/model/createSourceRegulation200Response.ts +1 -1
- package/model/createSourceRegulationV1Input.ts +1 -2
- package/model/createSourceRegulationV1Output.ts +1 -1
- package/model/createSourceV1Input.ts +2 -2
- package/model/createSourceV1Output.ts +1 -1
- package/model/createTrackingPlan200Response.ts +1 -1
- package/model/createTrackingPlanV1Input.ts +1 -1
- package/model/createTrackingPlanV1Output.ts +1 -1
- package/model/createTransformation200Response.ts +1 -1
- package/model/createTransformationBetaInput.ts +11 -1
- package/model/createTransformationBetaOutput.ts +1 -1
- package/model/createUserGroup200Response.ts +1 -1
- package/model/createUserGroupV1Input.ts +1 -1
- package/model/createUserGroupV1Output.ts +1 -1
- package/model/createValidationInWarehouse200Response.ts +1 -1
- package/model/createValidationInWarehouseV1Input.ts +2 -2
- package/model/createValidationInWarehouseV1Output.ts +1 -1
- package/model/createWarehouse200Response.ts +1 -1
- package/model/createWarehouseV1Input.ts +2 -2
- package/model/createWarehouseV1Output.ts +1 -1
- package/model/createWorkspaceRegulation200Response.ts +1 -1
- package/model/createWorkspaceRegulationV1Input.ts +1 -2
- package/model/createWorkspaceRegulationV1Output.ts +1 -1
- package/model/deleteDestination200Response.ts +1 -1
- package/model/deleteDestinationV1Output.ts +1 -1
- package/model/deleteFunction200Response.ts +1 -1
- package/model/deleteFunctionV1Output.ts +1 -1
- package/model/deleteInvites200Response.ts +1 -1
- package/model/deleteInvitesV1Output.ts +1 -1
- package/model/deleteLabel200Response.ts +4 -4
- package/model/deleteLabel200Response1.ts +4 -4
- package/model/deleteLabelAlphaOutput.ts +1 -1
- package/model/deleteLabelV1Output.ts +1 -1
- package/model/deleteRegulation200Response.ts +1 -1
- package/model/deleteRegulationV1Output.ts +1 -1
- package/model/deleteSource200Response.ts +4 -4
- package/model/deleteSource200Response1.ts +4 -4
- package/model/deleteSourceAlphaOutput.ts +1 -1
- package/model/deleteSourceV1Output.ts +1 -1
- package/model/deleteTrackingPlan200Response.ts +1 -1
- package/model/deleteTrackingPlanV1Output.ts +1 -1
- package/model/deleteTransformation200Response.ts +1 -1
- package/model/deleteTransformationBetaOutput.ts +1 -1
- package/model/deleteUserGroup200Response.ts +1 -1
- package/model/deleteUserGroupV1Output.ts +1 -1
- package/model/deleteUsers200Response.ts +1 -1
- package/model/deleteUsersV1Output.ts +1 -1
- package/model/deleteWarehouse200Response.ts +1 -1
- package/model/deleteWarehouseV1Output.ts +1 -1
- package/model/deliveryMetricsSummary.ts +2 -1
- package/model/deliveryMetricsSummaryBeta.ts +1 -1
- package/model/destination.ts +2 -1
- package/model/destination1.ts +2 -1
- package/model/destination2.ts +2 -1
- package/model/destinationFilterActionV1.ts +1 -1
- package/model/destinationFilterV1.ts +1 -1
- package/model/destinationMetadata.ts +2 -1
- package/model/destinationMetadataActionFieldV1.ts +1 -1
- package/model/destinationMetadataActionV1.ts +1 -1
- package/model/destinationMetadataComponentV1.ts +1 -1
- package/model/destinationMetadataFeaturesV1.ts +1 -1
- package/model/destinationMetadataMethodsV1.ts +1 -1
- package/model/destinationMetadataPlatformsV1.ts +1 -1
- package/model/destinationMetadataSubscriptionPresetV1.ts +1 -1
- package/model/destinationMetadataV1.ts +1 -1
- package/model/destinationStatusV1.ts +1 -1
- package/model/destinationSubscription.ts +2 -2
- package/model/destinationSubscriptionUpdateInput.ts +2 -2
- package/model/destinationV1.ts +1 -1
- package/model/disableEdgeFunctions200Response.ts +1 -1
- package/model/disableEdgeFunctionsAlphaOutput.ts +1 -1
- package/model/echo200Response.ts +4 -4
- package/model/echo200Response1.ts +4 -4
- package/model/echoAlphaOutput.ts +1 -1
- package/model/echoV1Output.ts +1 -1
- package/model/edgeFunctions.ts +2 -1
- package/model/edgeFunctions1.ts +2 -1
- package/model/edgeFunctionsAlpha.ts +1 -1
- package/model/eventSourceV1.ts +1 -1
- package/model/filter.ts +2 -1
- package/model/filter1.ts +2 -1
- package/model/filter2.ts +2 -1
- package/model/filter3.ts +2 -1
- package/model/function.ts +2 -1
- package/model/function1.ts +2 -1
- package/model/function2.ts +2 -1
- package/model/functionDeployment.ts +1 -1
- package/model/functionSettingV1.ts +1 -1
- package/model/functionV1.ts +1 -1
- package/model/generateUploadURLForEdgeFunctions200Response.ts +1 -1
- package/model/generateUploadURLForEdgeFunctionsAlphaOutput.ts +1 -1
- package/model/getAdvancedSyncScheduleFromWarehouse200Response.ts +1 -1
- package/model/getAdvancedSyncScheduleFromWarehouseV1Output.ts +1 -1
- package/model/getConnectionStateFromWarehouse200Response.ts +1 -1
- package/model/getConnectionStateFromWarehouseV1Output.ts +1 -1
- package/model/getDailyPerSourceAPICallsUsage200Response.ts +1 -1
- package/model/getDailyPerSourceAPICallsUsageV1Output.ts +1 -1
- package/model/getDailyPerSourceMTUUsage200Response.ts +1 -1
- package/model/getDailyPerSourceMTUUsageV1Output.ts +1 -1
- package/model/getDailyWorkspaceAPICallsUsage200Response.ts +1 -1
- package/model/getDailyWorkspaceAPICallsUsageV1Output.ts +1 -1
- package/model/getDailyWorkspaceMTUUsage200Response.ts +1 -1
- package/model/getDailyWorkspaceMTUUsageV1Output.ts +1 -1
- package/model/getDestination200Response.ts +1 -1
- package/model/getDestinationMetadata200Response.ts +1 -1
- package/model/getDestinationMetadataV1Output.ts +1 -1
- package/model/getDestinationV1Output.ts +1 -1
- package/model/getDestinationsCatalog200Response.ts +1 -1
- package/model/getDestinationsCatalogV1Output.ts +1 -1
- package/model/getEventsVolumeFromWorkspace200Response.ts +1 -1
- package/model/getEventsVolumeFromWorkspaceV1Output.ts +1 -1
- package/model/getFilterInDestination200Response.ts +1 -1
- package/model/getFilterInDestinationV1Output.ts +1 -1
- package/model/getFunction200Response.ts +1 -1
- package/model/getFunctionV1Output.ts +1 -1
- package/model/getLatestFromEdgeFunctions200Response.ts +1 -1
- package/model/getLatestFromEdgeFunctionsAlphaOutput.ts +1 -1
- package/model/getMessagingSubscriptionFailureResponse.ts +1 -1
- package/model/getMessagingSubscriptionSuccessResponse.ts +1 -1
- package/model/getRegulation200Response.ts +1 -1
- package/model/getRegulationV1Output.ts +1 -1
- package/model/getSource200Response.ts +4 -4
- package/model/getSource200Response1.ts +4 -4
- package/model/getSourceAlphaOutput.ts +1 -1
- package/model/getSourceMetadata200Response.ts +1 -1
- package/model/getSourceMetadataV1Output.ts +1 -1
- package/model/getSourceV1Output.ts +1 -1
- package/model/getSourcesCatalog200Response.ts +1 -1
- package/model/getSourcesCatalogV1Output.ts +1 -1
- package/model/getSpace200Response.ts +1 -1
- package/model/getSpaceAlphaOutput.ts +1 -1
- package/model/getSubscriptionFromDestination200Response.ts +1 -1
- package/model/getSubscriptionFromDestinationAlphaOutput.ts +1 -1
- package/model/getSubscriptionRequest.ts +1 -1
- package/model/getTrackingPlan200Response.ts +1 -1
- package/model/getTrackingPlanV1Output.ts +1 -1
- package/model/getTransformation200Response.ts +1 -1
- package/model/getTransformationBetaOutput.ts +1 -1
- package/model/getUser200Response.ts +1 -1
- package/model/getUserGroup200Response.ts +1 -1
- package/model/getUserGroupV1Output.ts +1 -1
- package/model/getUserV1Output.ts +1 -1
- package/model/getWarehouse200Response.ts +1 -1
- package/model/getWarehouseMetadata200Response.ts +1 -1
- package/model/getWarehouseMetadataV1Output.ts +1 -1
- package/model/getWarehouseV1Output.ts +1 -1
- package/model/getWarehousesCatalog200Response.ts +1 -1
- package/model/getWarehousesCatalogV1Output.ts +1 -1
- package/model/getWorkspace200Response.ts +1 -1
- package/model/getWorkspaceV1Output.ts +1 -1
- package/model/group.ts +2 -1
- package/model/groupSourceSettingsV1.ts +1 -1
- package/model/identify.ts +2 -1
- package/model/identifySourceSettingsV1.ts +1 -1
- package/model/input.ts +3 -2
- package/model/integrationOptionBeta.ts +1 -1
- package/model/invitePermissionV1.ts +1 -1
- package/model/inviteV1.ts +1 -1
- package/model/label.ts +2 -1
- package/model/label1.ts +2 -1
- package/model/label2.ts +2 -1
- package/model/labelAlpha.ts +1 -1
- package/model/labelV1.ts +1 -1
- package/model/listAuditEvents200Response.ts +1 -1
- package/model/listAuditEventsV1Output.ts +1 -1
- package/model/listConnectedDestinationsFromSource200Response.ts +4 -4
- package/model/listConnectedDestinationsFromSource200Response1.ts +4 -4
- package/model/listConnectedDestinationsFromSourceAlphaOutput.ts +1 -1
- package/model/listConnectedDestinationsFromSourceV1Output.ts +1 -1
- package/model/listConnectedSourcesFromWarehouse200Response.ts +1 -1
- package/model/listConnectedSourcesFromWarehouseV1Output.ts +1 -1
- package/model/listConnectedWarehousesFromSource200Response.ts +4 -4
- package/model/listConnectedWarehousesFromSource200Response1.ts +4 -4
- package/model/listConnectedWarehousesFromSourceAlphaOutput.ts +1 -1
- package/model/listConnectedWarehousesFromSourceV1Output.ts +1 -1
- package/model/listDeliveryMetricsSummaryFromDestination200Response.ts +1 -1
- package/model/listDeliveryMetricsSummaryFromDestinationBetaOutput.ts +1 -1
- package/model/listDestinations200Response.ts +1 -1
- package/model/listDestinationsV1Output.ts +1 -1
- package/model/listFiltersFromDestination200Response.ts +1 -1
- package/model/listFiltersFromDestinationV1Output.ts +1 -1
- package/model/listFunctionItemV1.ts +1 -1
- package/model/listFunctions200Response.ts +1 -1
- package/model/listFunctionsV1Output.ts +1 -1
- package/model/listInvites200Response.ts +1 -1
- package/model/listInvitesFromUserGroup200Response.ts +1 -1
- package/model/listInvitesFromUserGroupV1Output.ts +1 -1
- package/model/listInvitesV1Output.ts +1 -1
- package/model/listLabels200Response.ts +4 -4
- package/model/listLabels200Response1.ts +4 -4
- package/model/listLabelsAlphaOutput.ts +1 -1
- package/model/listLabelsV1Output.ts +1 -1
- package/model/listRegulationsFromSource200Response.ts +1 -1
- package/model/listRegulationsFromSourceV1Output.ts +1 -1
- package/model/listRoles200Response.ts +1 -1
- package/model/listRolesV1Output.ts +1 -1
- package/model/listRulesFromTrackingPlan200Response.ts +1 -1
- package/model/listRulesFromTrackingPlanV1Output.ts +1 -1
- package/model/listSchemaSettingsInSource200Response.ts +1 -1
- package/model/listSchemaSettingsInSourceV1Output.ts +1 -1
- package/model/listSelectiveSyncsFromWarehouseAndSource200Response.ts +1 -1
- package/model/listSelectiveSyncsFromWarehouseAndSourceV1Output.ts +1 -1
- package/model/listSources200Response.ts +4 -4
- package/model/listSources200Response1.ts +4 -4
- package/model/listSourcesAlphaOutput.ts +1 -1
- package/model/listSourcesFromTrackingPlan200Response.ts +1 -1
- package/model/listSourcesFromTrackingPlanV1Output.ts +1 -1
- package/model/listSourcesV1Output.ts +1 -1
- package/model/listSubscriptionsFromDestination200Response.ts +1 -1
- package/model/listSubscriptionsFromDestinationAlphaOutput.ts +1 -1
- package/model/listSuppressions200Response.ts +1 -1
- package/model/listSuppressionsV1Output.ts +1 -1
- package/model/listSyncsFromWarehouse200Response.ts +1 -1
- package/model/listSyncsFromWarehouseAndSource200Response.ts +1 -1
- package/model/listSyncsFromWarehouseAndSourceV1Output.ts +1 -1
- package/model/listSyncsFromWarehouseV1Output.ts +1 -1
- package/model/listTrackingPlans200Response.ts +1 -1
- package/model/listTrackingPlansV1Output.ts +1 -1
- package/model/listTransformations200Response.ts +1 -1
- package/model/listTransformationsBetaOutput.ts +1 -1
- package/model/listUserGroups200Response.ts +1 -1
- package/model/listUserGroupsFromUser200Response.ts +1 -1
- package/model/listUserGroupsFromUserV1Output.ts +1 -1
- package/model/listUserGroupsV1Output.ts +1 -1
- package/model/listUsers200Response.ts +1 -1
- package/model/listUsersFromUserGroup200Response.ts +1 -1
- package/model/listUsersFromUserGroupV1Output.ts +1 -1
- package/model/listUsersV1Output.ts +1 -1
- package/model/listWarehouses200Response.ts +1 -1
- package/model/listWarehousesV1Output.ts +1 -1
- package/model/listWorkspaceRegulations200Response.ts +1 -1
- package/model/listWorkspaceRegulationsV1Output.ts +1 -1
- package/model/logos.ts +2 -1
- package/model/logos1.ts +2 -1
- package/model/logos2.ts +2 -1
- package/model/logosBeta.ts +1 -1
- package/model/messageSubscriptionResponse.ts +1 -1
- package/model/messageSubscriptionResponseError.ts +1 -1
- package/model/messagesSubscriptionRequest.ts +1 -1
- package/model/metadata.ts +2 -1
- package/model/metadata1.ts +2 -1
- package/model/metadata2.ts +2 -1
- package/model/metricBeta.ts +1 -1
- package/model/minimalUserGroupV1.ts +1 -1
- package/model/minimalUserV1.ts +1 -1
- package/model/models.ts +3 -0
- package/model/mtuSnapshotV1.ts +1 -1
- package/model/pagination.ts +2 -1
- package/model/paginationInput.ts +1 -1
- package/model/paginationOutput.ts +1 -1
- package/model/permissionInputV1.ts +1 -1
- package/model/permissionResourceV1.ts +1 -1
- package/model/permissionV1.ts +1 -1
- package/model/previewDestinationFilter200Response.ts +1 -1
- package/model/previewDestinationFilterV1.ts +1 -1
- package/model/previewDestinationFilterV1Input.ts +1 -1
- package/model/previewDestinationFilterV1Output.ts +3 -3
- package/model/propertyRenameBeta.ts +1 -1
- package/model/propertyValueTransformationBeta.ts +47 -0
- package/model/regulation.ts +1 -1
- package/model/regulationListEntryV1.ts +1 -1
- package/model/removeFilterFromDestination200Response.ts +1 -1
- package/model/removeFilterFromDestinationV1Output.ts +1 -1
- package/model/removeRuleV1.ts +1 -1
- package/model/removeRulesFromTrackingPlan200Response.ts +1 -1
- package/model/removeRulesFromTrackingPlanV1Output.ts +1 -1
- package/model/removeSourceConnectionFromWarehouse200Response.ts +1 -1
- package/model/removeSourceConnectionFromWarehouseV1Output.ts +1 -1
- package/model/removeSourceFromTrackingPlan200Response.ts +1 -1
- package/model/removeSourceFromTrackingPlanV1Output.ts +1 -1
- package/model/removeSubscriptionFromDestination200Response.ts +1 -1
- package/model/removeSubscriptionFromDestinationAlphaOutput.ts +1 -1
- package/model/removeUsersFromUserGroup200Response.ts +1 -1
- package/model/removeUsersFromUserGroupV1Output.ts +1 -1
- package/model/replaceAdvancedSyncScheduleForWarehouse200Response.ts +1 -1
- package/model/replaceAdvancedSyncScheduleForWarehouseV1Input.ts +1 -1
- package/model/replaceAdvancedSyncScheduleForWarehouseV1Output.ts +1 -1
- package/model/replaceLabelsInSource200Response.ts +4 -4
- package/model/replaceLabelsInSource200Response1.ts +4 -4
- package/model/replaceLabelsInSourceAlphaInput.ts +1 -1
- package/model/replaceLabelsInSourceAlphaOutput.ts +1 -1
- package/model/replaceLabelsInSourceV1Input.ts +1 -1
- package/model/replaceLabelsInSourceV1Output.ts +1 -1
- package/model/replaceMessagingSubscriptionsInSpaces200Response.ts +1 -1
- package/model/replaceMessagingSubscriptionsInSpacesAlphaInput.ts +1 -1
- package/model/replaceMessagingSubscriptionsInSpacesAlphaOutput.ts +1 -1
- package/model/replacePermissionsForUser200Response.ts +1 -1
- package/model/replacePermissionsForUserGroup200Response.ts +1 -1
- package/model/replacePermissionsForUserGroupV1Input.ts +1 -1
- package/model/replacePermissionsForUserGroupV1Output.ts +1 -1
- package/model/replacePermissionsForUserV1Input.ts +1 -1
- package/model/replacePermissionsForUserV1Output.ts +1 -1
- package/model/replaceRulesInTrackingPlan200Response.ts +1 -1
- package/model/replaceRulesInTrackingPlanV1Input.ts +1 -1
- package/model/replaceRulesInTrackingPlanV1Output.ts +1 -1
- package/model/replaceUsersInUserGroup200Response.ts +1 -1
- package/model/replaceUsersInUserGroupV1Input.ts +1 -1
- package/model/replaceUsersInUserGroupV1Output.ts +1 -1
- package/model/requestError.ts +1 -1
- package/model/requestErrorEnvelope.ts +1 -1
- package/model/resourceV1.ts +1 -1
- package/model/roleV1.ts +1 -1
- package/model/ruleV1.ts +1 -1
- package/model/schedule.ts +2 -1
- package/model/schedule1.ts +2 -1
- package/model/schedule2.ts +2 -1
- package/model/settings.ts +2 -1
- package/model/settings1.ts +2 -1
- package/model/source.ts +2 -1
- package/model/source1.ts +3 -2
- package/model/source2.ts +3 -2
- package/model/source3.ts +3 -2
- package/model/source4.ts +3 -2
- package/model/source5.ts +3 -2
- package/model/source6.ts +3 -2
- package/model/sourceAPICallSnapshotV1.ts +1 -1
- package/model/sourceAlpha.ts +2 -2
- package/model/sourceEventVolumeDatapointV1.ts +1 -1
- package/model/sourceEventVolumeV1.ts +1 -1
- package/model/sourceMetadata.ts +2 -1
- package/model/sourceMetadataV1.ts +1 -1
- package/model/sourceSettingsOutputV1.ts +1 -1
- package/model/sourceV1.ts +2 -2
- package/model/space.ts +1 -1
- package/model/streamStatusV1.ts +1 -1
- package/model/subscription.ts +3 -2
- package/model/supportedFeatures.ts +2 -1
- package/model/supportedMethods.ts +2 -1
- package/model/supportedPlatforms.ts +2 -1
- package/model/suppressedInner.ts +1 -1
- package/model/syncNoticeV1.ts +1 -1
- package/model/syncV1.ts +1 -1
- package/model/track.ts +2 -1
- package/model/trackSourceSettingsV1.ts +1 -1
- package/model/trackingPlan.ts +2 -1
- package/model/trackingPlan1.ts +2 -1
- package/model/trackingPlanV1.ts +1 -1
- package/model/transformation.ts +12 -1
- package/model/transformation1.ts +12 -1
- package/model/transformation2.ts +12 -1
- package/model/transformationBeta.ts +11 -1
- package/model/updateDestination200Response.ts +1 -1
- package/model/updateDestinationV1Input.ts +1 -1
- package/model/updateDestinationV1Output.ts +1 -1
- package/model/updateFilterForDestination200Response.ts +1 -1
- package/model/updateFilterForDestinationV1Input.ts +1 -1
- package/model/updateFilterForDestinationV1Output.ts +1 -1
- package/model/updateFunction200Response.ts +1 -1
- package/model/updateFunctionV1Input.ts +1 -1
- package/model/updateFunctionV1Output.ts +1 -1
- package/model/updateRulesInTrackingPlan200Response.ts +1 -1
- package/model/updateRulesInTrackingPlanV1Input.ts +1 -1
- package/model/updateRulesInTrackingPlanV1Output.ts +1 -1
- package/model/updateSchemaSettingsInSource200Response.ts +1 -1
- package/model/updateSchemaSettingsInSourceV1Input.ts +1 -1
- package/model/updateSchemaSettingsInSourceV1Output.ts +1 -1
- package/model/updateSelectiveSyncForWarehouse200Response.ts +1 -1
- package/model/updateSelectiveSyncForWarehouseV1Input.ts +1 -1
- package/model/updateSelectiveSyncForWarehouseV1Output.ts +1 -1
- package/model/updateSource200Response.ts +4 -4
- package/model/updateSource200Response1.ts +4 -4
- package/model/updateSourceAlphaInput.ts +2 -2
- package/model/updateSourceAlphaOutput.ts +1 -1
- package/model/updateSourceV1Input.ts +2 -2
- package/model/updateSourceV1Output.ts +1 -1
- package/model/updateSubscriptionForDestination200Response.ts +1 -1
- package/model/updateSubscriptionForDestinationAlphaInput.ts +1 -1
- package/model/updateSubscriptionForDestinationAlphaOutput.ts +1 -1
- package/model/updateTrackingPlan200Response.ts +1 -1
- package/model/updateTrackingPlanV1Input.ts +1 -1
- package/model/updateTrackingPlanV1Output.ts +1 -1
- package/model/updateTransformation200Response.ts +1 -1
- package/model/updateTransformationBetaInput.ts +11 -1
- package/model/updateTransformationBetaOutput.ts +1 -1
- package/model/updateUserGroup200Response.ts +1 -1
- package/model/updateUserGroupV1Input.ts +1 -1
- package/model/updateUserGroupV1Output.ts +1 -1
- package/model/updateWarehouse200Response.ts +1 -1
- package/model/updateWarehouseV1Input.ts +2 -2
- package/model/updateWarehouseV1Output.ts +1 -1
- package/model/upsertRuleV1.ts +1 -1
- package/model/user.ts +2 -1
- package/model/userGroup.ts +2 -1
- package/model/userGroup1.ts +2 -1
- package/model/userGroup2.ts +2 -1
- package/model/userGroup3.ts +2 -1
- package/model/userGroupV1.ts +1 -1
- package/model/userV1.ts +1 -1
- package/model/usersPerSourceSnapshotV1.ts +1 -1
- package/model/warehouse.ts +3 -2
- package/model/warehouse1.ts +3 -2
- package/model/warehouse2.ts +3 -2
- package/model/warehouseAdvancedSyncV1.ts +1 -1
- package/model/warehouseMetadata.ts +2 -1
- package/model/warehouseMetadataV1.ts +1 -1
- package/model/warehouseSelectiveSyncItemV1.ts +1 -1
- package/model/warehouseSyncOverrideV1.ts +1 -1
- package/model/warehouseV1.ts +2 -2
- package/model/workspace.ts +2 -1
- package/model/workspaceV1.ts +1 -1
- package/package.json +1 -1
- package/tests/__snapshots__/smoke.test.ts.snap +9 -9
- package/tests/smoke.test.ts +6 -6
package/api/destinationsApi.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Segment Public API
|
|
3
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
4
|
*
|
|
5
|
-
* The version of the OpenAPI document:
|
|
5
|
+
* The version of the OpenAPI document: 33.0.2
|
|
6
6
|
* Contact: friends@segment.com
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -122,11 +122,11 @@ export class DestinationsApi {
|
|
|
122
122
|
}
|
|
123
123
|
|
|
124
124
|
/**
|
|
125
|
-
* Creates a new Destination. When called, this endpoint may generate the `Integration Created` [
|
|
125
|
+
* Creates a new Destination. When called, this endpoint may generate the `Integration Created` event in the [audit trail](/tag/Audit-Trail).
|
|
126
126
|
* @summary Create Destination
|
|
127
127
|
* @param CreateDestinationV1Input
|
|
128
128
|
*/
|
|
129
|
-
public async
|
|
129
|
+
public async createDestination(
|
|
130
130
|
CreateDestinationV1Input: CreateDestinationV1Input,
|
|
131
131
|
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
132
132
|
): Promise<{
|
|
@@ -140,13 +140,16 @@ export class DestinationsApi {
|
|
|
140
140
|
this._defaultHeaders
|
|
141
141
|
);
|
|
142
142
|
const produces = [
|
|
143
|
-
'application/vnd.segment.
|
|
143
|
+
'application/vnd.segment.v1+json',
|
|
144
144
|
'application/json',
|
|
145
|
+
'application/vnd.segment.v1beta+json',
|
|
146
|
+
'application/vnd.segment.v1alpha+json',
|
|
145
147
|
];
|
|
148
|
+
// give precedence to 'application/json'
|
|
146
149
|
if (produces.indexOf('application/json') >= 0) {
|
|
147
|
-
localVarHeaderParams.Accept = produces[0];
|
|
148
|
-
} else {
|
|
149
150
|
localVarHeaderParams.Accept = 'application/json';
|
|
151
|
+
} else {
|
|
152
|
+
localVarHeaderParams.Accept = produces.join(',');
|
|
150
153
|
}
|
|
151
154
|
let localVarFormParams: any = {};
|
|
152
155
|
|
|
@@ -156,7 +159,7 @@ export class DestinationsApi {
|
|
|
156
159
|
CreateDestinationV1Input === undefined
|
|
157
160
|
) {
|
|
158
161
|
throw new Error(
|
|
159
|
-
'Required parameter CreateDestinationV1Input was null or undefined when calling
|
|
162
|
+
'Required parameter CreateDestinationV1Input was null or undefined when calling createDestination.'
|
|
160
163
|
);
|
|
161
164
|
}
|
|
162
165
|
|
|
@@ -240,159 +243,56 @@ export class DestinationsApi {
|
|
|
240
243
|
});
|
|
241
244
|
}
|
|
242
245
|
/**
|
|
243
|
-
* Creates a new Destination
|
|
244
|
-
* @summary Create Destination
|
|
245
|
-
* @param
|
|
246
|
+
* Creates a new Destination subscription.
|
|
247
|
+
* @summary Create Destination Subscription
|
|
248
|
+
* @param destinationId
|
|
249
|
+
* @param CreateDestinationSubscriptionAlphaInput
|
|
246
250
|
*/
|
|
247
|
-
public async
|
|
248
|
-
|
|
251
|
+
public async createDestinationSubscription(
|
|
252
|
+
destinationId: string,
|
|
253
|
+
CreateDestinationSubscriptionAlphaInput: CreateDestinationSubscriptionAlphaInput,
|
|
249
254
|
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
250
255
|
): Promise<{
|
|
251
256
|
response: http.IncomingMessage;
|
|
252
|
-
body:
|
|
257
|
+
body: CreateDestinationSubscription200Response;
|
|
253
258
|
}> {
|
|
254
|
-
const localVarPath =
|
|
259
|
+
const localVarPath =
|
|
260
|
+
this.basePath +
|
|
261
|
+
'/destinations/{destinationId}/subscriptions'.replace(
|
|
262
|
+
'{' + 'destinationId' + '}',
|
|
263
|
+
encodeURIComponent(String(destinationId))
|
|
264
|
+
);
|
|
255
265
|
let localVarQueryParameters: any = {};
|
|
256
266
|
let localVarHeaderParams: any = (<any>Object).assign(
|
|
257
267
|
{},
|
|
258
268
|
this._defaultHeaders
|
|
259
269
|
);
|
|
260
270
|
const produces = [
|
|
261
|
-
'application/vnd.segment.
|
|
271
|
+
'application/vnd.segment.v1alpha+json',
|
|
262
272
|
'application/json',
|
|
263
273
|
];
|
|
274
|
+
// give precedence to 'application/json'
|
|
264
275
|
if (produces.indexOf('application/json') >= 0) {
|
|
265
|
-
localVarHeaderParams.Accept = produces[0];
|
|
266
|
-
} else {
|
|
267
276
|
localVarHeaderParams.Accept = 'application/json';
|
|
277
|
+
} else {
|
|
278
|
+
localVarHeaderParams.Accept = produces.join(',');
|
|
268
279
|
}
|
|
269
280
|
let localVarFormParams: any = {};
|
|
270
281
|
|
|
271
|
-
// verify required parameter '
|
|
272
|
-
if (
|
|
273
|
-
CreateDestinationV1Input === null ||
|
|
274
|
-
CreateDestinationV1Input === undefined
|
|
275
|
-
) {
|
|
282
|
+
// verify required parameter 'destinationId' is not null or undefined
|
|
283
|
+
if (destinationId === null || destinationId === undefined) {
|
|
276
284
|
throw new Error(
|
|
277
|
-
'Required parameter
|
|
278
|
-
);
|
|
279
|
-
}
|
|
280
|
-
|
|
281
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
282
|
-
|
|
283
|
-
let localVarUseFormData = false;
|
|
284
|
-
|
|
285
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
286
|
-
method: 'POST',
|
|
287
|
-
qs: localVarQueryParameters,
|
|
288
|
-
headers: localVarHeaderParams,
|
|
289
|
-
uri: localVarPath,
|
|
290
|
-
useQuerystring: this._useQuerystring,
|
|
291
|
-
json: true,
|
|
292
|
-
body: ObjectSerializer.serialize(
|
|
293
|
-
CreateDestinationV1Input,
|
|
294
|
-
'CreateDestinationV1Input'
|
|
295
|
-
),
|
|
296
|
-
};
|
|
297
|
-
|
|
298
|
-
let authenticationPromise = Promise.resolve();
|
|
299
|
-
if (this.authentications.token.accessToken) {
|
|
300
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
301
|
-
this.authentications.token.applyToRequest(
|
|
302
|
-
localVarRequestOptions
|
|
303
|
-
)
|
|
304
|
-
);
|
|
305
|
-
}
|
|
306
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
307
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
308
|
-
);
|
|
309
|
-
|
|
310
|
-
let interceptorPromise = authenticationPromise;
|
|
311
|
-
for (const interceptor of this.interceptors) {
|
|
312
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
313
|
-
interceptor(localVarRequestOptions)
|
|
285
|
+
'Required parameter destinationId was null or undefined when calling createDestinationSubscription.'
|
|
314
286
|
);
|
|
315
287
|
}
|
|
316
288
|
|
|
317
|
-
|
|
318
|
-
if (Object.keys(localVarFormParams).length) {
|
|
319
|
-
if (localVarUseFormData) {
|
|
320
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
321
|
-
} else {
|
|
322
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
323
|
-
}
|
|
324
|
-
}
|
|
325
|
-
return new Promise<{
|
|
326
|
-
response: http.IncomingMessage;
|
|
327
|
-
body: CreateDestination200Response;
|
|
328
|
-
}>((resolve, reject) => {
|
|
329
|
-
localVarRequest(
|
|
330
|
-
localVarRequestOptions,
|
|
331
|
-
(error, response, body) => {
|
|
332
|
-
if (error) {
|
|
333
|
-
reject(error);
|
|
334
|
-
} else {
|
|
335
|
-
if (
|
|
336
|
-
response.statusCode &&
|
|
337
|
-
response.statusCode >= 200 &&
|
|
338
|
-
response.statusCode <= 299
|
|
339
|
-
) {
|
|
340
|
-
body = ObjectSerializer.deserialize(
|
|
341
|
-
body,
|
|
342
|
-
'CreateDestination200Response'
|
|
343
|
-
);
|
|
344
|
-
resolve({ response: response, body: body });
|
|
345
|
-
} else {
|
|
346
|
-
reject(
|
|
347
|
-
new HttpError(
|
|
348
|
-
response,
|
|
349
|
-
body,
|
|
350
|
-
response.statusCode
|
|
351
|
-
)
|
|
352
|
-
);
|
|
353
|
-
}
|
|
354
|
-
}
|
|
355
|
-
}
|
|
356
|
-
);
|
|
357
|
-
});
|
|
358
|
-
});
|
|
359
|
-
}
|
|
360
|
-
/**
|
|
361
|
-
* Creates a new Destination. When called, this endpoint may generate the `Integration Created` [Audit Trail](/tag/Audit-Trail) event.
|
|
362
|
-
* @summary Create Destination
|
|
363
|
-
* @param CreateDestinationV1Input
|
|
364
|
-
*/
|
|
365
|
-
public async createDestinationCurrent(
|
|
366
|
-
CreateDestinationV1Input: CreateDestinationV1Input,
|
|
367
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
368
|
-
): Promise<{
|
|
369
|
-
response: http.IncomingMessage;
|
|
370
|
-
body: CreateDestination200Response;
|
|
371
|
-
}> {
|
|
372
|
-
const localVarPath = this.basePath + '/destinations';
|
|
373
|
-
let localVarQueryParameters: any = {};
|
|
374
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
375
|
-
{},
|
|
376
|
-
this._defaultHeaders
|
|
377
|
-
);
|
|
378
|
-
const produces = [
|
|
379
|
-
'application/vnd.segment.v1+json',
|
|
380
|
-
'application/json',
|
|
381
|
-
];
|
|
382
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
383
|
-
localVarHeaderParams.Accept = produces[0];
|
|
384
|
-
} else {
|
|
385
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
386
|
-
}
|
|
387
|
-
let localVarFormParams: any = {};
|
|
388
|
-
|
|
389
|
-
// verify required parameter 'CreateDestinationV1Input' is not null or undefined
|
|
289
|
+
// verify required parameter 'CreateDestinationSubscriptionAlphaInput' is not null or undefined
|
|
390
290
|
if (
|
|
391
|
-
|
|
392
|
-
|
|
291
|
+
CreateDestinationSubscriptionAlphaInput === null ||
|
|
292
|
+
CreateDestinationSubscriptionAlphaInput === undefined
|
|
393
293
|
) {
|
|
394
294
|
throw new Error(
|
|
395
|
-
'Required parameter
|
|
295
|
+
'Required parameter CreateDestinationSubscriptionAlphaInput was null or undefined when calling createDestinationSubscription.'
|
|
396
296
|
);
|
|
397
297
|
}
|
|
398
298
|
|
|
@@ -408,8 +308,8 @@ export class DestinationsApi {
|
|
|
408
308
|
useQuerystring: this._useQuerystring,
|
|
409
309
|
json: true,
|
|
410
310
|
body: ObjectSerializer.serialize(
|
|
411
|
-
|
|
412
|
-
'
|
|
311
|
+
CreateDestinationSubscriptionAlphaInput,
|
|
312
|
+
'CreateDestinationSubscriptionAlphaInput'
|
|
413
313
|
),
|
|
414
314
|
};
|
|
415
315
|
|
|
@@ -442,7 +342,7 @@ export class DestinationsApi {
|
|
|
442
342
|
}
|
|
443
343
|
return new Promise<{
|
|
444
344
|
response: http.IncomingMessage;
|
|
445
|
-
body:
|
|
345
|
+
body: CreateDestinationSubscription200Response;
|
|
446
346
|
}>((resolve, reject) => {
|
|
447
347
|
localVarRequest(
|
|
448
348
|
localVarRequestOptions,
|
|
@@ -457,7 +357,7 @@ export class DestinationsApi {
|
|
|
457
357
|
) {
|
|
458
358
|
body = ObjectSerializer.deserialize(
|
|
459
359
|
body,
|
|
460
|
-
'
|
|
360
|
+
'CreateDestinationSubscription200Response'
|
|
461
361
|
);
|
|
462
362
|
resolve({ response: response, body: body });
|
|
463
363
|
} else {
|
|
@@ -476,22 +376,20 @@ export class DestinationsApi {
|
|
|
476
376
|
});
|
|
477
377
|
}
|
|
478
378
|
/**
|
|
479
|
-
*
|
|
480
|
-
* @summary
|
|
379
|
+
* Deletes an existing Destination. When called, this endpoint may generate the `Integration Deleted` event in the [audit trail](/tag/Audit-Trail). Config API omitted fields: - `catalogId`
|
|
380
|
+
* @summary Delete Destination
|
|
481
381
|
* @param destinationId
|
|
482
|
-
* @param CreateDestinationSubscriptionAlphaInput
|
|
483
382
|
*/
|
|
484
|
-
public async
|
|
383
|
+
public async deleteDestination(
|
|
485
384
|
destinationId: string,
|
|
486
|
-
CreateDestinationSubscriptionAlphaInput: CreateDestinationSubscriptionAlphaInput,
|
|
487
385
|
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
488
386
|
): Promise<{
|
|
489
387
|
response: http.IncomingMessage;
|
|
490
|
-
body:
|
|
388
|
+
body: DeleteDestination200Response;
|
|
491
389
|
}> {
|
|
492
390
|
const localVarPath =
|
|
493
391
|
this.basePath +
|
|
494
|
-
'/destinations/{destinationId}
|
|
392
|
+
'/destinations/{destinationId}'.replace(
|
|
495
393
|
'{' + 'destinationId' + '}',
|
|
496
394
|
encodeURIComponent(String(destinationId))
|
|
497
395
|
);
|
|
@@ -501,30 +399,23 @@ export class DestinationsApi {
|
|
|
501
399
|
this._defaultHeaders
|
|
502
400
|
);
|
|
503
401
|
const produces = [
|
|
504
|
-
'application/vnd.segment.
|
|
402
|
+
'application/vnd.segment.v1+json',
|
|
505
403
|
'application/json',
|
|
404
|
+
'application/vnd.segment.v1beta+json',
|
|
405
|
+
'application/vnd.segment.v1alpha+json',
|
|
506
406
|
];
|
|
407
|
+
// give precedence to 'application/json'
|
|
507
408
|
if (produces.indexOf('application/json') >= 0) {
|
|
508
|
-
localVarHeaderParams.Accept = produces[0];
|
|
509
|
-
} else {
|
|
510
409
|
localVarHeaderParams.Accept = 'application/json';
|
|
410
|
+
} else {
|
|
411
|
+
localVarHeaderParams.Accept = produces.join(',');
|
|
511
412
|
}
|
|
512
413
|
let localVarFormParams: any = {};
|
|
513
414
|
|
|
514
415
|
// verify required parameter 'destinationId' is not null or undefined
|
|
515
416
|
if (destinationId === null || destinationId === undefined) {
|
|
516
417
|
throw new Error(
|
|
517
|
-
'Required parameter destinationId was null or undefined when calling
|
|
518
|
-
);
|
|
519
|
-
}
|
|
520
|
-
|
|
521
|
-
// verify required parameter 'CreateDestinationSubscriptionAlphaInput' is not null or undefined
|
|
522
|
-
if (
|
|
523
|
-
CreateDestinationSubscriptionAlphaInput === null ||
|
|
524
|
-
CreateDestinationSubscriptionAlphaInput === undefined
|
|
525
|
-
) {
|
|
526
|
-
throw new Error(
|
|
527
|
-
'Required parameter CreateDestinationSubscriptionAlphaInput was null or undefined when calling createDestinationSubscription.'
|
|
418
|
+
'Required parameter destinationId was null or undefined when calling deleteDestination.'
|
|
528
419
|
);
|
|
529
420
|
}
|
|
530
421
|
|
|
@@ -533,16 +424,12 @@ export class DestinationsApi {
|
|
|
533
424
|
let localVarUseFormData = false;
|
|
534
425
|
|
|
535
426
|
let localVarRequestOptions: localVarRequest.Options = {
|
|
536
|
-
method: '
|
|
427
|
+
method: 'DELETE',
|
|
537
428
|
qs: localVarQueryParameters,
|
|
538
429
|
headers: localVarHeaderParams,
|
|
539
430
|
uri: localVarPath,
|
|
540
431
|
useQuerystring: this._useQuerystring,
|
|
541
432
|
json: true,
|
|
542
|
-
body: ObjectSerializer.serialize(
|
|
543
|
-
CreateDestinationSubscriptionAlphaInput,
|
|
544
|
-
'CreateDestinationSubscriptionAlphaInput'
|
|
545
|
-
),
|
|
546
433
|
};
|
|
547
434
|
|
|
548
435
|
let authenticationPromise = Promise.resolve();
|
|
@@ -574,7 +461,7 @@ export class DestinationsApi {
|
|
|
574
461
|
}
|
|
575
462
|
return new Promise<{
|
|
576
463
|
response: http.IncomingMessage;
|
|
577
|
-
body:
|
|
464
|
+
body: DeleteDestination200Response;
|
|
578
465
|
}>((resolve, reject) => {
|
|
579
466
|
localVarRequest(
|
|
580
467
|
localVarRequestOptions,
|
|
@@ -589,7 +476,7 @@ export class DestinationsApi {
|
|
|
589
476
|
) {
|
|
590
477
|
body = ObjectSerializer.deserialize(
|
|
591
478
|
body,
|
|
592
|
-
'
|
|
479
|
+
'DeleteDestination200Response'
|
|
593
480
|
);
|
|
594
481
|
resolve({ response: response, body: body });
|
|
595
482
|
} else {
|
|
@@ -608,18 +495,23 @@ export class DestinationsApi {
|
|
|
608
495
|
});
|
|
609
496
|
}
|
|
610
497
|
/**
|
|
611
|
-
*
|
|
612
|
-
* @summary
|
|
613
|
-
* @param
|
|
498
|
+
* Returns a Destination by its id. Config API omitted fields: - `catalogId`
|
|
499
|
+
* @summary Get Destination
|
|
500
|
+
* @param destinationId
|
|
614
501
|
*/
|
|
615
|
-
public async
|
|
616
|
-
|
|
502
|
+
public async getDestination(
|
|
503
|
+
destinationId: string,
|
|
617
504
|
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
618
505
|
): Promise<{
|
|
619
506
|
response: http.IncomingMessage;
|
|
620
|
-
body:
|
|
507
|
+
body: GetDestination200Response;
|
|
621
508
|
}> {
|
|
622
|
-
const localVarPath =
|
|
509
|
+
const localVarPath =
|
|
510
|
+
this.basePath +
|
|
511
|
+
'/destinations/{destinationId}'.replace(
|
|
512
|
+
'{' + 'destinationId' + '}',
|
|
513
|
+
encodeURIComponent(String(destinationId))
|
|
514
|
+
);
|
|
623
515
|
let localVarQueryParameters: any = {};
|
|
624
516
|
let localVarHeaderParams: any = (<any>Object).assign(
|
|
625
517
|
{},
|
|
@@ -628,1861 +520,21 @@ export class DestinationsApi {
|
|
|
628
520
|
const produces = [
|
|
629
521
|
'application/vnd.segment.v1+json',
|
|
630
522
|
'application/json',
|
|
523
|
+
'application/vnd.segment.v1beta+json',
|
|
524
|
+
'application/vnd.segment.v1alpha+json',
|
|
631
525
|
];
|
|
526
|
+
// give precedence to 'application/json'
|
|
632
527
|
if (produces.indexOf('application/json') >= 0) {
|
|
633
|
-
localVarHeaderParams.Accept = produces[0];
|
|
634
|
-
} else {
|
|
635
528
|
localVarHeaderParams.Accept = 'application/json';
|
|
529
|
+
} else {
|
|
530
|
+
localVarHeaderParams.Accept = produces.join(',');
|
|
636
531
|
}
|
|
637
|
-
let localVarFormParams: any = {};
|
|
638
|
-
|
|
639
|
-
// verify required parameter '
|
|
640
|
-
if (
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
) {
|
|
644
|
-
throw new Error(
|
|
645
|
-
'Required parameter CreateDestinationV1Input was null or undefined when calling createDestinationV1.'
|
|
646
|
-
);
|
|
647
|
-
}
|
|
648
|
-
|
|
649
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
650
|
-
|
|
651
|
-
let localVarUseFormData = false;
|
|
652
|
-
|
|
653
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
654
|
-
method: 'POST',
|
|
655
|
-
qs: localVarQueryParameters,
|
|
656
|
-
headers: localVarHeaderParams,
|
|
657
|
-
uri: localVarPath,
|
|
658
|
-
useQuerystring: this._useQuerystring,
|
|
659
|
-
json: true,
|
|
660
|
-
body: ObjectSerializer.serialize(
|
|
661
|
-
CreateDestinationV1Input,
|
|
662
|
-
'CreateDestinationV1Input'
|
|
663
|
-
),
|
|
664
|
-
};
|
|
665
|
-
|
|
666
|
-
let authenticationPromise = Promise.resolve();
|
|
667
|
-
if (this.authentications.token.accessToken) {
|
|
668
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
669
|
-
this.authentications.token.applyToRequest(
|
|
670
|
-
localVarRequestOptions
|
|
671
|
-
)
|
|
672
|
-
);
|
|
673
|
-
}
|
|
674
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
675
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
676
|
-
);
|
|
677
|
-
|
|
678
|
-
let interceptorPromise = authenticationPromise;
|
|
679
|
-
for (const interceptor of this.interceptors) {
|
|
680
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
681
|
-
interceptor(localVarRequestOptions)
|
|
682
|
-
);
|
|
683
|
-
}
|
|
684
|
-
|
|
685
|
-
return interceptorPromise.then(() => {
|
|
686
|
-
if (Object.keys(localVarFormParams).length) {
|
|
687
|
-
if (localVarUseFormData) {
|
|
688
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
689
|
-
} else {
|
|
690
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
691
|
-
}
|
|
692
|
-
}
|
|
693
|
-
return new Promise<{
|
|
694
|
-
response: http.IncomingMessage;
|
|
695
|
-
body: CreateDestination200Response;
|
|
696
|
-
}>((resolve, reject) => {
|
|
697
|
-
localVarRequest(
|
|
698
|
-
localVarRequestOptions,
|
|
699
|
-
(error, response, body) => {
|
|
700
|
-
if (error) {
|
|
701
|
-
reject(error);
|
|
702
|
-
} else {
|
|
703
|
-
if (
|
|
704
|
-
response.statusCode &&
|
|
705
|
-
response.statusCode >= 200 &&
|
|
706
|
-
response.statusCode <= 299
|
|
707
|
-
) {
|
|
708
|
-
body = ObjectSerializer.deserialize(
|
|
709
|
-
body,
|
|
710
|
-
'CreateDestination200Response'
|
|
711
|
-
);
|
|
712
|
-
resolve({ response: response, body: body });
|
|
713
|
-
} else {
|
|
714
|
-
reject(
|
|
715
|
-
new HttpError(
|
|
716
|
-
response,
|
|
717
|
-
body,
|
|
718
|
-
response.statusCode
|
|
719
|
-
)
|
|
720
|
-
);
|
|
721
|
-
}
|
|
722
|
-
}
|
|
723
|
-
}
|
|
724
|
-
);
|
|
725
|
-
});
|
|
726
|
-
});
|
|
727
|
-
}
|
|
728
|
-
/**
|
|
729
|
-
* Deletes an existing Destination. When called, this endpoint may generate the `Integration Deleted` [Audit Trail](/tag/Audit-Trail) event. Config API omitted fields: - `catalogId`
|
|
730
|
-
* @summary Delete Destination
|
|
731
|
-
* @param destinationId
|
|
732
|
-
*/
|
|
733
|
-
public async deleteDestinationAlpha(
|
|
734
|
-
destinationId: string,
|
|
735
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
736
|
-
): Promise<{
|
|
737
|
-
response: http.IncomingMessage;
|
|
738
|
-
body: DeleteDestination200Response;
|
|
739
|
-
}> {
|
|
740
|
-
const localVarPath =
|
|
741
|
-
this.basePath +
|
|
742
|
-
'/destinations/{destinationId}'.replace(
|
|
743
|
-
'{' + 'destinationId' + '}',
|
|
744
|
-
encodeURIComponent(String(destinationId))
|
|
745
|
-
);
|
|
746
|
-
let localVarQueryParameters: any = {};
|
|
747
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
748
|
-
{},
|
|
749
|
-
this._defaultHeaders
|
|
750
|
-
);
|
|
751
|
-
const produces = [
|
|
752
|
-
'application/vnd.segment.v1alpha+json',
|
|
753
|
-
'application/json',
|
|
754
|
-
];
|
|
755
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
756
|
-
localVarHeaderParams.Accept = produces[0];
|
|
757
|
-
} else {
|
|
758
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
759
|
-
}
|
|
760
|
-
let localVarFormParams: any = {};
|
|
761
|
-
|
|
762
|
-
// verify required parameter 'destinationId' is not null or undefined
|
|
763
|
-
if (destinationId === null || destinationId === undefined) {
|
|
764
|
-
throw new Error(
|
|
765
|
-
'Required parameter destinationId was null or undefined when calling deleteDestinationAlpha.'
|
|
766
|
-
);
|
|
767
|
-
}
|
|
768
|
-
|
|
769
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
770
|
-
|
|
771
|
-
let localVarUseFormData = false;
|
|
772
|
-
|
|
773
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
774
|
-
method: 'DELETE',
|
|
775
|
-
qs: localVarQueryParameters,
|
|
776
|
-
headers: localVarHeaderParams,
|
|
777
|
-
uri: localVarPath,
|
|
778
|
-
useQuerystring: this._useQuerystring,
|
|
779
|
-
json: true,
|
|
780
|
-
};
|
|
781
|
-
|
|
782
|
-
let authenticationPromise = Promise.resolve();
|
|
783
|
-
if (this.authentications.token.accessToken) {
|
|
784
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
785
|
-
this.authentications.token.applyToRequest(
|
|
786
|
-
localVarRequestOptions
|
|
787
|
-
)
|
|
788
|
-
);
|
|
789
|
-
}
|
|
790
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
791
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
792
|
-
);
|
|
793
|
-
|
|
794
|
-
let interceptorPromise = authenticationPromise;
|
|
795
|
-
for (const interceptor of this.interceptors) {
|
|
796
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
797
|
-
interceptor(localVarRequestOptions)
|
|
798
|
-
);
|
|
799
|
-
}
|
|
800
|
-
|
|
801
|
-
return interceptorPromise.then(() => {
|
|
802
|
-
if (Object.keys(localVarFormParams).length) {
|
|
803
|
-
if (localVarUseFormData) {
|
|
804
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
805
|
-
} else {
|
|
806
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
807
|
-
}
|
|
808
|
-
}
|
|
809
|
-
return new Promise<{
|
|
810
|
-
response: http.IncomingMessage;
|
|
811
|
-
body: DeleteDestination200Response;
|
|
812
|
-
}>((resolve, reject) => {
|
|
813
|
-
localVarRequest(
|
|
814
|
-
localVarRequestOptions,
|
|
815
|
-
(error, response, body) => {
|
|
816
|
-
if (error) {
|
|
817
|
-
reject(error);
|
|
818
|
-
} else {
|
|
819
|
-
if (
|
|
820
|
-
response.statusCode &&
|
|
821
|
-
response.statusCode >= 200 &&
|
|
822
|
-
response.statusCode <= 299
|
|
823
|
-
) {
|
|
824
|
-
body = ObjectSerializer.deserialize(
|
|
825
|
-
body,
|
|
826
|
-
'DeleteDestination200Response'
|
|
827
|
-
);
|
|
828
|
-
resolve({ response: response, body: body });
|
|
829
|
-
} else {
|
|
830
|
-
reject(
|
|
831
|
-
new HttpError(
|
|
832
|
-
response,
|
|
833
|
-
body,
|
|
834
|
-
response.statusCode
|
|
835
|
-
)
|
|
836
|
-
);
|
|
837
|
-
}
|
|
838
|
-
}
|
|
839
|
-
}
|
|
840
|
-
);
|
|
841
|
-
});
|
|
842
|
-
});
|
|
843
|
-
}
|
|
844
|
-
/**
|
|
845
|
-
* Deletes an existing Destination. When called, this endpoint may generate the `Integration Deleted` [Audit Trail](/tag/Audit-Trail) event. Config API omitted fields: - `catalogId`
|
|
846
|
-
* @summary Delete Destination
|
|
847
|
-
* @param destinationId
|
|
848
|
-
*/
|
|
849
|
-
public async deleteDestinationBeta(
|
|
850
|
-
destinationId: string,
|
|
851
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
852
|
-
): Promise<{
|
|
853
|
-
response: http.IncomingMessage;
|
|
854
|
-
body: DeleteDestination200Response;
|
|
855
|
-
}> {
|
|
856
|
-
const localVarPath =
|
|
857
|
-
this.basePath +
|
|
858
|
-
'/destinations/{destinationId}'.replace(
|
|
859
|
-
'{' + 'destinationId' + '}',
|
|
860
|
-
encodeURIComponent(String(destinationId))
|
|
861
|
-
);
|
|
862
|
-
let localVarQueryParameters: any = {};
|
|
863
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
864
|
-
{},
|
|
865
|
-
this._defaultHeaders
|
|
866
|
-
);
|
|
867
|
-
const produces = [
|
|
868
|
-
'application/vnd.segment.v1beta+json',
|
|
869
|
-
'application/json',
|
|
870
|
-
];
|
|
871
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
872
|
-
localVarHeaderParams.Accept = produces[0];
|
|
873
|
-
} else {
|
|
874
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
875
|
-
}
|
|
876
|
-
let localVarFormParams: any = {};
|
|
877
|
-
|
|
878
|
-
// verify required parameter 'destinationId' is not null or undefined
|
|
879
|
-
if (destinationId === null || destinationId === undefined) {
|
|
880
|
-
throw new Error(
|
|
881
|
-
'Required parameter destinationId was null or undefined when calling deleteDestinationBeta.'
|
|
882
|
-
);
|
|
883
|
-
}
|
|
884
|
-
|
|
885
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
886
|
-
|
|
887
|
-
let localVarUseFormData = false;
|
|
888
|
-
|
|
889
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
890
|
-
method: 'DELETE',
|
|
891
|
-
qs: localVarQueryParameters,
|
|
892
|
-
headers: localVarHeaderParams,
|
|
893
|
-
uri: localVarPath,
|
|
894
|
-
useQuerystring: this._useQuerystring,
|
|
895
|
-
json: true,
|
|
896
|
-
};
|
|
897
|
-
|
|
898
|
-
let authenticationPromise = Promise.resolve();
|
|
899
|
-
if (this.authentications.token.accessToken) {
|
|
900
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
901
|
-
this.authentications.token.applyToRequest(
|
|
902
|
-
localVarRequestOptions
|
|
903
|
-
)
|
|
904
|
-
);
|
|
905
|
-
}
|
|
906
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
907
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
908
|
-
);
|
|
909
|
-
|
|
910
|
-
let interceptorPromise = authenticationPromise;
|
|
911
|
-
for (const interceptor of this.interceptors) {
|
|
912
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
913
|
-
interceptor(localVarRequestOptions)
|
|
914
|
-
);
|
|
915
|
-
}
|
|
916
|
-
|
|
917
|
-
return interceptorPromise.then(() => {
|
|
918
|
-
if (Object.keys(localVarFormParams).length) {
|
|
919
|
-
if (localVarUseFormData) {
|
|
920
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
921
|
-
} else {
|
|
922
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
923
|
-
}
|
|
924
|
-
}
|
|
925
|
-
return new Promise<{
|
|
926
|
-
response: http.IncomingMessage;
|
|
927
|
-
body: DeleteDestination200Response;
|
|
928
|
-
}>((resolve, reject) => {
|
|
929
|
-
localVarRequest(
|
|
930
|
-
localVarRequestOptions,
|
|
931
|
-
(error, response, body) => {
|
|
932
|
-
if (error) {
|
|
933
|
-
reject(error);
|
|
934
|
-
} else {
|
|
935
|
-
if (
|
|
936
|
-
response.statusCode &&
|
|
937
|
-
response.statusCode >= 200 &&
|
|
938
|
-
response.statusCode <= 299
|
|
939
|
-
) {
|
|
940
|
-
body = ObjectSerializer.deserialize(
|
|
941
|
-
body,
|
|
942
|
-
'DeleteDestination200Response'
|
|
943
|
-
);
|
|
944
|
-
resolve({ response: response, body: body });
|
|
945
|
-
} else {
|
|
946
|
-
reject(
|
|
947
|
-
new HttpError(
|
|
948
|
-
response,
|
|
949
|
-
body,
|
|
950
|
-
response.statusCode
|
|
951
|
-
)
|
|
952
|
-
);
|
|
953
|
-
}
|
|
954
|
-
}
|
|
955
|
-
}
|
|
956
|
-
);
|
|
957
|
-
});
|
|
958
|
-
});
|
|
959
|
-
}
|
|
960
|
-
/**
|
|
961
|
-
* Deletes an existing Destination. When called, this endpoint may generate the `Integration Deleted` [Audit Trail](/tag/Audit-Trail) event. Config API omitted fields: - `catalogId`
|
|
962
|
-
* @summary Delete Destination
|
|
963
|
-
* @param destinationId
|
|
964
|
-
*/
|
|
965
|
-
public async deleteDestinationCurrent(
|
|
966
|
-
destinationId: string,
|
|
967
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
968
|
-
): Promise<{
|
|
969
|
-
response: http.IncomingMessage;
|
|
970
|
-
body: DeleteDestination200Response;
|
|
971
|
-
}> {
|
|
972
|
-
const localVarPath =
|
|
973
|
-
this.basePath +
|
|
974
|
-
'/destinations/{destinationId}'.replace(
|
|
975
|
-
'{' + 'destinationId' + '}',
|
|
976
|
-
encodeURIComponent(String(destinationId))
|
|
977
|
-
);
|
|
978
|
-
let localVarQueryParameters: any = {};
|
|
979
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
980
|
-
{},
|
|
981
|
-
this._defaultHeaders
|
|
982
|
-
);
|
|
983
|
-
const produces = ['application/json'];
|
|
984
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
985
|
-
localVarHeaderParams.Accept = produces[0];
|
|
986
|
-
} else {
|
|
987
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
988
|
-
}
|
|
989
|
-
let localVarFormParams: any = {};
|
|
990
|
-
|
|
991
|
-
// verify required parameter 'destinationId' is not null or undefined
|
|
992
|
-
if (destinationId === null || destinationId === undefined) {
|
|
993
|
-
throw new Error(
|
|
994
|
-
'Required parameter destinationId was null or undefined when calling deleteDestinationCurrent.'
|
|
995
|
-
);
|
|
996
|
-
}
|
|
997
|
-
|
|
998
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
999
|
-
|
|
1000
|
-
let localVarUseFormData = false;
|
|
1001
|
-
|
|
1002
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
1003
|
-
method: 'DELETE',
|
|
1004
|
-
qs: localVarQueryParameters,
|
|
1005
|
-
headers: localVarHeaderParams,
|
|
1006
|
-
uri: localVarPath,
|
|
1007
|
-
useQuerystring: this._useQuerystring,
|
|
1008
|
-
json: true,
|
|
1009
|
-
};
|
|
1010
|
-
|
|
1011
|
-
let authenticationPromise = Promise.resolve();
|
|
1012
|
-
if (this.authentications.token.accessToken) {
|
|
1013
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1014
|
-
this.authentications.token.applyToRequest(
|
|
1015
|
-
localVarRequestOptions
|
|
1016
|
-
)
|
|
1017
|
-
);
|
|
1018
|
-
}
|
|
1019
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1020
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
1021
|
-
);
|
|
1022
|
-
|
|
1023
|
-
let interceptorPromise = authenticationPromise;
|
|
1024
|
-
for (const interceptor of this.interceptors) {
|
|
1025
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
1026
|
-
interceptor(localVarRequestOptions)
|
|
1027
|
-
);
|
|
1028
|
-
}
|
|
1029
|
-
|
|
1030
|
-
return interceptorPromise.then(() => {
|
|
1031
|
-
if (Object.keys(localVarFormParams).length) {
|
|
1032
|
-
if (localVarUseFormData) {
|
|
1033
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
1034
|
-
} else {
|
|
1035
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
1036
|
-
}
|
|
1037
|
-
}
|
|
1038
|
-
return new Promise<{
|
|
1039
|
-
response: http.IncomingMessage;
|
|
1040
|
-
body: DeleteDestination200Response;
|
|
1041
|
-
}>((resolve, reject) => {
|
|
1042
|
-
localVarRequest(
|
|
1043
|
-
localVarRequestOptions,
|
|
1044
|
-
(error, response, body) => {
|
|
1045
|
-
if (error) {
|
|
1046
|
-
reject(error);
|
|
1047
|
-
} else {
|
|
1048
|
-
if (
|
|
1049
|
-
response.statusCode &&
|
|
1050
|
-
response.statusCode >= 200 &&
|
|
1051
|
-
response.statusCode <= 299
|
|
1052
|
-
) {
|
|
1053
|
-
body = ObjectSerializer.deserialize(
|
|
1054
|
-
body,
|
|
1055
|
-
'DeleteDestination200Response'
|
|
1056
|
-
);
|
|
1057
|
-
resolve({ response: response, body: body });
|
|
1058
|
-
} else {
|
|
1059
|
-
reject(
|
|
1060
|
-
new HttpError(
|
|
1061
|
-
response,
|
|
1062
|
-
body,
|
|
1063
|
-
response.statusCode
|
|
1064
|
-
)
|
|
1065
|
-
);
|
|
1066
|
-
}
|
|
1067
|
-
}
|
|
1068
|
-
}
|
|
1069
|
-
);
|
|
1070
|
-
});
|
|
1071
|
-
});
|
|
1072
|
-
}
|
|
1073
|
-
/**
|
|
1074
|
-
* Deletes an existing Destination. When called, this endpoint may generate the `Integration Deleted` [Audit Trail](/tag/Audit-Trail) event. Config API omitted fields: - `catalogId`
|
|
1075
|
-
* @summary Delete Destination
|
|
1076
|
-
* @param destinationId
|
|
1077
|
-
*/
|
|
1078
|
-
public async deleteDestinationV1(
|
|
1079
|
-
destinationId: string,
|
|
1080
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
1081
|
-
): Promise<{
|
|
1082
|
-
response: http.IncomingMessage;
|
|
1083
|
-
body: DeleteDestination200Response;
|
|
1084
|
-
}> {
|
|
1085
|
-
const localVarPath =
|
|
1086
|
-
this.basePath +
|
|
1087
|
-
'/destinations/{destinationId}'.replace(
|
|
1088
|
-
'{' + 'destinationId' + '}',
|
|
1089
|
-
encodeURIComponent(String(destinationId))
|
|
1090
|
-
);
|
|
1091
|
-
let localVarQueryParameters: any = {};
|
|
1092
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
1093
|
-
{},
|
|
1094
|
-
this._defaultHeaders
|
|
1095
|
-
);
|
|
1096
|
-
const produces = [
|
|
1097
|
-
'application/vnd.segment.v1+json',
|
|
1098
|
-
'application/json',
|
|
1099
|
-
];
|
|
1100
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
1101
|
-
localVarHeaderParams.Accept = produces[0];
|
|
1102
|
-
} else {
|
|
1103
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
1104
|
-
}
|
|
1105
|
-
let localVarFormParams: any = {};
|
|
1106
|
-
|
|
1107
|
-
// verify required parameter 'destinationId' is not null or undefined
|
|
1108
|
-
if (destinationId === null || destinationId === undefined) {
|
|
1109
|
-
throw new Error(
|
|
1110
|
-
'Required parameter destinationId was null or undefined when calling deleteDestinationV1.'
|
|
1111
|
-
);
|
|
1112
|
-
}
|
|
1113
|
-
|
|
1114
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
1115
|
-
|
|
1116
|
-
let localVarUseFormData = false;
|
|
1117
|
-
|
|
1118
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
1119
|
-
method: 'DELETE',
|
|
1120
|
-
qs: localVarQueryParameters,
|
|
1121
|
-
headers: localVarHeaderParams,
|
|
1122
|
-
uri: localVarPath,
|
|
1123
|
-
useQuerystring: this._useQuerystring,
|
|
1124
|
-
json: true,
|
|
1125
|
-
};
|
|
1126
|
-
|
|
1127
|
-
let authenticationPromise = Promise.resolve();
|
|
1128
|
-
if (this.authentications.token.accessToken) {
|
|
1129
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1130
|
-
this.authentications.token.applyToRequest(
|
|
1131
|
-
localVarRequestOptions
|
|
1132
|
-
)
|
|
1133
|
-
);
|
|
1134
|
-
}
|
|
1135
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1136
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
1137
|
-
);
|
|
1138
|
-
|
|
1139
|
-
let interceptorPromise = authenticationPromise;
|
|
1140
|
-
for (const interceptor of this.interceptors) {
|
|
1141
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
1142
|
-
interceptor(localVarRequestOptions)
|
|
1143
|
-
);
|
|
1144
|
-
}
|
|
1145
|
-
|
|
1146
|
-
return interceptorPromise.then(() => {
|
|
1147
|
-
if (Object.keys(localVarFormParams).length) {
|
|
1148
|
-
if (localVarUseFormData) {
|
|
1149
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
1150
|
-
} else {
|
|
1151
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
1152
|
-
}
|
|
1153
|
-
}
|
|
1154
|
-
return new Promise<{
|
|
1155
|
-
response: http.IncomingMessage;
|
|
1156
|
-
body: DeleteDestination200Response;
|
|
1157
|
-
}>((resolve, reject) => {
|
|
1158
|
-
localVarRequest(
|
|
1159
|
-
localVarRequestOptions,
|
|
1160
|
-
(error, response, body) => {
|
|
1161
|
-
if (error) {
|
|
1162
|
-
reject(error);
|
|
1163
|
-
} else {
|
|
1164
|
-
if (
|
|
1165
|
-
response.statusCode &&
|
|
1166
|
-
response.statusCode >= 200 &&
|
|
1167
|
-
response.statusCode <= 299
|
|
1168
|
-
) {
|
|
1169
|
-
body = ObjectSerializer.deserialize(
|
|
1170
|
-
body,
|
|
1171
|
-
'DeleteDestination200Response'
|
|
1172
|
-
);
|
|
1173
|
-
resolve({ response: response, body: body });
|
|
1174
|
-
} else {
|
|
1175
|
-
reject(
|
|
1176
|
-
new HttpError(
|
|
1177
|
-
response,
|
|
1178
|
-
body,
|
|
1179
|
-
response.statusCode
|
|
1180
|
-
)
|
|
1181
|
-
);
|
|
1182
|
-
}
|
|
1183
|
-
}
|
|
1184
|
-
}
|
|
1185
|
-
);
|
|
1186
|
-
});
|
|
1187
|
-
});
|
|
1188
|
-
}
|
|
1189
|
-
/**
|
|
1190
|
-
* Returns a Destination by its id. Config API omitted fields: - `catalogId`
|
|
1191
|
-
* @summary Get Destination
|
|
1192
|
-
* @param destinationId
|
|
1193
|
-
*/
|
|
1194
|
-
public async getDestinationAlpha(
|
|
1195
|
-
destinationId: string,
|
|
1196
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
1197
|
-
): Promise<{
|
|
1198
|
-
response: http.IncomingMessage;
|
|
1199
|
-
body: GetDestination200Response;
|
|
1200
|
-
}> {
|
|
1201
|
-
const localVarPath =
|
|
1202
|
-
this.basePath +
|
|
1203
|
-
'/destinations/{destinationId}'.replace(
|
|
1204
|
-
'{' + 'destinationId' + '}',
|
|
1205
|
-
encodeURIComponent(String(destinationId))
|
|
1206
|
-
);
|
|
1207
|
-
let localVarQueryParameters: any = {};
|
|
1208
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
1209
|
-
{},
|
|
1210
|
-
this._defaultHeaders
|
|
1211
|
-
);
|
|
1212
|
-
const produces = [
|
|
1213
|
-
'application/vnd.segment.v1alpha+json',
|
|
1214
|
-
'application/json',
|
|
1215
|
-
];
|
|
1216
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
1217
|
-
localVarHeaderParams.Accept = produces[0];
|
|
1218
|
-
} else {
|
|
1219
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
1220
|
-
}
|
|
1221
|
-
let localVarFormParams: any = {};
|
|
1222
|
-
|
|
1223
|
-
// verify required parameter 'destinationId' is not null or undefined
|
|
1224
|
-
if (destinationId === null || destinationId === undefined) {
|
|
1225
|
-
throw new Error(
|
|
1226
|
-
'Required parameter destinationId was null or undefined when calling getDestinationAlpha.'
|
|
1227
|
-
);
|
|
1228
|
-
}
|
|
1229
|
-
|
|
1230
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
1231
|
-
|
|
1232
|
-
let localVarUseFormData = false;
|
|
1233
|
-
|
|
1234
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
1235
|
-
method: 'GET',
|
|
1236
|
-
qs: localVarQueryParameters,
|
|
1237
|
-
headers: localVarHeaderParams,
|
|
1238
|
-
uri: localVarPath,
|
|
1239
|
-
useQuerystring: this._useQuerystring,
|
|
1240
|
-
json: true,
|
|
1241
|
-
};
|
|
1242
|
-
|
|
1243
|
-
let authenticationPromise = Promise.resolve();
|
|
1244
|
-
if (this.authentications.token.accessToken) {
|
|
1245
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1246
|
-
this.authentications.token.applyToRequest(
|
|
1247
|
-
localVarRequestOptions
|
|
1248
|
-
)
|
|
1249
|
-
);
|
|
1250
|
-
}
|
|
1251
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1252
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
1253
|
-
);
|
|
1254
|
-
|
|
1255
|
-
let interceptorPromise = authenticationPromise;
|
|
1256
|
-
for (const interceptor of this.interceptors) {
|
|
1257
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
1258
|
-
interceptor(localVarRequestOptions)
|
|
1259
|
-
);
|
|
1260
|
-
}
|
|
1261
|
-
|
|
1262
|
-
return interceptorPromise.then(() => {
|
|
1263
|
-
if (Object.keys(localVarFormParams).length) {
|
|
1264
|
-
if (localVarUseFormData) {
|
|
1265
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
1266
|
-
} else {
|
|
1267
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
1268
|
-
}
|
|
1269
|
-
}
|
|
1270
|
-
return new Promise<{
|
|
1271
|
-
response: http.IncomingMessage;
|
|
1272
|
-
body: GetDestination200Response;
|
|
1273
|
-
}>((resolve, reject) => {
|
|
1274
|
-
localVarRequest(
|
|
1275
|
-
localVarRequestOptions,
|
|
1276
|
-
(error, response, body) => {
|
|
1277
|
-
if (error) {
|
|
1278
|
-
reject(error);
|
|
1279
|
-
} else {
|
|
1280
|
-
if (
|
|
1281
|
-
response.statusCode &&
|
|
1282
|
-
response.statusCode >= 200 &&
|
|
1283
|
-
response.statusCode <= 299
|
|
1284
|
-
) {
|
|
1285
|
-
body = ObjectSerializer.deserialize(
|
|
1286
|
-
body,
|
|
1287
|
-
'GetDestination200Response'
|
|
1288
|
-
);
|
|
1289
|
-
resolve({ response: response, body: body });
|
|
1290
|
-
} else {
|
|
1291
|
-
reject(
|
|
1292
|
-
new HttpError(
|
|
1293
|
-
response,
|
|
1294
|
-
body,
|
|
1295
|
-
response.statusCode
|
|
1296
|
-
)
|
|
1297
|
-
);
|
|
1298
|
-
}
|
|
1299
|
-
}
|
|
1300
|
-
}
|
|
1301
|
-
);
|
|
1302
|
-
});
|
|
1303
|
-
});
|
|
1304
|
-
}
|
|
1305
|
-
/**
|
|
1306
|
-
* Returns a Destination by its id. Config API omitted fields: - `catalogId`
|
|
1307
|
-
* @summary Get Destination
|
|
1308
|
-
* @param destinationId
|
|
1309
|
-
*/
|
|
1310
|
-
public async getDestinationBeta(
|
|
1311
|
-
destinationId: string,
|
|
1312
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
1313
|
-
): Promise<{
|
|
1314
|
-
response: http.IncomingMessage;
|
|
1315
|
-
body: GetDestination200Response;
|
|
1316
|
-
}> {
|
|
1317
|
-
const localVarPath =
|
|
1318
|
-
this.basePath +
|
|
1319
|
-
'/destinations/{destinationId}'.replace(
|
|
1320
|
-
'{' + 'destinationId' + '}',
|
|
1321
|
-
encodeURIComponent(String(destinationId))
|
|
1322
|
-
);
|
|
1323
|
-
let localVarQueryParameters: any = {};
|
|
1324
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
1325
|
-
{},
|
|
1326
|
-
this._defaultHeaders
|
|
1327
|
-
);
|
|
1328
|
-
const produces = [
|
|
1329
|
-
'application/vnd.segment.v1beta+json',
|
|
1330
|
-
'application/json',
|
|
1331
|
-
];
|
|
1332
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
1333
|
-
localVarHeaderParams.Accept = produces[0];
|
|
1334
|
-
} else {
|
|
1335
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
1336
|
-
}
|
|
1337
|
-
let localVarFormParams: any = {};
|
|
1338
|
-
|
|
1339
|
-
// verify required parameter 'destinationId' is not null or undefined
|
|
1340
|
-
if (destinationId === null || destinationId === undefined) {
|
|
1341
|
-
throw new Error(
|
|
1342
|
-
'Required parameter destinationId was null or undefined when calling getDestinationBeta.'
|
|
1343
|
-
);
|
|
1344
|
-
}
|
|
1345
|
-
|
|
1346
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
1347
|
-
|
|
1348
|
-
let localVarUseFormData = false;
|
|
1349
|
-
|
|
1350
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
1351
|
-
method: 'GET',
|
|
1352
|
-
qs: localVarQueryParameters,
|
|
1353
|
-
headers: localVarHeaderParams,
|
|
1354
|
-
uri: localVarPath,
|
|
1355
|
-
useQuerystring: this._useQuerystring,
|
|
1356
|
-
json: true,
|
|
1357
|
-
};
|
|
1358
|
-
|
|
1359
|
-
let authenticationPromise = Promise.resolve();
|
|
1360
|
-
if (this.authentications.token.accessToken) {
|
|
1361
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1362
|
-
this.authentications.token.applyToRequest(
|
|
1363
|
-
localVarRequestOptions
|
|
1364
|
-
)
|
|
1365
|
-
);
|
|
1366
|
-
}
|
|
1367
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1368
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
1369
|
-
);
|
|
1370
|
-
|
|
1371
|
-
let interceptorPromise = authenticationPromise;
|
|
1372
|
-
for (const interceptor of this.interceptors) {
|
|
1373
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
1374
|
-
interceptor(localVarRequestOptions)
|
|
1375
|
-
);
|
|
1376
|
-
}
|
|
1377
|
-
|
|
1378
|
-
return interceptorPromise.then(() => {
|
|
1379
|
-
if (Object.keys(localVarFormParams).length) {
|
|
1380
|
-
if (localVarUseFormData) {
|
|
1381
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
1382
|
-
} else {
|
|
1383
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
1384
|
-
}
|
|
1385
|
-
}
|
|
1386
|
-
return new Promise<{
|
|
1387
|
-
response: http.IncomingMessage;
|
|
1388
|
-
body: GetDestination200Response;
|
|
1389
|
-
}>((resolve, reject) => {
|
|
1390
|
-
localVarRequest(
|
|
1391
|
-
localVarRequestOptions,
|
|
1392
|
-
(error, response, body) => {
|
|
1393
|
-
if (error) {
|
|
1394
|
-
reject(error);
|
|
1395
|
-
} else {
|
|
1396
|
-
if (
|
|
1397
|
-
response.statusCode &&
|
|
1398
|
-
response.statusCode >= 200 &&
|
|
1399
|
-
response.statusCode <= 299
|
|
1400
|
-
) {
|
|
1401
|
-
body = ObjectSerializer.deserialize(
|
|
1402
|
-
body,
|
|
1403
|
-
'GetDestination200Response'
|
|
1404
|
-
);
|
|
1405
|
-
resolve({ response: response, body: body });
|
|
1406
|
-
} else {
|
|
1407
|
-
reject(
|
|
1408
|
-
new HttpError(
|
|
1409
|
-
response,
|
|
1410
|
-
body,
|
|
1411
|
-
response.statusCode
|
|
1412
|
-
)
|
|
1413
|
-
);
|
|
1414
|
-
}
|
|
1415
|
-
}
|
|
1416
|
-
}
|
|
1417
|
-
);
|
|
1418
|
-
});
|
|
1419
|
-
});
|
|
1420
|
-
}
|
|
1421
|
-
/**
|
|
1422
|
-
* Returns a Destination by its id. Config API omitted fields: - `catalogId`
|
|
1423
|
-
* @summary Get Destination
|
|
1424
|
-
* @param destinationId
|
|
1425
|
-
*/
|
|
1426
|
-
public async getDestinationCurrent(
|
|
1427
|
-
destinationId: string,
|
|
1428
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
1429
|
-
): Promise<{
|
|
1430
|
-
response: http.IncomingMessage;
|
|
1431
|
-
body: GetDestination200Response;
|
|
1432
|
-
}> {
|
|
1433
|
-
const localVarPath =
|
|
1434
|
-
this.basePath +
|
|
1435
|
-
'/destinations/{destinationId}'.replace(
|
|
1436
|
-
'{' + 'destinationId' + '}',
|
|
1437
|
-
encodeURIComponent(String(destinationId))
|
|
1438
|
-
);
|
|
1439
|
-
let localVarQueryParameters: any = {};
|
|
1440
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
1441
|
-
{},
|
|
1442
|
-
this._defaultHeaders
|
|
1443
|
-
);
|
|
1444
|
-
const produces = ['application/json'];
|
|
1445
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
1446
|
-
localVarHeaderParams.Accept = produces[0];
|
|
1447
|
-
} else {
|
|
1448
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
1449
|
-
}
|
|
1450
|
-
let localVarFormParams: any = {};
|
|
1451
|
-
|
|
1452
|
-
// verify required parameter 'destinationId' is not null or undefined
|
|
1453
|
-
if (destinationId === null || destinationId === undefined) {
|
|
1454
|
-
throw new Error(
|
|
1455
|
-
'Required parameter destinationId was null or undefined when calling getDestinationCurrent.'
|
|
1456
|
-
);
|
|
1457
|
-
}
|
|
1458
|
-
|
|
1459
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
1460
|
-
|
|
1461
|
-
let localVarUseFormData = false;
|
|
1462
|
-
|
|
1463
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
1464
|
-
method: 'GET',
|
|
1465
|
-
qs: localVarQueryParameters,
|
|
1466
|
-
headers: localVarHeaderParams,
|
|
1467
|
-
uri: localVarPath,
|
|
1468
|
-
useQuerystring: this._useQuerystring,
|
|
1469
|
-
json: true,
|
|
1470
|
-
};
|
|
1471
|
-
|
|
1472
|
-
let authenticationPromise = Promise.resolve();
|
|
1473
|
-
if (this.authentications.token.accessToken) {
|
|
1474
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1475
|
-
this.authentications.token.applyToRequest(
|
|
1476
|
-
localVarRequestOptions
|
|
1477
|
-
)
|
|
1478
|
-
);
|
|
1479
|
-
}
|
|
1480
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1481
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
1482
|
-
);
|
|
1483
|
-
|
|
1484
|
-
let interceptorPromise = authenticationPromise;
|
|
1485
|
-
for (const interceptor of this.interceptors) {
|
|
1486
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
1487
|
-
interceptor(localVarRequestOptions)
|
|
1488
|
-
);
|
|
1489
|
-
}
|
|
1490
|
-
|
|
1491
|
-
return interceptorPromise.then(() => {
|
|
1492
|
-
if (Object.keys(localVarFormParams).length) {
|
|
1493
|
-
if (localVarUseFormData) {
|
|
1494
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
1495
|
-
} else {
|
|
1496
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
1497
|
-
}
|
|
1498
|
-
}
|
|
1499
|
-
return new Promise<{
|
|
1500
|
-
response: http.IncomingMessage;
|
|
1501
|
-
body: GetDestination200Response;
|
|
1502
|
-
}>((resolve, reject) => {
|
|
1503
|
-
localVarRequest(
|
|
1504
|
-
localVarRequestOptions,
|
|
1505
|
-
(error, response, body) => {
|
|
1506
|
-
if (error) {
|
|
1507
|
-
reject(error);
|
|
1508
|
-
} else {
|
|
1509
|
-
if (
|
|
1510
|
-
response.statusCode &&
|
|
1511
|
-
response.statusCode >= 200 &&
|
|
1512
|
-
response.statusCode <= 299
|
|
1513
|
-
) {
|
|
1514
|
-
body = ObjectSerializer.deserialize(
|
|
1515
|
-
body,
|
|
1516
|
-
'GetDestination200Response'
|
|
1517
|
-
);
|
|
1518
|
-
resolve({ response: response, body: body });
|
|
1519
|
-
} else {
|
|
1520
|
-
reject(
|
|
1521
|
-
new HttpError(
|
|
1522
|
-
response,
|
|
1523
|
-
body,
|
|
1524
|
-
response.statusCode
|
|
1525
|
-
)
|
|
1526
|
-
);
|
|
1527
|
-
}
|
|
1528
|
-
}
|
|
1529
|
-
}
|
|
1530
|
-
);
|
|
1531
|
-
});
|
|
1532
|
-
});
|
|
1533
|
-
}
|
|
1534
|
-
/**
|
|
1535
|
-
* Returns a Destination by its id. Config API omitted fields: - `catalogId`
|
|
1536
|
-
* @summary Get Destination
|
|
1537
|
-
* @param destinationId
|
|
1538
|
-
*/
|
|
1539
|
-
public async getDestinationV1(
|
|
1540
|
-
destinationId: string,
|
|
1541
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
1542
|
-
): Promise<{
|
|
1543
|
-
response: http.IncomingMessage;
|
|
1544
|
-
body: GetDestination200Response;
|
|
1545
|
-
}> {
|
|
1546
|
-
const localVarPath =
|
|
1547
|
-
this.basePath +
|
|
1548
|
-
'/destinations/{destinationId}'.replace(
|
|
1549
|
-
'{' + 'destinationId' + '}',
|
|
1550
|
-
encodeURIComponent(String(destinationId))
|
|
1551
|
-
);
|
|
1552
|
-
let localVarQueryParameters: any = {};
|
|
1553
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
1554
|
-
{},
|
|
1555
|
-
this._defaultHeaders
|
|
1556
|
-
);
|
|
1557
|
-
const produces = [
|
|
1558
|
-
'application/vnd.segment.v1+json',
|
|
1559
|
-
'application/json',
|
|
1560
|
-
];
|
|
1561
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
1562
|
-
localVarHeaderParams.Accept = produces[0];
|
|
1563
|
-
} else {
|
|
1564
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
1565
|
-
}
|
|
1566
|
-
let localVarFormParams: any = {};
|
|
1567
|
-
|
|
1568
|
-
// verify required parameter 'destinationId' is not null or undefined
|
|
1569
|
-
if (destinationId === null || destinationId === undefined) {
|
|
1570
|
-
throw new Error(
|
|
1571
|
-
'Required parameter destinationId was null or undefined when calling getDestinationV1.'
|
|
1572
|
-
);
|
|
1573
|
-
}
|
|
1574
|
-
|
|
1575
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
1576
|
-
|
|
1577
|
-
let localVarUseFormData = false;
|
|
1578
|
-
|
|
1579
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
1580
|
-
method: 'GET',
|
|
1581
|
-
qs: localVarQueryParameters,
|
|
1582
|
-
headers: localVarHeaderParams,
|
|
1583
|
-
uri: localVarPath,
|
|
1584
|
-
useQuerystring: this._useQuerystring,
|
|
1585
|
-
json: true,
|
|
1586
|
-
};
|
|
1587
|
-
|
|
1588
|
-
let authenticationPromise = Promise.resolve();
|
|
1589
|
-
if (this.authentications.token.accessToken) {
|
|
1590
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1591
|
-
this.authentications.token.applyToRequest(
|
|
1592
|
-
localVarRequestOptions
|
|
1593
|
-
)
|
|
1594
|
-
);
|
|
1595
|
-
}
|
|
1596
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1597
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
1598
|
-
);
|
|
1599
|
-
|
|
1600
|
-
let interceptorPromise = authenticationPromise;
|
|
1601
|
-
for (const interceptor of this.interceptors) {
|
|
1602
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
1603
|
-
interceptor(localVarRequestOptions)
|
|
1604
|
-
);
|
|
1605
|
-
}
|
|
1606
|
-
|
|
1607
|
-
return interceptorPromise.then(() => {
|
|
1608
|
-
if (Object.keys(localVarFormParams).length) {
|
|
1609
|
-
if (localVarUseFormData) {
|
|
1610
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
1611
|
-
} else {
|
|
1612
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
1613
|
-
}
|
|
1614
|
-
}
|
|
1615
|
-
return new Promise<{
|
|
1616
|
-
response: http.IncomingMessage;
|
|
1617
|
-
body: GetDestination200Response;
|
|
1618
|
-
}>((resolve, reject) => {
|
|
1619
|
-
localVarRequest(
|
|
1620
|
-
localVarRequestOptions,
|
|
1621
|
-
(error, response, body) => {
|
|
1622
|
-
if (error) {
|
|
1623
|
-
reject(error);
|
|
1624
|
-
} else {
|
|
1625
|
-
if (
|
|
1626
|
-
response.statusCode &&
|
|
1627
|
-
response.statusCode >= 200 &&
|
|
1628
|
-
response.statusCode <= 299
|
|
1629
|
-
) {
|
|
1630
|
-
body = ObjectSerializer.deserialize(
|
|
1631
|
-
body,
|
|
1632
|
-
'GetDestination200Response'
|
|
1633
|
-
);
|
|
1634
|
-
resolve({ response: response, body: body });
|
|
1635
|
-
} else {
|
|
1636
|
-
reject(
|
|
1637
|
-
new HttpError(
|
|
1638
|
-
response,
|
|
1639
|
-
body,
|
|
1640
|
-
response.statusCode
|
|
1641
|
-
)
|
|
1642
|
-
);
|
|
1643
|
-
}
|
|
1644
|
-
}
|
|
1645
|
-
}
|
|
1646
|
-
);
|
|
1647
|
-
});
|
|
1648
|
-
});
|
|
1649
|
-
}
|
|
1650
|
-
/**
|
|
1651
|
-
* Gets a Destination subscription by id.
|
|
1652
|
-
* @summary Get Subscription from Destination
|
|
1653
|
-
* @param destinationId
|
|
1654
|
-
* @param id
|
|
1655
|
-
*/
|
|
1656
|
-
public async getSubscriptionFromDestination(
|
|
1657
|
-
destinationId: string,
|
|
1658
|
-
id: string,
|
|
1659
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
1660
|
-
): Promise<{
|
|
1661
|
-
response: http.IncomingMessage;
|
|
1662
|
-
body: GetSubscriptionFromDestination200Response;
|
|
1663
|
-
}> {
|
|
1664
|
-
const localVarPath =
|
|
1665
|
-
this.basePath +
|
|
1666
|
-
'/destinations/{destinationId}/subscriptions/{id}'
|
|
1667
|
-
.replace(
|
|
1668
|
-
'{' + 'destinationId' + '}',
|
|
1669
|
-
encodeURIComponent(String(destinationId))
|
|
1670
|
-
)
|
|
1671
|
-
.replace('{' + 'id' + '}', encodeURIComponent(String(id)));
|
|
1672
|
-
let localVarQueryParameters: any = {};
|
|
1673
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
1674
|
-
{},
|
|
1675
|
-
this._defaultHeaders
|
|
1676
|
-
);
|
|
1677
|
-
const produces = [
|
|
1678
|
-
'application/vnd.segment.v1alpha+json',
|
|
1679
|
-
'application/json',
|
|
1680
|
-
];
|
|
1681
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
1682
|
-
localVarHeaderParams.Accept = produces[0];
|
|
1683
|
-
} else {
|
|
1684
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
1685
|
-
}
|
|
1686
|
-
let localVarFormParams: any = {};
|
|
1687
|
-
|
|
1688
|
-
// verify required parameter 'destinationId' is not null or undefined
|
|
1689
|
-
if (destinationId === null || destinationId === undefined) {
|
|
1690
|
-
throw new Error(
|
|
1691
|
-
'Required parameter destinationId was null or undefined when calling getSubscriptionFromDestination.'
|
|
1692
|
-
);
|
|
1693
|
-
}
|
|
1694
|
-
|
|
1695
|
-
// verify required parameter 'id' is not null or undefined
|
|
1696
|
-
if (id === null || id === undefined) {
|
|
1697
|
-
throw new Error(
|
|
1698
|
-
'Required parameter id was null or undefined when calling getSubscriptionFromDestination.'
|
|
1699
|
-
);
|
|
1700
|
-
}
|
|
1701
|
-
|
|
1702
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
1703
|
-
|
|
1704
|
-
let localVarUseFormData = false;
|
|
1705
|
-
|
|
1706
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
1707
|
-
method: 'GET',
|
|
1708
|
-
qs: localVarQueryParameters,
|
|
1709
|
-
headers: localVarHeaderParams,
|
|
1710
|
-
uri: localVarPath,
|
|
1711
|
-
useQuerystring: this._useQuerystring,
|
|
1712
|
-
json: true,
|
|
1713
|
-
};
|
|
1714
|
-
|
|
1715
|
-
let authenticationPromise = Promise.resolve();
|
|
1716
|
-
if (this.authentications.token.accessToken) {
|
|
1717
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1718
|
-
this.authentications.token.applyToRequest(
|
|
1719
|
-
localVarRequestOptions
|
|
1720
|
-
)
|
|
1721
|
-
);
|
|
1722
|
-
}
|
|
1723
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1724
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
1725
|
-
);
|
|
1726
|
-
|
|
1727
|
-
let interceptorPromise = authenticationPromise;
|
|
1728
|
-
for (const interceptor of this.interceptors) {
|
|
1729
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
1730
|
-
interceptor(localVarRequestOptions)
|
|
1731
|
-
);
|
|
1732
|
-
}
|
|
1733
|
-
|
|
1734
|
-
return interceptorPromise.then(() => {
|
|
1735
|
-
if (Object.keys(localVarFormParams).length) {
|
|
1736
|
-
if (localVarUseFormData) {
|
|
1737
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
1738
|
-
} else {
|
|
1739
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
1740
|
-
}
|
|
1741
|
-
}
|
|
1742
|
-
return new Promise<{
|
|
1743
|
-
response: http.IncomingMessage;
|
|
1744
|
-
body: GetSubscriptionFromDestination200Response;
|
|
1745
|
-
}>((resolve, reject) => {
|
|
1746
|
-
localVarRequest(
|
|
1747
|
-
localVarRequestOptions,
|
|
1748
|
-
(error, response, body) => {
|
|
1749
|
-
if (error) {
|
|
1750
|
-
reject(error);
|
|
1751
|
-
} else {
|
|
1752
|
-
if (
|
|
1753
|
-
response.statusCode &&
|
|
1754
|
-
response.statusCode >= 200 &&
|
|
1755
|
-
response.statusCode <= 299
|
|
1756
|
-
) {
|
|
1757
|
-
body = ObjectSerializer.deserialize(
|
|
1758
|
-
body,
|
|
1759
|
-
'GetSubscriptionFromDestination200Response'
|
|
1760
|
-
);
|
|
1761
|
-
resolve({ response: response, body: body });
|
|
1762
|
-
} else {
|
|
1763
|
-
reject(
|
|
1764
|
-
new HttpError(
|
|
1765
|
-
response,
|
|
1766
|
-
body,
|
|
1767
|
-
response.statusCode
|
|
1768
|
-
)
|
|
1769
|
-
);
|
|
1770
|
-
}
|
|
1771
|
-
}
|
|
1772
|
-
}
|
|
1773
|
-
);
|
|
1774
|
-
});
|
|
1775
|
-
});
|
|
1776
|
-
}
|
|
1777
|
-
/**
|
|
1778
|
-
* Get event delivery metrics summary from a Destination. Based on the granularity, there are restrictions on the time range you can query: **Minute Granularity**: - Max time range: 4 hours - Oldest possible start time: 48 hours in the past **Hour Granularity**: - Max Time range: 1 week - Oldest possible start time: 10 days in the past **Day Granularity**: - Max time range: 60 days - Oldest possible start time: 60 days in the past
|
|
1779
|
-
* @summary List Delivery Metrics Summary from Destination
|
|
1780
|
-
* @param destinationId
|
|
1781
|
-
* @param sourceId The id of the Source linked to the Destination. Config API note: analogous to `parent`. This parameter exists in alpha.
|
|
1782
|
-
* @param startTime Filter events that happened after this time. Defaults to: - 1 hour ago if granularity is `MINUTE`. - 7 days ago if granularity is `HOUR`. - 30 days ago if granularity is `DAY`. This parameter exists in alpha.
|
|
1783
|
-
* @param endTime Filter events that happened before this time. Defaults to now if not set. This parameter exists in alpha.
|
|
1784
|
-
* @param granularity The granularity to filter metrics to. Either `MINUTE`, `HOUR` or `DAY`. Defaults to `MINUTE` if not set. This parameter exists in alpha.
|
|
1785
|
-
*/
|
|
1786
|
-
public async listDeliveryMetricsSummaryFromDestinationAlpha(
|
|
1787
|
-
destinationId: string,
|
|
1788
|
-
sourceId: string,
|
|
1789
|
-
startTime?: string,
|
|
1790
|
-
endTime?: string,
|
|
1791
|
-
granularity?: 'DAY' | 'HOUR' | 'MINUTE',
|
|
1792
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
1793
|
-
): Promise<{
|
|
1794
|
-
response: http.IncomingMessage;
|
|
1795
|
-
body: ListDeliveryMetricsSummaryFromDestination200Response;
|
|
1796
|
-
}> {
|
|
1797
|
-
const localVarPath =
|
|
1798
|
-
this.basePath +
|
|
1799
|
-
'/destinations/{destinationId}/delivery-metrics'.replace(
|
|
1800
|
-
'{' + 'destinationId' + '}',
|
|
1801
|
-
encodeURIComponent(String(destinationId))
|
|
1802
|
-
);
|
|
1803
|
-
let localVarQueryParameters: any = {};
|
|
1804
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
1805
|
-
{},
|
|
1806
|
-
this._defaultHeaders
|
|
1807
|
-
);
|
|
1808
|
-
const produces = [
|
|
1809
|
-
'application/vnd.segment.v1alpha+json',
|
|
1810
|
-
'application/json',
|
|
1811
|
-
];
|
|
1812
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
1813
|
-
localVarHeaderParams.Accept = produces[0];
|
|
1814
|
-
} else {
|
|
1815
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
1816
|
-
}
|
|
1817
|
-
let localVarFormParams: any = {};
|
|
1818
|
-
|
|
1819
|
-
// verify required parameter 'destinationId' is not null or undefined
|
|
1820
|
-
if (destinationId === null || destinationId === undefined) {
|
|
1821
|
-
throw new Error(
|
|
1822
|
-
'Required parameter destinationId was null or undefined when calling listDeliveryMetricsSummaryFromDestinationAlpha.'
|
|
1823
|
-
);
|
|
1824
|
-
}
|
|
1825
|
-
|
|
1826
|
-
// verify required parameter 'sourceId' is not null or undefined
|
|
1827
|
-
if (sourceId === null || sourceId === undefined) {
|
|
1828
|
-
throw new Error(
|
|
1829
|
-
'Required parameter sourceId was null or undefined when calling listDeliveryMetricsSummaryFromDestinationAlpha.'
|
|
1830
|
-
);
|
|
1831
|
-
}
|
|
1832
|
-
|
|
1833
|
-
if (sourceId !== undefined) {
|
|
1834
|
-
localVarQueryParameters['sourceId'] = ObjectSerializer.serialize(
|
|
1835
|
-
sourceId,
|
|
1836
|
-
'string'
|
|
1837
|
-
);
|
|
1838
|
-
}
|
|
1839
|
-
|
|
1840
|
-
if (startTime !== undefined) {
|
|
1841
|
-
localVarQueryParameters['startTime'] = ObjectSerializer.serialize(
|
|
1842
|
-
startTime,
|
|
1843
|
-
'string'
|
|
1844
|
-
);
|
|
1845
|
-
}
|
|
1846
|
-
|
|
1847
|
-
if (endTime !== undefined) {
|
|
1848
|
-
localVarQueryParameters['endTime'] = ObjectSerializer.serialize(
|
|
1849
|
-
endTime,
|
|
1850
|
-
'string'
|
|
1851
|
-
);
|
|
1852
|
-
}
|
|
1853
|
-
|
|
1854
|
-
if (granularity !== undefined) {
|
|
1855
|
-
localVarQueryParameters['granularity'] = ObjectSerializer.serialize(
|
|
1856
|
-
granularity,
|
|
1857
|
-
"'DAY' | 'HOUR' | 'MINUTE'"
|
|
1858
|
-
);
|
|
1859
|
-
}
|
|
1860
|
-
|
|
1861
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
1862
|
-
|
|
1863
|
-
let localVarUseFormData = false;
|
|
1864
|
-
|
|
1865
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
1866
|
-
method: 'GET',
|
|
1867
|
-
qs: localVarQueryParameters,
|
|
1868
|
-
headers: localVarHeaderParams,
|
|
1869
|
-
uri: localVarPath,
|
|
1870
|
-
useQuerystring: this._useQuerystring,
|
|
1871
|
-
json: true,
|
|
1872
|
-
};
|
|
1873
|
-
|
|
1874
|
-
let authenticationPromise = Promise.resolve();
|
|
1875
|
-
if (this.authentications.token.accessToken) {
|
|
1876
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1877
|
-
this.authentications.token.applyToRequest(
|
|
1878
|
-
localVarRequestOptions
|
|
1879
|
-
)
|
|
1880
|
-
);
|
|
1881
|
-
}
|
|
1882
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
1883
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
1884
|
-
);
|
|
1885
|
-
|
|
1886
|
-
let interceptorPromise = authenticationPromise;
|
|
1887
|
-
for (const interceptor of this.interceptors) {
|
|
1888
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
1889
|
-
interceptor(localVarRequestOptions)
|
|
1890
|
-
);
|
|
1891
|
-
}
|
|
1892
|
-
|
|
1893
|
-
return interceptorPromise.then(() => {
|
|
1894
|
-
if (Object.keys(localVarFormParams).length) {
|
|
1895
|
-
if (localVarUseFormData) {
|
|
1896
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
1897
|
-
} else {
|
|
1898
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
1899
|
-
}
|
|
1900
|
-
}
|
|
1901
|
-
return new Promise<{
|
|
1902
|
-
response: http.IncomingMessage;
|
|
1903
|
-
body: ListDeliveryMetricsSummaryFromDestination200Response;
|
|
1904
|
-
}>((resolve, reject) => {
|
|
1905
|
-
localVarRequest(
|
|
1906
|
-
localVarRequestOptions,
|
|
1907
|
-
(error, response, body) => {
|
|
1908
|
-
if (error) {
|
|
1909
|
-
reject(error);
|
|
1910
|
-
} else {
|
|
1911
|
-
if (
|
|
1912
|
-
response.statusCode &&
|
|
1913
|
-
response.statusCode >= 200 &&
|
|
1914
|
-
response.statusCode <= 299
|
|
1915
|
-
) {
|
|
1916
|
-
body = ObjectSerializer.deserialize(
|
|
1917
|
-
body,
|
|
1918
|
-
'ListDeliveryMetricsSummaryFromDestination200Response'
|
|
1919
|
-
);
|
|
1920
|
-
resolve({ response: response, body: body });
|
|
1921
|
-
} else {
|
|
1922
|
-
reject(
|
|
1923
|
-
new HttpError(
|
|
1924
|
-
response,
|
|
1925
|
-
body,
|
|
1926
|
-
response.statusCode
|
|
1927
|
-
)
|
|
1928
|
-
);
|
|
1929
|
-
}
|
|
1930
|
-
}
|
|
1931
|
-
}
|
|
1932
|
-
);
|
|
1933
|
-
});
|
|
1934
|
-
});
|
|
1935
|
-
}
|
|
1936
|
-
/**
|
|
1937
|
-
* Get event delivery metrics summary from a Destination. Based on the granularity, there are restrictions on the time range you can query: **Minute Granularity**: - Max time range: 4 hours - Oldest possible start time: 48 hours in the past **Hour Granularity**: - Max Time range: 1 week - Oldest possible start time: 10 days in the past **Day Granularity**: - Max time range: 60 days - Oldest possible start time: 60 days in the past
|
|
1938
|
-
* @summary List Delivery Metrics Summary from Destination
|
|
1939
|
-
* @param destinationId
|
|
1940
|
-
* @param sourceId The id of the Source linked to the Destination. Config API note: analogous to `parent`. This parameter exists in alpha.
|
|
1941
|
-
* @param startTime Filter events that happened after this time. Defaults to: - 1 hour ago if granularity is `MINUTE`. - 7 days ago if granularity is `HOUR`. - 30 days ago if granularity is `DAY`. This parameter exists in alpha.
|
|
1942
|
-
* @param endTime Filter events that happened before this time. Defaults to now if not set. This parameter exists in alpha.
|
|
1943
|
-
* @param granularity The granularity to filter metrics to. Either `MINUTE`, `HOUR` or `DAY`. Defaults to `MINUTE` if not set. This parameter exists in alpha.
|
|
1944
|
-
*/
|
|
1945
|
-
public async listDeliveryMetricsSummaryFromDestinationBeta(
|
|
1946
|
-
destinationId: string,
|
|
1947
|
-
sourceId: string,
|
|
1948
|
-
startTime?: string,
|
|
1949
|
-
endTime?: string,
|
|
1950
|
-
granularity?: 'DAY' | 'HOUR' | 'MINUTE',
|
|
1951
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
1952
|
-
): Promise<{
|
|
1953
|
-
response: http.IncomingMessage;
|
|
1954
|
-
body: ListDeliveryMetricsSummaryFromDestination200Response;
|
|
1955
|
-
}> {
|
|
1956
|
-
const localVarPath =
|
|
1957
|
-
this.basePath +
|
|
1958
|
-
'/destinations/{destinationId}/delivery-metrics'.replace(
|
|
1959
|
-
'{' + 'destinationId' + '}',
|
|
1960
|
-
encodeURIComponent(String(destinationId))
|
|
1961
|
-
);
|
|
1962
|
-
let localVarQueryParameters: any = {};
|
|
1963
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
1964
|
-
{},
|
|
1965
|
-
this._defaultHeaders
|
|
1966
|
-
);
|
|
1967
|
-
const produces = [
|
|
1968
|
-
'application/vnd.segment.v1beta+json',
|
|
1969
|
-
'application/json',
|
|
1970
|
-
];
|
|
1971
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
1972
|
-
localVarHeaderParams.Accept = produces[0];
|
|
1973
|
-
} else {
|
|
1974
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
1975
|
-
}
|
|
1976
|
-
let localVarFormParams: any = {};
|
|
1977
|
-
|
|
1978
|
-
// verify required parameter 'destinationId' is not null or undefined
|
|
1979
|
-
if (destinationId === null || destinationId === undefined) {
|
|
1980
|
-
throw new Error(
|
|
1981
|
-
'Required parameter destinationId was null or undefined when calling listDeliveryMetricsSummaryFromDestinationBeta.'
|
|
1982
|
-
);
|
|
1983
|
-
}
|
|
1984
|
-
|
|
1985
|
-
// verify required parameter 'sourceId' is not null or undefined
|
|
1986
|
-
if (sourceId === null || sourceId === undefined) {
|
|
1987
|
-
throw new Error(
|
|
1988
|
-
'Required parameter sourceId was null or undefined when calling listDeliveryMetricsSummaryFromDestinationBeta.'
|
|
1989
|
-
);
|
|
1990
|
-
}
|
|
1991
|
-
|
|
1992
|
-
if (sourceId !== undefined) {
|
|
1993
|
-
localVarQueryParameters['sourceId'] = ObjectSerializer.serialize(
|
|
1994
|
-
sourceId,
|
|
1995
|
-
'string'
|
|
1996
|
-
);
|
|
1997
|
-
}
|
|
1998
|
-
|
|
1999
|
-
if (startTime !== undefined) {
|
|
2000
|
-
localVarQueryParameters['startTime'] = ObjectSerializer.serialize(
|
|
2001
|
-
startTime,
|
|
2002
|
-
'string'
|
|
2003
|
-
);
|
|
2004
|
-
}
|
|
2005
|
-
|
|
2006
|
-
if (endTime !== undefined) {
|
|
2007
|
-
localVarQueryParameters['endTime'] = ObjectSerializer.serialize(
|
|
2008
|
-
endTime,
|
|
2009
|
-
'string'
|
|
2010
|
-
);
|
|
2011
|
-
}
|
|
2012
|
-
|
|
2013
|
-
if (granularity !== undefined) {
|
|
2014
|
-
localVarQueryParameters['granularity'] = ObjectSerializer.serialize(
|
|
2015
|
-
granularity,
|
|
2016
|
-
"'DAY' | 'HOUR' | 'MINUTE'"
|
|
2017
|
-
);
|
|
2018
|
-
}
|
|
2019
|
-
|
|
2020
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
2021
|
-
|
|
2022
|
-
let localVarUseFormData = false;
|
|
2023
|
-
|
|
2024
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
2025
|
-
method: 'GET',
|
|
2026
|
-
qs: localVarQueryParameters,
|
|
2027
|
-
headers: localVarHeaderParams,
|
|
2028
|
-
uri: localVarPath,
|
|
2029
|
-
useQuerystring: this._useQuerystring,
|
|
2030
|
-
json: true,
|
|
2031
|
-
};
|
|
2032
|
-
|
|
2033
|
-
let authenticationPromise = Promise.resolve();
|
|
2034
|
-
if (this.authentications.token.accessToken) {
|
|
2035
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
2036
|
-
this.authentications.token.applyToRequest(
|
|
2037
|
-
localVarRequestOptions
|
|
2038
|
-
)
|
|
2039
|
-
);
|
|
2040
|
-
}
|
|
2041
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
2042
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
2043
|
-
);
|
|
2044
|
-
|
|
2045
|
-
let interceptorPromise = authenticationPromise;
|
|
2046
|
-
for (const interceptor of this.interceptors) {
|
|
2047
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
2048
|
-
interceptor(localVarRequestOptions)
|
|
2049
|
-
);
|
|
2050
|
-
}
|
|
2051
|
-
|
|
2052
|
-
return interceptorPromise.then(() => {
|
|
2053
|
-
if (Object.keys(localVarFormParams).length) {
|
|
2054
|
-
if (localVarUseFormData) {
|
|
2055
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
2056
|
-
} else {
|
|
2057
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
2058
|
-
}
|
|
2059
|
-
}
|
|
2060
|
-
return new Promise<{
|
|
2061
|
-
response: http.IncomingMessage;
|
|
2062
|
-
body: ListDeliveryMetricsSummaryFromDestination200Response;
|
|
2063
|
-
}>((resolve, reject) => {
|
|
2064
|
-
localVarRequest(
|
|
2065
|
-
localVarRequestOptions,
|
|
2066
|
-
(error, response, body) => {
|
|
2067
|
-
if (error) {
|
|
2068
|
-
reject(error);
|
|
2069
|
-
} else {
|
|
2070
|
-
if (
|
|
2071
|
-
response.statusCode &&
|
|
2072
|
-
response.statusCode >= 200 &&
|
|
2073
|
-
response.statusCode <= 299
|
|
2074
|
-
) {
|
|
2075
|
-
body = ObjectSerializer.deserialize(
|
|
2076
|
-
body,
|
|
2077
|
-
'ListDeliveryMetricsSummaryFromDestination200Response'
|
|
2078
|
-
);
|
|
2079
|
-
resolve({ response: response, body: body });
|
|
2080
|
-
} else {
|
|
2081
|
-
reject(
|
|
2082
|
-
new HttpError(
|
|
2083
|
-
response,
|
|
2084
|
-
body,
|
|
2085
|
-
response.statusCode
|
|
2086
|
-
)
|
|
2087
|
-
);
|
|
2088
|
-
}
|
|
2089
|
-
}
|
|
2090
|
-
}
|
|
2091
|
-
);
|
|
2092
|
-
});
|
|
2093
|
-
});
|
|
2094
|
-
}
|
|
2095
|
-
/**
|
|
2096
|
-
* Returns a list of Destinations.
|
|
2097
|
-
* @summary List Destinations
|
|
2098
|
-
* @param pagination Required pagination params for the request. This parameter exists in alpha.
|
|
2099
|
-
*/
|
|
2100
|
-
public async listDestinationsAlpha(
|
|
2101
|
-
pagination: PaginationInput,
|
|
2102
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
2103
|
-
): Promise<{
|
|
2104
|
-
response: http.IncomingMessage;
|
|
2105
|
-
body: ListDestinations200Response;
|
|
2106
|
-
}> {
|
|
2107
|
-
const localVarPath = this.basePath + '/destinations';
|
|
2108
|
-
let localVarQueryParameters: any = {};
|
|
2109
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
2110
|
-
{},
|
|
2111
|
-
this._defaultHeaders
|
|
2112
|
-
);
|
|
2113
|
-
const produces = [
|
|
2114
|
-
'application/vnd.segment.v1alpha+json',
|
|
2115
|
-
'application/json',
|
|
2116
|
-
];
|
|
2117
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
2118
|
-
localVarHeaderParams.Accept = produces[0];
|
|
2119
|
-
} else {
|
|
2120
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
2121
|
-
}
|
|
2122
|
-
let localVarFormParams: any = {};
|
|
2123
|
-
|
|
2124
|
-
// verify required parameter 'pagination' is not null or undefined
|
|
2125
|
-
if (pagination === null || pagination === undefined) {
|
|
2126
|
-
throw new Error(
|
|
2127
|
-
'Required parameter pagination was null or undefined when calling listDestinationsAlpha.'
|
|
2128
|
-
);
|
|
2129
|
-
}
|
|
2130
|
-
|
|
2131
|
-
if (pagination !== undefined) {
|
|
2132
|
-
localVarQueryParameters['pagination'] = ObjectSerializer.serialize(
|
|
2133
|
-
pagination,
|
|
2134
|
-
'PaginationInput'
|
|
2135
|
-
);
|
|
2136
|
-
}
|
|
2137
|
-
|
|
2138
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
2139
|
-
|
|
2140
|
-
let localVarUseFormData = false;
|
|
2141
|
-
|
|
2142
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
2143
|
-
method: 'GET',
|
|
2144
|
-
qs: localVarQueryParameters,
|
|
2145
|
-
headers: localVarHeaderParams,
|
|
2146
|
-
uri: localVarPath,
|
|
2147
|
-
useQuerystring: this._useQuerystring,
|
|
2148
|
-
json: true,
|
|
2149
|
-
};
|
|
2150
|
-
|
|
2151
|
-
let authenticationPromise = Promise.resolve();
|
|
2152
|
-
if (this.authentications.token.accessToken) {
|
|
2153
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
2154
|
-
this.authentications.token.applyToRequest(
|
|
2155
|
-
localVarRequestOptions
|
|
2156
|
-
)
|
|
2157
|
-
);
|
|
2158
|
-
}
|
|
2159
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
2160
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
2161
|
-
);
|
|
2162
|
-
|
|
2163
|
-
let interceptorPromise = authenticationPromise;
|
|
2164
|
-
for (const interceptor of this.interceptors) {
|
|
2165
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
2166
|
-
interceptor(localVarRequestOptions)
|
|
2167
|
-
);
|
|
2168
|
-
}
|
|
2169
|
-
|
|
2170
|
-
return interceptorPromise.then(() => {
|
|
2171
|
-
if (Object.keys(localVarFormParams).length) {
|
|
2172
|
-
if (localVarUseFormData) {
|
|
2173
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
2174
|
-
} else {
|
|
2175
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
2176
|
-
}
|
|
2177
|
-
}
|
|
2178
|
-
return new Promise<{
|
|
2179
|
-
response: http.IncomingMessage;
|
|
2180
|
-
body: ListDestinations200Response;
|
|
2181
|
-
}>((resolve, reject) => {
|
|
2182
|
-
localVarRequest(
|
|
2183
|
-
localVarRequestOptions,
|
|
2184
|
-
(error, response, body) => {
|
|
2185
|
-
if (error) {
|
|
2186
|
-
reject(error);
|
|
2187
|
-
} else {
|
|
2188
|
-
if (
|
|
2189
|
-
response.statusCode &&
|
|
2190
|
-
response.statusCode >= 200 &&
|
|
2191
|
-
response.statusCode <= 299
|
|
2192
|
-
) {
|
|
2193
|
-
body = ObjectSerializer.deserialize(
|
|
2194
|
-
body,
|
|
2195
|
-
'ListDestinations200Response'
|
|
2196
|
-
);
|
|
2197
|
-
resolve({ response: response, body: body });
|
|
2198
|
-
} else {
|
|
2199
|
-
reject(
|
|
2200
|
-
new HttpError(
|
|
2201
|
-
response,
|
|
2202
|
-
body,
|
|
2203
|
-
response.statusCode
|
|
2204
|
-
)
|
|
2205
|
-
);
|
|
2206
|
-
}
|
|
2207
|
-
}
|
|
2208
|
-
}
|
|
2209
|
-
);
|
|
2210
|
-
});
|
|
2211
|
-
});
|
|
2212
|
-
}
|
|
2213
|
-
/**
|
|
2214
|
-
* Returns a list of Destinations.
|
|
2215
|
-
* @summary List Destinations
|
|
2216
|
-
* @param pagination Required pagination params for the request. This parameter exists in alpha.
|
|
2217
|
-
*/
|
|
2218
|
-
public async listDestinationsBeta(
|
|
2219
|
-
pagination: PaginationInput,
|
|
2220
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
2221
|
-
): Promise<{
|
|
2222
|
-
response: http.IncomingMessage;
|
|
2223
|
-
body: ListDestinations200Response;
|
|
2224
|
-
}> {
|
|
2225
|
-
const localVarPath = this.basePath + '/destinations';
|
|
2226
|
-
let localVarQueryParameters: any = {};
|
|
2227
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
2228
|
-
{},
|
|
2229
|
-
this._defaultHeaders
|
|
2230
|
-
);
|
|
2231
|
-
const produces = [
|
|
2232
|
-
'application/vnd.segment.v1beta+json',
|
|
2233
|
-
'application/json',
|
|
2234
|
-
];
|
|
2235
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
2236
|
-
localVarHeaderParams.Accept = produces[0];
|
|
2237
|
-
} else {
|
|
2238
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
2239
|
-
}
|
|
2240
|
-
let localVarFormParams: any = {};
|
|
2241
|
-
|
|
2242
|
-
// verify required parameter 'pagination' is not null or undefined
|
|
2243
|
-
if (pagination === null || pagination === undefined) {
|
|
2244
|
-
throw new Error(
|
|
2245
|
-
'Required parameter pagination was null or undefined when calling listDestinationsBeta.'
|
|
2246
|
-
);
|
|
2247
|
-
}
|
|
2248
|
-
|
|
2249
|
-
if (pagination !== undefined) {
|
|
2250
|
-
localVarQueryParameters['pagination'] = ObjectSerializer.serialize(
|
|
2251
|
-
pagination,
|
|
2252
|
-
'PaginationInput'
|
|
2253
|
-
);
|
|
2254
|
-
}
|
|
2255
|
-
|
|
2256
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
2257
|
-
|
|
2258
|
-
let localVarUseFormData = false;
|
|
2259
|
-
|
|
2260
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
2261
|
-
method: 'GET',
|
|
2262
|
-
qs: localVarQueryParameters,
|
|
2263
|
-
headers: localVarHeaderParams,
|
|
2264
|
-
uri: localVarPath,
|
|
2265
|
-
useQuerystring: this._useQuerystring,
|
|
2266
|
-
json: true,
|
|
2267
|
-
};
|
|
2268
|
-
|
|
2269
|
-
let authenticationPromise = Promise.resolve();
|
|
2270
|
-
if (this.authentications.token.accessToken) {
|
|
2271
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
2272
|
-
this.authentications.token.applyToRequest(
|
|
2273
|
-
localVarRequestOptions
|
|
2274
|
-
)
|
|
2275
|
-
);
|
|
2276
|
-
}
|
|
2277
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
2278
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
2279
|
-
);
|
|
2280
|
-
|
|
2281
|
-
let interceptorPromise = authenticationPromise;
|
|
2282
|
-
for (const interceptor of this.interceptors) {
|
|
2283
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
2284
|
-
interceptor(localVarRequestOptions)
|
|
2285
|
-
);
|
|
2286
|
-
}
|
|
2287
|
-
|
|
2288
|
-
return interceptorPromise.then(() => {
|
|
2289
|
-
if (Object.keys(localVarFormParams).length) {
|
|
2290
|
-
if (localVarUseFormData) {
|
|
2291
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
2292
|
-
} else {
|
|
2293
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
2294
|
-
}
|
|
2295
|
-
}
|
|
2296
|
-
return new Promise<{
|
|
2297
|
-
response: http.IncomingMessage;
|
|
2298
|
-
body: ListDestinations200Response;
|
|
2299
|
-
}>((resolve, reject) => {
|
|
2300
|
-
localVarRequest(
|
|
2301
|
-
localVarRequestOptions,
|
|
2302
|
-
(error, response, body) => {
|
|
2303
|
-
if (error) {
|
|
2304
|
-
reject(error);
|
|
2305
|
-
} else {
|
|
2306
|
-
if (
|
|
2307
|
-
response.statusCode &&
|
|
2308
|
-
response.statusCode >= 200 &&
|
|
2309
|
-
response.statusCode <= 299
|
|
2310
|
-
) {
|
|
2311
|
-
body = ObjectSerializer.deserialize(
|
|
2312
|
-
body,
|
|
2313
|
-
'ListDestinations200Response'
|
|
2314
|
-
);
|
|
2315
|
-
resolve({ response: response, body: body });
|
|
2316
|
-
} else {
|
|
2317
|
-
reject(
|
|
2318
|
-
new HttpError(
|
|
2319
|
-
response,
|
|
2320
|
-
body,
|
|
2321
|
-
response.statusCode
|
|
2322
|
-
)
|
|
2323
|
-
);
|
|
2324
|
-
}
|
|
2325
|
-
}
|
|
2326
|
-
}
|
|
2327
|
-
);
|
|
2328
|
-
});
|
|
2329
|
-
});
|
|
2330
|
-
}
|
|
2331
|
-
/**
|
|
2332
|
-
* Returns a list of Destinations.
|
|
2333
|
-
* @summary List Destinations
|
|
2334
|
-
* @param pagination Required pagination params for the request. This parameter exists in alpha.
|
|
2335
|
-
*/
|
|
2336
|
-
public async listDestinationsCurrent(
|
|
2337
|
-
pagination: PaginationInput,
|
|
2338
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
2339
|
-
): Promise<{
|
|
2340
|
-
response: http.IncomingMessage;
|
|
2341
|
-
body: ListDestinations200Response;
|
|
2342
|
-
}> {
|
|
2343
|
-
const localVarPath = this.basePath + '/destinations';
|
|
2344
|
-
let localVarQueryParameters: any = {};
|
|
2345
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
2346
|
-
{},
|
|
2347
|
-
this._defaultHeaders
|
|
2348
|
-
);
|
|
2349
|
-
const produces = ['application/json'];
|
|
2350
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
2351
|
-
localVarHeaderParams.Accept = produces[0];
|
|
2352
|
-
} else {
|
|
2353
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
2354
|
-
}
|
|
2355
|
-
let localVarFormParams: any = {};
|
|
2356
|
-
|
|
2357
|
-
// verify required parameter 'pagination' is not null or undefined
|
|
2358
|
-
if (pagination === null || pagination === undefined) {
|
|
2359
|
-
throw new Error(
|
|
2360
|
-
'Required parameter pagination was null or undefined when calling listDestinationsCurrent.'
|
|
2361
|
-
);
|
|
2362
|
-
}
|
|
2363
|
-
|
|
2364
|
-
if (pagination !== undefined) {
|
|
2365
|
-
localVarQueryParameters['pagination'] = ObjectSerializer.serialize(
|
|
2366
|
-
pagination,
|
|
2367
|
-
'PaginationInput'
|
|
2368
|
-
);
|
|
2369
|
-
}
|
|
2370
|
-
|
|
2371
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
2372
|
-
|
|
2373
|
-
let localVarUseFormData = false;
|
|
2374
|
-
|
|
2375
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
2376
|
-
method: 'GET',
|
|
2377
|
-
qs: localVarQueryParameters,
|
|
2378
|
-
headers: localVarHeaderParams,
|
|
2379
|
-
uri: localVarPath,
|
|
2380
|
-
useQuerystring: this._useQuerystring,
|
|
2381
|
-
json: true,
|
|
2382
|
-
};
|
|
2383
|
-
|
|
2384
|
-
let authenticationPromise = Promise.resolve();
|
|
2385
|
-
if (this.authentications.token.accessToken) {
|
|
2386
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
2387
|
-
this.authentications.token.applyToRequest(
|
|
2388
|
-
localVarRequestOptions
|
|
2389
|
-
)
|
|
2390
|
-
);
|
|
2391
|
-
}
|
|
2392
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
2393
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
2394
|
-
);
|
|
2395
|
-
|
|
2396
|
-
let interceptorPromise = authenticationPromise;
|
|
2397
|
-
for (const interceptor of this.interceptors) {
|
|
2398
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
2399
|
-
interceptor(localVarRequestOptions)
|
|
2400
|
-
);
|
|
2401
|
-
}
|
|
2402
|
-
|
|
2403
|
-
return interceptorPromise.then(() => {
|
|
2404
|
-
if (Object.keys(localVarFormParams).length) {
|
|
2405
|
-
if (localVarUseFormData) {
|
|
2406
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
2407
|
-
} else {
|
|
2408
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
2409
|
-
}
|
|
2410
|
-
}
|
|
2411
|
-
return new Promise<{
|
|
2412
|
-
response: http.IncomingMessage;
|
|
2413
|
-
body: ListDestinations200Response;
|
|
2414
|
-
}>((resolve, reject) => {
|
|
2415
|
-
localVarRequest(
|
|
2416
|
-
localVarRequestOptions,
|
|
2417
|
-
(error, response, body) => {
|
|
2418
|
-
if (error) {
|
|
2419
|
-
reject(error);
|
|
2420
|
-
} else {
|
|
2421
|
-
if (
|
|
2422
|
-
response.statusCode &&
|
|
2423
|
-
response.statusCode >= 200 &&
|
|
2424
|
-
response.statusCode <= 299
|
|
2425
|
-
) {
|
|
2426
|
-
body = ObjectSerializer.deserialize(
|
|
2427
|
-
body,
|
|
2428
|
-
'ListDestinations200Response'
|
|
2429
|
-
);
|
|
2430
|
-
resolve({ response: response, body: body });
|
|
2431
|
-
} else {
|
|
2432
|
-
reject(
|
|
2433
|
-
new HttpError(
|
|
2434
|
-
response,
|
|
2435
|
-
body,
|
|
2436
|
-
response.statusCode
|
|
2437
|
-
)
|
|
2438
|
-
);
|
|
2439
|
-
}
|
|
2440
|
-
}
|
|
2441
|
-
}
|
|
2442
|
-
);
|
|
2443
|
-
});
|
|
2444
|
-
});
|
|
2445
|
-
}
|
|
2446
|
-
/**
|
|
2447
|
-
* Returns a list of Destinations.
|
|
2448
|
-
* @summary List Destinations
|
|
2449
|
-
* @param pagination Required pagination params for the request. This parameter exists in alpha.
|
|
2450
|
-
*/
|
|
2451
|
-
public async listDestinationsV1(
|
|
2452
|
-
pagination: PaginationInput,
|
|
2453
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
2454
|
-
): Promise<{
|
|
2455
|
-
response: http.IncomingMessage;
|
|
2456
|
-
body: ListDestinations200Response;
|
|
2457
|
-
}> {
|
|
2458
|
-
const localVarPath = this.basePath + '/destinations';
|
|
2459
|
-
let localVarQueryParameters: any = {};
|
|
2460
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
2461
|
-
{},
|
|
2462
|
-
this._defaultHeaders
|
|
2463
|
-
);
|
|
2464
|
-
const produces = [
|
|
2465
|
-
'application/vnd.segment.v1+json',
|
|
2466
|
-
'application/json',
|
|
2467
|
-
];
|
|
2468
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
2469
|
-
localVarHeaderParams.Accept = produces[0];
|
|
2470
|
-
} else {
|
|
2471
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
2472
|
-
}
|
|
2473
|
-
let localVarFormParams: any = {};
|
|
2474
|
-
|
|
2475
|
-
// verify required parameter 'pagination' is not null or undefined
|
|
2476
|
-
if (pagination === null || pagination === undefined) {
|
|
2477
|
-
throw new Error(
|
|
2478
|
-
'Required parameter pagination was null or undefined when calling listDestinationsV1.'
|
|
2479
|
-
);
|
|
2480
|
-
}
|
|
2481
|
-
|
|
2482
|
-
if (pagination !== undefined) {
|
|
2483
|
-
localVarQueryParameters['pagination'] = ObjectSerializer.serialize(
|
|
2484
|
-
pagination,
|
|
2485
|
-
'PaginationInput'
|
|
532
|
+
let localVarFormParams: any = {};
|
|
533
|
+
|
|
534
|
+
// verify required parameter 'destinationId' is not null or undefined
|
|
535
|
+
if (destinationId === null || destinationId === undefined) {
|
|
536
|
+
throw new Error(
|
|
537
|
+
'Required parameter destinationId was null or undefined when calling getDestination.'
|
|
2486
538
|
);
|
|
2487
539
|
}
|
|
2488
540
|
|
|
@@ -2528,7 +580,7 @@ export class DestinationsApi {
|
|
|
2528
580
|
}
|
|
2529
581
|
return new Promise<{
|
|
2530
582
|
response: http.IncomingMessage;
|
|
2531
|
-
body:
|
|
583
|
+
body: GetDestination200Response;
|
|
2532
584
|
}>((resolve, reject) => {
|
|
2533
585
|
localVarRequest(
|
|
2534
586
|
localVarRequestOptions,
|
|
@@ -2543,7 +595,7 @@ export class DestinationsApi {
|
|
|
2543
595
|
) {
|
|
2544
596
|
body = ObjectSerializer.deserialize(
|
|
2545
597
|
body,
|
|
2546
|
-
'
|
|
598
|
+
'GetDestination200Response'
|
|
2547
599
|
);
|
|
2548
600
|
resolve({ response: response, body: body });
|
|
2549
601
|
} else {
|
|
@@ -2562,25 +614,27 @@ export class DestinationsApi {
|
|
|
2562
614
|
});
|
|
2563
615
|
}
|
|
2564
616
|
/**
|
|
2565
|
-
*
|
|
2566
|
-
* @summary
|
|
617
|
+
* Gets a Destination subscription by id.
|
|
618
|
+
* @summary Get Subscription from Destination
|
|
2567
619
|
* @param destinationId
|
|
2568
|
-
* @param
|
|
620
|
+
* @param id
|
|
2569
621
|
*/
|
|
2570
|
-
public async
|
|
622
|
+
public async getSubscriptionFromDestination(
|
|
2571
623
|
destinationId: string,
|
|
2572
|
-
|
|
624
|
+
id: string,
|
|
2573
625
|
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
2574
626
|
): Promise<{
|
|
2575
627
|
response: http.IncomingMessage;
|
|
2576
|
-
body:
|
|
628
|
+
body: GetSubscriptionFromDestination200Response;
|
|
2577
629
|
}> {
|
|
2578
630
|
const localVarPath =
|
|
2579
631
|
this.basePath +
|
|
2580
|
-
'/destinations/{destinationId}/subscriptions'
|
|
2581
|
-
|
|
2582
|
-
|
|
2583
|
-
|
|
632
|
+
'/destinations/{destinationId}/subscriptions/{id}'
|
|
633
|
+
.replace(
|
|
634
|
+
'{' + 'destinationId' + '}',
|
|
635
|
+
encodeURIComponent(String(destinationId))
|
|
636
|
+
)
|
|
637
|
+
.replace('{' + 'id' + '}', encodeURIComponent(String(id)));
|
|
2584
638
|
let localVarQueryParameters: any = {};
|
|
2585
639
|
let localVarHeaderParams: any = (<any>Object).assign(
|
|
2586
640
|
{},
|
|
@@ -2590,31 +644,25 @@ export class DestinationsApi {
|
|
|
2590
644
|
'application/vnd.segment.v1alpha+json',
|
|
2591
645
|
'application/json',
|
|
2592
646
|
];
|
|
647
|
+
// give precedence to 'application/json'
|
|
2593
648
|
if (produces.indexOf('application/json') >= 0) {
|
|
2594
|
-
localVarHeaderParams.Accept = produces[0];
|
|
2595
|
-
} else {
|
|
2596
649
|
localVarHeaderParams.Accept = 'application/json';
|
|
650
|
+
} else {
|
|
651
|
+
localVarHeaderParams.Accept = produces.join(',');
|
|
2597
652
|
}
|
|
2598
653
|
let localVarFormParams: any = {};
|
|
2599
654
|
|
|
2600
655
|
// verify required parameter 'destinationId' is not null or undefined
|
|
2601
656
|
if (destinationId === null || destinationId === undefined) {
|
|
2602
657
|
throw new Error(
|
|
2603
|
-
'Required parameter destinationId was null or undefined when calling
|
|
658
|
+
'Required parameter destinationId was null or undefined when calling getSubscriptionFromDestination.'
|
|
2604
659
|
);
|
|
2605
660
|
}
|
|
2606
661
|
|
|
2607
|
-
// verify required parameter '
|
|
2608
|
-
if (
|
|
662
|
+
// verify required parameter 'id' is not null or undefined
|
|
663
|
+
if (id === null || id === undefined) {
|
|
2609
664
|
throw new Error(
|
|
2610
|
-
'Required parameter
|
|
2611
|
-
);
|
|
2612
|
-
}
|
|
2613
|
-
|
|
2614
|
-
if (pagination !== undefined) {
|
|
2615
|
-
localVarQueryParameters['pagination'] = ObjectSerializer.serialize(
|
|
2616
|
-
pagination,
|
|
2617
|
-
'PaginationInput'
|
|
665
|
+
'Required parameter id was null or undefined when calling getSubscriptionFromDestination.'
|
|
2618
666
|
);
|
|
2619
667
|
}
|
|
2620
668
|
|
|
@@ -2660,7 +708,7 @@ export class DestinationsApi {
|
|
|
2660
708
|
}
|
|
2661
709
|
return new Promise<{
|
|
2662
710
|
response: http.IncomingMessage;
|
|
2663
|
-
body:
|
|
711
|
+
body: GetSubscriptionFromDestination200Response;
|
|
2664
712
|
}>((resolve, reject) => {
|
|
2665
713
|
localVarRequest(
|
|
2666
714
|
localVarRequestOptions,
|
|
@@ -2675,7 +723,7 @@ export class DestinationsApi {
|
|
|
2675
723
|
) {
|
|
2676
724
|
body = ObjectSerializer.deserialize(
|
|
2677
725
|
body,
|
|
2678
|
-
'
|
|
726
|
+
'GetSubscriptionFromDestination200Response'
|
|
2679
727
|
);
|
|
2680
728
|
resolve({ response: response, body: body });
|
|
2681
729
|
} else {
|
|
@@ -2694,54 +742,88 @@ export class DestinationsApi {
|
|
|
2694
742
|
});
|
|
2695
743
|
}
|
|
2696
744
|
/**
|
|
2697
|
-
*
|
|
2698
|
-
* @summary
|
|
745
|
+
* Get event delivery metrics summary from a Destination. Based on the granularity, there are restrictions on the time range you can query: **Minute Granularity**: - Max time range: 4 hours - Oldest possible start time: 48 hours in the past **Hour Granularity**: - Max Time range: 1 week - Oldest possible start time: 10 days in the past **Day Granularity**: - Max time range: 60 days - Oldest possible start time: 60 days in the past
|
|
746
|
+
* @summary List Delivery Metrics Summary from Destination
|
|
2699
747
|
* @param destinationId
|
|
2700
|
-
* @param id
|
|
748
|
+
* @param sourceId The id of the Source linked to the Destination. Config API note: analogous to `parent`. This parameter exists in beta.
|
|
749
|
+
* @param startTime Filter events that happened after this time. Defaults to: - 1 hour ago if granularity is `MINUTE`. - 7 days ago if granularity is `HOUR`. - 30 days ago if granularity is `DAY`. This parameter exists in beta.
|
|
750
|
+
* @param endTime Filter events that happened before this time. Defaults to now if not set. This parameter exists in beta.
|
|
751
|
+
* @param granularity The granularity to filter metrics to. Either `MINUTE`, `HOUR` or `DAY`. Defaults to `MINUTE` if not set. This parameter exists in beta.
|
|
2701
752
|
*/
|
|
2702
|
-
public async
|
|
753
|
+
public async listDeliveryMetricsSummaryFromDestination(
|
|
2703
754
|
destinationId: string,
|
|
2704
|
-
|
|
755
|
+
sourceId: string,
|
|
756
|
+
startTime?: string,
|
|
757
|
+
endTime?: string,
|
|
758
|
+
granularity?: 'DAY' | 'HOUR' | 'MINUTE',
|
|
2705
759
|
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
2706
760
|
): Promise<{
|
|
2707
761
|
response: http.IncomingMessage;
|
|
2708
|
-
body:
|
|
762
|
+
body: ListDeliveryMetricsSummaryFromDestination200Response;
|
|
2709
763
|
}> {
|
|
2710
764
|
const localVarPath =
|
|
2711
765
|
this.basePath +
|
|
2712
|
-
'/destinations/{destinationId}/
|
|
2713
|
-
|
|
2714
|
-
|
|
2715
|
-
|
|
2716
|
-
)
|
|
2717
|
-
.replace('{' + 'id' + '}', encodeURIComponent(String(id)));
|
|
766
|
+
'/destinations/{destinationId}/delivery-metrics'.replace(
|
|
767
|
+
'{' + 'destinationId' + '}',
|
|
768
|
+
encodeURIComponent(String(destinationId))
|
|
769
|
+
);
|
|
2718
770
|
let localVarQueryParameters: any = {};
|
|
2719
771
|
let localVarHeaderParams: any = (<any>Object).assign(
|
|
2720
772
|
{},
|
|
2721
773
|
this._defaultHeaders
|
|
2722
774
|
);
|
|
2723
775
|
const produces = [
|
|
776
|
+
'application/vnd.segment.v1beta+json',
|
|
2724
777
|
'application/vnd.segment.v1alpha+json',
|
|
2725
778
|
'application/json',
|
|
2726
779
|
];
|
|
780
|
+
// give precedence to 'application/json'
|
|
2727
781
|
if (produces.indexOf('application/json') >= 0) {
|
|
2728
|
-
localVarHeaderParams.Accept = produces[0];
|
|
2729
|
-
} else {
|
|
2730
782
|
localVarHeaderParams.Accept = 'application/json';
|
|
783
|
+
} else {
|
|
784
|
+
localVarHeaderParams.Accept = produces.join(',');
|
|
2731
785
|
}
|
|
2732
786
|
let localVarFormParams: any = {};
|
|
2733
787
|
|
|
2734
788
|
// verify required parameter 'destinationId' is not null or undefined
|
|
2735
789
|
if (destinationId === null || destinationId === undefined) {
|
|
2736
790
|
throw new Error(
|
|
2737
|
-
'Required parameter destinationId was null or undefined when calling
|
|
791
|
+
'Required parameter destinationId was null or undefined when calling listDeliveryMetricsSummaryFromDestination.'
|
|
2738
792
|
);
|
|
2739
793
|
}
|
|
2740
794
|
|
|
2741
|
-
// verify required parameter '
|
|
2742
|
-
if (
|
|
795
|
+
// verify required parameter 'sourceId' is not null or undefined
|
|
796
|
+
if (sourceId === null || sourceId === undefined) {
|
|
2743
797
|
throw new Error(
|
|
2744
|
-
'Required parameter
|
|
798
|
+
'Required parameter sourceId was null or undefined when calling listDeliveryMetricsSummaryFromDestination.'
|
|
799
|
+
);
|
|
800
|
+
}
|
|
801
|
+
|
|
802
|
+
if (sourceId !== undefined) {
|
|
803
|
+
localVarQueryParameters['sourceId'] = ObjectSerializer.serialize(
|
|
804
|
+
sourceId,
|
|
805
|
+
'string'
|
|
806
|
+
);
|
|
807
|
+
}
|
|
808
|
+
|
|
809
|
+
if (startTime !== undefined) {
|
|
810
|
+
localVarQueryParameters['startTime'] = ObjectSerializer.serialize(
|
|
811
|
+
startTime,
|
|
812
|
+
'string'
|
|
813
|
+
);
|
|
814
|
+
}
|
|
815
|
+
|
|
816
|
+
if (endTime !== undefined) {
|
|
817
|
+
localVarQueryParameters['endTime'] = ObjectSerializer.serialize(
|
|
818
|
+
endTime,
|
|
819
|
+
'string'
|
|
820
|
+
);
|
|
821
|
+
}
|
|
822
|
+
|
|
823
|
+
if (granularity !== undefined) {
|
|
824
|
+
localVarQueryParameters['granularity'] = ObjectSerializer.serialize(
|
|
825
|
+
granularity,
|
|
826
|
+
"'DAY' | 'HOUR' | 'MINUTE'"
|
|
2745
827
|
);
|
|
2746
828
|
}
|
|
2747
829
|
|
|
@@ -2750,7 +832,7 @@ export class DestinationsApi {
|
|
|
2750
832
|
let localVarUseFormData = false;
|
|
2751
833
|
|
|
2752
834
|
let localVarRequestOptions: localVarRequest.Options = {
|
|
2753
|
-
method: '
|
|
835
|
+
method: 'GET',
|
|
2754
836
|
qs: localVarQueryParameters,
|
|
2755
837
|
headers: localVarHeaderParams,
|
|
2756
838
|
uri: localVarPath,
|
|
@@ -2787,7 +869,7 @@ export class DestinationsApi {
|
|
|
2787
869
|
}
|
|
2788
870
|
return new Promise<{
|
|
2789
871
|
response: http.IncomingMessage;
|
|
2790
|
-
body:
|
|
872
|
+
body: ListDeliveryMetricsSummaryFromDestination200Response;
|
|
2791
873
|
}>((resolve, reject) => {
|
|
2792
874
|
localVarRequest(
|
|
2793
875
|
localVarRequestOptions,
|
|
@@ -2802,7 +884,7 @@ export class DestinationsApi {
|
|
|
2802
884
|
) {
|
|
2803
885
|
body = ObjectSerializer.deserialize(
|
|
2804
886
|
body,
|
|
2805
|
-
'
|
|
887
|
+
'ListDeliveryMetricsSummaryFromDestination200Response'
|
|
2806
888
|
);
|
|
2807
889
|
resolve({ response: response, body: body });
|
|
2808
890
|
} else {
|
|
@@ -2821,55 +903,48 @@ export class DestinationsApi {
|
|
|
2821
903
|
});
|
|
2822
904
|
}
|
|
2823
905
|
/**
|
|
2824
|
-
*
|
|
2825
|
-
* @summary
|
|
2826
|
-
* @param
|
|
2827
|
-
* @param UpdateDestinationV1Input
|
|
906
|
+
* Returns a list of Destinations.
|
|
907
|
+
* @summary List Destinations
|
|
908
|
+
* @param pagination Required pagination params for the request. This parameter exists in v1.
|
|
2828
909
|
*/
|
|
2829
|
-
public async
|
|
2830
|
-
|
|
2831
|
-
UpdateDestinationV1Input: UpdateDestinationV1Input,
|
|
910
|
+
public async listDestinations(
|
|
911
|
+
pagination: PaginationInput,
|
|
2832
912
|
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
2833
913
|
): Promise<{
|
|
2834
914
|
response: http.IncomingMessage;
|
|
2835
|
-
body:
|
|
915
|
+
body: ListDestinations200Response;
|
|
2836
916
|
}> {
|
|
2837
|
-
const localVarPath =
|
|
2838
|
-
this.basePath +
|
|
2839
|
-
'/destinations/{destinationId}'.replace(
|
|
2840
|
-
'{' + 'destinationId' + '}',
|
|
2841
|
-
encodeURIComponent(String(destinationId))
|
|
2842
|
-
);
|
|
917
|
+
const localVarPath = this.basePath + '/destinations';
|
|
2843
918
|
let localVarQueryParameters: any = {};
|
|
2844
919
|
let localVarHeaderParams: any = (<any>Object).assign(
|
|
2845
920
|
{},
|
|
2846
921
|
this._defaultHeaders
|
|
2847
922
|
);
|
|
2848
923
|
const produces = [
|
|
2849
|
-
'application/vnd.segment.
|
|
924
|
+
'application/vnd.segment.v1+json',
|
|
2850
925
|
'application/json',
|
|
926
|
+
'application/vnd.segment.v1beta+json',
|
|
927
|
+
'application/vnd.segment.v1alpha+json',
|
|
2851
928
|
];
|
|
929
|
+
// give precedence to 'application/json'
|
|
2852
930
|
if (produces.indexOf('application/json') >= 0) {
|
|
2853
|
-
localVarHeaderParams.Accept = produces[0];
|
|
2854
|
-
} else {
|
|
2855
931
|
localVarHeaderParams.Accept = 'application/json';
|
|
932
|
+
} else {
|
|
933
|
+
localVarHeaderParams.Accept = produces.join(',');
|
|
2856
934
|
}
|
|
2857
935
|
let localVarFormParams: any = {};
|
|
2858
936
|
|
|
2859
|
-
// verify required parameter '
|
|
2860
|
-
if (
|
|
937
|
+
// verify required parameter 'pagination' is not null or undefined
|
|
938
|
+
if (pagination === null || pagination === undefined) {
|
|
2861
939
|
throw new Error(
|
|
2862
|
-
'Required parameter
|
|
940
|
+
'Required parameter pagination was null or undefined when calling listDestinations.'
|
|
2863
941
|
);
|
|
2864
942
|
}
|
|
2865
943
|
|
|
2866
|
-
|
|
2867
|
-
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
) {
|
|
2871
|
-
throw new Error(
|
|
2872
|
-
'Required parameter UpdateDestinationV1Input was null or undefined when calling updateDestinationAlpha.'
|
|
944
|
+
if (pagination !== undefined) {
|
|
945
|
+
localVarQueryParameters['pagination'] = ObjectSerializer.serialize(
|
|
946
|
+
pagination,
|
|
947
|
+
'PaginationInput'
|
|
2873
948
|
);
|
|
2874
949
|
}
|
|
2875
950
|
|
|
@@ -2878,16 +953,12 @@ export class DestinationsApi {
|
|
|
2878
953
|
let localVarUseFormData = false;
|
|
2879
954
|
|
|
2880
955
|
let localVarRequestOptions: localVarRequest.Options = {
|
|
2881
|
-
method: '
|
|
956
|
+
method: 'GET',
|
|
2882
957
|
qs: localVarQueryParameters,
|
|
2883
958
|
headers: localVarHeaderParams,
|
|
2884
959
|
uri: localVarPath,
|
|
2885
960
|
useQuerystring: this._useQuerystring,
|
|
2886
961
|
json: true,
|
|
2887
|
-
body: ObjectSerializer.serialize(
|
|
2888
|
-
UpdateDestinationV1Input,
|
|
2889
|
-
'UpdateDestinationV1Input'
|
|
2890
|
-
),
|
|
2891
962
|
};
|
|
2892
963
|
|
|
2893
964
|
let authenticationPromise = Promise.resolve();
|
|
@@ -2919,7 +990,7 @@ export class DestinationsApi {
|
|
|
2919
990
|
}
|
|
2920
991
|
return new Promise<{
|
|
2921
992
|
response: http.IncomingMessage;
|
|
2922
|
-
body:
|
|
993
|
+
body: ListDestinations200Response;
|
|
2923
994
|
}>((resolve, reject) => {
|
|
2924
995
|
localVarRequest(
|
|
2925
996
|
localVarRequestOptions,
|
|
@@ -2934,7 +1005,7 @@ export class DestinationsApi {
|
|
|
2934
1005
|
) {
|
|
2935
1006
|
body = ObjectSerializer.deserialize(
|
|
2936
1007
|
body,
|
|
2937
|
-
'
|
|
1008
|
+
'ListDestinations200Response'
|
|
2938
1009
|
);
|
|
2939
1010
|
resolve({ response: response, body: body });
|
|
2940
1011
|
} else {
|
|
@@ -2953,22 +1024,22 @@ export class DestinationsApi {
|
|
|
2953
1024
|
});
|
|
2954
1025
|
}
|
|
2955
1026
|
/**
|
|
2956
|
-
*
|
|
2957
|
-
* @summary
|
|
1027
|
+
* Lists subscriptions for a Destination.
|
|
1028
|
+
* @summary List Subscriptions from Destination
|
|
2958
1029
|
* @param destinationId
|
|
2959
|
-
* @param
|
|
1030
|
+
* @param pagination Pagination options. This parameter exists in alpha.
|
|
2960
1031
|
*/
|
|
2961
|
-
public async
|
|
1032
|
+
public async listSubscriptionsFromDestination(
|
|
2962
1033
|
destinationId: string,
|
|
2963
|
-
|
|
1034
|
+
pagination: PaginationInput,
|
|
2964
1035
|
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
2965
1036
|
): Promise<{
|
|
2966
1037
|
response: http.IncomingMessage;
|
|
2967
|
-
body:
|
|
1038
|
+
body: ListSubscriptionsFromDestination200Response;
|
|
2968
1039
|
}> {
|
|
2969
1040
|
const localVarPath =
|
|
2970
1041
|
this.basePath +
|
|
2971
|
-
'/destinations/{destinationId}'.replace(
|
|
1042
|
+
'/destinations/{destinationId}/subscriptions'.replace(
|
|
2972
1043
|
'{' + 'destinationId' + '}',
|
|
2973
1044
|
encodeURIComponent(String(destinationId))
|
|
2974
1045
|
);
|
|
@@ -2978,30 +1049,35 @@ export class DestinationsApi {
|
|
|
2978
1049
|
this._defaultHeaders
|
|
2979
1050
|
);
|
|
2980
1051
|
const produces = [
|
|
2981
|
-
'application/vnd.segment.
|
|
1052
|
+
'application/vnd.segment.v1alpha+json',
|
|
2982
1053
|
'application/json',
|
|
2983
1054
|
];
|
|
1055
|
+
// give precedence to 'application/json'
|
|
2984
1056
|
if (produces.indexOf('application/json') >= 0) {
|
|
2985
|
-
localVarHeaderParams.Accept = produces[0];
|
|
2986
|
-
} else {
|
|
2987
1057
|
localVarHeaderParams.Accept = 'application/json';
|
|
1058
|
+
} else {
|
|
1059
|
+
localVarHeaderParams.Accept = produces.join(',');
|
|
2988
1060
|
}
|
|
2989
1061
|
let localVarFormParams: any = {};
|
|
2990
1062
|
|
|
2991
1063
|
// verify required parameter 'destinationId' is not null or undefined
|
|
2992
1064
|
if (destinationId === null || destinationId === undefined) {
|
|
2993
1065
|
throw new Error(
|
|
2994
|
-
'Required parameter destinationId was null or undefined when calling
|
|
1066
|
+
'Required parameter destinationId was null or undefined when calling listSubscriptionsFromDestination.'
|
|
2995
1067
|
);
|
|
2996
1068
|
}
|
|
2997
1069
|
|
|
2998
|
-
// verify required parameter '
|
|
2999
|
-
if (
|
|
3000
|
-
UpdateDestinationV1Input === null ||
|
|
3001
|
-
UpdateDestinationV1Input === undefined
|
|
3002
|
-
) {
|
|
1070
|
+
// verify required parameter 'pagination' is not null or undefined
|
|
1071
|
+
if (pagination === null || pagination === undefined) {
|
|
3003
1072
|
throw new Error(
|
|
3004
|
-
'Required parameter
|
|
1073
|
+
'Required parameter pagination was null or undefined when calling listSubscriptionsFromDestination.'
|
|
1074
|
+
);
|
|
1075
|
+
}
|
|
1076
|
+
|
|
1077
|
+
if (pagination !== undefined) {
|
|
1078
|
+
localVarQueryParameters['pagination'] = ObjectSerializer.serialize(
|
|
1079
|
+
pagination,
|
|
1080
|
+
'PaginationInput'
|
|
3005
1081
|
);
|
|
3006
1082
|
}
|
|
3007
1083
|
|
|
@@ -3010,16 +1086,12 @@ export class DestinationsApi {
|
|
|
3010
1086
|
let localVarUseFormData = false;
|
|
3011
1087
|
|
|
3012
1088
|
let localVarRequestOptions: localVarRequest.Options = {
|
|
3013
|
-
method: '
|
|
1089
|
+
method: 'GET',
|
|
3014
1090
|
qs: localVarQueryParameters,
|
|
3015
1091
|
headers: localVarHeaderParams,
|
|
3016
1092
|
uri: localVarPath,
|
|
3017
1093
|
useQuerystring: this._useQuerystring,
|
|
3018
1094
|
json: true,
|
|
3019
|
-
body: ObjectSerializer.serialize(
|
|
3020
|
-
UpdateDestinationV1Input,
|
|
3021
|
-
'UpdateDestinationV1Input'
|
|
3022
|
-
),
|
|
3023
1095
|
};
|
|
3024
1096
|
|
|
3025
1097
|
let authenticationPromise = Promise.resolve();
|
|
@@ -3051,7 +1123,7 @@ export class DestinationsApi {
|
|
|
3051
1123
|
}
|
|
3052
1124
|
return new Promise<{
|
|
3053
1125
|
response: http.IncomingMessage;
|
|
3054
|
-
body:
|
|
1126
|
+
body: ListSubscriptionsFromDestination200Response;
|
|
3055
1127
|
}>((resolve, reject) => {
|
|
3056
1128
|
localVarRequest(
|
|
3057
1129
|
localVarRequestOptions,
|
|
@@ -3066,7 +1138,7 @@ export class DestinationsApi {
|
|
|
3066
1138
|
) {
|
|
3067
1139
|
body = ObjectSerializer.deserialize(
|
|
3068
1140
|
body,
|
|
3069
|
-
'
|
|
1141
|
+
'ListSubscriptionsFromDestination200Response'
|
|
3070
1142
|
);
|
|
3071
1143
|
resolve({ response: response, body: body });
|
|
3072
1144
|
} else {
|
|
@@ -3085,55 +1157,55 @@ export class DestinationsApi {
|
|
|
3085
1157
|
});
|
|
3086
1158
|
}
|
|
3087
1159
|
/**
|
|
3088
|
-
*
|
|
3089
|
-
* @summary
|
|
1160
|
+
* Deletes an existing Destination subscription.
|
|
1161
|
+
* @summary Remove Subscription from Destination
|
|
3090
1162
|
* @param destinationId
|
|
3091
|
-
* @param
|
|
1163
|
+
* @param id
|
|
3092
1164
|
*/
|
|
3093
|
-
public async
|
|
1165
|
+
public async removeSubscriptionFromDestination(
|
|
3094
1166
|
destinationId: string,
|
|
3095
|
-
|
|
1167
|
+
id: string,
|
|
3096
1168
|
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
3097
1169
|
): Promise<{
|
|
3098
1170
|
response: http.IncomingMessage;
|
|
3099
|
-
body:
|
|
1171
|
+
body: RemoveSubscriptionFromDestination200Response;
|
|
3100
1172
|
}> {
|
|
3101
1173
|
const localVarPath =
|
|
3102
1174
|
this.basePath +
|
|
3103
|
-
'/destinations/{destinationId}'
|
|
3104
|
-
|
|
3105
|
-
|
|
3106
|
-
|
|
1175
|
+
'/destinations/{destinationId}/subscriptions/{id}'
|
|
1176
|
+
.replace(
|
|
1177
|
+
'{' + 'destinationId' + '}',
|
|
1178
|
+
encodeURIComponent(String(destinationId))
|
|
1179
|
+
)
|
|
1180
|
+
.replace('{' + 'id' + '}', encodeURIComponent(String(id)));
|
|
3107
1181
|
let localVarQueryParameters: any = {};
|
|
3108
1182
|
let localVarHeaderParams: any = (<any>Object).assign(
|
|
3109
1183
|
{},
|
|
3110
1184
|
this._defaultHeaders
|
|
3111
1185
|
);
|
|
3112
1186
|
const produces = [
|
|
3113
|
-
'application/vnd.segment.
|
|
1187
|
+
'application/vnd.segment.v1alpha+json',
|
|
3114
1188
|
'application/json',
|
|
3115
1189
|
];
|
|
1190
|
+
// give precedence to 'application/json'
|
|
3116
1191
|
if (produces.indexOf('application/json') >= 0) {
|
|
3117
|
-
localVarHeaderParams.Accept = produces[0];
|
|
3118
|
-
} else {
|
|
3119
1192
|
localVarHeaderParams.Accept = 'application/json';
|
|
1193
|
+
} else {
|
|
1194
|
+
localVarHeaderParams.Accept = produces.join(',');
|
|
3120
1195
|
}
|
|
3121
1196
|
let localVarFormParams: any = {};
|
|
3122
1197
|
|
|
3123
1198
|
// verify required parameter 'destinationId' is not null or undefined
|
|
3124
1199
|
if (destinationId === null || destinationId === undefined) {
|
|
3125
1200
|
throw new Error(
|
|
3126
|
-
'Required parameter destinationId was null or undefined when calling
|
|
1201
|
+
'Required parameter destinationId was null or undefined when calling removeSubscriptionFromDestination.'
|
|
3127
1202
|
);
|
|
3128
1203
|
}
|
|
3129
1204
|
|
|
3130
|
-
// verify required parameter '
|
|
3131
|
-
if (
|
|
3132
|
-
UpdateDestinationV1Input === null ||
|
|
3133
|
-
UpdateDestinationV1Input === undefined
|
|
3134
|
-
) {
|
|
1205
|
+
// verify required parameter 'id' is not null or undefined
|
|
1206
|
+
if (id === null || id === undefined) {
|
|
3135
1207
|
throw new Error(
|
|
3136
|
-
'Required parameter
|
|
1208
|
+
'Required parameter id was null or undefined when calling removeSubscriptionFromDestination.'
|
|
3137
1209
|
);
|
|
3138
1210
|
}
|
|
3139
1211
|
|
|
@@ -3142,16 +1214,12 @@ export class DestinationsApi {
|
|
|
3142
1214
|
let localVarUseFormData = false;
|
|
3143
1215
|
|
|
3144
1216
|
let localVarRequestOptions: localVarRequest.Options = {
|
|
3145
|
-
method: '
|
|
1217
|
+
method: 'DELETE',
|
|
3146
1218
|
qs: localVarQueryParameters,
|
|
3147
1219
|
headers: localVarHeaderParams,
|
|
3148
1220
|
uri: localVarPath,
|
|
3149
1221
|
useQuerystring: this._useQuerystring,
|
|
3150
1222
|
json: true,
|
|
3151
|
-
body: ObjectSerializer.serialize(
|
|
3152
|
-
UpdateDestinationV1Input,
|
|
3153
|
-
'UpdateDestinationV1Input'
|
|
3154
|
-
),
|
|
3155
1223
|
};
|
|
3156
1224
|
|
|
3157
1225
|
let authenticationPromise = Promise.resolve();
|
|
@@ -3183,7 +1251,7 @@ export class DestinationsApi {
|
|
|
3183
1251
|
}
|
|
3184
1252
|
return new Promise<{
|
|
3185
1253
|
response: http.IncomingMessage;
|
|
3186
|
-
body:
|
|
1254
|
+
body: RemoveSubscriptionFromDestination200Response;
|
|
3187
1255
|
}>((resolve, reject) => {
|
|
3188
1256
|
localVarRequest(
|
|
3189
1257
|
localVarRequestOptions,
|
|
@@ -3198,7 +1266,7 @@ export class DestinationsApi {
|
|
|
3198
1266
|
) {
|
|
3199
1267
|
body = ObjectSerializer.deserialize(
|
|
3200
1268
|
body,
|
|
3201
|
-
'
|
|
1269
|
+
'RemoveSubscriptionFromDestination200Response'
|
|
3202
1270
|
);
|
|
3203
1271
|
resolve({ response: response, body: body });
|
|
3204
1272
|
} else {
|
|
@@ -3217,12 +1285,12 @@ export class DestinationsApi {
|
|
|
3217
1285
|
});
|
|
3218
1286
|
}
|
|
3219
1287
|
/**
|
|
3220
|
-
* Updates an existing Destination. **Note**: if you attempt to update read-only settings for your destination you\'ll encounter the following behavior: * If only read-only properties are being updated, the endpoint will return an HTTP 400 error. * If there\'s a mix of writable and read-only properties in the payload, the request will be accepted, the writable properties will be updated and the read-only properties ignored. When called, this endpoint may generate the `Integration Disabled` [
|
|
1288
|
+
* Updates an existing Destination. **Note**: if you attempt to update read-only settings for your destination you\'ll encounter the following behavior: * If only read-only properties are being updated, the endpoint will return an HTTP 400 error. * If there\'s a mix of writable and read-only properties in the payload, the request will be accepted, the writable properties will be updated and the read-only properties ignored. When called, this endpoint may generate the `Integration Disabled` event in the [audit trail](/tag/Audit-Trail). Config API omitted fields: - `updateMask`
|
|
3221
1289
|
* @summary Update Destination
|
|
3222
1290
|
* @param destinationId
|
|
3223
1291
|
* @param UpdateDestinationV1Input
|
|
3224
1292
|
*/
|
|
3225
|
-
public async
|
|
1293
|
+
public async updateDestination(
|
|
3226
1294
|
destinationId: string,
|
|
3227
1295
|
UpdateDestinationV1Input: UpdateDestinationV1Input,
|
|
3228
1296
|
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
@@ -3244,18 +1312,21 @@ export class DestinationsApi {
|
|
|
3244
1312
|
const produces = [
|
|
3245
1313
|
'application/vnd.segment.v1+json',
|
|
3246
1314
|
'application/json',
|
|
1315
|
+
'application/vnd.segment.v1beta+json',
|
|
1316
|
+
'application/vnd.segment.v1alpha+json',
|
|
3247
1317
|
];
|
|
1318
|
+
// give precedence to 'application/json'
|
|
3248
1319
|
if (produces.indexOf('application/json') >= 0) {
|
|
3249
|
-
localVarHeaderParams.Accept = produces[0];
|
|
3250
|
-
} else {
|
|
3251
1320
|
localVarHeaderParams.Accept = 'application/json';
|
|
1321
|
+
} else {
|
|
1322
|
+
localVarHeaderParams.Accept = produces.join(',');
|
|
3252
1323
|
}
|
|
3253
1324
|
let localVarFormParams: any = {};
|
|
3254
1325
|
|
|
3255
1326
|
// verify required parameter 'destinationId' is not null or undefined
|
|
3256
1327
|
if (destinationId === null || destinationId === undefined) {
|
|
3257
1328
|
throw new Error(
|
|
3258
|
-
'Required parameter destinationId was null or undefined when calling
|
|
1329
|
+
'Required parameter destinationId was null or undefined when calling updateDestination.'
|
|
3259
1330
|
);
|
|
3260
1331
|
}
|
|
3261
1332
|
|
|
@@ -3265,7 +1336,7 @@ export class DestinationsApi {
|
|
|
3265
1336
|
UpdateDestinationV1Input === undefined
|
|
3266
1337
|
) {
|
|
3267
1338
|
throw new Error(
|
|
3268
|
-
'Required parameter UpdateDestinationV1Input was null or undefined when calling
|
|
1339
|
+
'Required parameter UpdateDestinationV1Input was null or undefined when calling updateDestination.'
|
|
3269
1340
|
);
|
|
3270
1341
|
}
|
|
3271
1342
|
|
|
@@ -3381,10 +1452,11 @@ export class DestinationsApi {
|
|
|
3381
1452
|
'application/vnd.segment.v1alpha+json',
|
|
3382
1453
|
'application/json',
|
|
3383
1454
|
];
|
|
1455
|
+
// give precedence to 'application/json'
|
|
3384
1456
|
if (produces.indexOf('application/json') >= 0) {
|
|
3385
|
-
localVarHeaderParams.Accept = produces[0];
|
|
3386
|
-
} else {
|
|
3387
1457
|
localVarHeaderParams.Accept = 'application/json';
|
|
1458
|
+
} else {
|
|
1459
|
+
localVarHeaderParams.Accept = produces.join(',');
|
|
3388
1460
|
}
|
|
3389
1461
|
let localVarFormParams: any = {};
|
|
3390
1462
|
|