@segment/public-api-sdk-typescript 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +2 -1
- package/api/aPICallsApi.ts +0 -1176
- package/api/apis.ts +0 -178
- package/api/auditTrailApi.ts +0 -714
- package/api/catalogApi.ts +0 -2916
- package/api/deletionAndSuppressionApi.ts +0 -4298
- package/api/destinationFiltersApi.ts +0 -3262
- package/api/destinationsApi.ts +0 -3494
- package/api/edgeFunctionsApi.ts +0 -593
- package/api/eventsApi.ts +0 -922
- package/api/functionsApi.ts +0 -3036
- package/api/iAMGroupsApi.ts +0 -6204
- package/api/iAMRolesApi.ts +0 -566
- package/api/iAMUsersApi.ts +0 -4486
- package/api/labelsApi.ts +0 -1488
- package/api/monthlyTrackedUsersApi.ts +0 -1178
- package/api/selectiveSyncApi.ts +0 -3321
- package/api/sourcesApi.ts +0 -5602
- package/api/spacesApi.ts +0 -489
- package/api/testingApi.ts +0 -568
- package/api/trackingPlansApi.ts +0 -6238
- package/api/transformationsApi.ts +0 -1316
- package/api/warehousesApi.ts +0 -5004
- package/api/workspacesApi.ts +0 -513
- package/api.ts +0 -3
- package/jest.config.js +0 -10
- package/model/aPICallSnapshotV1.ts +0 -50
- package/model/accessPermissionV1.ts +0 -60
- package/model/addConnectionFromSourceToWarehouse200Response.ts +0 -36
- package/model/addConnectionFromSourceToWarehouseV1Output.ts +0 -48
- package/model/addLabelsToSource200Response.ts +0 -36
- package/model/addLabelsToSource200Response1.ts +0 -36
- package/model/addLabelsToSourceAlphaInput.ts +0 -42
- package/model/addLabelsToSourceAlphaOutput.ts +0 -42
- package/model/addLabelsToSourceV1Input.ts +0 -42
- package/model/addLabelsToSourceV1Output.ts +0 -42
- package/model/addPermissionsToUser200Response.ts +0 -36
- package/model/addPermissionsToUserGroup200Response.ts +0 -36
- package/model/addPermissionsToUserGroupV1Input.ts +0 -42
- package/model/addPermissionsToUserGroupV1Output.ts +0 -42
- package/model/addPermissionsToUserV1Input.ts +0 -42
- package/model/addPermissionsToUserV1Output.ts +0 -42
- package/model/addSourceToTrackingPlan200Response.ts +0 -36
- package/model/addSourceToTrackingPlanV1Input.ts +0 -41
- package/model/addSourceToTrackingPlanV1Output.ts +0 -47
- package/model/addUsersToUserGroup200Response.ts +0 -36
- package/model/addUsersToUserGroupV1Input.ts +0 -41
- package/model/addUsersToUserGroupV1Output.ts +0 -39
- package/model/advancedWarehouseSyncScheduleV1Input.ts +0 -51
- package/model/advancedWarehouseSyncScheduleV1Output.ts +0 -51
- package/model/allowedLabelBeta.ts +0 -59
- package/model/auditEventV1.ts +0 -95
- package/model/batchQueryMessagingSubscriptionsForSpace200Response.ts +0 -36
- package/model/batchQueryMessagingSubscriptionsForSpaceAlphaInput.ts +0 -42
- package/model/batchQueryMessagingSubscriptionsForSpaceAlphaOutput.ts +0 -69
- package/model/breakdownBeta.ts +0 -50
- package/model/commonSourceSettingsV1.ts +0 -68
- package/model/createCloudSourceRegulation200Response.ts +0 -36
- package/model/createCloudSourceRegulationV1Input.ts +0 -82
- package/model/createCloudSourceRegulationV1Output.ts +0 -41
- package/model/createDestination200Response.ts +0 -36
- package/model/createDestinationSubscription200Response.ts +0 -36
- package/model/createDestinationSubscriptionAlphaInput.ts +0 -77
- package/model/createDestinationSubscriptionAlphaOutput.ts +0 -39
- package/model/createDestinationV1Input.ts +0 -77
- package/model/createDestinationV1Output.ts +0 -39
- package/model/createEdgeFunctions200Response.ts +0 -36
- package/model/createEdgeFunctionsAlphaInput.ts +0 -41
- package/model/createEdgeFunctionsAlphaOutput.ts +0 -39
- package/model/createFilterForDestination200Response.ts +0 -36
- package/model/createFilterForDestinationV1Input.ts +0 -87
- package/model/createFilterForDestinationV1Output.ts +0 -39
- package/model/createFunction200Response.ts +0 -36
- package/model/createFunctionDeployment200Response.ts +0 -36
- package/model/createFunctionDeploymentV1Output.ts +0 -39
- package/model/createFunctionV1Input.ts +0 -94
- package/model/createFunctionV1Output.ts +0 -39
- package/model/createInvites200Response.ts +0 -36
- package/model/createInvitesV1Input.ts +0 -42
- package/model/createInvitesV1Output.ts +0 -41
- package/model/createLabel200Response.ts +0 -36
- package/model/createLabel200Response1.ts +0 -36
- package/model/createLabelAlphaInput.ts +0 -39
- package/model/createLabelAlphaOutput.ts +0 -42
- package/model/createLabelV1Input.ts +0 -39
- package/model/createLabelV1Output.ts +0 -39
- package/model/createSource200Response.ts +0 -36
- package/model/createSource200Response1.ts +0 -36
- package/model/createSourceAlphaInput.ts +0 -77
- package/model/createSourceAlphaOutput.ts +0 -39
- package/model/createSourceRegulation200Response.ts +0 -36
- package/model/createSourceRegulationV1Input.ts +0 -73
- package/model/createSourceRegulationV1Output.ts +0 -41
- package/model/createSourceV1Input.ts +0 -68
- package/model/createSourceV1Output.ts +0 -39
- package/model/createTrackingPlan200Response.ts +0 -36
- package/model/createTrackingPlanV1Input.ts +0 -68
- package/model/createTrackingPlanV1Output.ts +0 -39
- package/model/createTransformation200Response.ts +0 -36
- package/model/createTransformationBetaInput.ts +0 -96
- package/model/createTransformationBetaOutput.ts +0 -39
- package/model/createUserGroup200Response.ts +0 -36
- package/model/createUserGroupV1Input.ts +0 -41
- package/model/createUserGroupV1Output.ts +0 -39
- package/model/createValidationInWarehouse200Response.ts +0 -36
- package/model/createValidationInWarehouseV1Input.ts +0 -50
- package/model/createValidationInWarehouseV1Output.ts +0 -48
- package/model/createWarehouse200Response.ts +0 -36
- package/model/createWarehouseV1Input.ts +0 -68
- package/model/createWarehouseV1Output.ts +0 -39
- package/model/createWorkspaceRegulation200Response.ts +0 -36
- package/model/createWorkspaceRegulationV1Input.ts +0 -74
- package/model/createWorkspaceRegulationV1Output.ts +0 -41
- package/model/deleteDestination200Response.ts +0 -36
- package/model/deleteDestinationV1Output.ts +0 -47
- package/model/deleteFunction200Response.ts +0 -36
- package/model/deleteFunctionV1Output.ts +0 -47
- package/model/deleteInvites200Response.ts +0 -36
- package/model/deleteInvitesV1Output.ts +0 -47
- package/model/deleteLabel200Response.ts +0 -36
- package/model/deleteLabel200Response1.ts +0 -36
- package/model/deleteLabelAlphaOutput.ts +0 -47
- package/model/deleteLabelV1Output.ts +0 -47
- package/model/deleteRegulation200Response.ts +0 -36
- package/model/deleteRegulationV1Output.ts +0 -47
- package/model/deleteSource200Response.ts +0 -36
- package/model/deleteSource200Response1.ts +0 -36
- package/model/deleteSourceAlphaOutput.ts +0 -47
- package/model/deleteSourceV1Output.ts +0 -47
- package/model/deleteTrackingPlan200Response.ts +0 -36
- package/model/deleteTrackingPlanV1Output.ts +0 -47
- package/model/deleteTransformation200Response.ts +0 -36
- package/model/deleteTransformationBetaOutput.ts +0 -47
- package/model/deleteUserGroup200Response.ts +0 -36
- package/model/deleteUserGroupV1Output.ts +0 -47
- package/model/deleteUsers200Response.ts +0 -36
- package/model/deleteUsersV1Output.ts +0 -47
- package/model/deleteWarehouse200Response.ts +0 -36
- package/model/deleteWarehouseV1Output.ts +0 -47
- package/model/deliveryMetricsSummary.ts +0 -60
- package/model/deliveryMetricsSummaryBeta.ts +0 -60
- package/model/destination.ts +0 -84
- package/model/destination1.ts +0 -84
- package/model/destination2.ts +0 -84
- package/model/destinationFilterActionV1.ts +0 -77
- package/model/destinationFilterV1.ts +0 -123
- package/model/destinationMetadata.ts +0 -184
- package/model/destinationMetadataActionFieldV1.ts +0 -163
- package/model/destinationMetadataActionV1.ts +0 -113
- package/model/destinationMetadataComponentV1.ts +0 -72
- package/model/destinationMetadataFeaturesV1.ts +0 -93
- package/model/destinationMetadataMethodsV1.ts +0 -77
- package/model/destinationMetadataPlatformsV1.ts +0 -59
- package/model/destinationMetadataSubscriptionPresetV1.ts +0 -68
- package/model/destinationMetadataV1.ts +0 -184
- package/model/destinationStatusV1.ts +0 -74
- package/model/destinationSubscription.ts +0 -104
- package/model/destinationSubscriptionUpdateInput.ts +0 -68
- package/model/destinationV1.ts +0 -84
- package/model/disableEdgeFunctions200Response.ts +0 -36
- package/model/disableEdgeFunctionsAlphaOutput.ts +0 -39
- package/model/echo200Response.ts +0 -36
- package/model/echo200Response1.ts +0 -36
- package/model/echoAlphaOutput.ts +0 -66
- package/model/echoV1Output.ts +0 -66
- package/model/edgeFunctions.ts +0 -86
- package/model/edgeFunctions1.ts +0 -86
- package/model/edgeFunctionsAlpha.ts +0 -86
- package/model/eventSourceV1.ts +0 -59
- package/model/filter.ts +0 -51
- package/model/filter1.ts +0 -123
- package/model/filter2.ts +0 -123
- package/model/filter3.ts +0 -123
- package/model/function.ts +0 -166
- package/model/function1.ts +0 -166
- package/model/function2.ts +0 -166
- package/model/functionDeployment.ts +0 -44
- package/model/functionSettingV1.ts +0 -92
- package/model/functionV1.ts +0 -166
- package/model/generateUploadURLForEdgeFunctions200Response.ts +0 -36
- package/model/generateUploadURLForEdgeFunctionsAlphaOutput.ts +0 -41
- package/model/getAdvancedSyncScheduleFromWarehouse200Response.ts +0 -36
- package/model/getAdvancedSyncScheduleFromWarehouseV1Output.ts +0 -48
- package/model/getConnectionStateFromWarehouse200Response.ts +0 -36
- package/model/getConnectionStateFromWarehouseV1Output.ts +0 -48
- package/model/getDailyPerSourceAPICallsUsage200Response.ts +0 -36
- package/model/getDailyPerSourceAPICallsUsageV1Output.ts +0 -49
- package/model/getDailyPerSourceMTUUsage200Response.ts +0 -36
- package/model/getDailyPerSourceMTUUsageV1Output.ts +0 -49
- package/model/getDailyWorkspaceAPICallsUsage200Response.ts +0 -36
- package/model/getDailyWorkspaceAPICallsUsageV1Output.ts +0 -49
- package/model/getDailyWorkspaceMTUUsage200Response.ts +0 -36
- package/model/getDailyWorkspaceMTUUsageV1Output.ts +0 -49
- package/model/getDestination200Response.ts +0 -36
- package/model/getDestinationMetadata200Response.ts +0 -36
- package/model/getDestinationMetadataV1Output.ts +0 -39
- package/model/getDestinationV1Output.ts +0 -39
- package/model/getDestinationsCatalog200Response.ts +0 -36
- package/model/getDestinationsCatalogV1Output.ts +0 -49
- package/model/getEventsVolumeFromWorkspace200Response.ts +0 -36
- package/model/getEventsVolumeFromWorkspaceV1Output.ts +0 -49
- package/model/getFilterInDestination200Response.ts +0 -36
- package/model/getFilterInDestinationV1Output.ts +0 -39
- package/model/getFunction200Response.ts +0 -36
- package/model/getFunctionV1Output.ts +0 -39
- package/model/getLatestFromEdgeFunctions200Response.ts +0 -36
- package/model/getLatestFromEdgeFunctionsAlphaOutput.ts +0 -39
- package/model/getMessagingSubscriptionFailureResponse.ts +0 -57
- package/model/getMessagingSubscriptionSuccessResponse.ts +0 -68
- package/model/getRegulation200Response.ts +0 -36
- package/model/getRegulationV1Output.ts +0 -39
- package/model/getSource200Response.ts +0 -36
- package/model/getSource200Response1.ts +0 -36
- package/model/getSourceAlphaOutput.ts +0 -39
- package/model/getSourceMetadata200Response.ts +0 -36
- package/model/getSourceMetadataV1Output.ts +0 -39
- package/model/getSourceV1Output.ts +0 -39
- package/model/getSourcesCatalog200Response.ts +0 -36
- package/model/getSourcesCatalogV1Output.ts +0 -49
- package/model/getSpace200Response.ts +0 -36
- package/model/getSpaceAlphaOutput.ts +0 -39
- package/model/getSubscriptionFromDestination200Response.ts +0 -36
- package/model/getSubscriptionFromDestinationAlphaOutput.ts +0 -39
- package/model/getSubscriptionRequest.ts +0 -54
- package/model/getTrackingPlan200Response.ts +0 -36
- package/model/getTrackingPlanV1Output.ts +0 -39
- package/model/getTransformation200Response.ts +0 -36
- package/model/getTransformationBetaOutput.ts +0 -39
- package/model/getUser200Response.ts +0 -36
- package/model/getUserGroup200Response.ts +0 -36
- package/model/getUserGroupV1Output.ts +0 -39
- package/model/getUserV1Output.ts +0 -39
- package/model/getWarehouse200Response.ts +0 -36
- package/model/getWarehouseMetadata200Response.ts +0 -36
- package/model/getWarehouseMetadataV1Output.ts +0 -39
- package/model/getWarehouseV1Output.ts +0 -39
- package/model/getWarehousesCatalog200Response.ts +0 -36
- package/model/getWarehousesCatalogV1Output.ts +0 -49
- package/model/getWorkspace200Response.ts +0 -36
- package/model/getWorkspaceV1Output.ts +0 -39
- package/model/group.ts +0 -67
- package/model/groupSourceSettingsV1.ts +0 -64
- package/model/identify.ts +0 -67
- package/model/identifySourceSettingsV1.ts +0 -64
- package/model/input.ts +0 -68
- package/model/integrationOptionBeta.ts +0 -86
- package/model/invitePermissionV1.ts +0 -61
- package/model/inviteV1.ts +0 -51
- package/model/label.ts +0 -59
- package/model/label1.ts +0 -59
- package/model/label2.ts +0 -59
- package/model/labelAlpha.ts +0 -59
- package/model/labelV1.ts +0 -59
- package/model/listAuditEvents200Response.ts +0 -36
- package/model/listAuditEventsV1Output.ts +0 -49
- package/model/listConnectedDestinationsFromSource200Response.ts +0 -36
- package/model/listConnectedDestinationsFromSource200Response1.ts +0 -36
- package/model/listConnectedDestinationsFromSourceAlphaOutput.ts +0 -49
- package/model/listConnectedDestinationsFromSourceV1Output.ts +0 -49
- package/model/listConnectedSourcesFromWarehouse200Response.ts +0 -36
- package/model/listConnectedSourcesFromWarehouseV1Output.ts +0 -49
- package/model/listConnectedWarehousesFromSource200Response.ts +0 -36
- package/model/listConnectedWarehousesFromSource200Response1.ts +0 -36
- package/model/listConnectedWarehousesFromSourceAlphaOutput.ts +0 -49
- package/model/listConnectedWarehousesFromSourceV1Output.ts +0 -49
- package/model/listDeliveryMetricsSummaryFromDestination200Response.ts +0 -36
- package/model/listDeliveryMetricsSummaryFromDestinationBetaOutput.ts +0 -39
- package/model/listDestinations200Response.ts +0 -36
- package/model/listDestinationsV1Output.ts +0 -49
- package/model/listFiltersFromDestination200Response.ts +0 -36
- package/model/listFiltersFromDestinationV1Output.ts +0 -49
- package/model/listFunctionItemV1.ts +0 -111
- package/model/listFunctions200Response.ts +0 -36
- package/model/listFunctionsV1Output.ts +0 -49
- package/model/listInvites200Response.ts +0 -36
- package/model/listInvitesFromUserGroup200Response.ts +0 -36
- package/model/listInvitesFromUserGroupV1Output.ts +0 -48
- package/model/listInvitesV1Output.ts +0 -48
- package/model/listLabels200Response.ts +0 -36
- package/model/listLabels200Response1.ts +0 -36
- package/model/listLabelsAlphaOutput.ts +0 -42
- package/model/listLabelsV1Output.ts +0 -42
- package/model/listRegulationsFromSource200Response.ts +0 -36
- package/model/listRegulationsFromSourceV1Output.ts +0 -42
- package/model/listRoles200Response.ts +0 -36
- package/model/listRolesV1Output.ts +0 -49
- package/model/listRulesFromTrackingPlan200Response.ts +0 -36
- package/model/listRulesFromTrackingPlanV1Output.ts +0 -49
- package/model/listSchemaSettingsInSource200Response.ts +0 -36
- package/model/listSchemaSettingsInSourceV1Output.ts +0 -48
- package/model/listSelectiveSyncsFromWarehouseAndSource200Response.ts +0 -36
- package/model/listSelectiveSyncsFromWarehouseAndSourceV1Output.ts +0 -49
- package/model/listSources200Response.ts +0 -36
- package/model/listSources200Response1.ts +0 -36
- package/model/listSourcesAlphaOutput.ts +0 -49
- package/model/listSourcesFromTrackingPlan200Response.ts +0 -36
- package/model/listSourcesFromTrackingPlanV1Output.ts +0 -49
- package/model/listSourcesV1Output.ts +0 -49
- package/model/listSubscriptionsFromDestination200Response.ts +0 -36
- package/model/listSubscriptionsFromDestinationAlphaOutput.ts +0 -49
- package/model/listSuppressions200Response.ts +0 -36
- package/model/listSuppressionsV1Output.ts +0 -49
- package/model/listSyncsFromWarehouse200Response.ts +0 -36
- package/model/listSyncsFromWarehouseAndSource200Response.ts +0 -36
- package/model/listSyncsFromWarehouseAndSourceV1Output.ts +0 -49
- package/model/listSyncsFromWarehouseV1Output.ts +0 -49
- package/model/listTrackingPlans200Response.ts +0 -36
- package/model/listTrackingPlansV1Output.ts +0 -49
- package/model/listTransformations200Response.ts +0 -36
- package/model/listTransformationsBetaOutput.ts +0 -49
- package/model/listUserGroups200Response.ts +0 -36
- package/model/listUserGroupsFromUser200Response.ts +0 -36
- package/model/listUserGroupsFromUserV1Output.ts +0 -49
- package/model/listUserGroupsV1Output.ts +0 -49
- package/model/listUsers200Response.ts +0 -36
- package/model/listUsersFromUserGroup200Response.ts +0 -36
- package/model/listUsersFromUserGroupV1Output.ts +0 -49
- package/model/listUsersV1Output.ts +0 -49
- package/model/listWarehouses200Response.ts +0 -36
- package/model/listWarehousesV1Output.ts +0 -49
- package/model/listWorkspaceRegulations200Response.ts +0 -36
- package/model/listWorkspaceRegulationsV1Output.ts +0 -49
- package/model/logos.ts +0 -59
- package/model/logos1.ts +0 -59
- package/model/logos2.ts +0 -59
- package/model/logosBeta.ts +0 -59
- package/model/messageSubscriptionResponse.ts +0 -78
- package/model/messageSubscriptionResponseError.ts +0 -47
- package/model/messagesSubscriptionRequest.ts +0 -68
- package/model/metadata.ts +0 -184
- package/model/metadata1.ts +0 -103
- package/model/metadata2.ts +0 -85
- package/model/metricBeta.ts +0 -60
- package/model/minimalUserGroupV1.ts +0 -50
- package/model/minimalUserV1.ts +0 -59
- package/model/models.ts +0 -1835
- package/model/mtuSnapshotV1.ts +0 -95
- package/model/pagination.ts +0 -68
- package/model/paginationInput.ts +0 -50
- package/model/paginationOutput.ts +0 -68
- package/model/permissionInputV1.ts +0 -51
- package/model/permissionResourceV1.ts +0 -70
- package/model/permissionV1.ts +0 -70
- package/model/previewDestinationFilter200Response.ts +0 -36
- package/model/previewDestinationFilterV1.ts +0 -51
- package/model/previewDestinationFilterV1Input.ts +0 -48
- package/model/previewDestinationFilterV1Output.ts +0 -50
- package/model/propertyRenameBeta.ts +0 -47
- package/model/regulation.ts +0 -99
- package/model/regulationListEntryV1.ts +0 -77
- package/model/removeFilterFromDestination200Response.ts +0 -36
- package/model/removeFilterFromDestinationV1Output.ts +0 -47
- package/model/removeRuleV1.ts +0 -61
- package/model/removeRulesFromTrackingPlan200Response.ts +0 -36
- package/model/removeRulesFromTrackingPlanV1Output.ts +0 -47
- package/model/removeSourceConnectionFromWarehouse200Response.ts +0 -36
- package/model/removeSourceConnectionFromWarehouseV1Output.ts +0 -47
- package/model/removeSourceFromTrackingPlan200Response.ts +0 -36
- package/model/removeSourceFromTrackingPlanV1Output.ts +0 -47
- package/model/removeSubscriptionFromDestination200Response.ts +0 -36
- package/model/removeSubscriptionFromDestinationAlphaOutput.ts +0 -47
- package/model/removeUsersFromUserGroup200Response.ts +0 -36
- package/model/removeUsersFromUserGroupV1Output.ts +0 -47
- package/model/replaceAdvancedSyncScheduleForWarehouse200Response.ts +0 -36
- package/model/replaceAdvancedSyncScheduleForWarehouseV1Input.ts +0 -48
- package/model/replaceAdvancedSyncScheduleForWarehouseV1Output.ts +0 -48
- package/model/replaceLabelsInSource200Response.ts +0 -36
- package/model/replaceLabelsInSource200Response1.ts +0 -36
- package/model/replaceLabelsInSourceAlphaInput.ts +0 -42
- package/model/replaceLabelsInSourceAlphaOutput.ts +0 -42
- package/model/replaceLabelsInSourceV1Input.ts +0 -42
- package/model/replaceLabelsInSourceV1Output.ts +0 -42
- package/model/replaceMessagingSubscriptionsInSpaces200Response.ts +0 -36
- package/model/replaceMessagingSubscriptionsInSpacesAlphaInput.ts +0 -42
- package/model/replaceMessagingSubscriptionsInSpacesAlphaOutput.ts +0 -58
- package/model/replacePermissionsForUser200Response.ts +0 -36
- package/model/replacePermissionsForUserGroup200Response.ts +0 -36
- package/model/replacePermissionsForUserGroupV1Input.ts +0 -42
- package/model/replacePermissionsForUserGroupV1Output.ts +0 -42
- package/model/replacePermissionsForUserV1Input.ts +0 -42
- package/model/replacePermissionsForUserV1Output.ts +0 -42
- package/model/replaceRulesInTrackingPlan200Response.ts +0 -36
- package/model/replaceRulesInTrackingPlanV1Input.ts +0 -42
- package/model/replaceRulesInTrackingPlanV1Output.ts +0 -47
- package/model/replaceUsersInUserGroup200Response.ts +0 -36
- package/model/replaceUsersInUserGroupV1Input.ts +0 -41
- package/model/replaceUsersInUserGroupV1Output.ts +0 -39
- package/model/requestError.ts +0 -77
- package/model/requestErrorEnvelope.ts +0 -39
- package/model/resourceV1.ts +0 -60
- package/model/roleV1.ts +0 -59
- package/model/ruleV1.ts +0 -106
- package/model/schedule.ts +0 -51
- package/model/schedule1.ts +0 -51
- package/model/schedule2.ts +0 -51
- package/model/settings.ts +0 -71
- package/model/settings1.ts +0 -71
- package/model/source.ts +0 -59
- package/model/source1.ts +0 -112
- package/model/source2.ts +0 -112
- package/model/source3.ts +0 -112
- package/model/source4.ts +0 -112
- package/model/source5.ts +0 -112
- package/model/source6.ts +0 -112
- package/model/sourceAPICallSnapshotV1.ts +0 -59
- package/model/sourceAlpha.ts +0 -112
- package/model/sourceEventVolumeDatapointV1.ts +0 -50
- package/model/sourceEventVolumeV1.ts +0 -76
- package/model/sourceMetadata.ts +0 -103
- package/model/sourceMetadataV1.ts +0 -103
- package/model/sourceSettingsOutputV1.ts +0 -71
- package/model/sourceV1.ts +0 -112
- package/model/space.ts +0 -50
- package/model/streamStatusV1.ts +0 -45
- package/model/subscription.ts +0 -104
- package/model/supportedFeatures.ts +0 -93
- package/model/supportedMethods.ts +0 -77
- package/model/supportedPlatforms.ts +0 -59
- package/model/suppressedInner.ts +0 -41
- package/model/syncNoticeV1.ts +0 -59
- package/model/syncV1.ts +0 -105
- package/model/track.ts +0 -85
- package/model/trackSourceSettingsV1.ts +0 -82
- package/model/trackingPlan.ts +0 -104
- package/model/trackingPlan1.ts +0 -104
- package/model/trackingPlanV1.ts +0 -104
- package/model/transformation.ts +0 -105
- package/model/transformation1.ts +0 -105
- package/model/transformation2.ts +0 -105
- package/model/transformationBeta.ts +0 -105
- package/model/updateDestination200Response.ts +0 -36
- package/model/updateDestinationV1Input.ts +0 -59
- package/model/updateDestinationV1Output.ts +0 -39
- package/model/updateFilterForDestination200Response.ts +0 -36
- package/model/updateFilterForDestinationV1Input.ts +0 -78
- package/model/updateFilterForDestinationV1Output.ts +0 -39
- package/model/updateFunction200Response.ts +0 -36
- package/model/updateFunctionV1Input.ts +0 -78
- package/model/updateFunctionV1Output.ts +0 -39
- package/model/updateRulesInTrackingPlan200Response.ts +0 -36
- package/model/updateRulesInTrackingPlanV1Input.ts +0 -42
- package/model/updateRulesInTrackingPlanV1Output.ts +0 -47
- package/model/updateSchemaSettingsInSource200Response.ts +0 -36
- package/model/updateSchemaSettingsInSourceV1Input.ts +0 -71
- package/model/updateSchemaSettingsInSourceV1Output.ts +0 -48
- package/model/updateSelectiveSyncForWarehouse200Response.ts +0 -36
- package/model/updateSelectiveSyncForWarehouseV1Input.ts +0 -42
- package/model/updateSelectiveSyncForWarehouseV1Output.ts +0 -57
- package/model/updateSource200Response.ts +0 -36
- package/model/updateSource200Response1.ts +0 -36
- package/model/updateSourceAlphaInput.ts +0 -68
- package/model/updateSourceAlphaOutput.ts +0 -39
- package/model/updateSourceV1Input.ts +0 -68
- package/model/updateSourceV1Output.ts +0 -39
- package/model/updateSubscriptionForDestination200Response.ts +0 -36
- package/model/updateSubscriptionForDestinationAlphaInput.ts +0 -39
- package/model/updateSubscriptionForDestinationAlphaOutput.ts +0 -39
- package/model/updateTrackingPlan200Response.ts +0 -36
- package/model/updateTrackingPlanV1Input.ts +0 -50
- package/model/updateTrackingPlanV1Output.ts +0 -47
- package/model/updateTransformation200Response.ts +0 -36
- package/model/updateTransformationBetaInput.ts +0 -96
- package/model/updateTransformationBetaOutput.ts +0 -39
- package/model/updateUserGroup200Response.ts +0 -36
- package/model/updateUserGroupV1Input.ts +0 -41
- package/model/updateUserGroupV1Output.ts +0 -39
- package/model/updateWarehouse200Response.ts +0 -36
- package/model/updateWarehouseV1Input.ts +0 -59
- package/model/updateWarehouseV1Output.ts +0 -39
- package/model/upsertRuleV1.ts +0 -112
- package/model/user.ts +0 -69
- package/model/userGroup.ts +0 -69
- package/model/userGroup1.ts +0 -69
- package/model/userGroup2.ts +0 -69
- package/model/userGroup3.ts +0 -69
- package/model/userGroupV1.ts +0 -69
- package/model/userV1.ts +0 -69
- package/model/usersPerSourceSnapshotV1.ts +0 -104
- package/model/warehouse.ts +0 -75
- package/model/warehouse1.ts +0 -75
- package/model/warehouse2.ts +0 -75
- package/model/warehouseAdvancedSyncV1.ts +0 -50
- package/model/warehouseMetadata.ts +0 -85
- package/model/warehouseMetadataV1.ts +0 -85
- package/model/warehouseSelectiveSyncItemV1.ts +0 -68
- package/model/warehouseSyncOverrideV1.ts +0 -68
- package/model/warehouseV1.ts +0 -75
- package/model/workspace.ts +0 -59
- package/model/workspaceV1.ts +0 -59
- package/tests/__snapshots__/smoke.test.ts.snap +0 -889
- package/tests/smoke.test.ts +0 -267
- package/tsconfig.json +0 -20
package/api/testingApi.ts
DELETED
|
@@ -1,568 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Segment Public API
|
|
3
|
-
* The Segment Public API helps you manage your Segment Workspaces and its resources. You can use the API to perform CRUD (create, read, update, delete) operations at no extra charge. This includes working with resources such as Sources, Destinations, Warehouses, Tracking Plans, and the Segment Destinations and Sources Catalogs. All CRUD endpoints in the API follow REST conventions and use standard HTTP methods. Different URL endpoints represent different resources in a Workspace. See the next sections for more information on how to use the Segment Public API.
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 32.0.1
|
|
6
|
-
* Contact: friends@segment.com
|
|
7
|
-
*
|
|
8
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
-
* https://openapi-generator.tech
|
|
10
|
-
* Do not edit the class manually.
|
|
11
|
-
*/
|
|
12
|
-
|
|
13
|
-
import localVarRequest from 'request';
|
|
14
|
-
import http from 'http';
|
|
15
|
-
|
|
16
|
-
/* tslint:disable:no-unused-locals */
|
|
17
|
-
import { Echo200Response } from '../model/echo200Response';
|
|
18
|
-
import { Echo200Response1 } from '../model/echo200Response1';
|
|
19
|
-
import { RequestErrorEnvelope } from '../model/requestErrorEnvelope';
|
|
20
|
-
|
|
21
|
-
import {
|
|
22
|
-
ObjectSerializer,
|
|
23
|
-
Authentication,
|
|
24
|
-
VoidAuth,
|
|
25
|
-
Interceptor,
|
|
26
|
-
} from '../model/models';
|
|
27
|
-
import {
|
|
28
|
-
HttpBasicAuth,
|
|
29
|
-
HttpBearerAuth,
|
|
30
|
-
ApiKeyAuth,
|
|
31
|
-
OAuth,
|
|
32
|
-
} from '../model/models';
|
|
33
|
-
|
|
34
|
-
import { HttpError, RequestFile } from './apis';
|
|
35
|
-
|
|
36
|
-
let defaultBasePath = 'https://api.segmentapis.com';
|
|
37
|
-
|
|
38
|
-
// ===============================================
|
|
39
|
-
// This file is autogenerated - Please do not edit
|
|
40
|
-
// ===============================================
|
|
41
|
-
|
|
42
|
-
export enum TestingApiApiKeys {}
|
|
43
|
-
|
|
44
|
-
export class TestingApi {
|
|
45
|
-
protected _basePath = defaultBasePath;
|
|
46
|
-
protected _defaultHeaders: any = {};
|
|
47
|
-
protected _useQuerystring: boolean = false;
|
|
48
|
-
|
|
49
|
-
protected authentications = {
|
|
50
|
-
default: <Authentication>new VoidAuth(),
|
|
51
|
-
token: new HttpBearerAuth(),
|
|
52
|
-
};
|
|
53
|
-
|
|
54
|
-
protected interceptors: Interceptor[] = [];
|
|
55
|
-
|
|
56
|
-
constructor(basePath?: string);
|
|
57
|
-
constructor(
|
|
58
|
-
basePathOrUsername: string,
|
|
59
|
-
password?: string,
|
|
60
|
-
basePath?: string
|
|
61
|
-
) {
|
|
62
|
-
if (password) {
|
|
63
|
-
if (basePath) {
|
|
64
|
-
this.basePath = basePath;
|
|
65
|
-
}
|
|
66
|
-
} else {
|
|
67
|
-
if (basePathOrUsername) {
|
|
68
|
-
this.basePath = basePathOrUsername;
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
set useQuerystring(value: boolean) {
|
|
74
|
-
this._useQuerystring = value;
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
set basePath(basePath: string) {
|
|
78
|
-
this._basePath = basePath;
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
set defaultHeaders(defaultHeaders: any) {
|
|
82
|
-
this._defaultHeaders = defaultHeaders;
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
get defaultHeaders() {
|
|
86
|
-
return this._defaultHeaders;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
get basePath() {
|
|
90
|
-
return this._basePath;
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
public setDefaultAuthentication(auth: Authentication) {
|
|
94
|
-
this.authentications.default = auth;
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
public setApiKey(key: TestingApiApiKeys, value: string) {
|
|
98
|
-
(this.authentications as any)[TestingApiApiKeys[key]].apiKey = value;
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
set accessToken(accessToken: string | (() => string)) {
|
|
102
|
-
this.authentications.token.accessToken = accessToken;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
public addInterceptor(interceptor: Interceptor) {
|
|
106
|
-
this.interceptors.push(interceptor);
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
/**
|
|
110
|
-
* Public Echo endpoint.
|
|
111
|
-
* @summary Echo
|
|
112
|
-
* @param message Sets the response `message` field. The response contains this field\'s entry. This parameter exists in v1.
|
|
113
|
-
* @param delay The desired response delay, in milliseconds. This parameter exists in v1.
|
|
114
|
-
* @param triggerError If `true`, returns an HTTP `4xx` error that contains the string in `message`. This parameter exists in v1.
|
|
115
|
-
* @param triggerMultipleErrors If `true`, returns an HTTP `4xx` error that contains the value of the `message` field in the error message array. This has no effect if the request sets `triggerError`. This parameter exists in v1.
|
|
116
|
-
* @param triggerUnexpectedError If `true`, triggers a `500` error. This has no effect if the request sets either `triggerError` or `triggerMultipleErrors`. This parameter exists in v1.
|
|
117
|
-
* @param statusCode Sets the HTTP status code to return. This parameter exists in v1.
|
|
118
|
-
*/
|
|
119
|
-
public async echoAlpha(
|
|
120
|
-
message: string,
|
|
121
|
-
delay?: number,
|
|
122
|
-
triggerError?: boolean,
|
|
123
|
-
triggerMultipleErrors?: boolean,
|
|
124
|
-
triggerUnexpectedError?: boolean,
|
|
125
|
-
statusCode?: number,
|
|
126
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
127
|
-
): Promise<{ response: http.IncomingMessage; body: Echo200Response }> {
|
|
128
|
-
const localVarPath = this.basePath + '/echo';
|
|
129
|
-
let localVarQueryParameters: any = {};
|
|
130
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
131
|
-
{},
|
|
132
|
-
this._defaultHeaders
|
|
133
|
-
);
|
|
134
|
-
const produces = [
|
|
135
|
-
'application/vnd.segment.v1alpha+json',
|
|
136
|
-
'application/json',
|
|
137
|
-
];
|
|
138
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
139
|
-
localVarHeaderParams.Accept = produces[0];
|
|
140
|
-
} else {
|
|
141
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
142
|
-
}
|
|
143
|
-
let localVarFormParams: any = {};
|
|
144
|
-
|
|
145
|
-
// verify required parameter 'message' is not null or undefined
|
|
146
|
-
if (message === null || message === undefined) {
|
|
147
|
-
throw new Error(
|
|
148
|
-
'Required parameter message was null or undefined when calling echoAlpha.'
|
|
149
|
-
);
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
if (message !== undefined) {
|
|
153
|
-
localVarQueryParameters['message'] = ObjectSerializer.serialize(
|
|
154
|
-
message,
|
|
155
|
-
'string'
|
|
156
|
-
);
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
if (delay !== undefined) {
|
|
160
|
-
localVarQueryParameters['delay'] = ObjectSerializer.serialize(
|
|
161
|
-
delay,
|
|
162
|
-
'number'
|
|
163
|
-
);
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
if (triggerError !== undefined) {
|
|
167
|
-
localVarQueryParameters['triggerError'] =
|
|
168
|
-
ObjectSerializer.serialize(triggerError, 'boolean');
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
if (triggerMultipleErrors !== undefined) {
|
|
172
|
-
localVarQueryParameters['triggerMultipleErrors'] =
|
|
173
|
-
ObjectSerializer.serialize(triggerMultipleErrors, 'boolean');
|
|
174
|
-
}
|
|
175
|
-
|
|
176
|
-
if (triggerUnexpectedError !== undefined) {
|
|
177
|
-
localVarQueryParameters['triggerUnexpectedError'] =
|
|
178
|
-
ObjectSerializer.serialize(triggerUnexpectedError, 'boolean');
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
if (statusCode !== undefined) {
|
|
182
|
-
localVarQueryParameters['statusCode'] = ObjectSerializer.serialize(
|
|
183
|
-
statusCode,
|
|
184
|
-
'number'
|
|
185
|
-
);
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
189
|
-
|
|
190
|
-
let localVarUseFormData = false;
|
|
191
|
-
|
|
192
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
193
|
-
method: 'GET',
|
|
194
|
-
qs: localVarQueryParameters,
|
|
195
|
-
headers: localVarHeaderParams,
|
|
196
|
-
uri: localVarPath,
|
|
197
|
-
useQuerystring: this._useQuerystring,
|
|
198
|
-
json: true,
|
|
199
|
-
};
|
|
200
|
-
|
|
201
|
-
let authenticationPromise = Promise.resolve();
|
|
202
|
-
if (this.authentications.token.accessToken) {
|
|
203
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
204
|
-
this.authentications.token.applyToRequest(
|
|
205
|
-
localVarRequestOptions
|
|
206
|
-
)
|
|
207
|
-
);
|
|
208
|
-
}
|
|
209
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
210
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
211
|
-
);
|
|
212
|
-
|
|
213
|
-
let interceptorPromise = authenticationPromise;
|
|
214
|
-
for (const interceptor of this.interceptors) {
|
|
215
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
216
|
-
interceptor(localVarRequestOptions)
|
|
217
|
-
);
|
|
218
|
-
}
|
|
219
|
-
|
|
220
|
-
return interceptorPromise.then(() => {
|
|
221
|
-
if (Object.keys(localVarFormParams).length) {
|
|
222
|
-
if (localVarUseFormData) {
|
|
223
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
224
|
-
} else {
|
|
225
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
226
|
-
}
|
|
227
|
-
}
|
|
228
|
-
return new Promise<{
|
|
229
|
-
response: http.IncomingMessage;
|
|
230
|
-
body: Echo200Response;
|
|
231
|
-
}>((resolve, reject) => {
|
|
232
|
-
localVarRequest(
|
|
233
|
-
localVarRequestOptions,
|
|
234
|
-
(error, response, body) => {
|
|
235
|
-
if (error) {
|
|
236
|
-
reject(error);
|
|
237
|
-
} else {
|
|
238
|
-
if (
|
|
239
|
-
response.statusCode &&
|
|
240
|
-
response.statusCode >= 200 &&
|
|
241
|
-
response.statusCode <= 299
|
|
242
|
-
) {
|
|
243
|
-
body = ObjectSerializer.deserialize(
|
|
244
|
-
body,
|
|
245
|
-
'Echo200Response'
|
|
246
|
-
);
|
|
247
|
-
resolve({ response: response, body: body });
|
|
248
|
-
} else {
|
|
249
|
-
reject(
|
|
250
|
-
new HttpError(
|
|
251
|
-
response,
|
|
252
|
-
body,
|
|
253
|
-
response.statusCode
|
|
254
|
-
)
|
|
255
|
-
);
|
|
256
|
-
}
|
|
257
|
-
}
|
|
258
|
-
}
|
|
259
|
-
);
|
|
260
|
-
});
|
|
261
|
-
});
|
|
262
|
-
}
|
|
263
|
-
/**
|
|
264
|
-
* Public Echo endpoint.
|
|
265
|
-
* @summary Echo
|
|
266
|
-
* @param message Sets the response `message` field. The response contains this field\'s entry. This parameter exists in v1.
|
|
267
|
-
* @param delay The desired response delay, in milliseconds. This parameter exists in v1.
|
|
268
|
-
* @param triggerError If `true`, returns an HTTP `4xx` error that contains the string in `message`. This parameter exists in v1.
|
|
269
|
-
* @param triggerMultipleErrors If `true`, returns an HTTP `4xx` error that contains the value of the `message` field in the error message array. This has no effect if the request sets `triggerError`. This parameter exists in v1.
|
|
270
|
-
* @param triggerUnexpectedError If `true`, triggers a `500` error. This has no effect if the request sets either `triggerError` or `triggerMultipleErrors`. This parameter exists in v1.
|
|
271
|
-
* @param statusCode Sets the HTTP status code to return. This parameter exists in v1.
|
|
272
|
-
*/
|
|
273
|
-
public async echoCurrent(
|
|
274
|
-
message: string,
|
|
275
|
-
delay?: number,
|
|
276
|
-
triggerError?: boolean,
|
|
277
|
-
triggerMultipleErrors?: boolean,
|
|
278
|
-
triggerUnexpectedError?: boolean,
|
|
279
|
-
statusCode?: number,
|
|
280
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
281
|
-
): Promise<{ response: http.IncomingMessage; body: Echo200Response1 }> {
|
|
282
|
-
const localVarPath = this.basePath + '/echo';
|
|
283
|
-
let localVarQueryParameters: any = {};
|
|
284
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
285
|
-
{},
|
|
286
|
-
this._defaultHeaders
|
|
287
|
-
);
|
|
288
|
-
const produces = ['application/json'];
|
|
289
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
290
|
-
localVarHeaderParams.Accept = produces[0];
|
|
291
|
-
} else {
|
|
292
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
293
|
-
}
|
|
294
|
-
let localVarFormParams: any = {};
|
|
295
|
-
|
|
296
|
-
// verify required parameter 'message' is not null or undefined
|
|
297
|
-
if (message === null || message === undefined) {
|
|
298
|
-
throw new Error(
|
|
299
|
-
'Required parameter message was null or undefined when calling echoCurrent.'
|
|
300
|
-
);
|
|
301
|
-
}
|
|
302
|
-
|
|
303
|
-
if (message !== undefined) {
|
|
304
|
-
localVarQueryParameters['message'] = ObjectSerializer.serialize(
|
|
305
|
-
message,
|
|
306
|
-
'string'
|
|
307
|
-
);
|
|
308
|
-
}
|
|
309
|
-
|
|
310
|
-
if (delay !== undefined) {
|
|
311
|
-
localVarQueryParameters['delay'] = ObjectSerializer.serialize(
|
|
312
|
-
delay,
|
|
313
|
-
'number'
|
|
314
|
-
);
|
|
315
|
-
}
|
|
316
|
-
|
|
317
|
-
if (triggerError !== undefined) {
|
|
318
|
-
localVarQueryParameters['triggerError'] =
|
|
319
|
-
ObjectSerializer.serialize(triggerError, 'boolean');
|
|
320
|
-
}
|
|
321
|
-
|
|
322
|
-
if (triggerMultipleErrors !== undefined) {
|
|
323
|
-
localVarQueryParameters['triggerMultipleErrors'] =
|
|
324
|
-
ObjectSerializer.serialize(triggerMultipleErrors, 'boolean');
|
|
325
|
-
}
|
|
326
|
-
|
|
327
|
-
if (triggerUnexpectedError !== undefined) {
|
|
328
|
-
localVarQueryParameters['triggerUnexpectedError'] =
|
|
329
|
-
ObjectSerializer.serialize(triggerUnexpectedError, 'boolean');
|
|
330
|
-
}
|
|
331
|
-
|
|
332
|
-
if (statusCode !== undefined) {
|
|
333
|
-
localVarQueryParameters['statusCode'] = ObjectSerializer.serialize(
|
|
334
|
-
statusCode,
|
|
335
|
-
'number'
|
|
336
|
-
);
|
|
337
|
-
}
|
|
338
|
-
|
|
339
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
340
|
-
|
|
341
|
-
let localVarUseFormData = false;
|
|
342
|
-
|
|
343
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
344
|
-
method: 'GET',
|
|
345
|
-
qs: localVarQueryParameters,
|
|
346
|
-
headers: localVarHeaderParams,
|
|
347
|
-
uri: localVarPath,
|
|
348
|
-
useQuerystring: this._useQuerystring,
|
|
349
|
-
json: true,
|
|
350
|
-
};
|
|
351
|
-
|
|
352
|
-
let authenticationPromise = Promise.resolve();
|
|
353
|
-
if (this.authentications.token.accessToken) {
|
|
354
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
355
|
-
this.authentications.token.applyToRequest(
|
|
356
|
-
localVarRequestOptions
|
|
357
|
-
)
|
|
358
|
-
);
|
|
359
|
-
}
|
|
360
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
361
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
362
|
-
);
|
|
363
|
-
|
|
364
|
-
let interceptorPromise = authenticationPromise;
|
|
365
|
-
for (const interceptor of this.interceptors) {
|
|
366
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
367
|
-
interceptor(localVarRequestOptions)
|
|
368
|
-
);
|
|
369
|
-
}
|
|
370
|
-
|
|
371
|
-
return interceptorPromise.then(() => {
|
|
372
|
-
if (Object.keys(localVarFormParams).length) {
|
|
373
|
-
if (localVarUseFormData) {
|
|
374
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
375
|
-
} else {
|
|
376
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
377
|
-
}
|
|
378
|
-
}
|
|
379
|
-
return new Promise<{
|
|
380
|
-
response: http.IncomingMessage;
|
|
381
|
-
body: Echo200Response1;
|
|
382
|
-
}>((resolve, reject) => {
|
|
383
|
-
localVarRequest(
|
|
384
|
-
localVarRequestOptions,
|
|
385
|
-
(error, response, body) => {
|
|
386
|
-
if (error) {
|
|
387
|
-
reject(error);
|
|
388
|
-
} else {
|
|
389
|
-
if (
|
|
390
|
-
response.statusCode &&
|
|
391
|
-
response.statusCode >= 200 &&
|
|
392
|
-
response.statusCode <= 299
|
|
393
|
-
) {
|
|
394
|
-
body = ObjectSerializer.deserialize(
|
|
395
|
-
body,
|
|
396
|
-
'Echo200Response1'
|
|
397
|
-
);
|
|
398
|
-
resolve({ response: response, body: body });
|
|
399
|
-
} else {
|
|
400
|
-
reject(
|
|
401
|
-
new HttpError(
|
|
402
|
-
response,
|
|
403
|
-
body,
|
|
404
|
-
response.statusCode
|
|
405
|
-
)
|
|
406
|
-
);
|
|
407
|
-
}
|
|
408
|
-
}
|
|
409
|
-
}
|
|
410
|
-
);
|
|
411
|
-
});
|
|
412
|
-
});
|
|
413
|
-
}
|
|
414
|
-
/**
|
|
415
|
-
* Public Echo endpoint.
|
|
416
|
-
* @summary Echo
|
|
417
|
-
* @param message Sets the response `message` field. The response contains this field\'s entry. This parameter exists in v1.
|
|
418
|
-
* @param delay The desired response delay, in milliseconds. This parameter exists in v1.
|
|
419
|
-
* @param triggerError If `true`, returns an HTTP `4xx` error that contains the string in `message`. This parameter exists in v1.
|
|
420
|
-
* @param triggerMultipleErrors If `true`, returns an HTTP `4xx` error that contains the value of the `message` field in the error message array. This has no effect if the request sets `triggerError`. This parameter exists in v1.
|
|
421
|
-
* @param triggerUnexpectedError If `true`, triggers a `500` error. This has no effect if the request sets either `triggerError` or `triggerMultipleErrors`. This parameter exists in v1.
|
|
422
|
-
* @param statusCode Sets the HTTP status code to return. This parameter exists in v1.
|
|
423
|
-
*/
|
|
424
|
-
public async echoV1(
|
|
425
|
-
message: string,
|
|
426
|
-
delay?: number,
|
|
427
|
-
triggerError?: boolean,
|
|
428
|
-
triggerMultipleErrors?: boolean,
|
|
429
|
-
triggerUnexpectedError?: boolean,
|
|
430
|
-
statusCode?: number,
|
|
431
|
-
options: { headers: { [name: string]: string } } = { headers: {} }
|
|
432
|
-
): Promise<{ response: http.IncomingMessage; body: Echo200Response1 }> {
|
|
433
|
-
const localVarPath = this.basePath + '/echo';
|
|
434
|
-
let localVarQueryParameters: any = {};
|
|
435
|
-
let localVarHeaderParams: any = (<any>Object).assign(
|
|
436
|
-
{},
|
|
437
|
-
this._defaultHeaders
|
|
438
|
-
);
|
|
439
|
-
const produces = [
|
|
440
|
-
'application/vnd.segment.v1+json',
|
|
441
|
-
'application/json',
|
|
442
|
-
];
|
|
443
|
-
if (produces.indexOf('application/json') >= 0) {
|
|
444
|
-
localVarHeaderParams.Accept = produces[0];
|
|
445
|
-
} else {
|
|
446
|
-
localVarHeaderParams.Accept = 'application/json';
|
|
447
|
-
}
|
|
448
|
-
let localVarFormParams: any = {};
|
|
449
|
-
|
|
450
|
-
// verify required parameter 'message' is not null or undefined
|
|
451
|
-
if (message === null || message === undefined) {
|
|
452
|
-
throw new Error(
|
|
453
|
-
'Required parameter message was null or undefined when calling echoV1.'
|
|
454
|
-
);
|
|
455
|
-
}
|
|
456
|
-
|
|
457
|
-
if (message !== undefined) {
|
|
458
|
-
localVarQueryParameters['message'] = ObjectSerializer.serialize(
|
|
459
|
-
message,
|
|
460
|
-
'string'
|
|
461
|
-
);
|
|
462
|
-
}
|
|
463
|
-
|
|
464
|
-
if (delay !== undefined) {
|
|
465
|
-
localVarQueryParameters['delay'] = ObjectSerializer.serialize(
|
|
466
|
-
delay,
|
|
467
|
-
'number'
|
|
468
|
-
);
|
|
469
|
-
}
|
|
470
|
-
|
|
471
|
-
if (triggerError !== undefined) {
|
|
472
|
-
localVarQueryParameters['triggerError'] =
|
|
473
|
-
ObjectSerializer.serialize(triggerError, 'boolean');
|
|
474
|
-
}
|
|
475
|
-
|
|
476
|
-
if (triggerMultipleErrors !== undefined) {
|
|
477
|
-
localVarQueryParameters['triggerMultipleErrors'] =
|
|
478
|
-
ObjectSerializer.serialize(triggerMultipleErrors, 'boolean');
|
|
479
|
-
}
|
|
480
|
-
|
|
481
|
-
if (triggerUnexpectedError !== undefined) {
|
|
482
|
-
localVarQueryParameters['triggerUnexpectedError'] =
|
|
483
|
-
ObjectSerializer.serialize(triggerUnexpectedError, 'boolean');
|
|
484
|
-
}
|
|
485
|
-
|
|
486
|
-
if (statusCode !== undefined) {
|
|
487
|
-
localVarQueryParameters['statusCode'] = ObjectSerializer.serialize(
|
|
488
|
-
statusCode,
|
|
489
|
-
'number'
|
|
490
|
-
);
|
|
491
|
-
}
|
|
492
|
-
|
|
493
|
-
(<any>Object).assign(localVarHeaderParams, options.headers);
|
|
494
|
-
|
|
495
|
-
let localVarUseFormData = false;
|
|
496
|
-
|
|
497
|
-
let localVarRequestOptions: localVarRequest.Options = {
|
|
498
|
-
method: 'GET',
|
|
499
|
-
qs: localVarQueryParameters,
|
|
500
|
-
headers: localVarHeaderParams,
|
|
501
|
-
uri: localVarPath,
|
|
502
|
-
useQuerystring: this._useQuerystring,
|
|
503
|
-
json: true,
|
|
504
|
-
};
|
|
505
|
-
|
|
506
|
-
let authenticationPromise = Promise.resolve();
|
|
507
|
-
if (this.authentications.token.accessToken) {
|
|
508
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
509
|
-
this.authentications.token.applyToRequest(
|
|
510
|
-
localVarRequestOptions
|
|
511
|
-
)
|
|
512
|
-
);
|
|
513
|
-
}
|
|
514
|
-
authenticationPromise = authenticationPromise.then(() =>
|
|
515
|
-
this.authentications.default.applyToRequest(localVarRequestOptions)
|
|
516
|
-
);
|
|
517
|
-
|
|
518
|
-
let interceptorPromise = authenticationPromise;
|
|
519
|
-
for (const interceptor of this.interceptors) {
|
|
520
|
-
interceptorPromise = interceptorPromise.then(() =>
|
|
521
|
-
interceptor(localVarRequestOptions)
|
|
522
|
-
);
|
|
523
|
-
}
|
|
524
|
-
|
|
525
|
-
return interceptorPromise.then(() => {
|
|
526
|
-
if (Object.keys(localVarFormParams).length) {
|
|
527
|
-
if (localVarUseFormData) {
|
|
528
|
-
(<any>localVarRequestOptions).formData = localVarFormParams;
|
|
529
|
-
} else {
|
|
530
|
-
localVarRequestOptions.form = localVarFormParams;
|
|
531
|
-
}
|
|
532
|
-
}
|
|
533
|
-
return new Promise<{
|
|
534
|
-
response: http.IncomingMessage;
|
|
535
|
-
body: Echo200Response1;
|
|
536
|
-
}>((resolve, reject) => {
|
|
537
|
-
localVarRequest(
|
|
538
|
-
localVarRequestOptions,
|
|
539
|
-
(error, response, body) => {
|
|
540
|
-
if (error) {
|
|
541
|
-
reject(error);
|
|
542
|
-
} else {
|
|
543
|
-
if (
|
|
544
|
-
response.statusCode &&
|
|
545
|
-
response.statusCode >= 200 &&
|
|
546
|
-
response.statusCode <= 299
|
|
547
|
-
) {
|
|
548
|
-
body = ObjectSerializer.deserialize(
|
|
549
|
-
body,
|
|
550
|
-
'Echo200Response1'
|
|
551
|
-
);
|
|
552
|
-
resolve({ response: response, body: body });
|
|
553
|
-
} else {
|
|
554
|
-
reject(
|
|
555
|
-
new HttpError(
|
|
556
|
-
response,
|
|
557
|
-
body,
|
|
558
|
-
response.statusCode
|
|
559
|
-
)
|
|
560
|
-
);
|
|
561
|
-
}
|
|
562
|
-
}
|
|
563
|
-
}
|
|
564
|
-
);
|
|
565
|
-
});
|
|
566
|
-
});
|
|
567
|
-
}
|
|
568
|
-
}
|