@datadog/datadog-api-client 1.3.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 +26 -0
- package/README.md +72 -0
- package/dist/packages/datadog-api-client-common/configuration.js +2 -1
- package/dist/packages/datadog-api-client-common/configuration.js.map +1 -1
- package/dist/packages/datadog-api-client-common/http/isomorphic-fetch.js +3 -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.js +1093 -1594
- 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 +20 -0
- package/dist/packages/datadog-api-client-v1/index.js +35 -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/HourlyUsageAttributionUsageType.d.ts +2 -1
- package/dist/packages/datadog-api-client-v1/models/HourlyUsageAttributionUsageType.js +2 -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/MonthlyUsageAttributionSupportedMetrics.d.ts +3 -1
- package/dist/packages/datadog-api-client-v1/models/MonthlyUsageAttributionSupportedMetrics.js +4 -2
- package/dist/packages/datadog-api-client-v1/models/MonthlyUsageAttributionSupportedMetrics.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/MonthlyUsageAttributionValues.d.ts +8 -0
- package/dist/packages/datadog-api-client-v1/models/MonthlyUsageAttributionValues.js +10 -0
- package/dist/packages/datadog-api-client-v1/models/MonthlyUsageAttributionValues.js.map +1 -1
- package/dist/packages/datadog-api-client-v1/models/ObjectSerializer.js +44 -0
- package/dist/packages/datadog-api-client-v1/models/ObjectSerializer.js.map +1 -1
- 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/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 +3 -1
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionSort.js +3 -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 +3 -1
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionSupportedMetrics.js +3 -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 +8 -0
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionValues.js +10 -0
- package/dist/packages/datadog-api-client-v1/models/UsageAttributionValues.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 +4 -0
- package/dist/packages/datadog-api-client-v1/models/UsageSummaryDate.js +5 -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 +4 -0
- package/dist/packages/datadog-api-client-v1/models/UsageSummaryDateOrg.js +5 -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 +4 -0
- package/dist/packages/datadog-api-client-v1/models/UsageSummaryResponse.js +5 -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-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 +57 -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.js +222 -310
- 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 -685
- 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 +35 -5
- package/dist/packages/datadog-api-client-v2/index.js +49 -15
- package/dist/packages/datadog-api-client-v2/index.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/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 +73 -10
- package/dist/packages/datadog-api-client-v2/models/ObjectSerializer.js.map +1 -1
- 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/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 +1 -1
- package/dist/packages/datadog-api-client-v2/models/SecurityMonitoringRuleQueryCreate.js.map +0 -1
|
@@ -55,9 +55,9 @@ exports.KeyManagementApi = exports.KeyManagementApiResponseProcessor = exports.K
|
|
|
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 KeyManagementApiRequestFactory = /** @class */ (function (_super) {
|
|
62
62
|
__extends(KeyManagementApiRequestFactory, _super);
|
|
63
63
|
function KeyManagementApiRequestFactory() {
|
|
@@ -490,63 +490,49 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
490
490
|
*/
|
|
491
491
|
KeyManagementApiResponseProcessor.prototype.createAPIKey = function (response) {
|
|
492
492
|
return __awaiter(this, void 0, void 0, function () {
|
|
493
|
-
var contentType, body_1, _a, _b, _c, _d,
|
|
494
|
-
return __generator(this, function (
|
|
495
|
-
switch (
|
|
493
|
+
var contentType, body_1, _a, _b, _c, _d, bodyText, _e, _f, body_2, body_3, _g, _h, _j, _k, body;
|
|
494
|
+
return __generator(this, function (_l) {
|
|
495
|
+
switch (_l.label) {
|
|
496
496
|
case 0:
|
|
497
497
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
498
|
-
if (!(
|
|
498
|
+
if (!(response.httpStatusCode == 201)) return [3 /*break*/, 2];
|
|
499
499
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
500
500
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
501
501
|
return [4 /*yield*/, response.body.text()];
|
|
502
502
|
case 1:
|
|
503
|
-
body_1 = _b.apply(_a, [_d.apply(_c, [
|
|
504
|
-
"APIKeyResponse"
|
|
505
|
-
""]);
|
|
503
|
+
body_1 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
504
|
+
"APIKeyResponse"]);
|
|
506
505
|
return [2 /*return*/, body_1];
|
|
507
506
|
case 2:
|
|
508
|
-
if (!(
|
|
509
|
-
|
|
510
|
-
|
|
507
|
+
if (!(response.httpStatusCode == 400 ||
|
|
508
|
+
response.httpStatusCode == 403 ||
|
|
509
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
510
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
511
511
|
return [4 /*yield*/, response.body.text()];
|
|
512
512
|
case 3:
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
""
|
|
516
|
-
|
|
513
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
514
|
+
try {
|
|
515
|
+
body_2 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
516
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_2);
|
|
517
|
+
}
|
|
518
|
+
catch (error) {
|
|
519
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
520
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
521
|
+
}
|
|
522
|
+
_l.label = 4;
|
|
517
523
|
case 4:
|
|
518
|
-
if (!(
|
|
519
|
-
|
|
520
|
-
|
|
524
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
525
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
526
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
521
527
|
return [4 /*yield*/, response.body.text()];
|
|
522
528
|
case 5:
|
|
523
|
-
body_3 =
|
|
524
|
-
"APIErrorResponse",
|
|
525
|
-
""]);
|
|
526
|
-
throw new exception_1.ApiException(403, body_3);
|
|
527
|
-
case 6:
|
|
528
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
529
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
530
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
531
|
-
return [4 /*yield*/, response.body.text()];
|
|
532
|
-
case 7:
|
|
533
|
-
body_4 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
534
|
-
"APIErrorResponse",
|
|
535
|
-
""]);
|
|
536
|
-
throw new exception_1.ApiException(429, body_4);
|
|
537
|
-
case 8:
|
|
538
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
539
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
540
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
541
|
-
return [4 /*yield*/, response.body.text()];
|
|
542
|
-
case 9:
|
|
543
|
-
body_5 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
529
|
+
body_3 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
544
530
|
"APIKeyResponse",
|
|
545
531
|
""]);
|
|
546
|
-
return [2 /*return*/,
|
|
547
|
-
case
|
|
548
|
-
case
|
|
549
|
-
body = (
|
|
532
|
+
return [2 /*return*/, body_3];
|
|
533
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
534
|
+
case 7:
|
|
535
|
+
body = (_l.sent()) || "";
|
|
550
536
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
551
537
|
}
|
|
552
538
|
});
|
|
@@ -561,63 +547,49 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
561
547
|
*/
|
|
562
548
|
KeyManagementApiResponseProcessor.prototype.createCurrentUserApplicationKey = function (response) {
|
|
563
549
|
return __awaiter(this, void 0, void 0, function () {
|
|
564
|
-
var contentType,
|
|
565
|
-
return __generator(this, function (
|
|
566
|
-
switch (
|
|
550
|
+
var contentType, body_4, _a, _b, _c, _d, bodyText, _e, _f, body_5, body_6, _g, _h, _j, _k, body;
|
|
551
|
+
return __generator(this, function (_l) {
|
|
552
|
+
switch (_l.label) {
|
|
567
553
|
case 0:
|
|
568
554
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
569
|
-
if (!(
|
|
555
|
+
if (!(response.httpStatusCode == 201)) return [3 /*break*/, 2];
|
|
570
556
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
571
557
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
572
558
|
return [4 /*yield*/, response.body.text()];
|
|
573
559
|
case 1:
|
|
574
|
-
|
|
575
|
-
"ApplicationKeyResponse"
|
|
576
|
-
|
|
577
|
-
return [2 /*return*/, body_6];
|
|
560
|
+
body_4 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
561
|
+
"ApplicationKeyResponse"]);
|
|
562
|
+
return [2 /*return*/, body_4];
|
|
578
563
|
case 2:
|
|
579
|
-
if (!(
|
|
580
|
-
|
|
581
|
-
|
|
564
|
+
if (!(response.httpStatusCode == 400 ||
|
|
565
|
+
response.httpStatusCode == 403 ||
|
|
566
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
567
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
582
568
|
return [4 /*yield*/, response.body.text()];
|
|
583
569
|
case 3:
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
""
|
|
587
|
-
|
|
570
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
571
|
+
try {
|
|
572
|
+
body_5 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
573
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_5);
|
|
574
|
+
}
|
|
575
|
+
catch (error) {
|
|
576
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
577
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
578
|
+
}
|
|
579
|
+
_l.label = 4;
|
|
588
580
|
case 4:
|
|
589
|
-
if (!(
|
|
590
|
-
|
|
591
|
-
|
|
581
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
582
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
583
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
592
584
|
return [4 /*yield*/, response.body.text()];
|
|
593
585
|
case 5:
|
|
594
|
-
|
|
595
|
-
"APIErrorResponse",
|
|
596
|
-
""]);
|
|
597
|
-
throw new exception_1.ApiException(403, body_8);
|
|
598
|
-
case 6:
|
|
599
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
600
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
601
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
602
|
-
return [4 /*yield*/, response.body.text()];
|
|
603
|
-
case 7:
|
|
604
|
-
body_9 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
605
|
-
"APIErrorResponse",
|
|
606
|
-
""]);
|
|
607
|
-
throw new exception_1.ApiException(429, body_9);
|
|
608
|
-
case 8:
|
|
609
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
610
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
611
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
612
|
-
return [4 /*yield*/, response.body.text()];
|
|
613
|
-
case 9:
|
|
614
|
-
body_10 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
586
|
+
body_6 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
615
587
|
"ApplicationKeyResponse",
|
|
616
588
|
""]);
|
|
617
|
-
return [2 /*return*/,
|
|
618
|
-
case
|
|
619
|
-
case
|
|
620
|
-
body = (
|
|
589
|
+
return [2 /*return*/, body_6];
|
|
590
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
591
|
+
case 7:
|
|
592
|
+
body = (_l.sent()) || "";
|
|
621
593
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
622
594
|
}
|
|
623
595
|
});
|
|
@@ -632,56 +604,43 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
632
604
|
*/
|
|
633
605
|
KeyManagementApiResponseProcessor.prototype.deleteAPIKey = function (response) {
|
|
634
606
|
return __awaiter(this, void 0, void 0, function () {
|
|
635
|
-
var contentType,
|
|
636
|
-
return __generator(this, function (
|
|
637
|
-
switch (
|
|
607
|
+
var contentType, bodyText, _a, _b, body_7, body_8, _c, _d, _e, _f, body;
|
|
608
|
+
return __generator(this, function (_g) {
|
|
609
|
+
switch (_g.label) {
|
|
638
610
|
case 0:
|
|
639
611
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
640
|
-
if (
|
|
612
|
+
if (response.httpStatusCode == 204) {
|
|
641
613
|
return [2 /*return*/];
|
|
642
614
|
}
|
|
643
|
-
if (!(
|
|
644
|
-
|
|
645
|
-
|
|
615
|
+
if (!(response.httpStatusCode == 403 ||
|
|
616
|
+
response.httpStatusCode == 404 ||
|
|
617
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 2];
|
|
618
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).parse;
|
|
646
619
|
return [4 /*yield*/, response.body.text()];
|
|
647
620
|
case 1:
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
""
|
|
651
|
-
|
|
621
|
+
bodyText = _b.apply(_a, [_g.sent(), contentType]);
|
|
622
|
+
try {
|
|
623
|
+
body_7 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
624
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_7);
|
|
625
|
+
}
|
|
626
|
+
catch (error) {
|
|
627
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
628
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
629
|
+
}
|
|
630
|
+
_g.label = 2;
|
|
652
631
|
case 2:
|
|
653
|
-
if (!(
|
|
654
|
-
|
|
655
|
-
|
|
632
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 4];
|
|
633
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
634
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
656
635
|
return [4 /*yield*/, response.body.text()];
|
|
657
636
|
case 3:
|
|
658
|
-
|
|
659
|
-
"APIErrorResponse",
|
|
660
|
-
""]);
|
|
661
|
-
throw new exception_1.ApiException(404, body_12);
|
|
662
|
-
case 4:
|
|
663
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 6];
|
|
664
|
-
_k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
665
|
-
_m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
|
|
666
|
-
return [4 /*yield*/, response.body.text()];
|
|
667
|
-
case 5:
|
|
668
|
-
body_13 = _k.apply(_j, [_m.apply(_l, [_s.sent(), contentType]),
|
|
669
|
-
"APIErrorResponse",
|
|
670
|
-
""]);
|
|
671
|
-
throw new exception_1.ApiException(429, body_13);
|
|
672
|
-
case 6:
|
|
673
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 8];
|
|
674
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
675
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
676
|
-
return [4 /*yield*/, response.body.text()];
|
|
677
|
-
case 7:
|
|
678
|
-
body_14 = _p.apply(_o, [_r.apply(_q, [_s.sent(), contentType]),
|
|
637
|
+
body_8 = _d.apply(_c, [_f.apply(_e, [_g.sent(), contentType]),
|
|
679
638
|
"void",
|
|
680
639
|
""]);
|
|
681
|
-
return [2 /*return*/,
|
|
682
|
-
case
|
|
683
|
-
case
|
|
684
|
-
body = (
|
|
640
|
+
return [2 /*return*/, body_8];
|
|
641
|
+
case 4: return [4 /*yield*/, response.body.text()];
|
|
642
|
+
case 5:
|
|
643
|
+
body = (_g.sent()) || "";
|
|
685
644
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
686
645
|
}
|
|
687
646
|
});
|
|
@@ -696,56 +655,43 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
696
655
|
*/
|
|
697
656
|
KeyManagementApiResponseProcessor.prototype.deleteApplicationKey = function (response) {
|
|
698
657
|
return __awaiter(this, void 0, void 0, function () {
|
|
699
|
-
var contentType,
|
|
700
|
-
return __generator(this, function (
|
|
701
|
-
switch (
|
|
658
|
+
var contentType, bodyText, _a, _b, body_9, body_10, _c, _d, _e, _f, body;
|
|
659
|
+
return __generator(this, function (_g) {
|
|
660
|
+
switch (_g.label) {
|
|
702
661
|
case 0:
|
|
703
662
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
704
|
-
if (
|
|
663
|
+
if (response.httpStatusCode == 204) {
|
|
705
664
|
return [2 /*return*/];
|
|
706
665
|
}
|
|
707
|
-
if (!(
|
|
708
|
-
|
|
709
|
-
|
|
666
|
+
if (!(response.httpStatusCode == 403 ||
|
|
667
|
+
response.httpStatusCode == 404 ||
|
|
668
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 2];
|
|
669
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).parse;
|
|
710
670
|
return [4 /*yield*/, response.body.text()];
|
|
711
671
|
case 1:
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
""
|
|
715
|
-
|
|
672
|
+
bodyText = _b.apply(_a, [_g.sent(), contentType]);
|
|
673
|
+
try {
|
|
674
|
+
body_9 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
675
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_9);
|
|
676
|
+
}
|
|
677
|
+
catch (error) {
|
|
678
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
679
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
680
|
+
}
|
|
681
|
+
_g.label = 2;
|
|
716
682
|
case 2:
|
|
717
|
-
if (!(
|
|
718
|
-
|
|
719
|
-
|
|
683
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 4];
|
|
684
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
685
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
720
686
|
return [4 /*yield*/, response.body.text()];
|
|
721
687
|
case 3:
|
|
722
|
-
|
|
723
|
-
"APIErrorResponse",
|
|
724
|
-
""]);
|
|
725
|
-
throw new exception_1.ApiException(404, body_16);
|
|
726
|
-
case 4:
|
|
727
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 6];
|
|
728
|
-
_k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
729
|
-
_m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
|
|
730
|
-
return [4 /*yield*/, response.body.text()];
|
|
731
|
-
case 5:
|
|
732
|
-
body_17 = _k.apply(_j, [_m.apply(_l, [_s.sent(), contentType]),
|
|
733
|
-
"APIErrorResponse",
|
|
734
|
-
""]);
|
|
735
|
-
throw new exception_1.ApiException(429, body_17);
|
|
736
|
-
case 6:
|
|
737
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 8];
|
|
738
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
739
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
740
|
-
return [4 /*yield*/, response.body.text()];
|
|
741
|
-
case 7:
|
|
742
|
-
body_18 = _p.apply(_o, [_r.apply(_q, [_s.sent(), contentType]),
|
|
688
|
+
body_10 = _d.apply(_c, [_f.apply(_e, [_g.sent(), contentType]),
|
|
743
689
|
"void",
|
|
744
690
|
""]);
|
|
745
|
-
return [2 /*return*/,
|
|
746
|
-
case
|
|
747
|
-
case
|
|
748
|
-
body = (
|
|
691
|
+
return [2 /*return*/, body_10];
|
|
692
|
+
case 4: return [4 /*yield*/, response.body.text()];
|
|
693
|
+
case 5:
|
|
694
|
+
body = (_g.sent()) || "";
|
|
749
695
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
750
696
|
}
|
|
751
697
|
});
|
|
@@ -760,56 +706,43 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
760
706
|
*/
|
|
761
707
|
KeyManagementApiResponseProcessor.prototype.deleteCurrentUserApplicationKey = function (response) {
|
|
762
708
|
return __awaiter(this, void 0, void 0, function () {
|
|
763
|
-
var contentType,
|
|
764
|
-
return __generator(this, function (
|
|
765
|
-
switch (
|
|
709
|
+
var contentType, bodyText, _a, _b, body_11, body_12, _c, _d, _e, _f, body;
|
|
710
|
+
return __generator(this, function (_g) {
|
|
711
|
+
switch (_g.label) {
|
|
766
712
|
case 0:
|
|
767
713
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
768
|
-
if (
|
|
714
|
+
if (response.httpStatusCode == 204) {
|
|
769
715
|
return [2 /*return*/];
|
|
770
716
|
}
|
|
771
|
-
if (!(
|
|
772
|
-
|
|
773
|
-
|
|
717
|
+
if (!(response.httpStatusCode == 403 ||
|
|
718
|
+
response.httpStatusCode == 404 ||
|
|
719
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 2];
|
|
720
|
+
_b = (_a = ObjectSerializer_1.ObjectSerializer).parse;
|
|
774
721
|
return [4 /*yield*/, response.body.text()];
|
|
775
722
|
case 1:
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
""
|
|
779
|
-
|
|
723
|
+
bodyText = _b.apply(_a, [_g.sent(), contentType]);
|
|
724
|
+
try {
|
|
725
|
+
body_11 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
726
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_11);
|
|
727
|
+
}
|
|
728
|
+
catch (error) {
|
|
729
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
730
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
731
|
+
}
|
|
732
|
+
_g.label = 2;
|
|
780
733
|
case 2:
|
|
781
|
-
if (!(
|
|
782
|
-
|
|
783
|
-
|
|
734
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 4];
|
|
735
|
+
_d = (_c = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
736
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
784
737
|
return [4 /*yield*/, response.body.text()];
|
|
785
738
|
case 3:
|
|
786
|
-
|
|
787
|
-
"APIErrorResponse",
|
|
788
|
-
""]);
|
|
789
|
-
throw new exception_1.ApiException(404, body_20);
|
|
790
|
-
case 4:
|
|
791
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 6];
|
|
792
|
-
_k = (_j = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
793
|
-
_m = (_l = ObjectSerializer_1.ObjectSerializer).parse;
|
|
794
|
-
return [4 /*yield*/, response.body.text()];
|
|
795
|
-
case 5:
|
|
796
|
-
body_21 = _k.apply(_j, [_m.apply(_l, [_s.sent(), contentType]),
|
|
797
|
-
"APIErrorResponse",
|
|
798
|
-
""]);
|
|
799
|
-
throw new exception_1.ApiException(429, body_21);
|
|
800
|
-
case 6:
|
|
801
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 8];
|
|
802
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
803
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
804
|
-
return [4 /*yield*/, response.body.text()];
|
|
805
|
-
case 7:
|
|
806
|
-
body_22 = _p.apply(_o, [_r.apply(_q, [_s.sent(), contentType]),
|
|
739
|
+
body_12 = _d.apply(_c, [_f.apply(_e, [_g.sent(), contentType]),
|
|
807
740
|
"void",
|
|
808
741
|
""]);
|
|
809
|
-
return [2 /*return*/,
|
|
810
|
-
case
|
|
811
|
-
case
|
|
812
|
-
body = (
|
|
742
|
+
return [2 /*return*/, body_12];
|
|
743
|
+
case 4: return [4 /*yield*/, response.body.text()];
|
|
744
|
+
case 5:
|
|
745
|
+
body = (_g.sent()) || "";
|
|
813
746
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
814
747
|
}
|
|
815
748
|
});
|
|
@@ -824,63 +757,49 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
824
757
|
*/
|
|
825
758
|
KeyManagementApiResponseProcessor.prototype.getAPIKey = function (response) {
|
|
826
759
|
return __awaiter(this, void 0, void 0, function () {
|
|
827
|
-
var contentType,
|
|
828
|
-
return __generator(this, function (
|
|
829
|
-
switch (
|
|
760
|
+
var contentType, body_13, _a, _b, _c, _d, bodyText, _e, _f, body_14, body_15, _g, _h, _j, _k, body;
|
|
761
|
+
return __generator(this, function (_l) {
|
|
762
|
+
switch (_l.label) {
|
|
830
763
|
case 0:
|
|
831
764
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
832
|
-
if (!(
|
|
765
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
833
766
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
834
767
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
835
768
|
return [4 /*yield*/, response.body.text()];
|
|
836
769
|
case 1:
|
|
837
|
-
|
|
838
|
-
"APIKeyResponse"
|
|
839
|
-
|
|
840
|
-
return [2 /*return*/, body_23];
|
|
770
|
+
body_13 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
771
|
+
"APIKeyResponse"]);
|
|
772
|
+
return [2 /*return*/, body_13];
|
|
841
773
|
case 2:
|
|
842
|
-
if (!(
|
|
843
|
-
|
|
844
|
-
|
|
774
|
+
if (!(response.httpStatusCode == 403 ||
|
|
775
|
+
response.httpStatusCode == 404 ||
|
|
776
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
777
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
845
778
|
return [4 /*yield*/, response.body.text()];
|
|
846
779
|
case 3:
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
""
|
|
850
|
-
|
|
780
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
781
|
+
try {
|
|
782
|
+
body_14 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
783
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_14);
|
|
784
|
+
}
|
|
785
|
+
catch (error) {
|
|
786
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
787
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
788
|
+
}
|
|
789
|
+
_l.label = 4;
|
|
851
790
|
case 4:
|
|
852
|
-
if (!(
|
|
853
|
-
|
|
854
|
-
|
|
791
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
792
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
793
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
855
794
|
return [4 /*yield*/, response.body.text()];
|
|
856
795
|
case 5:
|
|
857
|
-
|
|
858
|
-
"APIErrorResponse",
|
|
859
|
-
""]);
|
|
860
|
-
throw new exception_1.ApiException(404, body_25);
|
|
861
|
-
case 6:
|
|
862
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
863
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
864
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
865
|
-
return [4 /*yield*/, response.body.text()];
|
|
866
|
-
case 7:
|
|
867
|
-
body_26 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
868
|
-
"APIErrorResponse",
|
|
869
|
-
""]);
|
|
870
|
-
throw new exception_1.ApiException(429, body_26);
|
|
871
|
-
case 8:
|
|
872
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
873
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
874
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
875
|
-
return [4 /*yield*/, response.body.text()];
|
|
876
|
-
case 9:
|
|
877
|
-
body_27 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
796
|
+
body_15 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
878
797
|
"APIKeyResponse",
|
|
879
798
|
""]);
|
|
880
|
-
return [2 /*return*/,
|
|
881
|
-
case
|
|
882
|
-
case
|
|
883
|
-
body = (
|
|
799
|
+
return [2 /*return*/, body_15];
|
|
800
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
801
|
+
case 7:
|
|
802
|
+
body = (_l.sent()) || "";
|
|
884
803
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
885
804
|
}
|
|
886
805
|
});
|
|
@@ -895,73 +814,50 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
895
814
|
*/
|
|
896
815
|
KeyManagementApiResponseProcessor.prototype.getApplicationKey = function (response) {
|
|
897
816
|
return __awaiter(this, void 0, void 0, function () {
|
|
898
|
-
var contentType,
|
|
899
|
-
return __generator(this, function (
|
|
900
|
-
switch (
|
|
817
|
+
var contentType, body_16, _a, _b, _c, _d, bodyText, _e, _f, body_17, body_18, _g, _h, _j, _k, body;
|
|
818
|
+
return __generator(this, function (_l) {
|
|
819
|
+
switch (_l.label) {
|
|
901
820
|
case 0:
|
|
902
821
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
903
|
-
if (!(
|
|
822
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
904
823
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
905
824
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
906
825
|
return [4 /*yield*/, response.body.text()];
|
|
907
826
|
case 1:
|
|
908
|
-
|
|
909
|
-
"ApplicationKeyResponse"
|
|
910
|
-
|
|
911
|
-
return [2 /*return*/, body_28];
|
|
827
|
+
body_16 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
828
|
+
"ApplicationKeyResponse"]);
|
|
829
|
+
return [2 /*return*/, body_16];
|
|
912
830
|
case 2:
|
|
913
|
-
if (!(
|
|
914
|
-
|
|
915
|
-
|
|
831
|
+
if (!(response.httpStatusCode == 400 ||
|
|
832
|
+
response.httpStatusCode == 403 ||
|
|
833
|
+
response.httpStatusCode == 404 ||
|
|
834
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
835
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
916
836
|
return [4 /*yield*/, response.body.text()];
|
|
917
837
|
case 3:
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
""
|
|
921
|
-
|
|
838
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
839
|
+
try {
|
|
840
|
+
body_17 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
841
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_17);
|
|
842
|
+
}
|
|
843
|
+
catch (error) {
|
|
844
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
845
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
846
|
+
}
|
|
847
|
+
_l.label = 4;
|
|
922
848
|
case 4:
|
|
923
|
-
if (!(
|
|
924
|
-
|
|
925
|
-
|
|
849
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
850
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
851
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
926
852
|
return [4 /*yield*/, response.body.text()];
|
|
927
853
|
case 5:
|
|
928
|
-
|
|
929
|
-
"APIErrorResponse",
|
|
930
|
-
""]);
|
|
931
|
-
throw new exception_1.ApiException(403, body_30);
|
|
932
|
-
case 6:
|
|
933
|
-
if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
934
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
935
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
936
|
-
return [4 /*yield*/, response.body.text()];
|
|
937
|
-
case 7:
|
|
938
|
-
body_31 = _p.apply(_o, [_r.apply(_q, [_0.sent(), contentType]),
|
|
939
|
-
"APIErrorResponse",
|
|
940
|
-
""]);
|
|
941
|
-
throw new exception_1.ApiException(404, body_31);
|
|
942
|
-
case 8:
|
|
943
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 10];
|
|
944
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
945
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
946
|
-
return [4 /*yield*/, response.body.text()];
|
|
947
|
-
case 9:
|
|
948
|
-
body_32 = _t.apply(_s, [_v.apply(_u, [_0.sent(), contentType]),
|
|
949
|
-
"APIErrorResponse",
|
|
950
|
-
""]);
|
|
951
|
-
throw new exception_1.ApiException(429, body_32);
|
|
952
|
-
case 10:
|
|
953
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 12];
|
|
954
|
-
_x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
955
|
-
_z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
|
|
956
|
-
return [4 /*yield*/, response.body.text()];
|
|
957
|
-
case 11:
|
|
958
|
-
body_33 = _x.apply(_w, [_z.apply(_y, [_0.sent(), contentType]),
|
|
854
|
+
body_18 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
959
855
|
"ApplicationKeyResponse",
|
|
960
856
|
""]);
|
|
961
|
-
return [2 /*return*/,
|
|
962
|
-
case
|
|
963
|
-
case
|
|
964
|
-
body = (
|
|
857
|
+
return [2 /*return*/, body_18];
|
|
858
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
859
|
+
case 7:
|
|
860
|
+
body = (_l.sent()) || "";
|
|
965
861
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
966
862
|
}
|
|
967
863
|
});
|
|
@@ -976,63 +872,49 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
976
872
|
*/
|
|
977
873
|
KeyManagementApiResponseProcessor.prototype.getCurrentUserApplicationKey = function (response) {
|
|
978
874
|
return __awaiter(this, void 0, void 0, function () {
|
|
979
|
-
var contentType,
|
|
980
|
-
return __generator(this, function (
|
|
981
|
-
switch (
|
|
875
|
+
var contentType, body_19, _a, _b, _c, _d, bodyText, _e, _f, body_20, body_21, _g, _h, _j, _k, body;
|
|
876
|
+
return __generator(this, function (_l) {
|
|
877
|
+
switch (_l.label) {
|
|
982
878
|
case 0:
|
|
983
879
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
984
|
-
if (!(
|
|
880
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
985
881
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
986
882
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
987
883
|
return [4 /*yield*/, response.body.text()];
|
|
988
884
|
case 1:
|
|
989
|
-
|
|
990
|
-
"ApplicationKeyResponse"
|
|
991
|
-
|
|
992
|
-
return [2 /*return*/, body_34];
|
|
885
|
+
body_19 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
886
|
+
"ApplicationKeyResponse"]);
|
|
887
|
+
return [2 /*return*/, body_19];
|
|
993
888
|
case 2:
|
|
994
|
-
if (!(
|
|
995
|
-
|
|
996
|
-
|
|
889
|
+
if (!(response.httpStatusCode == 403 ||
|
|
890
|
+
response.httpStatusCode == 404 ||
|
|
891
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
892
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
997
893
|
return [4 /*yield*/, response.body.text()];
|
|
998
894
|
case 3:
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
""
|
|
1002
|
-
|
|
895
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
896
|
+
try {
|
|
897
|
+
body_20 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
898
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_20);
|
|
899
|
+
}
|
|
900
|
+
catch (error) {
|
|
901
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
902
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
903
|
+
}
|
|
904
|
+
_l.label = 4;
|
|
1003
905
|
case 4:
|
|
1004
|
-
if (!(
|
|
1005
|
-
|
|
1006
|
-
|
|
906
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
907
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
908
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1007
909
|
return [4 /*yield*/, response.body.text()];
|
|
1008
910
|
case 5:
|
|
1009
|
-
|
|
1010
|
-
"APIErrorResponse",
|
|
1011
|
-
""]);
|
|
1012
|
-
throw new exception_1.ApiException(404, body_36);
|
|
1013
|
-
case 6:
|
|
1014
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1015
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1016
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1017
|
-
return [4 /*yield*/, response.body.text()];
|
|
1018
|
-
case 7:
|
|
1019
|
-
body_37 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
1020
|
-
"APIErrorResponse",
|
|
1021
|
-
""]);
|
|
1022
|
-
throw new exception_1.ApiException(429, body_37);
|
|
1023
|
-
case 8:
|
|
1024
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
1025
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1026
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1027
|
-
return [4 /*yield*/, response.body.text()];
|
|
1028
|
-
case 9:
|
|
1029
|
-
body_38 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
911
|
+
body_21 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1030
912
|
"ApplicationKeyResponse",
|
|
1031
913
|
""]);
|
|
1032
|
-
return [2 /*return*/,
|
|
1033
|
-
case
|
|
1034
|
-
case
|
|
1035
|
-
body = (
|
|
914
|
+
return [2 /*return*/, body_21];
|
|
915
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
916
|
+
case 7:
|
|
917
|
+
body = (_l.sent()) || "";
|
|
1036
918
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1037
919
|
}
|
|
1038
920
|
});
|
|
@@ -1047,63 +929,49 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
1047
929
|
*/
|
|
1048
930
|
KeyManagementApiResponseProcessor.prototype.listAPIKeys = function (response) {
|
|
1049
931
|
return __awaiter(this, void 0, void 0, function () {
|
|
1050
|
-
var contentType,
|
|
1051
|
-
return __generator(this, function (
|
|
1052
|
-
switch (
|
|
932
|
+
var contentType, body_22, _a, _b, _c, _d, bodyText, _e, _f, body_23, body_24, _g, _h, _j, _k, body;
|
|
933
|
+
return __generator(this, function (_l) {
|
|
934
|
+
switch (_l.label) {
|
|
1053
935
|
case 0:
|
|
1054
936
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1055
|
-
if (!(
|
|
937
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1056
938
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1057
939
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1058
940
|
return [4 /*yield*/, response.body.text()];
|
|
1059
941
|
case 1:
|
|
1060
|
-
|
|
1061
|
-
"APIKeysResponse"
|
|
1062
|
-
|
|
1063
|
-
return [2 /*return*/, body_39];
|
|
942
|
+
body_22 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
943
|
+
"APIKeysResponse"]);
|
|
944
|
+
return [2 /*return*/, body_22];
|
|
1064
945
|
case 2:
|
|
1065
|
-
if (!(
|
|
1066
|
-
|
|
1067
|
-
|
|
946
|
+
if (!(response.httpStatusCode == 400 ||
|
|
947
|
+
response.httpStatusCode == 403 ||
|
|
948
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
949
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1068
950
|
return [4 /*yield*/, response.body.text()];
|
|
1069
951
|
case 3:
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
""
|
|
1073
|
-
|
|
952
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
953
|
+
try {
|
|
954
|
+
body_23 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
955
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_23);
|
|
956
|
+
}
|
|
957
|
+
catch (error) {
|
|
958
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
959
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
960
|
+
}
|
|
961
|
+
_l.label = 4;
|
|
1074
962
|
case 4:
|
|
1075
|
-
if (!(
|
|
1076
|
-
|
|
1077
|
-
|
|
963
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
964
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
965
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1078
966
|
return [4 /*yield*/, response.body.text()];
|
|
1079
967
|
case 5:
|
|
1080
|
-
|
|
1081
|
-
"APIErrorResponse",
|
|
1082
|
-
""]);
|
|
1083
|
-
throw new exception_1.ApiException(403, body_41);
|
|
1084
|
-
case 6:
|
|
1085
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1086
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1087
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1088
|
-
return [4 /*yield*/, response.body.text()];
|
|
1089
|
-
case 7:
|
|
1090
|
-
body_42 = _p.apply(_o, [_r.apply(_q, [_w.sent(), contentType]),
|
|
1091
|
-
"APIErrorResponse",
|
|
1092
|
-
""]);
|
|
1093
|
-
throw new exception_1.ApiException(429, body_42);
|
|
1094
|
-
case 8:
|
|
1095
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 10];
|
|
1096
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1097
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1098
|
-
return [4 /*yield*/, response.body.text()];
|
|
1099
|
-
case 9:
|
|
1100
|
-
body_43 = _t.apply(_s, [_v.apply(_u, [_w.sent(), contentType]),
|
|
968
|
+
body_24 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1101
969
|
"APIKeysResponse",
|
|
1102
970
|
""]);
|
|
1103
|
-
return [2 /*return*/,
|
|
1104
|
-
case
|
|
1105
|
-
case
|
|
1106
|
-
body = (
|
|
971
|
+
return [2 /*return*/, body_24];
|
|
972
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
973
|
+
case 7:
|
|
974
|
+
body = (_l.sent()) || "";
|
|
1107
975
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1108
976
|
}
|
|
1109
977
|
});
|
|
@@ -1118,73 +986,50 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
1118
986
|
*/
|
|
1119
987
|
KeyManagementApiResponseProcessor.prototype.listApplicationKeys = function (response) {
|
|
1120
988
|
return __awaiter(this, void 0, void 0, function () {
|
|
1121
|
-
var contentType,
|
|
1122
|
-
return __generator(this, function (
|
|
1123
|
-
switch (
|
|
989
|
+
var contentType, body_25, _a, _b, _c, _d, bodyText, _e, _f, body_26, body_27, _g, _h, _j, _k, body;
|
|
990
|
+
return __generator(this, function (_l) {
|
|
991
|
+
switch (_l.label) {
|
|
1124
992
|
case 0:
|
|
1125
993
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1126
|
-
if (!(
|
|
994
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1127
995
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1128
996
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1129
997
|
return [4 /*yield*/, response.body.text()];
|
|
1130
998
|
case 1:
|
|
1131
|
-
|
|
1132
|
-
"ListApplicationKeysResponse"
|
|
1133
|
-
|
|
1134
|
-
return [2 /*return*/, body_44];
|
|
999
|
+
body_25 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1000
|
+
"ListApplicationKeysResponse"]);
|
|
1001
|
+
return [2 /*return*/, body_25];
|
|
1135
1002
|
case 2:
|
|
1136
|
-
if (!(
|
|
1137
|
-
|
|
1138
|
-
|
|
1003
|
+
if (!(response.httpStatusCode == 400 ||
|
|
1004
|
+
response.httpStatusCode == 403 ||
|
|
1005
|
+
response.httpStatusCode == 404 ||
|
|
1006
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1007
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1139
1008
|
return [4 /*yield*/, response.body.text()];
|
|
1140
1009
|
case 3:
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
""
|
|
1144
|
-
|
|
1010
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1011
|
+
try {
|
|
1012
|
+
body_26 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1013
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_26);
|
|
1014
|
+
}
|
|
1015
|
+
catch (error) {
|
|
1016
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1017
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1018
|
+
}
|
|
1019
|
+
_l.label = 4;
|
|
1145
1020
|
case 4:
|
|
1146
|
-
if (!(
|
|
1147
|
-
|
|
1148
|
-
|
|
1021
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1022
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1023
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1149
1024
|
return [4 /*yield*/, response.body.text()];
|
|
1150
1025
|
case 5:
|
|
1151
|
-
|
|
1152
|
-
"APIErrorResponse",
|
|
1153
|
-
""]);
|
|
1154
|
-
throw new exception_1.ApiException(403, body_46);
|
|
1155
|
-
case 6:
|
|
1156
|
-
if (!(0, util_1.isCodeInRange)("404", 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_47 = _p.apply(_o, [_r.apply(_q, [_0.sent(), contentType]),
|
|
1162
|
-
"APIErrorResponse",
|
|
1163
|
-
""]);
|
|
1164
|
-
throw new exception_1.ApiException(404, body_47);
|
|
1165
|
-
case 8:
|
|
1166
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) 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_48 = _t.apply(_s, [_v.apply(_u, [_0.sent(), contentType]),
|
|
1172
|
-
"APIErrorResponse",
|
|
1173
|
-
""]);
|
|
1174
|
-
throw new exception_1.ApiException(429, body_48);
|
|
1175
|
-
case 10:
|
|
1176
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 12];
|
|
1177
|
-
_x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1178
|
-
_z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1179
|
-
return [4 /*yield*/, response.body.text()];
|
|
1180
|
-
case 11:
|
|
1181
|
-
body_49 = _x.apply(_w, [_z.apply(_y, [_0.sent(), contentType]),
|
|
1026
|
+
body_27 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1182
1027
|
"ListApplicationKeysResponse",
|
|
1183
1028
|
""]);
|
|
1184
|
-
return [2 /*return*/,
|
|
1185
|
-
case
|
|
1186
|
-
case
|
|
1187
|
-
body = (
|
|
1029
|
+
return [2 /*return*/, body_27];
|
|
1030
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1031
|
+
case 7:
|
|
1032
|
+
body = (_l.sent()) || "";
|
|
1188
1033
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1189
1034
|
}
|
|
1190
1035
|
});
|
|
@@ -1199,73 +1044,50 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
1199
1044
|
*/
|
|
1200
1045
|
KeyManagementApiResponseProcessor.prototype.listCurrentUserApplicationKeys = function (response) {
|
|
1201
1046
|
return __awaiter(this, void 0, void 0, function () {
|
|
1202
|
-
var contentType,
|
|
1203
|
-
return __generator(this, function (
|
|
1204
|
-
switch (
|
|
1047
|
+
var contentType, body_28, _a, _b, _c, _d, bodyText, _e, _f, body_29, body_30, _g, _h, _j, _k, body;
|
|
1048
|
+
return __generator(this, function (_l) {
|
|
1049
|
+
switch (_l.label) {
|
|
1205
1050
|
case 0:
|
|
1206
1051
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1207
|
-
if (!(
|
|
1052
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1208
1053
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1209
1054
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1210
1055
|
return [4 /*yield*/, response.body.text()];
|
|
1211
1056
|
case 1:
|
|
1212
|
-
|
|
1213
|
-
"ListApplicationKeysResponse"
|
|
1214
|
-
|
|
1215
|
-
return [2 /*return*/, body_50];
|
|
1057
|
+
body_28 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1058
|
+
"ListApplicationKeysResponse"]);
|
|
1059
|
+
return [2 /*return*/, body_28];
|
|
1216
1060
|
case 2:
|
|
1217
|
-
if (!(
|
|
1218
|
-
|
|
1219
|
-
|
|
1061
|
+
if (!(response.httpStatusCode == 400 ||
|
|
1062
|
+
response.httpStatusCode == 403 ||
|
|
1063
|
+
response.httpStatusCode == 404 ||
|
|
1064
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1065
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1220
1066
|
return [4 /*yield*/, response.body.text()];
|
|
1221
1067
|
case 3:
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
""
|
|
1225
|
-
|
|
1068
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1069
|
+
try {
|
|
1070
|
+
body_29 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1071
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_29);
|
|
1072
|
+
}
|
|
1073
|
+
catch (error) {
|
|
1074
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1075
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1076
|
+
}
|
|
1077
|
+
_l.label = 4;
|
|
1226
1078
|
case 4:
|
|
1227
|
-
if (!(
|
|
1228
|
-
|
|
1229
|
-
|
|
1079
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1080
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1081
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1230
1082
|
return [4 /*yield*/, response.body.text()];
|
|
1231
1083
|
case 5:
|
|
1232
|
-
|
|
1233
|
-
"APIErrorResponse",
|
|
1234
|
-
""]);
|
|
1235
|
-
throw new exception_1.ApiException(403, body_52);
|
|
1236
|
-
case 6:
|
|
1237
|
-
if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1238
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1239
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1240
|
-
return [4 /*yield*/, response.body.text()];
|
|
1241
|
-
case 7:
|
|
1242
|
-
body_53 = _p.apply(_o, [_r.apply(_q, [_0.sent(), contentType]),
|
|
1243
|
-
"APIErrorResponse",
|
|
1244
|
-
""]);
|
|
1245
|
-
throw new exception_1.ApiException(404, body_53);
|
|
1246
|
-
case 8:
|
|
1247
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 10];
|
|
1248
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1249
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1250
|
-
return [4 /*yield*/, response.body.text()];
|
|
1251
|
-
case 9:
|
|
1252
|
-
body_54 = _t.apply(_s, [_v.apply(_u, [_0.sent(), contentType]),
|
|
1253
|
-
"APIErrorResponse",
|
|
1254
|
-
""]);
|
|
1255
|
-
throw new exception_1.ApiException(429, body_54);
|
|
1256
|
-
case 10:
|
|
1257
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 12];
|
|
1258
|
-
_x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1259
|
-
_z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1260
|
-
return [4 /*yield*/, response.body.text()];
|
|
1261
|
-
case 11:
|
|
1262
|
-
body_55 = _x.apply(_w, [_z.apply(_y, [_0.sent(), contentType]),
|
|
1084
|
+
body_30 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1263
1085
|
"ListApplicationKeysResponse",
|
|
1264
1086
|
""]);
|
|
1265
|
-
return [2 /*return*/,
|
|
1266
|
-
case
|
|
1267
|
-
case
|
|
1268
|
-
body = (
|
|
1087
|
+
return [2 /*return*/, body_30];
|
|
1088
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1089
|
+
case 7:
|
|
1090
|
+
body = (_l.sent()) || "";
|
|
1269
1091
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1270
1092
|
}
|
|
1271
1093
|
});
|
|
@@ -1280,73 +1102,50 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
1280
1102
|
*/
|
|
1281
1103
|
KeyManagementApiResponseProcessor.prototype.updateAPIKey = function (response) {
|
|
1282
1104
|
return __awaiter(this, void 0, void 0, function () {
|
|
1283
|
-
var contentType,
|
|
1284
|
-
return __generator(this, function (
|
|
1285
|
-
switch (
|
|
1105
|
+
var contentType, body_31, _a, _b, _c, _d, bodyText, _e, _f, body_32, body_33, _g, _h, _j, _k, body;
|
|
1106
|
+
return __generator(this, function (_l) {
|
|
1107
|
+
switch (_l.label) {
|
|
1286
1108
|
case 0:
|
|
1287
1109
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1288
|
-
if (!(
|
|
1110
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1289
1111
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1290
1112
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1291
1113
|
return [4 /*yield*/, response.body.text()];
|
|
1292
1114
|
case 1:
|
|
1293
|
-
|
|
1294
|
-
"APIKeyResponse"
|
|
1295
|
-
|
|
1296
|
-
return [2 /*return*/, body_56];
|
|
1115
|
+
body_31 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1116
|
+
"APIKeyResponse"]);
|
|
1117
|
+
return [2 /*return*/, body_31];
|
|
1297
1118
|
case 2:
|
|
1298
|
-
if (!(
|
|
1299
|
-
|
|
1300
|
-
|
|
1119
|
+
if (!(response.httpStatusCode == 400 ||
|
|
1120
|
+
response.httpStatusCode == 403 ||
|
|
1121
|
+
response.httpStatusCode == 404 ||
|
|
1122
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1123
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1301
1124
|
return [4 /*yield*/, response.body.text()];
|
|
1302
1125
|
case 3:
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
""
|
|
1306
|
-
|
|
1126
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1127
|
+
try {
|
|
1128
|
+
body_32 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1129
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_32);
|
|
1130
|
+
}
|
|
1131
|
+
catch (error) {
|
|
1132
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1133
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1134
|
+
}
|
|
1135
|
+
_l.label = 4;
|
|
1307
1136
|
case 4:
|
|
1308
|
-
if (!(
|
|
1309
|
-
|
|
1310
|
-
|
|
1137
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1138
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1139
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1311
1140
|
return [4 /*yield*/, response.body.text()];
|
|
1312
1141
|
case 5:
|
|
1313
|
-
|
|
1314
|
-
"APIErrorResponse",
|
|
1315
|
-
""]);
|
|
1316
|
-
throw new exception_1.ApiException(403, body_58);
|
|
1317
|
-
case 6:
|
|
1318
|
-
if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1319
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1320
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1321
|
-
return [4 /*yield*/, response.body.text()];
|
|
1322
|
-
case 7:
|
|
1323
|
-
body_59 = _p.apply(_o, [_r.apply(_q, [_0.sent(), contentType]),
|
|
1324
|
-
"APIErrorResponse",
|
|
1325
|
-
""]);
|
|
1326
|
-
throw new exception_1.ApiException(404, body_59);
|
|
1327
|
-
case 8:
|
|
1328
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 10];
|
|
1329
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1330
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1331
|
-
return [4 /*yield*/, response.body.text()];
|
|
1332
|
-
case 9:
|
|
1333
|
-
body_60 = _t.apply(_s, [_v.apply(_u, [_0.sent(), contentType]),
|
|
1334
|
-
"APIErrorResponse",
|
|
1335
|
-
""]);
|
|
1336
|
-
throw new exception_1.ApiException(429, body_60);
|
|
1337
|
-
case 10:
|
|
1338
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 12];
|
|
1339
|
-
_x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1340
|
-
_z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1341
|
-
return [4 /*yield*/, response.body.text()];
|
|
1342
|
-
case 11:
|
|
1343
|
-
body_61 = _x.apply(_w, [_z.apply(_y, [_0.sent(), contentType]),
|
|
1142
|
+
body_33 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1344
1143
|
"APIKeyResponse",
|
|
1345
1144
|
""]);
|
|
1346
|
-
return [2 /*return*/,
|
|
1347
|
-
case
|
|
1348
|
-
case
|
|
1349
|
-
body = (
|
|
1145
|
+
return [2 /*return*/, body_33];
|
|
1146
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1147
|
+
case 7:
|
|
1148
|
+
body = (_l.sent()) || "";
|
|
1350
1149
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1351
1150
|
}
|
|
1352
1151
|
});
|
|
@@ -1361,73 +1160,50 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
1361
1160
|
*/
|
|
1362
1161
|
KeyManagementApiResponseProcessor.prototype.updateApplicationKey = function (response) {
|
|
1363
1162
|
return __awaiter(this, void 0, void 0, function () {
|
|
1364
|
-
var contentType,
|
|
1365
|
-
return __generator(this, function (
|
|
1366
|
-
switch (
|
|
1163
|
+
var contentType, body_34, _a, _b, _c, _d, bodyText, _e, _f, body_35, body_36, _g, _h, _j, _k, body;
|
|
1164
|
+
return __generator(this, function (_l) {
|
|
1165
|
+
switch (_l.label) {
|
|
1367
1166
|
case 0:
|
|
1368
1167
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1369
|
-
if (!(
|
|
1168
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1370
1169
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1371
1170
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1372
1171
|
return [4 /*yield*/, response.body.text()];
|
|
1373
1172
|
case 1:
|
|
1374
|
-
|
|
1375
|
-
"ApplicationKeyResponse"
|
|
1376
|
-
|
|
1377
|
-
return [2 /*return*/, body_62];
|
|
1173
|
+
body_34 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1174
|
+
"ApplicationKeyResponse"]);
|
|
1175
|
+
return [2 /*return*/, body_34];
|
|
1378
1176
|
case 2:
|
|
1379
|
-
if (!(
|
|
1380
|
-
|
|
1381
|
-
|
|
1177
|
+
if (!(response.httpStatusCode == 400 ||
|
|
1178
|
+
response.httpStatusCode == 403 ||
|
|
1179
|
+
response.httpStatusCode == 404 ||
|
|
1180
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1181
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1382
1182
|
return [4 /*yield*/, response.body.text()];
|
|
1383
1183
|
case 3:
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
""
|
|
1387
|
-
|
|
1184
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1185
|
+
try {
|
|
1186
|
+
body_35 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1187
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_35);
|
|
1188
|
+
}
|
|
1189
|
+
catch (error) {
|
|
1190
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1191
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1192
|
+
}
|
|
1193
|
+
_l.label = 4;
|
|
1388
1194
|
case 4:
|
|
1389
|
-
if (!(
|
|
1390
|
-
|
|
1391
|
-
|
|
1195
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1196
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1197
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1392
1198
|
return [4 /*yield*/, response.body.text()];
|
|
1393
1199
|
case 5:
|
|
1394
|
-
|
|
1395
|
-
"APIErrorResponse",
|
|
1396
|
-
""]);
|
|
1397
|
-
throw new exception_1.ApiException(403, body_64);
|
|
1398
|
-
case 6:
|
|
1399
|
-
if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1400
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1401
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1402
|
-
return [4 /*yield*/, response.body.text()];
|
|
1403
|
-
case 7:
|
|
1404
|
-
body_65 = _p.apply(_o, [_r.apply(_q, [_0.sent(), contentType]),
|
|
1405
|
-
"APIErrorResponse",
|
|
1406
|
-
""]);
|
|
1407
|
-
throw new exception_1.ApiException(404, body_65);
|
|
1408
|
-
case 8:
|
|
1409
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 10];
|
|
1410
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1411
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1412
|
-
return [4 /*yield*/, response.body.text()];
|
|
1413
|
-
case 9:
|
|
1414
|
-
body_66 = _t.apply(_s, [_v.apply(_u, [_0.sent(), contentType]),
|
|
1415
|
-
"APIErrorResponse",
|
|
1416
|
-
""]);
|
|
1417
|
-
throw new exception_1.ApiException(429, body_66);
|
|
1418
|
-
case 10:
|
|
1419
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 12];
|
|
1420
|
-
_x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1421
|
-
_z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1422
|
-
return [4 /*yield*/, response.body.text()];
|
|
1423
|
-
case 11:
|
|
1424
|
-
body_67 = _x.apply(_w, [_z.apply(_y, [_0.sent(), contentType]),
|
|
1200
|
+
body_36 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1425
1201
|
"ApplicationKeyResponse",
|
|
1426
1202
|
""]);
|
|
1427
|
-
return [2 /*return*/,
|
|
1428
|
-
case
|
|
1429
|
-
case
|
|
1430
|
-
body = (
|
|
1203
|
+
return [2 /*return*/, body_36];
|
|
1204
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1205
|
+
case 7:
|
|
1206
|
+
body = (_l.sent()) || "";
|
|
1431
1207
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1432
1208
|
}
|
|
1433
1209
|
});
|
|
@@ -1442,73 +1218,50 @@ var KeyManagementApiResponseProcessor = /** @class */ (function () {
|
|
|
1442
1218
|
*/
|
|
1443
1219
|
KeyManagementApiResponseProcessor.prototype.updateCurrentUserApplicationKey = function (response) {
|
|
1444
1220
|
return __awaiter(this, void 0, void 0, function () {
|
|
1445
|
-
var contentType,
|
|
1446
|
-
return __generator(this, function (
|
|
1447
|
-
switch (
|
|
1221
|
+
var contentType, body_37, _a, _b, _c, _d, bodyText, _e, _f, body_38, body_39, _g, _h, _j, _k, body;
|
|
1222
|
+
return __generator(this, function (_l) {
|
|
1223
|
+
switch (_l.label) {
|
|
1448
1224
|
case 0:
|
|
1449
1225
|
contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers["content-type"]);
|
|
1450
|
-
if (!(
|
|
1226
|
+
if (!(response.httpStatusCode == 200)) return [3 /*break*/, 2];
|
|
1451
1227
|
_b = (_a = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1452
1228
|
_d = (_c = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1453
1229
|
return [4 /*yield*/, response.body.text()];
|
|
1454
1230
|
case 1:
|
|
1455
|
-
|
|
1456
|
-
"ApplicationKeyResponse"
|
|
1457
|
-
|
|
1458
|
-
return [2 /*return*/, body_68];
|
|
1231
|
+
body_37 = _b.apply(_a, [_d.apply(_c, [_l.sent(), contentType]),
|
|
1232
|
+
"ApplicationKeyResponse"]);
|
|
1233
|
+
return [2 /*return*/, body_37];
|
|
1459
1234
|
case 2:
|
|
1460
|
-
if (!(
|
|
1461
|
-
|
|
1462
|
-
|
|
1235
|
+
if (!(response.httpStatusCode == 400 ||
|
|
1236
|
+
response.httpStatusCode == 403 ||
|
|
1237
|
+
response.httpStatusCode == 404 ||
|
|
1238
|
+
response.httpStatusCode == 429)) return [3 /*break*/, 4];
|
|
1239
|
+
_f = (_e = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1463
1240
|
return [4 /*yield*/, response.body.text()];
|
|
1464
1241
|
case 3:
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
""
|
|
1468
|
-
|
|
1242
|
+
bodyText = _f.apply(_e, [_l.sent(), contentType]);
|
|
1243
|
+
try {
|
|
1244
|
+
body_38 = ObjectSerializer_1.ObjectSerializer.deserialize(bodyText, "APIErrorResponse");
|
|
1245
|
+
throw new exception_1.ApiException(response.httpStatusCode, body_38);
|
|
1246
|
+
}
|
|
1247
|
+
catch (error) {
|
|
1248
|
+
logger_1.logger.info("Got error deserializing error: ".concat(error));
|
|
1249
|
+
throw new exception_1.ApiException(response.httpStatusCode, bodyText);
|
|
1250
|
+
}
|
|
1251
|
+
_l.label = 4;
|
|
1469
1252
|
case 4:
|
|
1470
|
-
if (!(
|
|
1471
|
-
|
|
1472
|
-
|
|
1253
|
+
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 6];
|
|
1254
|
+
_h = (_g = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1255
|
+
_k = (_j = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1473
1256
|
return [4 /*yield*/, response.body.text()];
|
|
1474
1257
|
case 5:
|
|
1475
|
-
|
|
1476
|
-
"APIErrorResponse",
|
|
1477
|
-
""]);
|
|
1478
|
-
throw new exception_1.ApiException(403, body_70);
|
|
1479
|
-
case 6:
|
|
1480
|
-
if (!(0, util_1.isCodeInRange)("404", response.httpStatusCode)) return [3 /*break*/, 8];
|
|
1481
|
-
_p = (_o = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1482
|
-
_r = (_q = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1483
|
-
return [4 /*yield*/, response.body.text()];
|
|
1484
|
-
case 7:
|
|
1485
|
-
body_71 = _p.apply(_o, [_r.apply(_q, [_0.sent(), contentType]),
|
|
1486
|
-
"APIErrorResponse",
|
|
1487
|
-
""]);
|
|
1488
|
-
throw new exception_1.ApiException(404, body_71);
|
|
1489
|
-
case 8:
|
|
1490
|
-
if (!(0, util_1.isCodeInRange)("429", response.httpStatusCode)) return [3 /*break*/, 10];
|
|
1491
|
-
_t = (_s = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1492
|
-
_v = (_u = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1493
|
-
return [4 /*yield*/, response.body.text()];
|
|
1494
|
-
case 9:
|
|
1495
|
-
body_72 = _t.apply(_s, [_v.apply(_u, [_0.sent(), contentType]),
|
|
1496
|
-
"APIErrorResponse",
|
|
1497
|
-
""]);
|
|
1498
|
-
throw new exception_1.ApiException(429, body_72);
|
|
1499
|
-
case 10:
|
|
1500
|
-
if (!(response.httpStatusCode >= 200 && response.httpStatusCode <= 299)) return [3 /*break*/, 12];
|
|
1501
|
-
_x = (_w = ObjectSerializer_1.ObjectSerializer).deserialize;
|
|
1502
|
-
_z = (_y = ObjectSerializer_1.ObjectSerializer).parse;
|
|
1503
|
-
return [4 /*yield*/, response.body.text()];
|
|
1504
|
-
case 11:
|
|
1505
|
-
body_73 = _x.apply(_w, [_z.apply(_y, [_0.sent(), contentType]),
|
|
1258
|
+
body_39 = _h.apply(_g, [_k.apply(_j, [_l.sent(), contentType]),
|
|
1506
1259
|
"ApplicationKeyResponse",
|
|
1507
1260
|
""]);
|
|
1508
|
-
return [2 /*return*/,
|
|
1509
|
-
case
|
|
1510
|
-
case
|
|
1511
|
-
body = (
|
|
1261
|
+
return [2 /*return*/, body_39];
|
|
1262
|
+
case 6: return [4 /*yield*/, response.body.text()];
|
|
1263
|
+
case 7:
|
|
1264
|
+
body = (_l.sent()) || "";
|
|
1512
1265
|
throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!\nBody: "' + body + '"');
|
|
1513
1266
|
}
|
|
1514
1267
|
});
|