@datadog/datadog-api-client 1.2.0 → 1.4.0
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/CHANGELOG.md +54 -0
- package/LICENSE-3rdparty.csv +1 -0
- package/README.md +120 -3
- package/dist/packages/datadog-api-client-common/configuration.d.ts +5 -1
- package/dist/packages/datadog-api-client-common/configuration.js +3 -6
- package/dist/packages/datadog-api-client-common/configuration.js.map +1 -1
- package/dist/packages/datadog-api-client-common/http/http.d.ts +2 -0
- package/dist/packages/datadog-api-client-common/http/isomorphic-fetch.d.ts +2 -1
- package/dist/packages/datadog-api-client-common/http/isomorphic-fetch.js +11 -5
- package/dist/packages/datadog-api-client-common/http/isomorphic-fetch.js.map +1 -1
- package/dist/packages/datadog-api-client-common/servers.js.map +1 -1
- package/dist/packages/datadog-api-client-common/util.d.ts +0 -9
- package/dist/packages/datadog-api-client-common/util.js +1 -32
- package/dist/packages/datadog-api-client-common/util.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/AWSIntegrationApi.js +262 -407
- package/dist/packages/datadog-api-client-v1/apis/AWSIntegrationApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/AWSLogsIntegrationApi.js +201 -291
- package/dist/packages/datadog-api-client-v1/apis/AWSLogsIntegrationApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/AuthenticationApi.js +27 -33
- package/dist/packages/datadog-api-client-v1/apis/AuthenticationApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/AzureIntegrationApi.js +145 -215
- package/dist/packages/datadog-api-client-v1/apis/AzureIntegrationApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/DashboardListsApi.js +144 -215
- package/dist/packages/datadog-api-client-v1/apis/DashboardListsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/DashboardsApi.js +198 -313
- package/dist/packages/datadog-api-client-v1/apis/DashboardsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/DowntimesApi.js +201 -308
- package/dist/packages/datadog-api-client-v1/apis/DowntimesApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/EventsApi.js +85 -119
- package/dist/packages/datadog-api-client-v1/apis/EventsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/GCPIntegrationApi.js +116 -172
- package/dist/packages/datadog-api-client-v1/apis/GCPIntegrationApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/HostsApi.js +116 -172
- package/dist/packages/datadog-api-client-v1/apis/HostsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/IPRangesApi.js +23 -19
- package/dist/packages/datadog-api-client-v1/apis/IPRangesApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/KeyManagementApi.js +291 -460
- package/dist/packages/datadog-api-client-v1/apis/KeyManagementApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/LogsApi.js +75 -67
- package/dist/packages/datadog-api-client-v1/apis/LogsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/LogsIndexesApi.js +210 -226
- package/dist/packages/datadog-api-client-v1/apis/LogsIndexesApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/LogsPipelinesApi.js +246 -272
- package/dist/packages/datadog-api-client-v1/apis/LogsPipelinesApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/MetricsApi.js +208 -351
- package/dist/packages/datadog-api-client-v1/apis/MetricsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/MonitorsApi.js +295 -490
- package/dist/packages/datadog-api-client-v1/apis/MonitorsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/NotebooksApi.js +146 -251
- package/dist/packages/datadog-api-client-v1/apis/NotebooksApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/OrganizationsApi.js +173 -258
- package/dist/packages/datadog-api-client-v1/apis/OrganizationsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/PagerDutyIntegrationApi.js +111 -174
- package/dist/packages/datadog-api-client-v1/apis/PagerDutyIntegrationApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/SecurityMonitoringApi.js +90 -159
- package/dist/packages/datadog-api-client-v1/apis/SecurityMonitoringApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/ServiceChecksApi.js +31 -63
- package/dist/packages/datadog-api-client-v1/apis/ServiceChecksApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/ServiceLevelObjectiveCorrectionsApi.js +142 -221
- package/dist/packages/datadog-api-client-v1/apis/ServiceLevelObjectiveCorrectionsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/ServiceLevelObjectivesApi.d.ts +8 -1
- package/dist/packages/datadog-api-client-v1/apis/ServiceLevelObjectivesApi.js +298 -492
- package/dist/packages/datadog-api-client-v1/apis/ServiceLevelObjectivesApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/SlackIntegrationApi.js +147 -261
- package/dist/packages/datadog-api-client-v1/apis/SlackIntegrationApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/SnapshotsApi.js +29 -43
- package/dist/packages/datadog-api-client-v1/apis/SnapshotsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/SyntheticsApi.js +765 -1130
- package/dist/packages/datadog-api-client-v1/apis/SyntheticsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/TagsApi.js +142 -211
- package/dist/packages/datadog-api-client-v1/apis/TagsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/UsageMeteringApi.d.ts +37 -27
- package/dist/packages/datadog-api-client-v1/apis/UsageMeteringApi.js +1129 -1641
- package/dist/packages/datadog-api-client-v1/apis/UsageMeteringApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/UsersApi.js +146 -235
- package/dist/packages/datadog-api-client-v1/apis/UsersApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/apis/WebhooksIntegrationApi.js +230 -376
- package/dist/packages/datadog-api-client-v1/apis/WebhooksIntegrationApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/index.d.ts +23 -0
- package/dist/packages/datadog-api-client-v1/index.js +37 -7
- package/dist/packages/datadog-api-client-v1/index.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/DashboardTemplateVariable.d.ts +5 -1
- package/dist/packages/datadog-api-client-v1/models/DashboardTemplateVariable.js +4 -0
- package/dist/packages/datadog-api-client-v1/models/DashboardTemplateVariable.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/DashboardTemplateVariablePresetValue.d.ts +5 -1
- package/dist/packages/datadog-api-client-v1/models/DashboardTemplateVariablePresetValue.js +4 -0
- package/dist/packages/datadog-api-client-v1/models/DashboardTemplateVariablePresetValue.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/FormulaAndFunctionEventQueryDefinition.d.ts +4 -0
- package/dist/packages/datadog-api-client-v1/models/FormulaAndFunctionEventQueryDefinition.js +4 -0
- package/dist/packages/datadog-api-client-v1/models/FormulaAndFunctionEventQueryDefinition.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/FormulaAndFunctionEventsDataSource.d.ts +2 -1
- package/dist/packages/datadog-api-client-v1/models/FormulaAndFunctionEventsDataSource.js +2 -1
- package/dist/packages/datadog-api-client-v1/models/FormulaAndFunctionEventsDataSource.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/HourlyUsageAttributionUsageType.d.ts +3 -1
- package/dist/packages/datadog-api-client-v1/models/HourlyUsageAttributionUsageType.js +3 -1
- package/dist/packages/datadog-api-client-v1/models/HourlyUsageAttributionUsageType.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/ListStreamQuery.d.ts +4 -0
- package/dist/packages/datadog-api-client-v1/models/ListStreamQuery.js +4 -0
- package/dist/packages/datadog-api-client-v1/models/ListStreamQuery.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/ListStreamSource.d.ts +2 -1
- package/dist/packages/datadog-api-client-v1/models/ListStreamSource.js +2 -1
- package/dist/packages/datadog-api-client-v1/models/ListStreamSource.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/MetricContentEncoding.d.ts +2 -1
- package/dist/packages/datadog-api-client-v1/models/MetricContentEncoding.js +2 -1
- package/dist/packages/datadog-api-client-v1/models/MetricContentEncoding.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/MonitorOptions.d.ts +16 -0
- package/dist/packages/datadog-api-client-v1/models/MonitorOptions.js +8 -0
- package/dist/packages/datadog-api-client-v1/models/MonitorOptions.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/MonitorSummaryWidgetDefinition.d.ts +4 -0
- package/dist/packages/datadog-api-client-v1/models/MonitorSummaryWidgetDefinition.js +4 -0
- package/dist/packages/datadog-api-client-v1/models/MonitorSummaryWidgetDefinition.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/MonthlyUsageAttributionSupportedMetrics.d.ts +5 -1
- package/dist/packages/datadog-api-client-v1/models/MonthlyUsageAttributionSupportedMetrics.js +6 -1
- package/dist/packages/datadog-api-client-v1/models/MonthlyUsageAttributionSupportedMetrics.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/MonthlyUsageAttributionValues.d.ts +16 -0
- package/dist/packages/datadog-api-client-v1/models/MonthlyUsageAttributionValues.js +20 -0
- package/dist/packages/datadog-api-client-v1/models/MonthlyUsageAttributionValues.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/ObjectSerializer.js +71 -3
- package/dist/packages/datadog-api-client-v1/models/ObjectSerializer.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/OnMissingDataOption.d.ts +10 -0
- package/dist/packages/datadog-api-client-v1/models/OnMissingDataOption.js +13 -0
- package/dist/packages/datadog-api-client-v1/models/OnMissingDataOption.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SLOCreator.d.ts +36 -0
- package/dist/packages/datadog-api-client-v1/models/SLOCreator.js +42 -0
- package/dist/packages/datadog-api-client-v1/models/SLOCreator.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetDefinition.d.ts +47 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetDefinition.js +46 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetDefinition.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetDefinitionType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetDefinitionType.js +10 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetDefinitionType.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetQuery.d.ts +32 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetQuery.js +39 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetQuery.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetRequest.d.ts +34 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetRequest.js +34 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetRequest.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetRequestType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetRequestType.js +10 -0
- package/dist/packages/datadog-api-client-v1/models/SLOListWidgetRequestType.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SLOOverallStatuses.d.ts +55 -0
- package/dist/packages/datadog-api-client-v1/models/SLOOverallStatuses.js +56 -0
- package/dist/packages/datadog-api-client-v1/models/SLOOverallStatuses.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SLORawErrorBudgetRemaining.d.ts +32 -0
- package/dist/packages/datadog-api-client-v1/models/SLORawErrorBudgetRemaining.js +38 -0
- package/dist/packages/datadog-api-client-v1/models/SLORawErrorBudgetRemaining.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SearchSLOQuery.d.ts +39 -0
- package/dist/packages/datadog-api-client-v1/models/SearchSLOQuery.js +43 -0
- package/dist/packages/datadog-api-client-v1/models/SearchSLOQuery.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SearchSLOResponseDataAttributes.d.ts +2 -2
- package/dist/packages/datadog-api-client-v1/models/SearchSLOResponseDataAttributes.js +3 -3
- package/dist/packages/datadog-api-client-v1/models/SearchSLOResponseDataAttributes.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/SearchSLOThreshold.d.ts +54 -0
- package/dist/packages/datadog-api-client-v1/models/SearchSLOThreshold.js +48 -0
- package/dist/packages/datadog-api-client-v1/models/SearchSLOThreshold.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SearchSLOTimeframe.d.ts +9 -0
- package/dist/packages/datadog-api-client-v1/models/SearchSLOTimeframe.js +12 -0
- package/dist/packages/datadog-api-client-v1/models/SearchSLOTimeframe.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SearchServiceLevelObjective.d.ts +29 -0
- package/dist/packages/datadog-api-client-v1/models/SearchServiceLevelObjective.js +28 -0
- package/dist/packages/datadog-api-client-v1/models/SearchServiceLevelObjective.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SearchServiceLevelObjectiveAttributes.d.ts +103 -0
- package/dist/packages/datadog-api-client-v1/models/SearchServiceLevelObjectiveAttributes.js +88 -0
- package/dist/packages/datadog-api-client-v1/models/SearchServiceLevelObjectiveAttributes.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SearchServiceLevelObjectiveData.d.ts +40 -0
- package/dist/packages/datadog-api-client-v1/models/SearchServiceLevelObjectiveData.js +36 -0
- package/dist/packages/datadog-api-client-v1/models/SearchServiceLevelObjectiveData.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SyntheticsAssertionOperator.d.ts +2 -1
- package/dist/packages/datadog-api-client-v1/models/SyntheticsAssertionOperator.js +2 -1
- package/dist/packages/datadog-api-client-v1/models/SyntheticsAssertionOperator.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/SyntheticsBasicAuth.d.ts +2 -1
- package/dist/packages/datadog-api-client-v1/models/SyntheticsBasicAuthDigest.d.ts +37 -0
- package/dist/packages/datadog-api-client-v1/models/SyntheticsBasicAuthDigest.js +38 -0
- package/dist/packages/datadog-api-client-v1/models/SyntheticsBasicAuthDigest.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SyntheticsBasicAuthDigestType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v1/models/SyntheticsBasicAuthDigestType.js +10 -0
- package/dist/packages/datadog-api-client-v1/models/SyntheticsBasicAuthDigestType.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/SyntheticsGlobalVariableParseTestOptions.d.ts +5 -1
- package/dist/packages/datadog-api-client-v1/models/SyntheticsGlobalVariableParseTestOptions.js +4 -1
- package/dist/packages/datadog-api-client-v1/models/SyntheticsGlobalVariableParseTestOptions.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/SyntheticsGlobalVariableParseTestOptionsType.d.ts +2 -1
- package/dist/packages/datadog-api-client-v1/models/SyntheticsGlobalVariableParseTestOptionsType.js +2 -1
- package/dist/packages/datadog-api-client-v1/models/SyntheticsGlobalVariableParseTestOptionsType.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/SyntheticsTestOptions.d.ts +12 -0
- package/dist/packages/datadog-api-client-v1/models/SyntheticsTestOptions.js +13 -0
- package/dist/packages/datadog-api-client-v1/models/SyntheticsTestOptions.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/SyntheticsTestProcessStatus.d.ts +1 -2
- package/dist/packages/datadog-api-client-v1/models/SyntheticsTestProcessStatus.js +1 -2
- package/dist/packages/datadog-api-client-v1/models/SyntheticsTestProcessStatus.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/SyntheticsTestRequest.d.ts +4 -0
- package/dist/packages/datadog-api-client-v1/models/SyntheticsTestRequest.js +4 -0
- package/dist/packages/datadog-api-client-v1/models/SyntheticsTestRequest.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/TopologyMapWidgetDefinition.d.ts +52 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyMapWidgetDefinition.js +50 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyMapWidgetDefinition.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyMapWidgetDefinitionType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyMapWidgetDefinitionType.js +10 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyMapWidgetDefinitionType.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyQuery.d.ts +37 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyQuery.js +36 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyQuery.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyQueryDataSource.d.ts +8 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyQueryDataSource.js +11 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyQueryDataSource.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyRequest.d.ts +34 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyRequest.js +32 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyRequest.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyRequestType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyRequestType.js +10 -0
- package/dist/packages/datadog-api-client-v1/models/TopologyRequestType.js.map +1 -0
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionSort.d.ts +5 -1
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionSort.js +5 -1
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionSort.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionSupportedMetrics.d.ts +5 -1
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionSupportedMetrics.js +5 -1
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionSupportedMetrics.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionValues.d.ts +16 -0
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionValues.js +20 -0
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionValues.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/UsageBillableSummaryHour.d.ts +4 -0
- package/dist/packages/datadog-api-client-v1/models/UsageBillableSummaryHour.js +4 -0
- package/dist/packages/datadog-api-client-v1/models/UsageBillableSummaryHour.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/UsageCloudSecurityPostureManagementHour.d.ts +4 -0
- package/dist/packages/datadog-api-client-v1/models/UsageCloudSecurityPostureManagementHour.js +5 -0
- package/dist/packages/datadog-api-client-v1/models/UsageCloudSecurityPostureManagementHour.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/UsageFargateHour.d.ts +4 -0
- package/dist/packages/datadog-api-client-v1/models/UsageFargateHour.js +5 -0
- package/dist/packages/datadog-api-client-v1/models/UsageFargateHour.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/UsageSummaryDate.d.ts +8 -0
- package/dist/packages/datadog-api-client-v1/models/UsageSummaryDate.js +10 -0
- package/dist/packages/datadog-api-client-v1/models/UsageSummaryDate.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/UsageSummaryDateOrg.d.ts +12 -0
- package/dist/packages/datadog-api-client-v1/models/UsageSummaryDateOrg.js +14 -0
- package/dist/packages/datadog-api-client-v1/models/UsageSummaryDateOrg.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/UsageSummaryResponse.d.ts +8 -0
- package/dist/packages/datadog-api-client-v1/models/UsageSummaryResponse.js +10 -0
- package/dist/packages/datadog-api-client-v1/models/UsageSummaryResponse.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/WidgetDefinition.d.ts +3 -1
- package/dist/packages/datadog-api-client-v1/models/WidgetMonitorSummarySort.d.ts +3 -1
- package/dist/packages/datadog-api-client-v1/models/WidgetMonitorSummarySort.js +3 -1
- package/dist/packages/datadog-api-client-v1/models/WidgetMonitorSummarySort.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/AuditApi.js +58 -86
- package/dist/packages/datadog-api-client-v2/apis/AuditApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/AuthNMappingsApi.js +144 -241
- package/dist/packages/datadog-api-client-v2/apis/AuthNMappingsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/CloudWorkloadSecurityApi.js +167 -260
- package/dist/packages/datadog-api-client-v2/apis/CloudWorkloadSecurityApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/DashboardListsApi.js +119 -202
- package/dist/packages/datadog-api-client-v2/apis/DashboardListsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/EventsApi.js +58 -86
- package/dist/packages/datadog-api-client-v2/apis/EventsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/IncidentServicesApi.js +151 -311
- package/dist/packages/datadog-api-client-v2/apis/IncidentServicesApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/IncidentTeamsApi.js +151 -311
- package/dist/packages/datadog-api-client-v2/apis/IncidentTeamsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/IncidentsApi.d.ts +67 -0
- package/dist/packages/datadog-api-client-v2/apis/IncidentsApi.js +365 -303
- package/dist/packages/datadog-api-client-v2/apis/IncidentsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/KeyManagementApi.js +403 -650
- package/dist/packages/datadog-api-client-v2/apis/KeyManagementApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/LogsApi.js +121 -222
- package/dist/packages/datadog-api-client-v2/apis/LogsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/LogsArchivesApi.js +285 -469
- package/dist/packages/datadog-api-client-v2/apis/LogsArchivesApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/LogsMetricsApi.js +142 -221
- package/dist/packages/datadog-api-client-v2/apis/LogsMetricsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/MetricsApi.d.ts +41 -8
- package/dist/packages/datadog-api-client-v2/apis/MetricsApi.js +428 -560
- package/dist/packages/datadog-api-client-v2/apis/MetricsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/OpsgenieIntegrationApi.js +146 -261
- package/dist/packages/datadog-api-client-v2/apis/OpsgenieIntegrationApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/OrganizationsApi.js +27 -40
- package/dist/packages/datadog-api-client-v2/apis/OrganizationsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/ProcessesApi.js +29 -43
- package/dist/packages/datadog-api-client-v2/apis/ProcessesApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/RUMApi.d.ts +105 -0
- package/dist/packages/datadog-api-client-v2/apis/RUMApi.js +549 -122
- package/dist/packages/datadog-api-client-v2/apis/RUMApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/RolesApi.js +380 -625
- package/dist/packages/datadog-api-client-v2/apis/RolesApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/SecurityMonitoringApi.d.ts +21 -0
- package/dist/packages/datadog-api-client-v2/apis/SecurityMonitoringApi.js +522 -688
- package/dist/packages/datadog-api-client-v2/apis/SecurityMonitoringApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/ServiceAccountsApi.js +144 -231
- package/dist/packages/datadog-api-client-v2/apis/ServiceAccountsApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/UsageMeteringApi.d.ts +43 -6
- package/dist/packages/datadog-api-client-v2/apis/UsageMeteringApi.js +284 -265
- package/dist/packages/datadog-api-client-v2/apis/UsageMeteringApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/apis/UsersApi.js +289 -446
- package/dist/packages/datadog-api-client-v2/apis/UsersApi.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/index.d.ts +49 -6
- package/dist/packages/datadog-api-client-v2/index.js +69 -15
- package/dist/packages/datadog-api-client-v2/index.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/models/ContentEncoding.d.ts +2 -1
- package/dist/packages/datadog-api-client-v2/models/ContentEncoding.js +2 -1
- package/dist/packages/datadog-api-client-v2/models/ContentEncoding.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentAttachmentType.d.ts +8 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentAttachmentType.js +11 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentAttachmentType.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentAttributes.d.ts +12 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentAttributes.js +3 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentAttributes.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentData.d.ts +43 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentData.js +44 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentData.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentLinkAttachmentType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentLinkAttachmentType.js +10 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentLinkAttachmentType.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentLinkAttributes.d.ts +34 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentLinkAttributes.js +34 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentLinkAttributes.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentLinkAttributesAttachmentObject.d.ts +32 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentLinkAttributesAttachmentObject.js +39 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentLinkAttributesAttachmentObject.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentPostmortemAttachmentType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentPostmortemAttachmentType.js +10 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentPostmortemAttachmentType.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentPostmortemAttributes.d.ts +34 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentPostmortemAttributes.js +34 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentPostmortemAttributes.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentRelatedObject.d.ts +7 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentRelatedObject.js +10 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentRelatedObject.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentRelationships.d.ts +29 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentRelationships.js +28 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentRelationships.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentType.js +10 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentType.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentUpdateAttributes.d.ts +12 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentUpdateAttributes.js +3 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentUpdateAttributes.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentUpdateData.d.ts +38 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentUpdateData.js +37 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentUpdateData.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentUpdateRequest.d.ts +32 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentUpdateRequest.js +29 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentUpdateRequest.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentUpdateResponse.d.ts +35 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentUpdateResponse.js +33 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentUpdateResponse.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentsPostmortemAttributesAttachmentObject.d.ts +32 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentsPostmortemAttributesAttachmentObject.js +39 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentsPostmortemAttributesAttachmentObject.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentsResponse.d.ts +34 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentsResponse.js +33 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentsResponse.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentsResponseIncludedItem.d.ts +11 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentsResponseIncludedItem.js +3 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentAttachmentsResponseIncludedItem.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/IncidentRelatedObject.d.ts +2 -1
- package/dist/packages/datadog-api-client-v2/models/IncidentRelatedObject.js +2 -1
- package/dist/packages/datadog-api-client-v2/models/IncidentRelatedObject.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/models/IncidentResponseAttributes.d.ts +0 -4
- package/dist/packages/datadog-api-client-v2/models/IncidentResponseAttributes.js +0 -4
- package/dist/packages/datadog-api-client-v2/models/IncidentResponseAttributes.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/models/IncidentResponseIncludedItem.d.ts +2 -1
- package/dist/packages/datadog-api-client-v2/models/IncidentResponseRelationships.d.ts +5 -5
- package/dist/packages/datadog-api-client-v2/models/IncidentResponseRelationships.js +4 -4
- package/dist/packages/datadog-api-client-v2/models/IncidentResponseRelationships.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/models/MetricActiveConfigurationType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v2/models/MetricActiveConfigurationType.js +10 -0
- package/dist/packages/datadog-api-client-v2/models/MetricActiveConfigurationType.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/MetricContentEncoding.d.ts +3 -1
- package/dist/packages/datadog-api-client-v2/models/MetricContentEncoding.js +3 -1
- package/dist/packages/datadog-api-client-v2/models/MetricContentEncoding.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/models/MetricSuggestedTagsAndAggregations.d.ts +38 -0
- package/dist/packages/datadog-api-client-v2/models/MetricSuggestedTagsAndAggregations.js +36 -0
- package/dist/packages/datadog-api-client-v2/models/MetricSuggestedTagsAndAggregations.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/MetricSuggestedTagsAndAggregationsResponse.d.ts +29 -0
- package/dist/packages/datadog-api-client-v2/models/MetricSuggestedTagsAndAggregationsResponse.js +28 -0
- package/dist/packages/datadog-api-client-v2/models/MetricSuggestedTagsAndAggregationsResponse.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/MetricSuggestedTagsAttributes.d.ts +33 -0
- package/dist/packages/datadog-api-client-v2/models/MetricSuggestedTagsAttributes.js +32 -0
- package/dist/packages/datadog-api-client-v2/models/MetricSuggestedTagsAttributes.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/ObjectSerializer.js +98 -12
- package/dist/packages/datadog-api-client-v2/models/ObjectSerializer.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/models/RUMApplication.d.ts +38 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplication.js +39 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplication.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationAttributes.d.ts +60 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationAttributes.js +76 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationAttributes.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationCreate.d.ts +34 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationCreate.js +34 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationCreate.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationCreateAttributes.d.ts +32 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationCreateAttributes.js +38 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationCreateAttributes.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationCreateRequest.d.ts +29 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationCreateRequest.js +29 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationCreateRequest.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationCreateType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationCreateType.js +10 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationCreateType.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationResponse.d.ts +29 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationResponse.js +28 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationResponse.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationType.js +10 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationType.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationUpdate.d.ts +38 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationUpdate.js +38 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationUpdate.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationUpdateAttributes.d.ts +32 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationUpdateAttributes.js +37 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationUpdateAttributes.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationUpdateRequest.d.ts +29 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationUpdateRequest.js +29 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationUpdateRequest.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationUpdateType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationUpdateType.js +10 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationUpdateType.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationsResponse.d.ts +29 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationsResponse.js +28 -0
- package/dist/packages/datadog-api-client-v2/models/RUMApplicationsResponse.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RelationshipToIncidentAttachment.d.ts +29 -0
- package/dist/packages/datadog-api-client-v2/models/RelationshipToIncidentAttachment.js +29 -0
- package/dist/packages/datadog-api-client-v2/models/RelationshipToIncidentAttachment.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RelationshipToIncidentAttachmentData.d.ts +33 -0
- package/dist/packages/datadog-api-client-v2/models/RelationshipToIncidentAttachmentData.js +34 -0
- package/dist/packages/datadog-api-client-v2/models/RelationshipToIncidentAttachmentData.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/RoleUpdateData.d.ts +5 -0
- package/dist/packages/datadog-api-client-v2/models/RoleUpdateData.js +4 -0
- package/dist/packages/datadog-api-client-v2/models/RoleUpdateData.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleCreatePayload.d.ts +4 -61
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleCreatePayload.js +0 -67
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleCreatePayload.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleQuery.d.ts +4 -46
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleQuery.js +0 -49
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleQuery.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleQueryAggregation.d.ts +2 -1
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleQueryAggregation.js +2 -1
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleQueryAggregation.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleResponse.d.ts +5 -90
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleResponse.js +0 -93
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleResponse.js.map +1 -1
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringSignalRuleCreatePayload.d.ts +69 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringSignalRuleCreatePayload.js +70 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringSignalRuleCreatePayload.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringSignalRuleQuery.d.ts +49 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringSignalRuleQuery.js +50 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringSignalRuleQuery.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringSignalRuleResponse.d.ts +97 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringSignalRuleResponse.js +96 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringSignalRuleResponse.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringSignalRuleType.d.ts +7 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringSignalRuleType.js +10 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringSignalRuleType.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringStandardRuleCreatePayload.d.ts +69 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringStandardRuleCreatePayload.js +70 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringStandardRuleCreatePayload.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/{SecurityMonitoringRuleQueryCreate.d.ts → SecurityMonitoringStandardRuleQuery.d.ts} +1 -1
- package/dist/packages/datadog-api-client-v2/models/{SecurityMonitoringRuleQueryCreate.js → SecurityMonitoringStandardRuleQuery.js} +9 -9
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringStandardRuleQuery.js.map +1 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringStandardRuleResponse.d.ts +97 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringStandardRuleResponse.js +96 -0
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringStandardRuleResponse.js.map +1 -0
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +3 -2
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleQueryCreate.js.map +0 -1
|
@@ -55,9 +55,9 @@ exports.SyntheticsApi = exports.SyntheticsApiResponseProcessor = exports.Synthet
|
|
|
55
55
|
var baseapi_1 = require("../../datadog-api-client-common/baseapi");
|
|
56
56
|
var configuration_1 = require("../../datadog-api-client-common/configuration");
|
|
57
57
|
var http_1 = require("../../datadog-api-client-common/http/http");
|
|
58
|
+
var logger_1 = require("../../../logger");
|
|
58
59
|
var ObjectSerializer_1 = require("../models/ObjectSerializer");
|
|
59
60
|
var exception_1 = require("../../datadog-api-client-common/exception");
|
|
60
|
-
var util_1 = require("../../datadog-api-client-common/util");
|
|
61
61
|
var SyntheticsApiRequestFactory = /** @class */ (function (_super) {
|
|
62
62
|
__extends(SyntheticsApiRequestFactory, _super);
|
|
63
63
|
function SyntheticsApiRequestFactory() {
|
|
@@ -811,63 +811,49 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
811
811
|
*/
|
|
812
812
|
SyntheticsApiResponseProcessor.prototype.createGlobalVariable = function (response) {
|
|
813
813
|
return __awaiter(this, void 0, void 0, function () {
|
|
814
|
-
var contentType, body_1, _a, _b, _c, _d,
|
|
815
|
-
return __generator(this, function (
|
|
816
|
-
switch (
|
|
814
|
+
var contentType, body_1, _a, _b, _c, _d, bodyText, _e, _f, body_2, body_3, _g, _h, _j, _k, body;
|
|
815
|
+
return __generator(this, function (_l) {
|
|
816
|
+
switch (_l.label) {
|
|
817
817
|
case 0:
|
|
818
818
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
819
|
-
if (!(
|
|
819
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
820
820
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
821
821
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
822
822
|
return [4 /*yield*/, response.body.text()];
|
|
823
823
|
case 1:
|
|
824
|
-
body_1 = _b.apply(_a, [_d.apply(_c, [
|
|
825
|
-
"SyntheticsGlobalVariable"
|
|
826
|
-
""]);
|
|
824
|
+
body_1 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
825
|
+
"SyntheticsGlobalVariable"]);
|
|
827
826
|
return [2 /*return*/, body_1];
|
|
828
827
|
case 2:
|
|
829
|
-
if (!(
|
|
830
|
-
|
|
831
|
-
|
|
828
|
+
if (!(response.httpStatusCode == 400 ||
|
|
829
|
+
response.httpStatusCode == 403 ||
|
|
830
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
831
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
832
832
|
return [4 /*yield*/, response.body.text()];
|
|
833
833
|
case 3:
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
""
|
|
837
|
-
|
|
834
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
835
|
+
try {
|
|
836
|
+
body_2 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
837
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_2);
|
|
838
|
+
}
|
|
839
|
+
catch (error) {
|
|
840
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
841
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
842
|
+
}
|
|
843
|
+
_l.label = 4;
|
|
838
844
|
case 4:
|
|
839
|
-
if (!(
|
|
840
|
-
|
|
841
|
-
|
|
845
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
846
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
847
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
842
848
|
return [4 /*yield*/, response.body.text()];
|
|
843
849
|
case 5:
|
|
844
|
-
body_3 =
|
|
845
|
-
"APIErrorResponse",
|
|
846
|
-
""]);
|
|
847
|
-
throw new exception_1.ApiException(403, body_3);
|
|
848
|
-
case 6:
|
|
849
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
850
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
851
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
852
|
-
return [4 /*yield*/, response.body.text()];
|
|
853
|
-
case 7:
|
|
854
|
-
body_4 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
855
|
-
"APIErrorResponse",
|
|
856
|
-
""]);
|
|
857
|
-
throw new exception_1.ApiException(429, body_4);
|
|
858
|
-
case 8:
|
|
859
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
860
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
861
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
862
|
-
return [4 /*yield*/, response.body.text()];
|
|
863
|
-
case 9:
|
|
864
|
-
body_5 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
850
|
+
body_3 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
865
851
|
"SyntheticsGlobalVariable",
|
|
866
852
|
""]);
|
|
867
|
-
return [2 /*return*/,
|
|
868
|
-
case
|
|
869
|
-
case
|
|
870
|
-
body = (
|
|
853
|
+
return [2 /*return*/, body_3];
|
|
854
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
855
|
+
case 7:
|
|
856
|
+
body = (_l.sent()) || "";
|
|
871
857
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
872
858
|
}
|
|
873
859
|
});
|
|
@@ -882,63 +868,49 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
882
868
|
*/
|
|
883
869
|
SyntheticsApiResponseProcessor.prototype.createPrivateLocation = function (response) {
|
|
884
870
|
return __awaiter(this, void 0, void 0, function () {
|
|
885
|
-
var contentType,
|
|
886
|
-
return __generator(this, function (
|
|
887
|
-
switch (
|
|
871
|
+
var contentType, body_4, _a, _b, _c, _d, bodyText, _e, _f, body_5, body_6, _g, _h, _j, _k, body;
|
|
872
|
+
return __generator(this, function (_l) {
|
|
873
|
+
switch (_l.label) {
|
|
888
874
|
case 0:
|
|
889
875
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
890
|
-
if (!(
|
|
876
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
891
877
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
892
878
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
893
879
|
return [4 /*yield*/, response.body.text()];
|
|
894
880
|
case 1:
|
|
895
|
-
|
|
896
|
-
"SyntheticsPrivateLocationCreationResponse"
|
|
897
|
-
|
|
898
|
-
return [2 /*return*/, body_6];
|
|
881
|
+
body_4 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
882
|
+
"SyntheticsPrivateLocationCreationResponse"]);
|
|
883
|
+
return [2 /*return*/, body_4];
|
|
899
884
|
case 2:
|
|
900
|
-
if (!(
|
|
901
|
-
|
|
902
|
-
|
|
885
|
+
if (!(response.httpStatusCode == 402 ||
|
|
886
|
+
response.httpStatusCode == 404 ||
|
|
887
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
888
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
903
889
|
return [4 /*yield*/, response.body.text()];
|
|
904
890
|
case 3:
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
""
|
|
908
|
-
|
|
891
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
892
|
+
try {
|
|
893
|
+
body_5 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
894
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_5);
|
|
895
|
+
}
|
|
896
|
+
catch (error) {
|
|
897
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
898
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
899
|
+
}
|
|
900
|
+
_l.label = 4;
|
|
909
901
|
case 4:
|
|
910
|
-
if (!(
|
|
911
|
-
|
|
912
|
-
|
|
902
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
903
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
904
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
913
905
|
return [4 /*yield*/, response.body.text()];
|
|
914
906
|
case 5:
|
|
915
|
-
|
|
916
|
-
"APIErrorResponse",
|
|
917
|
-
""]);
|
|
918
|
-
throw new exception_1.ApiException(404, body_8);
|
|
919
|
-
case 6:
|
|
920
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
921
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
922
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
923
|
-
return [4 /*yield*/, response.body.text()];
|
|
924
|
-
case 7:
|
|
925
|
-
body_9 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
926
|
-
"APIErrorResponse",
|
|
927
|
-
""]);
|
|
928
|
-
throw new exception_1.ApiException(429, body_9);
|
|
929
|
-
case 8:
|
|
930
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
931
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
932
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
933
|
-
return [4 /*yield*/, response.body.text()];
|
|
934
|
-
case 9:
|
|
935
|
-
body_10 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
907
|
+
body_6 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
936
908
|
"SyntheticsPrivateLocationCreationResponse",
|
|
937
909
|
""]);
|
|
938
|
-
return [2 /*return*/,
|
|
939
|
-
case
|
|
940
|
-
case
|
|
941
|
-
body = (
|
|
910
|
+
return [2 /*return*/, body_6];
|
|
911
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
912
|
+
case 7:
|
|
913
|
+
body = (_l.sent()) || "";
|
|
942
914
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
943
915
|
}
|
|
944
916
|
});
|
|
@@ -953,73 +925,50 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
953
925
|
*/
|
|
954
926
|
SyntheticsApiResponseProcessor.prototype.createSyntheticsAPITest = function (response) {
|
|
955
927
|
return __awaiter(this, void 0, void 0, function () {
|
|
956
|
-
var contentType,
|
|
957
|
-
return __generator(this, function (
|
|
958
|
-
switch (
|
|
928
|
+
var contentType, body_7, _a, _b, _c, _d, bodyText, _e, _f, body_8, body_9, _g, _h, _j, _k, body;
|
|
929
|
+
return __generator(this, function (_l) {
|
|
930
|
+
switch (_l.label) {
|
|
959
931
|
case 0:
|
|
960
932
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
961
|
-
if (!(
|
|
933
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
962
934
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
963
935
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
964
936
|
return [4 /*yield*/, response.body.text()];
|
|
965
937
|
case 1:
|
|
966
|
-
|
|
967
|
-
"SyntheticsAPITest"
|
|
968
|
-
|
|
969
|
-
return [2 /*return*/, body_11];
|
|
938
|
+
body_7 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
939
|
+
"SyntheticsAPITest"]);
|
|
940
|
+
return [2 /*return*/, body_7];
|
|
970
941
|
case 2:
|
|
971
|
-
if (!(
|
|
972
|
-
|
|
973
|
-
|
|
942
|
+
if (!(response.httpStatusCode == 400 ||
|
|
943
|
+
response.httpStatusCode == 402 ||
|
|
944
|
+
response.httpStatusCode == 403 ||
|
|
945
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
946
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
974
947
|
return [4 /*yield*/, response.body.text()];
|
|
975
948
|
case 3:
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
""
|
|
979
|
-
|
|
949
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
950
|
+
try {
|
|
951
|
+
body_8 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
952
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_8);
|
|
953
|
+
}
|
|
954
|
+
catch (error) {
|
|
955
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
956
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
957
|
+
}
|
|
958
|
+
_l.label = 4;
|
|
980
959
|
case 4:
|
|
981
|
-
if (!(
|
|
982
|
-
|
|
983
|
-
|
|
960
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
961
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
962
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
984
963
|
return [4 /*yield*/, response.body.text()];
|
|
985
964
|
case 5:
|
|
986
|
-
|
|
987
|
-
"APIErrorResponse",
|
|
988
|
-
""]);
|
|
989
|
-
throw new exception_1.ApiException(402, body_13);
|
|
990
|
-
case 6:
|
|
991
|
-
if (!(0, util_1.isCodeInRange)("403", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
992
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
993
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
994
|
-
return [4 /*yield*/, response.body.text()];
|
|
995
|
-
case 7:
|
|
996
|
-
body_14 = _p.apply(_o, [_r.apply(_q, [_0.sent(), contentType]),
|
|
997
|
-
"APIErrorResponse",
|
|
998
|
-
""]);
|
|
999
|
-
throw new exception_1.ApiException(403, body_14);
|
|
1000
|
-
case 8:
|
|
1001
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 10];
|
|
1002
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1003
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1004
|
-
return [4 /*yield*/, response.body.text()];
|
|
1005
|
-
case 9:
|
|
1006
|
-
body_15 = _t.apply(_s, [_v.apply(_u, [_0.sent(), contentType]),
|
|
1007
|
-
"APIErrorResponse",
|
|
1008
|
-
""]);
|
|
1009
|
-
throw new exception_1.ApiException(429, body_15);
|
|
1010
|
-
case 10:
|
|
1011
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 12];
|
|
1012
|
-
_x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1013
|
-
_z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1014
|
-
return [4 /*yield*/, response.body.text()];
|
|
1015
|
-
case 11:
|
|
1016
|
-
body_16 = _x.apply(_w, [_z.apply(_y, [_0.sent(), contentType]),
|
|
965
|
+
body_9 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1017
966
|
"SyntheticsAPITest",
|
|
1018
967
|
""]);
|
|
1019
|
-
return [2 /*return*/,
|
|
1020
|
-
case
|
|
1021
|
-
case
|
|
1022
|
-
body = (
|
|
968
|
+
return [2 /*return*/, body_9];
|
|
969
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
970
|
+
case 7:
|
|
971
|
+
body = (_l.sent()) || "";
|
|
1023
972
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1024
973
|
}
|
|
1025
974
|
});
|
|
@@ -1034,73 +983,50 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1034
983
|
*/
|
|
1035
984
|
SyntheticsApiResponseProcessor.prototype.createSyntheticsBrowserTest = function (response) {
|
|
1036
985
|
return __awaiter(this, void 0, void 0, function () {
|
|
1037
|
-
var contentType,
|
|
1038
|
-
return __generator(this, function (
|
|
1039
|
-
switch (
|
|
986
|
+
var contentType, body_10, _a, _b, _c, _d, bodyText, _e, _f, body_11, body_12, _g, _h, _j, _k, body;
|
|
987
|
+
return __generator(this, function (_l) {
|
|
988
|
+
switch (_l.label) {
|
|
1040
989
|
case 0:
|
|
1041
990
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1042
|
-
if (!(
|
|
991
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1043
992
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1044
993
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1045
994
|
return [4 /*yield*/, response.body.text()];
|
|
1046
995
|
case 1:
|
|
1047
|
-
|
|
1048
|
-
"SyntheticsBrowserTest"
|
|
1049
|
-
|
|
1050
|
-
return [2 /*return*/, body_17];
|
|
996
|
+
body_10 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
997
|
+
"SyntheticsBrowserTest"]);
|
|
998
|
+
return [2 /*return*/, body_10];
|
|
1051
999
|
case 2:
|
|
1052
|
-
if (!(
|
|
1053
|
-
|
|
1054
|
-
|
|
1000
|
+
if (!(response.httpStatusCode == 400 ||
|
|
1001
|
+
response.httpStatusCode == 402 ||
|
|
1002
|
+
response.httpStatusCode == 403 ||
|
|
1003
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1004
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1055
1005
|
return [4 /*yield*/, response.body.text()];
|
|
1056
1006
|
case 3:
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
""
|
|
1060
|
-
|
|
1007
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1008
|
+
try {
|
|
1009
|
+
body_11 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1010
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_11);
|
|
1011
|
+
}
|
|
1012
|
+
catch (error) {
|
|
1013
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1014
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1015
|
+
}
|
|
1016
|
+
_l.label = 4;
|
|
1061
1017
|
case 4:
|
|
1062
|
-
if (!(
|
|
1063
|
-
|
|
1064
|
-
|
|
1018
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1019
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1020
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1065
1021
|
return [4 /*yield*/, response.body.text()];
|
|
1066
1022
|
case 5:
|
|
1067
|
-
|
|
1068
|
-
"APIErrorResponse",
|
|
1069
|
-
""]);
|
|
1070
|
-
throw new exception_1.ApiException(402, body_19);
|
|
1071
|
-
case 6:
|
|
1072
|
-
if (!(0, util_1.isCodeInRange)("403", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1073
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1074
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1075
|
-
return [4 /*yield*/, response.body.text()];
|
|
1076
|
-
case 7:
|
|
1077
|
-
body_20 = _p.apply(_o, [_r.apply(_q, [_0.sent(), contentType]),
|
|
1078
|
-
"APIErrorResponse",
|
|
1079
|
-
""]);
|
|
1080
|
-
throw new exception_1.ApiException(403, body_20);
|
|
1081
|
-
case 8:
|
|
1082
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 10];
|
|
1083
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1084
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1085
|
-
return [4 /*yield*/, response.body.text()];
|
|
1086
|
-
case 9:
|
|
1087
|
-
body_21 = _t.apply(_s, [_v.apply(_u, [_0.sent(), contentType]),
|
|
1088
|
-
"APIErrorResponse",
|
|
1089
|
-
""]);
|
|
1090
|
-
throw new exception_1.ApiException(429, body_21);
|
|
1091
|
-
case 10:
|
|
1092
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 12];
|
|
1093
|
-
_x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1094
|
-
_z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1095
|
-
return [4 /*yield*/, response.body.text()];
|
|
1096
|
-
case 11:
|
|
1097
|
-
body_22 = _x.apply(_w, [_z.apply(_y, [_0.sent(), contentType]),
|
|
1023
|
+
body_12 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1098
1024
|
"SyntheticsBrowserTest",
|
|
1099
1025
|
""]);
|
|
1100
|
-
return [2 /*return*/,
|
|
1101
|
-
case
|
|
1102
|
-
case
|
|
1103
|
-
body = (
|
|
1026
|
+
return [2 /*return*/, body_12];
|
|
1027
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1028
|
+
case 7:
|
|
1029
|
+
body = (_l.sent()) || "";
|
|
1104
1030
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1105
1031
|
}
|
|
1106
1032
|
});
|
|
@@ -1115,66 +1041,44 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1115
1041
|
*/
|
|
1116
1042
|
SyntheticsApiResponseProcessor.prototype.deleteGlobalVariable = function (response) {
|
|
1117
1043
|
return __awaiter(this, void 0, void 0, function () {
|
|
1118
|
-
var contentType,
|
|
1119
|
-
return __generator(this, function (
|
|
1120
|
-
switch (
|
|
1044
|
+
var contentType, bodyText, _a, _b, body_13, body_14, _c, _d, _e, _f, body;
|
|
1045
|
+
return __generator(this, function (_g) {
|
|
1046
|
+
switch (_g.label) {
|
|
1121
1047
|
case 0:
|
|
1122
1048
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1123
|
-
if (
|
|
1049
|
+
if (response.httpStatusCode == 200) {
|
|
1124
1050
|
return [2 /*return*/];
|
|
1125
1051
|
}
|
|
1126
|
-
if (!(
|
|
1127
|
-
|
|
1128
|
-
|
|
1052
|
+
if (!(response.httpStatusCode == 400 ||
|
|
1053
|
+
response.httpStatusCode == 403 ||
|
|
1054
|
+
response.httpStatusCode == 404 ||
|
|
1055
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 2];
|
|
1056
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1129
1057
|
return [4 /*yield*/, response.body.text()];
|
|
1130
1058
|
case 1:
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
""
|
|
1134
|
-
|
|
1059
|
+
bodyText = _b.apply(_a, [_g.sent(), contentType]);
|
|
1060
|
+
try {
|
|
1061
|
+
body_13 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1062
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_13);
|
|
1063
|
+
}
|
|
1064
|
+
catch (error) {
|
|
1065
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1066
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1067
|
+
}
|
|
1068
|
+
_g.label = 2;
|
|
1135
1069
|
case 2:
|
|
1136
|
-
if (!(
|
|
1137
|
-
|
|
1138
|
-
|
|
1070
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 4];
|
|
1071
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1072
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1139
1073
|
return [4 /*yield*/, response.body.text()];
|
|
1140
1074
|
case 3:
|
|
1141
|
-
|
|
1142
|
-
"APIErrorResponse",
|
|
1143
|
-
""]);
|
|
1144
|
-
throw new exception_1.ApiException(403, body_24);
|
|
1145
|
-
case 4:
|
|
1146
|
-
if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3 /*break*/, 6];
|
|
1147
|
-
_k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1148
|
-
_m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1149
|
-
return [4 /*yield*/, response.body.text()];
|
|
1150
|
-
case 5:
|
|
1151
|
-
body_25 = _k.apply(_j, [_m.apply(_l, [_w.sent(), contentType]),
|
|
1152
|
-
"APIErrorResponse",
|
|
1153
|
-
""]);
|
|
1154
|
-
throw new exception_1.ApiException(404, body_25);
|
|
1155
|
-
case 6:
|
|
1156
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1157
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1158
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1159
|
-
return [4 /*yield*/, response.body.text()];
|
|
1160
|
-
case 7:
|
|
1161
|
-
body_26 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
1162
|
-
"APIErrorResponse",
|
|
1163
|
-
""]);
|
|
1164
|
-
throw new exception_1.ApiException(429, body_26);
|
|
1165
|
-
case 8:
|
|
1166
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
1167
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1168
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1169
|
-
return [4 /*yield*/, response.body.text()];
|
|
1170
|
-
case 9:
|
|
1171
|
-
body_27 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
1075
|
+
body_14 = _d.apply(_c, [_f.apply(_e, [_g.sent(), contentType]),
|
|
1172
1076
|
"void",
|
|
1173
1077
|
""]);
|
|
1174
|
-
return [2 /*return*/,
|
|
1175
|
-
case
|
|
1176
|
-
case
|
|
1177
|
-
body = (
|
|
1078
|
+
return [2 /*return*/, body_14];
|
|
1079
|
+
case 4: return [4 /*yield*/, response.body.text()];
|
|
1080
|
+
case 5:
|
|
1081
|
+
body = (_g.sent()) || "";
|
|
1178
1082
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1179
1083
|
}
|
|
1180
1084
|
});
|
|
@@ -1189,46 +1093,41 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1189
1093
|
*/
|
|
1190
1094
|
SyntheticsApiResponseProcessor.prototype.deletePrivateLocation = function (response) {
|
|
1191
1095
|
return __awaiter(this, void 0, void 0, function () {
|
|
1192
|
-
var contentType,
|
|
1193
|
-
return __generator(this, function (
|
|
1194
|
-
switch (
|
|
1096
|
+
var contentType, bodyText, _a, _b, body_15, body_16, _c, _d, _e, _f, body;
|
|
1097
|
+
return __generator(this, function (_g) {
|
|
1098
|
+
switch (_g.label) {
|
|
1195
1099
|
case 0:
|
|
1196
1100
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1197
|
-
if (
|
|
1101
|
+
if (response.httpStatusCode == 204) {
|
|
1198
1102
|
return [2 /*return*/];
|
|
1199
1103
|
}
|
|
1200
|
-
if (!(
|
|
1201
|
-
_b = (_a = ObjectSerializer_1.ObjectSerializer).
|
|
1202
|
-
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1104
|
+
if (!(response.httpStatusCode == 404 || response.httpStatusCode == 429)) return [3 /*break*/, 2];
|
|
1105
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1203
1106
|
return [4 /*yield*/, response.body.text()];
|
|
1204
1107
|
case 1:
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
""
|
|
1208
|
-
|
|
1108
|
+
bodyText = _b.apply(_a, [_g.sent(), contentType]);
|
|
1109
|
+
try {
|
|
1110
|
+
body_15 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1111
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_15);
|
|
1112
|
+
}
|
|
1113
|
+
catch (error) {
|
|
1114
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1115
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1116
|
+
}
|
|
1117
|
+
_g.label = 2;
|
|
1209
1118
|
case 2:
|
|
1210
|
-
if (!(
|
|
1211
|
-
|
|
1212
|
-
|
|
1119
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 4];
|
|
1120
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1121
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1213
1122
|
return [4 /*yield*/, response.body.text()];
|
|
1214
1123
|
case 3:
|
|
1215
|
-
|
|
1216
|
-
"APIErrorResponse",
|
|
1217
|
-
""]);
|
|
1218
|
-
throw new exception_1.ApiException(429, body_29);
|
|
1219
|
-
case 4:
|
|
1220
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1221
|
-
_k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1222
|
-
_m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1223
|
-
return [4 /*yield*/, response.body.text()];
|
|
1224
|
-
case 5:
|
|
1225
|
-
body_30 = _k.apply(_j, [_m.apply(_l, [_o.sent(), contentType]),
|
|
1124
|
+
body_16 = _d.apply(_c, [_f.apply(_e, [_g.sent(), contentType]),
|
|
1226
1125
|
"void",
|
|
1227
1126
|
""]);
|
|
1228
|
-
return [2 /*return*/,
|
|
1229
|
-
case
|
|
1230
|
-
case
|
|
1231
|
-
body = (
|
|
1127
|
+
return [2 /*return*/, body_16];
|
|
1128
|
+
case 4: return [4 /*yield*/, response.body.text()];
|
|
1129
|
+
case 5:
|
|
1130
|
+
body = (_g.sent()) || "";
|
|
1232
1131
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1233
1132
|
}
|
|
1234
1133
|
});
|
|
@@ -1243,73 +1142,50 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1243
1142
|
*/
|
|
1244
1143
|
SyntheticsApiResponseProcessor.prototype.deleteTests = function (response) {
|
|
1245
1144
|
return __awaiter(this, void 0, void 0, function () {
|
|
1246
|
-
var contentType,
|
|
1247
|
-
return __generator(this, function (
|
|
1248
|
-
switch (
|
|
1145
|
+
var contentType, body_17, _a, _b, _c, _d, bodyText, _e, _f, body_18, body_19, _g, _h, _j, _k, body;
|
|
1146
|
+
return __generator(this, function (_l) {
|
|
1147
|
+
switch (_l.label) {
|
|
1249
1148
|
case 0:
|
|
1250
1149
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1251
|
-
if (!(
|
|
1150
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1252
1151
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1253
1152
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1254
1153
|
return [4 /*yield*/, response.body.text()];
|
|
1255
1154
|
case 1:
|
|
1256
|
-
|
|
1257
|
-
"SyntheticsDeleteTestsResponse"
|
|
1258
|
-
|
|
1259
|
-
return [2 /*return*/, body_31];
|
|
1155
|
+
body_17 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1156
|
+
"SyntheticsDeleteTestsResponse"]);
|
|
1157
|
+
return [2 /*return*/, body_17];
|
|
1260
1158
|
case 2:
|
|
1261
|
-
if (!(
|
|
1262
|
-
|
|
1263
|
-
|
|
1159
|
+
if (!(response.httpStatusCode == 400 ||
|
|
1160
|
+
response.httpStatusCode == 403 ||
|
|
1161
|
+
response.httpStatusCode == 404 ||
|
|
1162
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1163
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1264
1164
|
return [4 /*yield*/, response.body.text()];
|
|
1265
1165
|
case 3:
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
""
|
|
1269
|
-
|
|
1166
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1167
|
+
try {
|
|
1168
|
+
body_18 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1169
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_18);
|
|
1170
|
+
}
|
|
1171
|
+
catch (error) {
|
|
1172
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1173
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1174
|
+
}
|
|
1175
|
+
_l.label = 4;
|
|
1270
1176
|
case 4:
|
|
1271
|
-
if (!(
|
|
1272
|
-
|
|
1273
|
-
|
|
1177
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1178
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1179
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1274
1180
|
return [4 /*yield*/, response.body.text()];
|
|
1275
1181
|
case 5:
|
|
1276
|
-
|
|
1277
|
-
"APIErrorResponse",
|
|
1278
|
-
""]);
|
|
1279
|
-
throw new exception_1.ApiException(403, body_33);
|
|
1280
|
-
case 6:
|
|
1281
|
-
if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1282
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1283
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1284
|
-
return [4 /*yield*/, response.body.text()];
|
|
1285
|
-
case 7:
|
|
1286
|
-
body_34 = _p.apply(_o, [_r.apply(_q, [_0.sent(), contentType]),
|
|
1287
|
-
"APIErrorResponse",
|
|
1288
|
-
""]);
|
|
1289
|
-
throw new exception_1.ApiException(404, body_34);
|
|
1290
|
-
case 8:
|
|
1291
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 10];
|
|
1292
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1293
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1294
|
-
return [4 /*yield*/, response.body.text()];
|
|
1295
|
-
case 9:
|
|
1296
|
-
body_35 = _t.apply(_s, [_v.apply(_u, [_0.sent(), contentType]),
|
|
1297
|
-
"APIErrorResponse",
|
|
1298
|
-
""]);
|
|
1299
|
-
throw new exception_1.ApiException(429, body_35);
|
|
1300
|
-
case 10:
|
|
1301
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 12];
|
|
1302
|
-
_x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1303
|
-
_z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1304
|
-
return [4 /*yield*/, response.body.text()];
|
|
1305
|
-
case 11:
|
|
1306
|
-
body_36 = _x.apply(_w, [_z.apply(_y, [_0.sent(), contentType]),
|
|
1182
|
+
body_19 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1307
1183
|
"SyntheticsDeleteTestsResponse",
|
|
1308
1184
|
""]);
|
|
1309
|
-
return [2 /*return*/,
|
|
1310
|
-
case
|
|
1311
|
-
case
|
|
1312
|
-
body = (
|
|
1185
|
+
return [2 /*return*/, body_19];
|
|
1186
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1187
|
+
case 7:
|
|
1188
|
+
body = (_l.sent()) || "";
|
|
1313
1189
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1314
1190
|
}
|
|
1315
1191
|
});
|
|
@@ -1324,63 +1200,49 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1324
1200
|
*/
|
|
1325
1201
|
SyntheticsApiResponseProcessor.prototype.editGlobalVariable = function (response) {
|
|
1326
1202
|
return __awaiter(this, void 0, void 0, function () {
|
|
1327
|
-
var contentType,
|
|
1328
|
-
return __generator(this, function (
|
|
1329
|
-
switch (
|
|
1203
|
+
var contentType, body_20, _a, _b, _c, _d, bodyText, _e, _f, body_21, body_22, _g, _h, _j, _k, body;
|
|
1204
|
+
return __generator(this, function (_l) {
|
|
1205
|
+
switch (_l.label) {
|
|
1330
1206
|
case 0:
|
|
1331
1207
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1332
|
-
if (!(
|
|
1208
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1333
1209
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1334
1210
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1335
1211
|
return [4 /*yield*/, response.body.text()];
|
|
1336
1212
|
case 1:
|
|
1337
|
-
|
|
1338
|
-
"SyntheticsGlobalVariable"
|
|
1339
|
-
|
|
1340
|
-
return [2 /*return*/, body_37];
|
|
1213
|
+
body_20 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1214
|
+
"SyntheticsGlobalVariable"]);
|
|
1215
|
+
return [2 /*return*/, body_20];
|
|
1341
1216
|
case 2:
|
|
1342
|
-
if (!(
|
|
1343
|
-
|
|
1344
|
-
|
|
1217
|
+
if (!(response.httpStatusCode == 400 ||
|
|
1218
|
+
response.httpStatusCode == 403 ||
|
|
1219
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1220
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1345
1221
|
return [4 /*yield*/, response.body.text()];
|
|
1346
1222
|
case 3:
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
""
|
|
1350
|
-
|
|
1223
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1224
|
+
try {
|
|
1225
|
+
body_21 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1226
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_21);
|
|
1227
|
+
}
|
|
1228
|
+
catch (error) {
|
|
1229
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1230
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1231
|
+
}
|
|
1232
|
+
_l.label = 4;
|
|
1351
1233
|
case 4:
|
|
1352
|
-
if (!(
|
|
1353
|
-
|
|
1354
|
-
|
|
1234
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1235
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1236
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1355
1237
|
return [4 /*yield*/, response.body.text()];
|
|
1356
1238
|
case 5:
|
|
1357
|
-
|
|
1358
|
-
"APIErrorResponse",
|
|
1359
|
-
""]);
|
|
1360
|
-
throw new exception_1.ApiException(403, body_39);
|
|
1361
|
-
case 6:
|
|
1362
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1363
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1364
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1365
|
-
return [4 /*yield*/, response.body.text()];
|
|
1366
|
-
case 7:
|
|
1367
|
-
body_40 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
1368
|
-
"APIErrorResponse",
|
|
1369
|
-
""]);
|
|
1370
|
-
throw new exception_1.ApiException(429, body_40);
|
|
1371
|
-
case 8:
|
|
1372
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
1373
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1374
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1375
|
-
return [4 /*yield*/, response.body.text()];
|
|
1376
|
-
case 9:
|
|
1377
|
-
body_41 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
1239
|
+
body_22 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1378
1240
|
"SyntheticsGlobalVariable",
|
|
1379
1241
|
""]);
|
|
1380
|
-
return [2 /*return*/,
|
|
1381
|
-
case
|
|
1382
|
-
case
|
|
1383
|
-
body = (
|
|
1242
|
+
return [2 /*return*/, body_22];
|
|
1243
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1244
|
+
case 7:
|
|
1245
|
+
body = (_l.sent()) || "";
|
|
1384
1246
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1385
1247
|
}
|
|
1386
1248
|
});
|
|
@@ -1395,63 +1257,49 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1395
1257
|
*/
|
|
1396
1258
|
SyntheticsApiResponseProcessor.prototype.getAPITest = function (response) {
|
|
1397
1259
|
return __awaiter(this, void 0, void 0, function () {
|
|
1398
|
-
var contentType,
|
|
1399
|
-
return __generator(this, function (
|
|
1400
|
-
switch (
|
|
1260
|
+
var contentType, body_23, _a, _b, _c, _d, bodyText, _e, _f, body_24, body_25, _g, _h, _j, _k, body;
|
|
1261
|
+
return __generator(this, function (_l) {
|
|
1262
|
+
switch (_l.label) {
|
|
1401
1263
|
case 0:
|
|
1402
1264
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1403
|
-
if (!(
|
|
1265
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1404
1266
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1405
1267
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1406
1268
|
return [4 /*yield*/, response.body.text()];
|
|
1407
1269
|
case 1:
|
|
1408
|
-
|
|
1409
|
-
"SyntheticsAPITest"
|
|
1410
|
-
|
|
1411
|
-
return [2 /*return*/, body_42];
|
|
1270
|
+
body_23 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1271
|
+
"SyntheticsAPITest"]);
|
|
1272
|
+
return [2 /*return*/, body_23];
|
|
1412
1273
|
case 2:
|
|
1413
|
-
if (!(
|
|
1414
|
-
|
|
1415
|
-
|
|
1274
|
+
if (!(response.httpStatusCode == 403 ||
|
|
1275
|
+
response.httpStatusCode == 404 ||
|
|
1276
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1277
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1416
1278
|
return [4 /*yield*/, response.body.text()];
|
|
1417
1279
|
case 3:
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
""
|
|
1421
|
-
|
|
1280
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1281
|
+
try {
|
|
1282
|
+
body_24 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1283
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_24);
|
|
1284
|
+
}
|
|
1285
|
+
catch (error) {
|
|
1286
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1287
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1288
|
+
}
|
|
1289
|
+
_l.label = 4;
|
|
1422
1290
|
case 4:
|
|
1423
|
-
if (!(
|
|
1424
|
-
|
|
1425
|
-
|
|
1291
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1292
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1293
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1426
1294
|
return [4 /*yield*/, response.body.text()];
|
|
1427
1295
|
case 5:
|
|
1428
|
-
|
|
1429
|
-
"APIErrorResponse",
|
|
1430
|
-
""]);
|
|
1431
|
-
throw new exception_1.ApiException(404, body_44);
|
|
1432
|
-
case 6:
|
|
1433
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1434
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1435
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1436
|
-
return [4 /*yield*/, response.body.text()];
|
|
1437
|
-
case 7:
|
|
1438
|
-
body_45 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
1439
|
-
"APIErrorResponse",
|
|
1440
|
-
""]);
|
|
1441
|
-
throw new exception_1.ApiException(429, body_45);
|
|
1442
|
-
case 8:
|
|
1443
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
1444
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1445
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1446
|
-
return [4 /*yield*/, response.body.text()];
|
|
1447
|
-
case 9:
|
|
1448
|
-
body_46 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
1296
|
+
body_25 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1449
1297
|
"SyntheticsAPITest",
|
|
1450
1298
|
""]);
|
|
1451
|
-
return [2 /*return*/,
|
|
1452
|
-
case
|
|
1453
|
-
case
|
|
1454
|
-
body = (
|
|
1299
|
+
return [2 /*return*/, body_25];
|
|
1300
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1301
|
+
case 7:
|
|
1302
|
+
body = (_l.sent()) || "";
|
|
1455
1303
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1456
1304
|
}
|
|
1457
1305
|
});
|
|
@@ -1466,63 +1314,49 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1466
1314
|
*/
|
|
1467
1315
|
SyntheticsApiResponseProcessor.prototype.getAPITestLatestResults = function (response) {
|
|
1468
1316
|
return __awaiter(this, void 0, void 0, function () {
|
|
1469
|
-
var contentType,
|
|
1470
|
-
return __generator(this, function (
|
|
1471
|
-
switch (
|
|
1317
|
+
var contentType, body_26, _a, _b, _c, _d, bodyText, _e, _f, body_27, body_28, _g, _h, _j, _k, body;
|
|
1318
|
+
return __generator(this, function (_l) {
|
|
1319
|
+
switch (_l.label) {
|
|
1472
1320
|
case 0:
|
|
1473
1321
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1474
|
-
if (!(
|
|
1322
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1475
1323
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1476
1324
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1477
1325
|
return [4 /*yield*/, response.body.text()];
|
|
1478
1326
|
case 1:
|
|
1479
|
-
|
|
1480
|
-
"SyntheticsGetAPITestLatestResultsResponse"
|
|
1481
|
-
|
|
1482
|
-
return [2 /*return*/, body_47];
|
|
1327
|
+
body_26 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1328
|
+
"SyntheticsGetAPITestLatestResultsResponse"]);
|
|
1329
|
+
return [2 /*return*/, body_26];
|
|
1483
1330
|
case 2:
|
|
1484
|
-
if (!(
|
|
1485
|
-
|
|
1486
|
-
|
|
1331
|
+
if (!(response.httpStatusCode == 403 ||
|
|
1332
|
+
response.httpStatusCode == 404 ||
|
|
1333
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1334
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1487
1335
|
return [4 /*yield*/, response.body.text()];
|
|
1488
1336
|
case 3:
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
""
|
|
1492
|
-
|
|
1337
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1338
|
+
try {
|
|
1339
|
+
body_27 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1340
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_27);
|
|
1341
|
+
}
|
|
1342
|
+
catch (error) {
|
|
1343
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1344
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1345
|
+
}
|
|
1346
|
+
_l.label = 4;
|
|
1493
1347
|
case 4:
|
|
1494
|
-
if (!(
|
|
1495
|
-
|
|
1496
|
-
|
|
1348
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1349
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1350
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1497
1351
|
return [4 /*yield*/, response.body.text()];
|
|
1498
1352
|
case 5:
|
|
1499
|
-
|
|
1500
|
-
"APIErrorResponse",
|
|
1501
|
-
""]);
|
|
1502
|
-
throw new exception_1.ApiException(404, body_49);
|
|
1503
|
-
case 6:
|
|
1504
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1505
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1506
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1507
|
-
return [4 /*yield*/, response.body.text()];
|
|
1508
|
-
case 7:
|
|
1509
|
-
body_50 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
1510
|
-
"APIErrorResponse",
|
|
1511
|
-
""]);
|
|
1512
|
-
throw new exception_1.ApiException(429, body_50);
|
|
1513
|
-
case 8:
|
|
1514
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
1515
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1516
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1517
|
-
return [4 /*yield*/, response.body.text()];
|
|
1518
|
-
case 9:
|
|
1519
|
-
body_51 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
1353
|
+
body_28 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1520
1354
|
"SyntheticsGetAPITestLatestResultsResponse",
|
|
1521
1355
|
""]);
|
|
1522
|
-
return [2 /*return*/,
|
|
1523
|
-
case
|
|
1524
|
-
case
|
|
1525
|
-
body = (
|
|
1356
|
+
return [2 /*return*/, body_28];
|
|
1357
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1358
|
+
case 7:
|
|
1359
|
+
body = (_l.sent()) || "";
|
|
1526
1360
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1527
1361
|
}
|
|
1528
1362
|
});
|
|
@@ -1537,63 +1371,49 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1537
1371
|
*/
|
|
1538
1372
|
SyntheticsApiResponseProcessor.prototype.getAPITestResult = function (response) {
|
|
1539
1373
|
return __awaiter(this, void 0, void 0, function () {
|
|
1540
|
-
var contentType,
|
|
1541
|
-
return __generator(this, function (
|
|
1542
|
-
switch (
|
|
1374
|
+
var contentType, body_29, _a, _b, _c, _d, bodyText, _e, _f, body_30, body_31, _g, _h, _j, _k, body;
|
|
1375
|
+
return __generator(this, function (_l) {
|
|
1376
|
+
switch (_l.label) {
|
|
1543
1377
|
case 0:
|
|
1544
1378
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1545
|
-
if (!(
|
|
1379
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1546
1380
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1547
1381
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1548
1382
|
return [4 /*yield*/, response.body.text()];
|
|
1549
1383
|
case 1:
|
|
1550
|
-
|
|
1551
|
-
"SyntheticsAPITestResultFull"
|
|
1552
|
-
|
|
1553
|
-
return [2 /*return*/, body_52];
|
|
1384
|
+
body_29 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1385
|
+
"SyntheticsAPITestResultFull"]);
|
|
1386
|
+
return [2 /*return*/, body_29];
|
|
1554
1387
|
case 2:
|
|
1555
|
-
if (!(
|
|
1556
|
-
|
|
1557
|
-
|
|
1388
|
+
if (!(response.httpStatusCode == 403 ||
|
|
1389
|
+
response.httpStatusCode == 404 ||
|
|
1390
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1391
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1558
1392
|
return [4 /*yield*/, response.body.text()];
|
|
1559
1393
|
case 3:
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
""
|
|
1563
|
-
|
|
1394
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1395
|
+
try {
|
|
1396
|
+
body_30 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1397
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_30);
|
|
1398
|
+
}
|
|
1399
|
+
catch (error) {
|
|
1400
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1401
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1402
|
+
}
|
|
1403
|
+
_l.label = 4;
|
|
1564
1404
|
case 4:
|
|
1565
|
-
if (!(
|
|
1566
|
-
|
|
1567
|
-
|
|
1405
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1406
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1407
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1568
1408
|
return [4 /*yield*/, response.body.text()];
|
|
1569
1409
|
case 5:
|
|
1570
|
-
|
|
1571
|
-
"APIErrorResponse",
|
|
1572
|
-
""]);
|
|
1573
|
-
throw new exception_1.ApiException(404, body_54);
|
|
1574
|
-
case 6:
|
|
1575
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1576
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1577
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1578
|
-
return [4 /*yield*/, response.body.text()];
|
|
1579
|
-
case 7:
|
|
1580
|
-
body_55 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
1581
|
-
"APIErrorResponse",
|
|
1582
|
-
""]);
|
|
1583
|
-
throw new exception_1.ApiException(429, body_55);
|
|
1584
|
-
case 8:
|
|
1585
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
1586
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1587
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1588
|
-
return [4 /*yield*/, response.body.text()];
|
|
1589
|
-
case 9:
|
|
1590
|
-
body_56 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
1410
|
+
body_31 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1591
1411
|
"SyntheticsAPITestResultFull",
|
|
1592
1412
|
""]);
|
|
1593
|
-
return [2 /*return*/,
|
|
1594
|
-
case
|
|
1595
|
-
case
|
|
1596
|
-
body = (
|
|
1413
|
+
return [2 /*return*/, body_31];
|
|
1414
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1415
|
+
case 7:
|
|
1416
|
+
body = (_l.sent()) || "";
|
|
1597
1417
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1598
1418
|
}
|
|
1599
1419
|
});
|
|
@@ -1608,63 +1428,49 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1608
1428
|
*/
|
|
1609
1429
|
SyntheticsApiResponseProcessor.prototype.getBrowserTest = function (response) {
|
|
1610
1430
|
return __awaiter(this, void 0, void 0, function () {
|
|
1611
|
-
var contentType,
|
|
1612
|
-
return __generator(this, function (
|
|
1613
|
-
switch (
|
|
1431
|
+
var contentType, body_32, _a, _b, _c, _d, bodyText, _e, _f, body_33, body_34, _g, _h, _j, _k, body;
|
|
1432
|
+
return __generator(this, function (_l) {
|
|
1433
|
+
switch (_l.label) {
|
|
1614
1434
|
case 0:
|
|
1615
1435
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1616
|
-
if (!(
|
|
1436
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1617
1437
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1618
1438
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1619
1439
|
return [4 /*yield*/, response.body.text()];
|
|
1620
1440
|
case 1:
|
|
1621
|
-
|
|
1622
|
-
"SyntheticsBrowserTest"
|
|
1623
|
-
|
|
1624
|
-
return [2 /*return*/, body_57];
|
|
1441
|
+
body_32 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1442
|
+
"SyntheticsBrowserTest"]);
|
|
1443
|
+
return [2 /*return*/, body_32];
|
|
1625
1444
|
case 2:
|
|
1626
|
-
if (!(
|
|
1627
|
-
|
|
1628
|
-
|
|
1445
|
+
if (!(response.httpStatusCode == 403 ||
|
|
1446
|
+
response.httpStatusCode == 404 ||
|
|
1447
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1448
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1629
1449
|
return [4 /*yield*/, response.body.text()];
|
|
1630
1450
|
case 3:
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
""
|
|
1634
|
-
|
|
1451
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1452
|
+
try {
|
|
1453
|
+
body_33 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1454
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_33);
|
|
1455
|
+
}
|
|
1456
|
+
catch (error) {
|
|
1457
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1458
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1459
|
+
}
|
|
1460
|
+
_l.label = 4;
|
|
1635
1461
|
case 4:
|
|
1636
|
-
if (!(
|
|
1637
|
-
|
|
1638
|
-
|
|
1462
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1463
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1464
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1639
1465
|
return [4 /*yield*/, response.body.text()];
|
|
1640
1466
|
case 5:
|
|
1641
|
-
|
|
1642
|
-
"APIErrorResponse",
|
|
1643
|
-
""]);
|
|
1644
|
-
throw new exception_1.ApiException(404, body_59);
|
|
1645
|
-
case 6:
|
|
1646
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1647
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1648
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1649
|
-
return [4 /*yield*/, response.body.text()];
|
|
1650
|
-
case 7:
|
|
1651
|
-
body_60 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
1652
|
-
"APIErrorResponse",
|
|
1653
|
-
""]);
|
|
1654
|
-
throw new exception_1.ApiException(429, body_60);
|
|
1655
|
-
case 8:
|
|
1656
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
1657
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1658
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1659
|
-
return [4 /*yield*/, response.body.text()];
|
|
1660
|
-
case 9:
|
|
1661
|
-
body_61 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
1467
|
+
body_34 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1662
1468
|
"SyntheticsBrowserTest",
|
|
1663
1469
|
""]);
|
|
1664
|
-
return [2 /*return*/,
|
|
1665
|
-
case
|
|
1666
|
-
case
|
|
1667
|
-
body = (
|
|
1470
|
+
return [2 /*return*/, body_34];
|
|
1471
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1472
|
+
case 7:
|
|
1473
|
+
body = (_l.sent()) || "";
|
|
1668
1474
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1669
1475
|
}
|
|
1670
1476
|
});
|
|
@@ -1679,63 +1485,49 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1679
1485
|
*/
|
|
1680
1486
|
SyntheticsApiResponseProcessor.prototype.getBrowserTestLatestResults = function (response) {
|
|
1681
1487
|
return __awaiter(this, void 0, void 0, function () {
|
|
1682
|
-
var contentType,
|
|
1683
|
-
return __generator(this, function (
|
|
1684
|
-
switch (
|
|
1488
|
+
var contentType, body_35, _a, _b, _c, _d, bodyText, _e, _f, body_36, body_37, _g, _h, _j, _k, body;
|
|
1489
|
+
return __generator(this, function (_l) {
|
|
1490
|
+
switch (_l.label) {
|
|
1685
1491
|
case 0:
|
|
1686
1492
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1687
|
-
if (!(
|
|
1493
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1688
1494
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1689
1495
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1690
1496
|
return [4 /*yield*/, response.body.text()];
|
|
1691
1497
|
case 1:
|
|
1692
|
-
|
|
1693
|
-
"SyntheticsGetBrowserTestLatestResultsResponse"
|
|
1694
|
-
|
|
1695
|
-
return [2 /*return*/, body_62];
|
|
1498
|
+
body_35 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1499
|
+
"SyntheticsGetBrowserTestLatestResultsResponse"]);
|
|
1500
|
+
return [2 /*return*/, body_35];
|
|
1696
1501
|
case 2:
|
|
1697
|
-
if (!(
|
|
1698
|
-
|
|
1699
|
-
|
|
1502
|
+
if (!(response.httpStatusCode == 403 ||
|
|
1503
|
+
response.httpStatusCode == 404 ||
|
|
1504
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1505
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1700
1506
|
return [4 /*yield*/, response.body.text()];
|
|
1701
1507
|
case 3:
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
""
|
|
1705
|
-
|
|
1508
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1509
|
+
try {
|
|
1510
|
+
body_36 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1511
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_36);
|
|
1512
|
+
}
|
|
1513
|
+
catch (error) {
|
|
1514
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1515
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1516
|
+
}
|
|
1517
|
+
_l.label = 4;
|
|
1706
1518
|
case 4:
|
|
1707
|
-
if (!(
|
|
1708
|
-
|
|
1709
|
-
|
|
1519
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1520
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1521
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1710
1522
|
return [4 /*yield*/, response.body.text()];
|
|
1711
1523
|
case 5:
|
|
1712
|
-
|
|
1713
|
-
"APIErrorResponse",
|
|
1714
|
-
""]);
|
|
1715
|
-
throw new exception_1.ApiException(404, body_64);
|
|
1716
|
-
case 6:
|
|
1717
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1718
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1719
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1720
|
-
return [4 /*yield*/, response.body.text()];
|
|
1721
|
-
case 7:
|
|
1722
|
-
body_65 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
1723
|
-
"APIErrorResponse",
|
|
1724
|
-
""]);
|
|
1725
|
-
throw new exception_1.ApiException(429, body_65);
|
|
1726
|
-
case 8:
|
|
1727
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
1728
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1729
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1730
|
-
return [4 /*yield*/, response.body.text()];
|
|
1731
|
-
case 9:
|
|
1732
|
-
body_66 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
1524
|
+
body_37 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1733
1525
|
"SyntheticsGetBrowserTestLatestResultsResponse",
|
|
1734
1526
|
""]);
|
|
1735
|
-
return [2 /*return*/,
|
|
1736
|
-
case
|
|
1737
|
-
case
|
|
1738
|
-
body = (
|
|
1527
|
+
return [2 /*return*/, body_37];
|
|
1528
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1529
|
+
case 7:
|
|
1530
|
+
body = (_l.sent()) || "";
|
|
1739
1531
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1740
1532
|
}
|
|
1741
1533
|
});
|
|
@@ -1750,63 +1542,49 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1750
1542
|
*/
|
|
1751
1543
|
SyntheticsApiResponseProcessor.prototype.getBrowserTestResult = function (response) {
|
|
1752
1544
|
return __awaiter(this, void 0, void 0, function () {
|
|
1753
|
-
var contentType,
|
|
1754
|
-
return __generator(this, function (
|
|
1755
|
-
switch (
|
|
1545
|
+
var contentType, body_38, _a, _b, _c, _d, bodyText, _e, _f, body_39, body_40, _g, _h, _j, _k, body;
|
|
1546
|
+
return __generator(this, function (_l) {
|
|
1547
|
+
switch (_l.label) {
|
|
1756
1548
|
case 0:
|
|
1757
1549
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1758
|
-
if (!(
|
|
1550
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1759
1551
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1760
1552
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1761
1553
|
return [4 /*yield*/, response.body.text()];
|
|
1762
1554
|
case 1:
|
|
1763
|
-
|
|
1764
|
-
"SyntheticsBrowserTestResultFull"
|
|
1765
|
-
|
|
1766
|
-
return [2 /*return*/, body_67];
|
|
1555
|
+
body_38 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1556
|
+
"SyntheticsBrowserTestResultFull"]);
|
|
1557
|
+
return [2 /*return*/, body_38];
|
|
1767
1558
|
case 2:
|
|
1768
|
-
if (!(
|
|
1769
|
-
|
|
1770
|
-
|
|
1559
|
+
if (!(response.httpStatusCode == 403 ||
|
|
1560
|
+
response.httpStatusCode == 404 ||
|
|
1561
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1562
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1771
1563
|
return [4 /*yield*/, response.body.text()];
|
|
1772
1564
|
case 3:
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
""
|
|
1776
|
-
|
|
1565
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1566
|
+
try {
|
|
1567
|
+
body_39 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1568
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_39);
|
|
1569
|
+
}
|
|
1570
|
+
catch (error) {
|
|
1571
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1572
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1573
|
+
}
|
|
1574
|
+
_l.label = 4;
|
|
1777
1575
|
case 4:
|
|
1778
|
-
if (!(
|
|
1779
|
-
|
|
1780
|
-
|
|
1576
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1577
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1578
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1781
1579
|
return [4 /*yield*/, response.body.text()];
|
|
1782
1580
|
case 5:
|
|
1783
|
-
|
|
1784
|
-
"APIErrorResponse",
|
|
1785
|
-
""]);
|
|
1786
|
-
throw new exception_1.ApiException(404, body_69);
|
|
1787
|
-
case 6:
|
|
1788
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1789
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1790
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1791
|
-
return [4 /*yield*/, response.body.text()];
|
|
1792
|
-
case 7:
|
|
1793
|
-
body_70 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
1794
|
-
"APIErrorResponse",
|
|
1795
|
-
""]);
|
|
1796
|
-
throw new exception_1.ApiException(429, body_70);
|
|
1797
|
-
case 8:
|
|
1798
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
1799
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1800
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1801
|
-
return [4 /*yield*/, response.body.text()];
|
|
1802
|
-
case 9:
|
|
1803
|
-
body_71 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
1581
|
+
body_40 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1804
1582
|
"SyntheticsBrowserTestResultFull",
|
|
1805
1583
|
""]);
|
|
1806
|
-
return [2 /*return*/,
|
|
1807
|
-
case
|
|
1808
|
-
case
|
|
1809
|
-
body = (
|
|
1584
|
+
return [2 /*return*/, body_40];
|
|
1585
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1586
|
+
case 7:
|
|
1587
|
+
body = (_l.sent()) || "";
|
|
1810
1588
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1811
1589
|
}
|
|
1812
1590
|
});
|
|
@@ -1821,63 +1599,49 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1821
1599
|
*/
|
|
1822
1600
|
SyntheticsApiResponseProcessor.prototype.getGlobalVariable = function (response) {
|
|
1823
1601
|
return __awaiter(this, void 0, void 0, function () {
|
|
1824
|
-
var contentType,
|
|
1825
|
-
return __generator(this, function (
|
|
1826
|
-
switch (
|
|
1602
|
+
var contentType, body_41, _a, _b, _c, _d, bodyText, _e, _f, body_42, body_43, _g, _h, _j, _k, body;
|
|
1603
|
+
return __generator(this, function (_l) {
|
|
1604
|
+
switch (_l.label) {
|
|
1827
1605
|
case 0:
|
|
1828
1606
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1829
|
-
if (!(
|
|
1607
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1830
1608
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1831
1609
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1832
1610
|
return [4 /*yield*/, response.body.text()];
|
|
1833
1611
|
case 1:
|
|
1834
|
-
|
|
1835
|
-
"SyntheticsGlobalVariable"
|
|
1836
|
-
|
|
1837
|
-
return [2 /*return*/, body_72];
|
|
1612
|
+
body_41 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1613
|
+
"SyntheticsGlobalVariable"]);
|
|
1614
|
+
return [2 /*return*/, body_41];
|
|
1838
1615
|
case 2:
|
|
1839
|
-
if (!(
|
|
1840
|
-
|
|
1841
|
-
|
|
1616
|
+
if (!(response.httpStatusCode == 403 ||
|
|
1617
|
+
response.httpStatusCode == 404 ||
|
|
1618
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1619
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1842
1620
|
return [4 /*yield*/, response.body.text()];
|
|
1843
1621
|
case 3:
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
""
|
|
1847
|
-
|
|
1622
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1623
|
+
try {
|
|
1624
|
+
body_42 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1625
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_42);
|
|
1626
|
+
}
|
|
1627
|
+
catch (error) {
|
|
1628
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1629
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1630
|
+
}
|
|
1631
|
+
_l.label = 4;
|
|
1848
1632
|
case 4:
|
|
1849
|
-
if (!(
|
|
1850
|
-
|
|
1851
|
-
|
|
1633
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1634
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1635
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1852
1636
|
return [4 /*yield*/, response.body.text()];
|
|
1853
1637
|
case 5:
|
|
1854
|
-
|
|
1855
|
-
"APIErrorResponse",
|
|
1856
|
-
""]);
|
|
1857
|
-
throw new exception_1.ApiException(404, body_74);
|
|
1858
|
-
case 6:
|
|
1859
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1860
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1861
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1862
|
-
return [4 /*yield*/, response.body.text()];
|
|
1863
|
-
case 7:
|
|
1864
|
-
body_75 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
1865
|
-
"APIErrorResponse",
|
|
1866
|
-
""]);
|
|
1867
|
-
throw new exception_1.ApiException(429, body_75);
|
|
1868
|
-
case 8:
|
|
1869
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
1870
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1871
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1872
|
-
return [4 /*yield*/, response.body.text()];
|
|
1873
|
-
case 9:
|
|
1874
|
-
body_76 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
1638
|
+
body_43 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1875
1639
|
"SyntheticsGlobalVariable",
|
|
1876
1640
|
""]);
|
|
1877
|
-
return [2 /*return*/,
|
|
1878
|
-
case
|
|
1879
|
-
case
|
|
1880
|
-
body = (
|
|
1641
|
+
return [2 /*return*/, body_43];
|
|
1642
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1643
|
+
case 7:
|
|
1644
|
+
body = (_l.sent()) || "";
|
|
1881
1645
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1882
1646
|
}
|
|
1883
1647
|
});
|
|
@@ -1892,53 +1656,47 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1892
1656
|
*/
|
|
1893
1657
|
SyntheticsApiResponseProcessor.prototype.getPrivateLocation = function (response) {
|
|
1894
1658
|
return __awaiter(this, void 0, void 0, function () {
|
|
1895
|
-
var contentType,
|
|
1896
|
-
return __generator(this, function (
|
|
1897
|
-
switch (
|
|
1659
|
+
var contentType, body_44, _a, _b, _c, _d, bodyText, _e, _f, body_45, body_46, _g, _h, _j, _k, body;
|
|
1660
|
+
return __generator(this, function (_l) {
|
|
1661
|
+
switch (_l.label) {
|
|
1898
1662
|
case 0:
|
|
1899
1663
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1900
|
-
if (!(
|
|
1664
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1901
1665
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1902
1666
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1903
1667
|
return [4 /*yield*/, response.body.text()];
|
|
1904
1668
|
case 1:
|
|
1905
|
-
|
|
1906
|
-
"SyntheticsPrivateLocation"
|
|
1907
|
-
|
|
1908
|
-
return [2 /*return*/, body_77];
|
|
1669
|
+
body_44 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1670
|
+
"SyntheticsPrivateLocation"]);
|
|
1671
|
+
return [2 /*return*/, body_44];
|
|
1909
1672
|
case 2:
|
|
1910
|
-
if (!(
|
|
1911
|
-
_f = (_e = ObjectSerializer_1.ObjectSerializer).
|
|
1912
|
-
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1673
|
+
if (!(response.httpStatusCode == 404 || response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1674
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1913
1675
|
return [4 /*yield*/, response.body.text()];
|
|
1914
1676
|
case 3:
|
|
1915
|
-
|
|
1916
|
-
|
|
1917
|
-
""
|
|
1918
|
-
|
|
1677
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1678
|
+
try {
|
|
1679
|
+
body_45 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1680
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_45);
|
|
1681
|
+
}
|
|
1682
|
+
catch (error) {
|
|
1683
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1684
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1685
|
+
}
|
|
1686
|
+
_l.label = 4;
|
|
1919
1687
|
case 4:
|
|
1920
|
-
if (!(
|
|
1921
|
-
|
|
1922
|
-
|
|
1688
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1689
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1690
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1923
1691
|
return [4 /*yield*/, response.body.text()];
|
|
1924
1692
|
case 5:
|
|
1925
|
-
|
|
1926
|
-
"APIErrorResponse",
|
|
1927
|
-
""]);
|
|
1928
|
-
throw new exception_1.ApiException(429, body_79);
|
|
1929
|
-
case 6:
|
|
1930
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 8];
|
|
1931
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1932
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1933
|
-
return [4 /*yield*/, response.body.text()];
|
|
1934
|
-
case 7:
|
|
1935
|
-
body_80 = _p.apply(_o, [_r.apply(_q, [_s.sent(), contentType]),
|
|
1693
|
+
body_46 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1936
1694
|
"SyntheticsPrivateLocation",
|
|
1937
1695
|
""]);
|
|
1938
|
-
return [2 /*return*/,
|
|
1939
|
-
case
|
|
1940
|
-
case
|
|
1941
|
-
body = (
|
|
1696
|
+
return [2 /*return*/, body_46];
|
|
1697
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1698
|
+
case 7:
|
|
1699
|
+
body = (_l.sent()) || "";
|
|
1942
1700
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1943
1701
|
}
|
|
1944
1702
|
});
|
|
@@ -1953,53 +1711,47 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
1953
1711
|
*/
|
|
1954
1712
|
SyntheticsApiResponseProcessor.prototype.getSyntheticsCIBatch = function (response) {
|
|
1955
1713
|
return __awaiter(this, void 0, void 0, function () {
|
|
1956
|
-
var contentType,
|
|
1957
|
-
return __generator(this, function (
|
|
1958
|
-
switch (
|
|
1714
|
+
var contentType, body_47, _a, _b, _c, _d, bodyText, _e, _f, body_48, body_49, _g, _h, _j, _k, body;
|
|
1715
|
+
return __generator(this, function (_l) {
|
|
1716
|
+
switch (_l.label) {
|
|
1959
1717
|
case 0:
|
|
1960
1718
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1961
|
-
if (!(
|
|
1719
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1962
1720
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1963
1721
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1964
1722
|
return [4 /*yield*/, response.body.text()];
|
|
1965
1723
|
case 1:
|
|
1966
|
-
|
|
1967
|
-
"SyntheticsBatchDetails"
|
|
1968
|
-
|
|
1969
|
-
return [2 /*return*/, body_81];
|
|
1724
|
+
body_47 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1725
|
+
"SyntheticsBatchDetails"]);
|
|
1726
|
+
return [2 /*return*/, body_47];
|
|
1970
1727
|
case 2:
|
|
1971
|
-
if (!(
|
|
1972
|
-
_f = (_e = ObjectSerializer_1.ObjectSerializer).
|
|
1973
|
-
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1728
|
+
if (!(response.httpStatusCode == 404 || response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1729
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1974
1730
|
return [4 /*yield*/, response.body.text()];
|
|
1975
1731
|
case 3:
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
""
|
|
1979
|
-
|
|
1732
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1733
|
+
try {
|
|
1734
|
+
body_48 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1735
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_48);
|
|
1736
|
+
}
|
|
1737
|
+
catch (error) {
|
|
1738
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1739
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1740
|
+
}
|
|
1741
|
+
_l.label = 4;
|
|
1980
1742
|
case 4:
|
|
1981
|
-
if (!(
|
|
1982
|
-
|
|
1983
|
-
|
|
1743
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1744
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1745
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1984
1746
|
return [4 /*yield*/, response.body.text()];
|
|
1985
1747
|
case 5:
|
|
1986
|
-
|
|
1987
|
-
"APIErrorResponse",
|
|
1988
|
-
""]);
|
|
1989
|
-
throw new exception_1.ApiException(429, body_83);
|
|
1990
|
-
case 6:
|
|
1991
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 8];
|
|
1992
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1993
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1994
|
-
return [4 /*yield*/, response.body.text()];
|
|
1995
|
-
case 7:
|
|
1996
|
-
body_84 = _p.apply(_o, [_r.apply(_q, [_s.sent(), contentType]),
|
|
1748
|
+
body_49 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1997
1749
|
"SyntheticsBatchDetails",
|
|
1998
1750
|
""]);
|
|
1999
|
-
return [2 /*return*/,
|
|
2000
|
-
case
|
|
2001
|
-
case
|
|
2002
|
-
body = (
|
|
1751
|
+
return [2 /*return*/, body_49];
|
|
1752
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1753
|
+
case 7:
|
|
1754
|
+
body = (_l.sent()) || "";
|
|
2003
1755
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
2004
1756
|
}
|
|
2005
1757
|
});
|
|
@@ -2014,63 +1766,49 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
2014
1766
|
*/
|
|
2015
1767
|
SyntheticsApiResponseProcessor.prototype.getTest = function (response) {
|
|
2016
1768
|
return __awaiter(this, void 0, void 0, function () {
|
|
2017
|
-
var contentType,
|
|
2018
|
-
return __generator(this, function (
|
|
2019
|
-
switch (
|
|
1769
|
+
var contentType, body_50, _a, _b, _c, _d, bodyText, _e, _f, body_51, body_52, _g, _h, _j, _k, body;
|
|
1770
|
+
return __generator(this, function (_l) {
|
|
1771
|
+
switch (_l.label) {
|
|
2020
1772
|
case 0:
|
|
2021
1773
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
2022
|
-
if (!(
|
|
1774
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
2023
1775
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2024
1776
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2025
1777
|
return [4 /*yield*/, response.body.text()];
|
|
2026
1778
|
case 1:
|
|
2027
|
-
|
|
2028
|
-
"SyntheticsTestDetails"
|
|
2029
|
-
|
|
2030
|
-
return [2 /*return*/, body_85];
|
|
1779
|
+
body_50 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1780
|
+
"SyntheticsTestDetails"]);
|
|
1781
|
+
return [2 /*return*/, body_50];
|
|
2031
1782
|
case 2:
|
|
2032
|
-
if (!(
|
|
2033
|
-
|
|
2034
|
-
|
|
1783
|
+
if (!(response.httpStatusCode == 403 ||
|
|
1784
|
+
response.httpStatusCode == 404 ||
|
|
1785
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1786
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2035
1787
|
return [4 /*yield*/, response.body.text()];
|
|
2036
1788
|
case 3:
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
""
|
|
2040
|
-
|
|
1789
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1790
|
+
try {
|
|
1791
|
+
body_51 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1792
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_51);
|
|
1793
|
+
}
|
|
1794
|
+
catch (error) {
|
|
1795
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1796
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1797
|
+
}
|
|
1798
|
+
_l.label = 4;
|
|
2041
1799
|
case 4:
|
|
2042
|
-
if (!(
|
|
2043
|
-
|
|
2044
|
-
|
|
1800
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1801
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1802
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2045
1803
|
return [4 /*yield*/, response.body.text()];
|
|
2046
1804
|
case 5:
|
|
2047
|
-
|
|
2048
|
-
"APIErrorResponse",
|
|
2049
|
-
""]);
|
|
2050
|
-
throw new exception_1.ApiException(404, body_87);
|
|
2051
|
-
case 6:
|
|
2052
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
2053
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2054
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2055
|
-
return [4 /*yield*/, response.body.text()];
|
|
2056
|
-
case 7:
|
|
2057
|
-
body_88 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
2058
|
-
"APIErrorResponse",
|
|
2059
|
-
""]);
|
|
2060
|
-
throw new exception_1.ApiException(429, body_88);
|
|
2061
|
-
case 8:
|
|
2062
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
2063
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2064
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2065
|
-
return [4 /*yield*/, response.body.text()];
|
|
2066
|
-
case 9:
|
|
2067
|
-
body_89 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
1805
|
+
body_52 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
2068
1806
|
"SyntheticsTestDetails",
|
|
2069
1807
|
""]);
|
|
2070
|
-
return [2 /*return*/,
|
|
2071
|
-
case
|
|
2072
|
-
case
|
|
2073
|
-
body = (
|
|
1808
|
+
return [2 /*return*/, body_52];
|
|
1809
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1810
|
+
case 7:
|
|
1811
|
+
body = (_l.sent()) || "";
|
|
2074
1812
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
2075
1813
|
}
|
|
2076
1814
|
});
|
|
@@ -2085,53 +1823,47 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
2085
1823
|
*/
|
|
2086
1824
|
SyntheticsApiResponseProcessor.prototype.listGlobalVariables = function (response) {
|
|
2087
1825
|
return __awaiter(this, void 0, void 0, function () {
|
|
2088
|
-
var contentType,
|
|
2089
|
-
return __generator(this, function (
|
|
2090
|
-
switch (
|
|
1826
|
+
var contentType, body_53, _a, _b, _c, _d, bodyText, _e, _f, body_54, body_55, _g, _h, _j, _k, body;
|
|
1827
|
+
return __generator(this, function (_l) {
|
|
1828
|
+
switch (_l.label) {
|
|
2091
1829
|
case 0:
|
|
2092
1830
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
2093
|
-
if (!(
|
|
1831
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
2094
1832
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2095
1833
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2096
1834
|
return [4 /*yield*/, response.body.text()];
|
|
2097
1835
|
case 1:
|
|
2098
|
-
|
|
2099
|
-
"SyntheticsListGlobalVariablesResponse"
|
|
2100
|
-
|
|
2101
|
-
return [2 /*return*/, body_90];
|
|
1836
|
+
body_53 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1837
|
+
"SyntheticsListGlobalVariablesResponse"]);
|
|
1838
|
+
return [2 /*return*/, body_53];
|
|
2102
1839
|
case 2:
|
|
2103
|
-
if (!(
|
|
2104
|
-
_f = (_e = ObjectSerializer_1.ObjectSerializer).
|
|
2105
|
-
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1840
|
+
if (!(response.httpStatusCode == 403 || response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1841
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2106
1842
|
return [4 /*yield*/, response.body.text()];
|
|
2107
1843
|
case 3:
|
|
2108
|
-
|
|
2109
|
-
|
|
2110
|
-
""
|
|
2111
|
-
|
|
1844
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1845
|
+
try {
|
|
1846
|
+
body_54 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1847
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_54);
|
|
1848
|
+
}
|
|
1849
|
+
catch (error) {
|
|
1850
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1851
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1852
|
+
}
|
|
1853
|
+
_l.label = 4;
|
|
2112
1854
|
case 4:
|
|
2113
|
-
if (!(
|
|
2114
|
-
|
|
2115
|
-
|
|
1855
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1856
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1857
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2116
1858
|
return [4 /*yield*/, response.body.text()];
|
|
2117
1859
|
case 5:
|
|
2118
|
-
|
|
2119
|
-
"APIErrorResponse",
|
|
2120
|
-
""]);
|
|
2121
|
-
throw new exception_1.ApiException(429, body_92);
|
|
2122
|
-
case 6:
|
|
2123
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 8];
|
|
2124
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2125
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2126
|
-
return [4 /*yield*/, response.body.text()];
|
|
2127
|
-
case 7:
|
|
2128
|
-
body_93 = _p.apply(_o, [_r.apply(_q, [_s.sent(), contentType]),
|
|
1860
|
+
body_55 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
2129
1861
|
"SyntheticsListGlobalVariablesResponse",
|
|
2130
1862
|
""]);
|
|
2131
|
-
return [2 /*return*/,
|
|
2132
|
-
case
|
|
2133
|
-
case
|
|
2134
|
-
body = (
|
|
1863
|
+
return [2 /*return*/, body_55];
|
|
1864
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1865
|
+
case 7:
|
|
1866
|
+
body = (_l.sent()) || "";
|
|
2135
1867
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
2136
1868
|
}
|
|
2137
1869
|
});
|
|
@@ -2146,43 +1878,47 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
2146
1878
|
*/
|
|
2147
1879
|
SyntheticsApiResponseProcessor.prototype.listLocations = function (response) {
|
|
2148
1880
|
return __awaiter(this, void 0, void 0, function () {
|
|
2149
|
-
var contentType,
|
|
2150
|
-
return __generator(this, function (
|
|
2151
|
-
switch (
|
|
1881
|
+
var contentType, body_56, _a, _b, _c, _d, bodyText, _e, _f, body_57, body_58, _g, _h, _j, _k, body;
|
|
1882
|
+
return __generator(this, function (_l) {
|
|
1883
|
+
switch (_l.label) {
|
|
2152
1884
|
case 0:
|
|
2153
1885
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
2154
|
-
if (!(
|
|
1886
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
2155
1887
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2156
1888
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2157
1889
|
return [4 /*yield*/, response.body.text()];
|
|
2158
1890
|
case 1:
|
|
2159
|
-
|
|
2160
|
-
"SyntheticsLocations"
|
|
2161
|
-
|
|
2162
|
-
return [2 /*return*/, body_94];
|
|
1891
|
+
body_56 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1892
|
+
"SyntheticsLocations"]);
|
|
1893
|
+
return [2 /*return*/, body_56];
|
|
2163
1894
|
case 2:
|
|
2164
|
-
if (!(
|
|
2165
|
-
_f = (_e = ObjectSerializer_1.ObjectSerializer).
|
|
2166
|
-
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1895
|
+
if (!(response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1896
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2167
1897
|
return [4 /*yield*/, response.body.text()];
|
|
2168
1898
|
case 3:
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
""
|
|
2172
|
-
|
|
1899
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1900
|
+
try {
|
|
1901
|
+
body_57 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1902
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_57);
|
|
1903
|
+
}
|
|
1904
|
+
catch (error) {
|
|
1905
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1906
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1907
|
+
}
|
|
1908
|
+
_l.label = 4;
|
|
2173
1909
|
case 4:
|
|
2174
1910
|
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
2175
|
-
|
|
2176
|
-
|
|
1911
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1912
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2177
1913
|
return [4 /*yield*/, response.body.text()];
|
|
2178
1914
|
case 5:
|
|
2179
|
-
|
|
1915
|
+
body_58 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
2180
1916
|
"SyntheticsLocations",
|
|
2181
1917
|
""]);
|
|
2182
|
-
return [2 /*return*/,
|
|
1918
|
+
return [2 /*return*/, body_58];
|
|
2183
1919
|
case 6: return [4 /*yield*/, response.body.text()];
|
|
2184
1920
|
case 7:
|
|
2185
|
-
body = (
|
|
1921
|
+
body = (_l.sent()) || "";
|
|
2186
1922
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
2187
1923
|
}
|
|
2188
1924
|
});
|
|
@@ -2197,63 +1933,49 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
2197
1933
|
*/
|
|
2198
1934
|
SyntheticsApiResponseProcessor.prototype.listTests = function (response) {
|
|
2199
1935
|
return __awaiter(this, void 0, void 0, function () {
|
|
2200
|
-
var contentType,
|
|
2201
|
-
return __generator(this, function (
|
|
2202
|
-
switch (
|
|
1936
|
+
var contentType, body_59, _a, _b, _c, _d, bodyText, _e, _f, body_60, body_61, _g, _h, _j, _k, body;
|
|
1937
|
+
return __generator(this, function (_l) {
|
|
1938
|
+
switch (_l.label) {
|
|
2203
1939
|
case 0:
|
|
2204
1940
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
2205
|
-
if (!(
|
|
1941
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
2206
1942
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2207
1943
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2208
1944
|
return [4 /*yield*/, response.body.text()];
|
|
2209
1945
|
case 1:
|
|
2210
|
-
|
|
2211
|
-
"SyntheticsListTestsResponse"
|
|
2212
|
-
|
|
2213
|
-
return [2 /*return*/, body_97];
|
|
1946
|
+
body_59 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1947
|
+
"SyntheticsListTestsResponse"]);
|
|
1948
|
+
return [2 /*return*/, body_59];
|
|
2214
1949
|
case 2:
|
|
2215
|
-
if (!(
|
|
2216
|
-
|
|
2217
|
-
|
|
1950
|
+
if (!(response.httpStatusCode == 403 ||
|
|
1951
|
+
response.httpStatusCode == 404 ||
|
|
1952
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1953
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2218
1954
|
return [4 /*yield*/, response.body.text()];
|
|
2219
1955
|
case 3:
|
|
2220
|
-
|
|
2221
|
-
|
|
2222
|
-
""
|
|
2223
|
-
|
|
1956
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1957
|
+
try {
|
|
1958
|
+
body_60 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1959
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_60);
|
|
1960
|
+
}
|
|
1961
|
+
catch (error) {
|
|
1962
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1963
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1964
|
+
}
|
|
1965
|
+
_l.label = 4;
|
|
2224
1966
|
case 4:
|
|
2225
|
-
if (!(
|
|
2226
|
-
|
|
2227
|
-
|
|
1967
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1968
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1969
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2228
1970
|
return [4 /*yield*/, response.body.text()];
|
|
2229
1971
|
case 5:
|
|
2230
|
-
|
|
2231
|
-
"APIErrorResponse",
|
|
2232
|
-
""]);
|
|
2233
|
-
throw new exception_1.ApiException(404, body_99);
|
|
2234
|
-
case 6:
|
|
2235
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
2236
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2237
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2238
|
-
return [4 /*yield*/, response.body.text()];
|
|
2239
|
-
case 7:
|
|
2240
|
-
body_100 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
2241
|
-
"APIErrorResponse",
|
|
2242
|
-
""]);
|
|
2243
|
-
throw new exception_1.ApiException(429, body_100);
|
|
2244
|
-
case 8:
|
|
2245
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
2246
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2247
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2248
|
-
return [4 /*yield*/, response.body.text()];
|
|
2249
|
-
case 9:
|
|
2250
|
-
body_101 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
1972
|
+
body_61 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
2251
1973
|
"SyntheticsListTestsResponse",
|
|
2252
1974
|
""]);
|
|
2253
|
-
return [2 /*return*/,
|
|
2254
|
-
case
|
|
2255
|
-
case
|
|
2256
|
-
body = (
|
|
1975
|
+
return [2 /*return*/, body_61];
|
|
1976
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1977
|
+
case 7:
|
|
1978
|
+
body = (_l.sent()) || "";
|
|
2257
1979
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
2258
1980
|
}
|
|
2259
1981
|
});
|
|
@@ -2268,53 +1990,47 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
2268
1990
|
*/
|
|
2269
1991
|
SyntheticsApiResponseProcessor.prototype.triggerCITests = function (response) {
|
|
2270
1992
|
return __awaiter(this, void 0, void 0, function () {
|
|
2271
|
-
var contentType,
|
|
2272
|
-
return __generator(this, function (
|
|
2273
|
-
switch (
|
|
1993
|
+
var contentType, body_62, _a, _b, _c, _d, bodyText, _e, _f, body_63, body_64, _g, _h, _j, _k, body;
|
|
1994
|
+
return __generator(this, function (_l) {
|
|
1995
|
+
switch (_l.label) {
|
|
2274
1996
|
case 0:
|
|
2275
1997
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
2276
|
-
if (!(
|
|
1998
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
2277
1999
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2278
2000
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2279
2001
|
return [4 /*yield*/, response.body.text()];
|
|
2280
2002
|
case 1:
|
|
2281
|
-
|
|
2282
|
-
"SyntheticsTriggerCITestsResponse"
|
|
2283
|
-
|
|
2284
|
-
return [2 /*return*/, body_102];
|
|
2003
|
+
body_62 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
2004
|
+
"SyntheticsTriggerCITestsResponse"]);
|
|
2005
|
+
return [2 /*return*/, body_62];
|
|
2285
2006
|
case 2:
|
|
2286
|
-
if (!(
|
|
2287
|
-
_f = (_e = ObjectSerializer_1.ObjectSerializer).
|
|
2288
|
-
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2007
|
+
if (!(response.httpStatusCode == 400 || response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
2008
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2289
2009
|
return [4 /*yield*/, response.body.text()];
|
|
2290
2010
|
case 3:
|
|
2291
|
-
|
|
2292
|
-
|
|
2293
|
-
""
|
|
2294
|
-
|
|
2011
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
2012
|
+
try {
|
|
2013
|
+
body_63 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
2014
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_63);
|
|
2015
|
+
}
|
|
2016
|
+
catch (error) {
|
|
2017
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
2018
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
2019
|
+
}
|
|
2020
|
+
_l.label = 4;
|
|
2295
2021
|
case 4:
|
|
2296
|
-
if (!(
|
|
2297
|
-
|
|
2298
|
-
|
|
2022
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
2023
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2024
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2299
2025
|
return [4 /*yield*/, response.body.text()];
|
|
2300
2026
|
case 5:
|
|
2301
|
-
|
|
2302
|
-
"APIErrorResponse",
|
|
2303
|
-
""]);
|
|
2304
|
-
throw new exception_1.ApiException(429, body_104);
|
|
2305
|
-
case 6:
|
|
2306
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 8];
|
|
2307
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2308
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2309
|
-
return [4 /*yield*/, response.body.text()];
|
|
2310
|
-
case 7:
|
|
2311
|
-
body_105 = _p.apply(_o, [_r.apply(_q, [_s.sent(), contentType]),
|
|
2027
|
+
body_64 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
2312
2028
|
"SyntheticsTriggerCITestsResponse",
|
|
2313
2029
|
""]);
|
|
2314
|
-
return [2 /*return*/,
|
|
2315
|
-
case
|
|
2316
|
-
case
|
|
2317
|
-
body = (
|
|
2030
|
+
return [2 /*return*/, body_64];
|
|
2031
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
2032
|
+
case 7:
|
|
2033
|
+
body = (_l.sent()) || "";
|
|
2318
2034
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
2319
2035
|
}
|
|
2320
2036
|
});
|
|
@@ -2329,53 +2045,47 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
2329
2045
|
*/
|
|
2330
2046
|
SyntheticsApiResponseProcessor.prototype.triggerTests = function (response) {
|
|
2331
2047
|
return __awaiter(this, void 0, void 0, function () {
|
|
2332
|
-
var contentType,
|
|
2333
|
-
return __generator(this, function (
|
|
2334
|
-
switch (
|
|
2048
|
+
var contentType, body_65, _a, _b, _c, _d, bodyText, _e, _f, body_66, body_67, _g, _h, _j, _k, body;
|
|
2049
|
+
return __generator(this, function (_l) {
|
|
2050
|
+
switch (_l.label) {
|
|
2335
2051
|
case 0:
|
|
2336
2052
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
2337
|
-
if (!(
|
|
2053
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
2338
2054
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2339
2055
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2340
2056
|
return [4 /*yield*/, response.body.text()];
|
|
2341
2057
|
case 1:
|
|
2342
|
-
|
|
2343
|
-
"SyntheticsTriggerCITestsResponse"
|
|
2344
|
-
|
|
2345
|
-
return [2 /*return*/, body_106];
|
|
2058
|
+
body_65 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
2059
|
+
"SyntheticsTriggerCITestsResponse"]);
|
|
2060
|
+
return [2 /*return*/, body_65];
|
|
2346
2061
|
case 2:
|
|
2347
|
-
if (!(
|
|
2348
|
-
_f = (_e = ObjectSerializer_1.ObjectSerializer).
|
|
2349
|
-
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2062
|
+
if (!(response.httpStatusCode == 400 || response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
2063
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2350
2064
|
return [4 /*yield*/, response.body.text()];
|
|
2351
2065
|
case 3:
|
|
2352
|
-
|
|
2353
|
-
|
|
2354
|
-
""
|
|
2355
|
-
|
|
2066
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
2067
|
+
try {
|
|
2068
|
+
body_66 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
2069
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_66);
|
|
2070
|
+
}
|
|
2071
|
+
catch (error) {
|
|
2072
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
2073
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
2074
|
+
}
|
|
2075
|
+
_l.label = 4;
|
|
2356
2076
|
case 4:
|
|
2357
|
-
if (!(
|
|
2358
|
-
|
|
2359
|
-
|
|
2077
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
2078
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2079
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2360
2080
|
return [4 /*yield*/, response.body.text()];
|
|
2361
2081
|
case 5:
|
|
2362
|
-
|
|
2363
|
-
"APIErrorResponse",
|
|
2364
|
-
""]);
|
|
2365
|
-
throw new exception_1.ApiException(429, body_108);
|
|
2366
|
-
case 6:
|
|
2367
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 8];
|
|
2368
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2369
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2370
|
-
return [4 /*yield*/, response.body.text()];
|
|
2371
|
-
case 7:
|
|
2372
|
-
body_109 = _p.apply(_o, [_r.apply(_q, [_s.sent(), contentType]),
|
|
2082
|
+
body_67 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
2373
2083
|
"SyntheticsTriggerCITestsResponse",
|
|
2374
2084
|
""]);
|
|
2375
|
-
return [2 /*return*/,
|
|
2376
|
-
case
|
|
2377
|
-
case
|
|
2378
|
-
body = (
|
|
2085
|
+
return [2 /*return*/, body_67];
|
|
2086
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
2087
|
+
case 7:
|
|
2088
|
+
body = (_l.sent()) || "";
|
|
2379
2089
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
2380
2090
|
}
|
|
2381
2091
|
});
|
|
@@ -2390,73 +2100,50 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
2390
2100
|
*/
|
|
2391
2101
|
SyntheticsApiResponseProcessor.prototype.updateAPITest = function (response) {
|
|
2392
2102
|
return __awaiter(this, void 0, void 0, function () {
|
|
2393
|
-
var contentType,
|
|
2394
|
-
return __generator(this, function (
|
|
2395
|
-
switch (
|
|
2103
|
+
var contentType, body_68, _a, _b, _c, _d, bodyText, _e, _f, body_69, body_70, _g, _h, _j, _k, body;
|
|
2104
|
+
return __generator(this, function (_l) {
|
|
2105
|
+
switch (_l.label) {
|
|
2396
2106
|
case 0:
|
|
2397
2107
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
2398
|
-
if (!(
|
|
2108
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
2399
2109
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2400
2110
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2401
2111
|
return [4 /*yield*/, response.body.text()];
|
|
2402
2112
|
case 1:
|
|
2403
|
-
|
|
2404
|
-
"SyntheticsAPITest"
|
|
2405
|
-
|
|
2406
|
-
return [2 /*return*/, body_110];
|
|
2113
|
+
body_68 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
2114
|
+
"SyntheticsAPITest"]);
|
|
2115
|
+
return [2 /*return*/, body_68];
|
|
2407
2116
|
case 2:
|
|
2408
|
-
if (!(
|
|
2409
|
-
|
|
2410
|
-
|
|
2117
|
+
if (!(response.httpStatusCode == 400 ||
|
|
2118
|
+
response.httpStatusCode == 403 ||
|
|
2119
|
+
response.httpStatusCode == 404 ||
|
|
2120
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
2121
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2411
2122
|
return [4 /*yield*/, response.body.text()];
|
|
2412
2123
|
case 3:
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
""
|
|
2416
|
-
|
|
2124
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
2125
|
+
try {
|
|
2126
|
+
body_69 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
2127
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_69);
|
|
2128
|
+
}
|
|
2129
|
+
catch (error) {
|
|
2130
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
2131
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
2132
|
+
}
|
|
2133
|
+
_l.label = 4;
|
|
2417
2134
|
case 4:
|
|
2418
|
-
if (!(
|
|
2419
|
-
|
|
2420
|
-
|
|
2135
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
2136
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2137
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2421
2138
|
return [4 /*yield*/, response.body.text()];
|
|
2422
2139
|
case 5:
|
|
2423
|
-
|
|
2424
|
-
"APIErrorResponse",
|
|
2425
|
-
""]);
|
|
2426
|
-
throw new exception_1.ApiException(403, body_112);
|
|
2427
|
-
case 6:
|
|
2428
|
-
if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
2429
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2430
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2431
|
-
return [4 /*yield*/, response.body.text()];
|
|
2432
|
-
case 7:
|
|
2433
|
-
body_113 = _p.apply(_o, [_r.apply(_q, [_0.sent(), contentType]),
|
|
2434
|
-
"APIErrorResponse",
|
|
2435
|
-
""]);
|
|
2436
|
-
throw new exception_1.ApiException(404, body_113);
|
|
2437
|
-
case 8:
|
|
2438
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 10];
|
|
2439
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2440
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2441
|
-
return [4 /*yield*/, response.body.text()];
|
|
2442
|
-
case 9:
|
|
2443
|
-
body_114 = _t.apply(_s, [_v.apply(_u, [_0.sent(), contentType]),
|
|
2444
|
-
"APIErrorResponse",
|
|
2445
|
-
""]);
|
|
2446
|
-
throw new exception_1.ApiException(429, body_114);
|
|
2447
|
-
case 10:
|
|
2448
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 12];
|
|
2449
|
-
_x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2450
|
-
_z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2451
|
-
return [4 /*yield*/, response.body.text()];
|
|
2452
|
-
case 11:
|
|
2453
|
-
body_115 = _x.apply(_w, [_z.apply(_y, [_0.sent(), contentType]),
|
|
2140
|
+
body_70 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
2454
2141
|
"SyntheticsAPITest",
|
|
2455
2142
|
""]);
|
|
2456
|
-
return [2 /*return*/,
|
|
2457
|
-
case
|
|
2458
|
-
case
|
|
2459
|
-
body = (
|
|
2143
|
+
return [2 /*return*/, body_70];
|
|
2144
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
2145
|
+
case 7:
|
|
2146
|
+
body = (_l.sent()) || "";
|
|
2460
2147
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
2461
2148
|
}
|
|
2462
2149
|
});
|
|
@@ -2471,73 +2158,50 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
2471
2158
|
*/
|
|
2472
2159
|
SyntheticsApiResponseProcessor.prototype.updateBrowserTest = function (response) {
|
|
2473
2160
|
return __awaiter(this, void 0, void 0, function () {
|
|
2474
|
-
var contentType,
|
|
2475
|
-
return __generator(this, function (
|
|
2476
|
-
switch (
|
|
2161
|
+
var contentType, body_71, _a, _b, _c, _d, bodyText, _e, _f, body_72, body_73, _g, _h, _j, _k, body;
|
|
2162
|
+
return __generator(this, function (_l) {
|
|
2163
|
+
switch (_l.label) {
|
|
2477
2164
|
case 0:
|
|
2478
2165
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
2479
|
-
if (!(
|
|
2166
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
2480
2167
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2481
2168
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2482
2169
|
return [4 /*yield*/, response.body.text()];
|
|
2483
2170
|
case 1:
|
|
2484
|
-
|
|
2485
|
-
"SyntheticsBrowserTest"
|
|
2486
|
-
|
|
2487
|
-
return [2 /*return*/, body_116];
|
|
2171
|
+
body_71 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
2172
|
+
"SyntheticsBrowserTest"]);
|
|
2173
|
+
return [2 /*return*/, body_71];
|
|
2488
2174
|
case 2:
|
|
2489
|
-
if (!(
|
|
2490
|
-
|
|
2491
|
-
|
|
2175
|
+
if (!(response.httpStatusCode == 400 ||
|
|
2176
|
+
response.httpStatusCode == 403 ||
|
|
2177
|
+
response.httpStatusCode == 404 ||
|
|
2178
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
2179
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2492
2180
|
return [4 /*yield*/, response.body.text()];
|
|
2493
2181
|
case 3:
|
|
2494
|
-
|
|
2495
|
-
|
|
2496
|
-
""
|
|
2497
|
-
|
|
2182
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
2183
|
+
try {
|
|
2184
|
+
body_72 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
2185
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_72);
|
|
2186
|
+
}
|
|
2187
|
+
catch (error) {
|
|
2188
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
2189
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
2190
|
+
}
|
|
2191
|
+
_l.label = 4;
|
|
2498
2192
|
case 4:
|
|
2499
|
-
if (!(
|
|
2500
|
-
|
|
2501
|
-
|
|
2193
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
2194
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2195
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2502
2196
|
return [4 /*yield*/, response.body.text()];
|
|
2503
2197
|
case 5:
|
|
2504
|
-
|
|
2505
|
-
"APIErrorResponse",
|
|
2506
|
-
""]);
|
|
2507
|
-
throw new exception_1.ApiException(403, body_118);
|
|
2508
|
-
case 6:
|
|
2509
|
-
if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
2510
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2511
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2512
|
-
return [4 /*yield*/, response.body.text()];
|
|
2513
|
-
case 7:
|
|
2514
|
-
body_119 = _p.apply(_o, [_r.apply(_q, [_0.sent(), contentType]),
|
|
2515
|
-
"APIErrorResponse",
|
|
2516
|
-
""]);
|
|
2517
|
-
throw new exception_1.ApiException(404, body_119);
|
|
2518
|
-
case 8:
|
|
2519
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 10];
|
|
2520
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2521
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2522
|
-
return [4 /*yield*/, response.body.text()];
|
|
2523
|
-
case 9:
|
|
2524
|
-
body_120 = _t.apply(_s, [_v.apply(_u, [_0.sent(), contentType]),
|
|
2525
|
-
"APIErrorResponse",
|
|
2526
|
-
""]);
|
|
2527
|
-
throw new exception_1.ApiException(429, body_120);
|
|
2528
|
-
case 10:
|
|
2529
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 12];
|
|
2530
|
-
_x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2531
|
-
_z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2532
|
-
return [4 /*yield*/, response.body.text()];
|
|
2533
|
-
case 11:
|
|
2534
|
-
body_121 = _x.apply(_w, [_z.apply(_y, [_0.sent(), contentType]),
|
|
2198
|
+
body_73 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
2535
2199
|
"SyntheticsBrowserTest",
|
|
2536
2200
|
""]);
|
|
2537
|
-
return [2 /*return*/,
|
|
2538
|
-
case
|
|
2539
|
-
case
|
|
2540
|
-
body = (
|
|
2201
|
+
return [2 /*return*/, body_73];
|
|
2202
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
2203
|
+
case 7:
|
|
2204
|
+
body = (_l.sent()) || "";
|
|
2541
2205
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
2542
2206
|
}
|
|
2543
2207
|
});
|
|
@@ -2552,53 +2216,47 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
2552
2216
|
*/
|
|
2553
2217
|
SyntheticsApiResponseProcessor.prototype.updatePrivateLocation = function (response) {
|
|
2554
2218
|
return __awaiter(this, void 0, void 0, function () {
|
|
2555
|
-
var contentType,
|
|
2556
|
-
return __generator(this, function (
|
|
2557
|
-
switch (
|
|
2219
|
+
var contentType, body_74, _a, _b, _c, _d, bodyText, _e, _f, body_75, body_76, _g, _h, _j, _k, body;
|
|
2220
|
+
return __generator(this, function (_l) {
|
|
2221
|
+
switch (_l.label) {
|
|
2558
2222
|
case 0:
|
|
2559
2223
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
2560
|
-
if (!(
|
|
2224
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
2561
2225
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2562
2226
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2563
2227
|
return [4 /*yield*/, response.body.text()];
|
|
2564
2228
|
case 1:
|
|
2565
|
-
|
|
2566
|
-
"SyntheticsPrivateLocation"
|
|
2567
|
-
|
|
2568
|
-
return [2 /*return*/, body_122];
|
|
2229
|
+
body_74 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
2230
|
+
"SyntheticsPrivateLocation"]);
|
|
2231
|
+
return [2 /*return*/, body_74];
|
|
2569
2232
|
case 2:
|
|
2570
|
-
if (!(
|
|
2571
|
-
_f = (_e = ObjectSerializer_1.ObjectSerializer).
|
|
2572
|
-
_h = (_g = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2233
|
+
if (!(response.httpStatusCode == 404 || response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
2234
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2573
2235
|
return [4 /*yield*/, response.body.text()];
|
|
2574
2236
|
case 3:
|
|
2575
|
-
|
|
2576
|
-
|
|
2577
|
-
""
|
|
2578
|
-
|
|
2237
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
2238
|
+
try {
|
|
2239
|
+
body_75 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
2240
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_75);
|
|
2241
|
+
}
|
|
2242
|
+
catch (error) {
|
|
2243
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
2244
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
2245
|
+
}
|
|
2246
|
+
_l.label = 4;
|
|
2579
2247
|
case 4:
|
|
2580
|
-
if (!(
|
|
2581
|
-
|
|
2582
|
-
|
|
2248
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
2249
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2250
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2583
2251
|
return [4 /*yield*/, response.body.text()];
|
|
2584
2252
|
case 5:
|
|
2585
|
-
|
|
2586
|
-
"APIErrorResponse",
|
|
2587
|
-
""]);
|
|
2588
|
-
throw new exception_1.ApiException(429, body_124);
|
|
2589
|
-
case 6:
|
|
2590
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 8];
|
|
2591
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2592
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2593
|
-
return [4 /*yield*/, response.body.text()];
|
|
2594
|
-
case 7:
|
|
2595
|
-
body_125 = _p.apply(_o, [_r.apply(_q, [_s.sent(), contentType]),
|
|
2253
|
+
body_76 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
2596
2254
|
"SyntheticsPrivateLocation",
|
|
2597
2255
|
""]);
|
|
2598
|
-
return [2 /*return*/,
|
|
2599
|
-
case
|
|
2600
|
-
case
|
|
2601
|
-
body = (
|
|
2256
|
+
return [2 /*return*/, body_76];
|
|
2257
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
2258
|
+
case 7:
|
|
2259
|
+
body = (_l.sent()) || "";
|
|
2602
2260
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
2603
2261
|
}
|
|
2604
2262
|
});
|
|
@@ -2613,73 +2271,50 @@ var SyntheticsApiResponseProcessor = /** @class */ (function () {
|
|
|
2613
2271
|
*/
|
|
2614
2272
|
SyntheticsApiResponseProcessor.prototype.updateTestPauseStatus = function (response) {
|
|
2615
2273
|
return __awaiter(this, void 0, void 0, function () {
|
|
2616
|
-
var contentType,
|
|
2617
|
-
return __generator(this, function (
|
|
2618
|
-
switch (
|
|
2274
|
+
var contentType, body_77, _a, _b, _c, _d, bodyText, _e, _f, body_78, body_79, _g, _h, _j, _k, body;
|
|
2275
|
+
return __generator(this, function (_l) {
|
|
2276
|
+
switch (_l.label) {
|
|
2619
2277
|
case 0:
|
|
2620
2278
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
2621
|
-
if (!(
|
|
2279
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
2622
2280
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2623
2281
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2624
2282
|
return [4 /*yield*/, response.body.text()];
|
|
2625
2283
|
case 1:
|
|
2626
|
-
|
|
2627
|
-
"boolean"
|
|
2628
|
-
|
|
2629
|
-
return [2 /*return*/, body_126];
|
|
2284
|
+
body_77 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
2285
|
+
"boolean"]);
|
|
2286
|
+
return [2 /*return*/, body_77];
|
|
2630
2287
|
case 2:
|
|
2631
|
-
if (!(
|
|
2632
|
-
|
|
2633
|
-
|
|
2288
|
+
if (!(response.httpStatusCode == 400 ||
|
|
2289
|
+
response.httpStatusCode == 403 ||
|
|
2290
|
+
response.httpStatusCode == 404 ||
|
|
2291
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
2292
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2634
2293
|
return [4 /*yield*/, response.body.text()];
|
|
2635
2294
|
case 3:
|
|
2636
|
-
|
|
2637
|
-
|
|
2638
|
-
""
|
|
2639
|
-
|
|
2295
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
2296
|
+
try {
|
|
2297
|
+
body_78 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
2298
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_78);
|
|
2299
|
+
}
|
|
2300
|
+
catch (error) {
|
|
2301
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
2302
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
2303
|
+
}
|
|
2304
|
+
_l.label = 4;
|
|
2640
2305
|
case 4:
|
|
2641
|
-
if (!(
|
|
2642
|
-
|
|
2643
|
-
|
|
2306
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
2307
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2308
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2644
2309
|
return [4 /*yield*/, response.body.text()];
|
|
2645
2310
|
case 5:
|
|
2646
|
-
|
|
2647
|
-
"APIErrorResponse",
|
|
2648
|
-
""]);
|
|
2649
|
-
throw new exception_1.ApiException(403, body_128);
|
|
2650
|
-
case 6:
|
|
2651
|
-
if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
2652
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2653
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2654
|
-
return [4 /*yield*/, response.body.text()];
|
|
2655
|
-
case 7:
|
|
2656
|
-
body_129 = _p.apply(_o, [_r.apply(_q, [_0.sent(), contentType]),
|
|
2657
|
-
"APIErrorResponse",
|
|
2658
|
-
""]);
|
|
2659
|
-
throw new exception_1.ApiException(404, body_129);
|
|
2660
|
-
case 8:
|
|
2661
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 10];
|
|
2662
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2663
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2664
|
-
return [4 /*yield*/, response.body.text()];
|
|
2665
|
-
case 9:
|
|
2666
|
-
body_130 = _t.apply(_s, [_v.apply(_u, [_0.sent(), contentType]),
|
|
2667
|
-
"APIErrorResponse",
|
|
2668
|
-
""]);
|
|
2669
|
-
throw new exception_1.ApiException(429, body_130);
|
|
2670
|
-
case 10:
|
|
2671
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 12];
|
|
2672
|
-
_x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
2673
|
-
_z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
|
|
2674
|
-
return [4 /*yield*/, response.body.text()];
|
|
2675
|
-
case 11:
|
|
2676
|
-
body_131 = _x.apply(_w, [_z.apply(_y, [_0.sent(), contentType]),
|
|
2311
|
+
body_79 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
2677
2312
|
"boolean",
|
|
2678
2313
|
""]);
|
|
2679
|
-
return [2 /*return*/,
|
|
2680
|
-
case
|
|
2681
|
-
case
|
|
2682
|
-
body = (
|
|
2314
|
+
return [2 /*return*/, body_79];
|
|
2315
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
2316
|
+
case 7:
|
|
2317
|
+
body = (_l.sent()) || "";
|
|
2683
2318
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
2684
2319
|
}
|
|
2685
2320
|
});
|