diff --git a/clients/client-accessanalyzer/src/protocols/Aws_restJson1.ts b/clients/client-accessanalyzer/src/protocols/Aws_restJson1.ts index 32c8fc4e8bda..cc4c15ae1c2c 100644 --- a/clients/client-accessanalyzer/src/protocols/Aws_restJson1.ts +++ b/clients/client-accessanalyzer/src/protocols/Aws_restJson1.ts @@ -365,7 +365,7 @@ export const serializeAws_restJson1GetAccessPreviewCommand = async ( false ); const query: any = map({ - analyzerArn: [, input.analyzerArn!], + analyzerArn: [, __expectNonNull(input.analyzerArn!, `analyzerArn`)], }); let body: any; return new __HttpRequest({ @@ -388,8 +388,8 @@ export const serializeAws_restJson1GetAnalyzedResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/analyzed-resource"; const query: any = map({ - analyzerArn: [, input.analyzerArn!], - resourceArn: [, input.resourceArn!], + analyzerArn: [, __expectNonNull(input.analyzerArn!, `analyzerArn`)], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; return new __HttpRequest({ @@ -470,7 +470,7 @@ export const serializeAws_restJson1GetFindingCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/finding/{id}"; resolvedPath = __resolvedPath(resolvedPath, input, "id", () => input.id!, "{id}", false); const query: any = map({ - analyzerArn: [, input.analyzerArn!], + analyzerArn: [, __expectNonNull(input.analyzerArn!, `analyzerArn`)], }); let body: any; return new __HttpRequest({ @@ -561,7 +561,7 @@ export const serializeAws_restJson1ListAccessPreviewsCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/access-preview"; const query: any = map({ - analyzerArn: [, input.analyzerArn!], + analyzerArn: [, __expectNonNull(input.analyzerArn!, `analyzerArn`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -826,7 +826,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-amp/src/protocols/Aws_restJson1.ts b/clients/client-amp/src/protocols/Aws_restJson1.ts index 1022f23f7352..16f7c1bd2947 100644 --- a/clients/client-amp/src/protocols/Aws_restJson1.ts +++ b/clients/client-amp/src/protocols/Aws_restJson1.ts @@ -573,7 +573,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-amplify/src/protocols/Aws_restJson1.ts b/clients/client-amplify/src/protocols/Aws_restJson1.ts index f1510b053737..bd29d2e8a99a 100644 --- a/clients/client-amplify/src/protocols/Aws_restJson1.ts +++ b/clients/client-amplify/src/protocols/Aws_restJson1.ts @@ -967,7 +967,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-api-gateway/src/protocols/Aws_restJson1.ts b/clients/client-api-gateway/src/protocols/Aws_restJson1.ts index 45110018b139..4110a49b4b24 100644 --- a/clients/client-api-gateway/src/protocols/Aws_restJson1.ts +++ b/clients/client-api-gateway/src/protocols/Aws_restJson1.ts @@ -2393,8 +2393,8 @@ export const serializeAws_restJson1GetUsageCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "usagePlanId", () => input.usagePlanId!, "{usagePlanId}", false); const query: any = map({ keyId: [, input.keyId!], - startDate: [, input.startDate!], - endDate: [, input.endDate!], + startDate: [, __expectNonNull(input.startDate!, `startDate`)], + endDate: [, __expectNonNull(input.endDate!, `endDate`)], position: [, input.position!], limit: [() => input.limit !== void 0, () => input.limit!.toString()], }); @@ -2561,7 +2561,7 @@ export const serializeAws_restJson1ImportApiKeysCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/apikeys"; const query: any = map({ mode: [, "import"], - format: [, input.format!], + format: [, __expectNonNull(input.format!, `format`)], failonwarnings: [() => input.failOnWarnings !== void 0, () => input.failOnWarnings!.toString()], }); let body: any; @@ -2993,7 +2993,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-apigatewayv2/src/protocols/Aws_restJson1.ts b/clients/client-apigatewayv2/src/protocols/Aws_restJson1.ts index 27529487daaf..b4153836682e 100644 --- a/clients/client-apigatewayv2/src/protocols/Aws_restJson1.ts +++ b/clients/client-apigatewayv2/src/protocols/Aws_restJson1.ts @@ -1041,7 +1041,7 @@ export const serializeAws_restJson1ExportApiCommand = async ( const query: any = map({ exportVersion: [, input.ExportVersion!], includeExtensions: [() => input.IncludeExtensions !== void 0, () => input.IncludeExtensions!.toString()], - outputType: [, input.OutputType!], + outputType: [, __expectNonNull(input.OutputType!, `OutputType`)], stageName: [, input.StageName!], }); let body: any; @@ -1846,7 +1846,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v2/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-app-mesh/src/protocols/Aws_restJson1.ts b/clients/client-app-mesh/src/protocols/Aws_restJson1.ts index e3b46744a22a..cbe9f5c9f3ae 100644 --- a/clients/client-app-mesh/src/protocols/Aws_restJson1.ts +++ b/clients/client-app-mesh/src/protocols/Aws_restJson1.ts @@ -1092,7 +1092,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v20190125/tags"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], nextToken: [, input.nextToken!], limit: [() => input.limit !== void 0, () => input.limit!.toString()], }); @@ -1230,7 +1230,7 @@ export const serializeAws_restJson1TagResourceCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v20190125/tag"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; body = JSON.stringify({ @@ -1258,7 +1258,7 @@ export const serializeAws_restJson1UntagResourceCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v20190125/untag"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; body = JSON.stringify({ diff --git a/clients/client-appconfig/src/protocols/Aws_restJson1.ts b/clients/client-appconfig/src/protocols/Aws_restJson1.ts index 8aa09a6b37fa..eb0899d77b1f 100644 --- a/clients/client-appconfig/src/protocols/Aws_restJson1.ts +++ b/clients/client-appconfig/src/protocols/Aws_restJson1.ts @@ -686,7 +686,7 @@ export const serializeAws_restJson1GetConfigurationCommand = async ( false ); const query: any = map({ - client_id: [, input.ClientId!], + client_id: [, __expectNonNull(input.ClientId!, `ClientId`)], client_configuration_version: [, input.ClientConfigurationVersion!], }); let body: any; @@ -1357,7 +1357,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ @@ -1631,7 +1634,7 @@ export const serializeAws_restJson1ValidateConfigurationCommand = async ( false ); const query: any = map({ - configuration_version: [, input.ConfigurationVersion!], + configuration_version: [, __expectNonNull(input.ConfigurationVersion!, `ConfigurationVersion`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-appconfigdata/src/protocols/Aws_restJson1.ts b/clients/client-appconfigdata/src/protocols/Aws_restJson1.ts index 30cecdb2e4c1..6d4edb5129b4 100644 --- a/clients/client-appconfigdata/src/protocols/Aws_restJson1.ts +++ b/clients/client-appconfigdata/src/protocols/Aws_restJson1.ts @@ -43,7 +43,7 @@ export const serializeAws_restJson1GetLatestConfigurationCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/configuration"; const query: any = map({ - configuration_token: [, input.ConfigurationToken!], + configuration_token: [, __expectNonNull(input.ConfigurationToken!, `ConfigurationToken`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-appflow/src/protocols/Aws_restJson1.ts b/clients/client-appflow/src/protocols/Aws_restJson1.ts index cecf4464fcbe..0e815ee413dd 100644 --- a/clients/client-appflow/src/protocols/Aws_restJson1.ts +++ b/clients/client-appflow/src/protocols/Aws_restJson1.ts @@ -768,7 +768,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-appintegrations/src/protocols/Aws_restJson1.ts b/clients/client-appintegrations/src/protocols/Aws_restJson1.ts index eb6fd5ceac2f..056470633a00 100644 --- a/clients/client-appintegrations/src/protocols/Aws_restJson1.ts +++ b/clients/client-appintegrations/src/protocols/Aws_restJson1.ts @@ -408,7 +408,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-appsync/src/protocols/Aws_restJson1.ts b/clients/client-appsync/src/protocols/Aws_restJson1.ts index bd16d016fed5..09e8ff513a99 100644 --- a/clients/client-appsync/src/protocols/Aws_restJson1.ts +++ b/clients/client-appsync/src/protocols/Aws_restJson1.ts @@ -854,7 +854,7 @@ export const serializeAws_restJson1GetIntrospectionSchemaCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/apis/{apiId}/schema"; resolvedPath = __resolvedPath(resolvedPath, input, "apiId", () => input.apiId!, "{apiId}", false); const query: any = map({ - format: [, input.format!], + format: [, __expectNonNull(input.format!, `format`)], includeDirectives: [() => input.includeDirectives !== void 0, () => input.includeDirectives!.toString()], }); let body: any; @@ -926,7 +926,7 @@ export const serializeAws_restJson1GetTypeCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "apiId", () => input.apiId!, "{apiId}", false); resolvedPath = __resolvedPath(resolvedPath, input, "typeName", () => input.typeName!, "{typeName}", false); const query: any = map({ - format: [, input.format!], + format: [, __expectNonNull(input.format!, `format`)], }); let body: any; return new __HttpRequest({ @@ -1151,7 +1151,7 @@ export const serializeAws_restJson1ListTypesCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/apis/{apiId}/types"; resolvedPath = __resolvedPath(resolvedPath, input, "apiId", () => input.apiId!, "{apiId}", false); const query: any = map({ - format: [, input.format!], + format: [, __expectNonNull(input.format!, `format`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -1228,7 +1228,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-auditmanager/src/protocols/Aws_restJson1.ts b/clients/client-auditmanager/src/protocols/Aws_restJson1.ts index 711938cea7e4..19f25f0842e4 100644 --- a/clients/client-auditmanager/src/protocols/Aws_restJson1.ts +++ b/clients/client-auditmanager/src/protocols/Aws_restJson1.ts @@ -664,7 +664,7 @@ export const serializeAws_restJson1DeleteAssessmentFrameworkShareCommand = async "/assessmentFrameworkShareRequests/{requestId}"; resolvedPath = __resolvedPath(resolvedPath, input, "requestId", () => input.requestId!, "{requestId}", false); const query: any = map({ - requestType: [, input.requestType!], + requestType: [, __expectNonNull(input.requestType!, `requestType`)], }); let body: any; return new __HttpRequest({ @@ -1348,8 +1348,8 @@ export const serializeAws_restJson1ListAssessmentControlInsightsByControlDomainC const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/insights/controls-by-assessment"; const query: any = map({ - controlDomainId: [, input.controlDomainId!], - assessmentId: [, input.assessmentId!], + controlDomainId: [, __expectNonNull(input.controlDomainId!, `controlDomainId`)], + assessmentId: [, __expectNonNull(input.assessmentId!, `assessmentId`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -1374,7 +1374,7 @@ export const serializeAws_restJson1ListAssessmentFrameworksCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/assessmentFrameworks"; const query: any = map({ - frameworkType: [, input.frameworkType!], + frameworkType: [, __expectNonNull(input.frameworkType!, `frameworkType`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -1400,7 +1400,7 @@ export const serializeAws_restJson1ListAssessmentFrameworkShareRequestsCommand = const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/assessmentFrameworkShareRequests"; const query: any = map({ - requestType: [, input.requestType!], + requestType: [, __expectNonNull(input.requestType!, `requestType`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -1500,7 +1500,7 @@ export const serializeAws_restJson1ListControlDomainInsightsByAssessmentCommand const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/insights/control-domains-by-assessment"; const query: any = map({ - assessmentId: [, input.assessmentId!], + assessmentId: [, __expectNonNull(input.assessmentId!, `assessmentId`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -1525,7 +1525,7 @@ export const serializeAws_restJson1ListControlInsightsByControlDomainCommand = a const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/insights/controls"; const query: any = map({ - controlDomainId: [, input.controlDomainId!], + controlDomainId: [, __expectNonNull(input.controlDomainId!, `controlDomainId`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -1550,7 +1550,7 @@ export const serializeAws_restJson1ListControlsCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/controls"; const query: any = map({ - controlType: [, input.controlType!], + controlType: [, __expectNonNull(input.controlType!, `controlType`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -1575,7 +1575,7 @@ export const serializeAws_restJson1ListKeywordsForDataSourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/dataSourceKeywords"; const query: any = map({ - source: [, input.source!], + source: [, __expectNonNull(input.source!, `source`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -1750,7 +1750,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-backupstorage/src/protocols/Aws_restJson1.ts b/clients/client-backupstorage/src/protocols/Aws_restJson1.ts index 85a686826aca..e8ab9825e376 100644 --- a/clients/client-backupstorage/src/protocols/Aws_restJson1.ts +++ b/clients/client-backupstorage/src/protocols/Aws_restJson1.ts @@ -223,8 +223,8 @@ export const serializeAws_restJson1NotifyObjectCompleteCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "BackupJobId", () => input.BackupJobId!, "{BackupJobId}", false); resolvedPath = __resolvedPath(resolvedPath, input, "UploadId", () => input.UploadId!, "{UploadId}", false); const query: any = map({ - checksum: [, input.ObjectChecksum!], - "checksum-algorithm": [, input.ObjectChecksumAlgorithm!], + checksum: [, __expectNonNull(input.ObjectChecksum!, `ObjectChecksum`)], + "checksum-algorithm": [, __expectNonNull(input.ObjectChecksumAlgorithm!, `ObjectChecksumAlgorithm`)], "metadata-string": [, input.MetadataString!], "metadata-blob-length": [() => input.MetadataBlobLength !== void 0, () => input.MetadataBlobLength!.toString()], "metadata-checksum": [, input.MetadataBlobChecksum!], @@ -269,9 +269,9 @@ export const serializeAws_restJson1PutChunkCommand = async ( false ); const query: any = map({ - length: [() => input.Length !== void 0, () => input.Length!.toString()], - checksum: [, input.Checksum!], - "checksum-algorithm": [, input.ChecksumAlgorithm!], + length: [__expectNonNull(input.Length, `Length`) != null, () => input.Length!.toString()], + checksum: [, __expectNonNull(input.Checksum!, `Checksum`)], + "checksum-algorithm": [, __expectNonNull(input.ChecksumAlgorithm!, `ChecksumAlgorithm`)], }); let body: any; if (input.Data !== undefined) { diff --git a/clients/client-batch/src/protocols/Aws_restJson1.ts b/clients/client-batch/src/protocols/Aws_restJson1.ts index a05e320c93b1..bbb2c6c3eebe 100644 --- a/clients/client-batch/src/protocols/Aws_restJson1.ts +++ b/clients/client-batch/src/protocols/Aws_restJson1.ts @@ -747,7 +747,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-billingconductor/src/protocols/Aws_restJson1.ts b/clients/client-billingconductor/src/protocols/Aws_restJson1.ts index dc04236fc167..20a154df1abe 100644 --- a/clients/client-billingconductor/src/protocols/Aws_restJson1.ts +++ b/clients/client-billingconductor/src/protocols/Aws_restJson1.ts @@ -887,7 +887,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-braket/src/protocols/Aws_restJson1.ts b/clients/client-braket/src/protocols/Aws_restJson1.ts index 9f0713fccae3..ca6f949ad2fe 100644 --- a/clients/client-braket/src/protocols/Aws_restJson1.ts +++ b/clients/client-braket/src/protocols/Aws_restJson1.ts @@ -406,7 +406,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-chime-sdk-identity/src/protocols/Aws_restJson1.ts b/clients/client-chime-sdk-identity/src/protocols/Aws_restJson1.ts index dcc50406b039..9ad476ccd93d 100644 --- a/clients/client-chime-sdk-identity/src/protocols/Aws_restJson1.ts +++ b/clients/client-chime-sdk-identity/src/protocols/Aws_restJson1.ts @@ -587,7 +587,7 @@ export const serializeAws_restJson1ListAppInstanceUsersCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/app-instance-users"; const query: any = map({ - "app-instance-arn": [, input.AppInstanceArn!], + "app-instance-arn": [, __expectNonNull(input.AppInstanceArn!, `AppInstanceArn`)], "max-results": [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], "next-token": [, input.NextToken!], }); @@ -612,7 +612,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - arn: [, input.ResourceARN!], + arn: [, __expectNonNull(input.ResourceARN!, `ResourceARN`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-chime-sdk-media-pipelines/src/protocols/Aws_restJson1.ts b/clients/client-chime-sdk-media-pipelines/src/protocols/Aws_restJson1.ts index c265d23066e6..f988b1d3c265 100644 --- a/clients/client-chime-sdk-media-pipelines/src/protocols/Aws_restJson1.ts +++ b/clients/client-chime-sdk-media-pipelines/src/protocols/Aws_restJson1.ts @@ -363,7 +363,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - arn: [, input.ResourceARN!], + arn: [, __expectNonNull(input.ResourceARN!, `ResourceARN`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-chime-sdk-meetings/src/protocols/Aws_restJson1.ts b/clients/client-chime-sdk-meetings/src/protocols/Aws_restJson1.ts index d6cbac047091..cd5a613a11f7 100644 --- a/clients/client-chime-sdk-meetings/src/protocols/Aws_restJson1.ts +++ b/clients/client-chime-sdk-meetings/src/protocols/Aws_restJson1.ts @@ -386,7 +386,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - arn: [, input.ResourceARN!], + arn: [, __expectNonNull(input.ResourceARN!, `ResourceARN`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-chime-sdk-messaging/src/protocols/Aws_restJson1.ts b/clients/client-chime-sdk-messaging/src/protocols/Aws_restJson1.ts index f23b2a46cb7b..301e47d86a6c 100644 --- a/clients/client-chime-sdk-messaging/src/protocols/Aws_restJson1.ts +++ b/clients/client-chime-sdk-messaging/src/protocols/Aws_restJson1.ts @@ -727,7 +727,7 @@ export const serializeAws_restJson1DescribeChannelMembershipForAppInstanceUserCo resolvedPath = __resolvedPath(resolvedPath, input, "ChannelArn", () => input.ChannelArn!, "{ChannelArn}", false); const query: any = map({ scope: [, "app-instance-user-membership"], - "app-instance-user-arn": [, input.AppInstanceUserArn!], + "app-instance-user-arn": [, __expectNonNull(input.AppInstanceUserArn!, `AppInstanceUserArn`)], }); let body: any; return new __HttpRequest({ @@ -754,7 +754,7 @@ export const serializeAws_restJson1DescribeChannelModeratedByAppInstanceUserComm resolvedPath = __resolvedPath(resolvedPath, input, "ChannelArn", () => input.ChannelArn!, "{ChannelArn}", false); const query: any = map({ scope: [, "app-instance-user-moderated-channel"], - "app-instance-user-arn": [, input.AppInstanceUserArn!], + "app-instance-user-arn": [, __expectNonNull(input.AppInstanceUserArn!, `AppInstanceUserArn`)], }); let body: any; return new __HttpRequest({ @@ -976,7 +976,7 @@ export const serializeAws_restJson1ListChannelFlowsCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/channel-flows"; const query: any = map({ - "app-instance-arn": [, input.AppInstanceArn!], + "app-instance-arn": [, __expectNonNull(input.AppInstanceArn!, `AppInstanceArn`)], "max-results": [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], "next-token": [, input.NextToken!], }); @@ -1127,7 +1127,7 @@ export const serializeAws_restJson1ListChannelsCommand = async ( }); const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/channels"; const query: any = map({ - "app-instance-arn": [, input.AppInstanceArn!], + "app-instance-arn": [, __expectNonNull(input.AppInstanceArn!, `AppInstanceArn`)], privacy: [, input.Privacy!], "max-results": [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], "next-token": [, input.NextToken!], @@ -1154,7 +1154,7 @@ export const serializeAws_restJson1ListChannelsAssociatedWithChannelFlowCommand const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/channels"; const query: any = map({ scope: [, "channel-flow-associations"], - "channel-flow-arn": [, input.ChannelFlowArn!], + "channel-flow-arn": [, __expectNonNull(input.ChannelFlowArn!, `ChannelFlowArn`)], "max-results": [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], "next-token": [, input.NextToken!], }); @@ -1235,7 +1235,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - arn: [, input.ResourceARN!], + arn: [, __expectNonNull(input.ResourceARN!, `ResourceARN`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-chime-sdk-voice/src/protocols/Aws_restJson1.ts b/clients/client-chime-sdk-voice/src/protocols/Aws_restJson1.ts index 8a9e1bcf53ba..bfedc9d10280 100644 --- a/clients/client-chime-sdk-voice/src/protocols/Aws_restJson1.ts +++ b/clients/client-chime-sdk-voice/src/protocols/Aws_restJson1.ts @@ -1791,7 +1791,7 @@ export const serializeAws_restJson1ListSupportedPhoneNumberCountriesCommand = as const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/phone-number-countries"; const query: any = map({ - "product-type": [, input.ProductType!], + "product-type": [, __expectNonNull(input.ProductType!, `ProductType`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-chime/src/protocols/Aws_restJson1.ts b/clients/client-chime/src/protocols/Aws_restJson1.ts index 279133127132..ce8219b1efb7 100644 --- a/clients/client-chime/src/protocols/Aws_restJson1.ts +++ b/clients/client-chime/src/protocols/Aws_restJson1.ts @@ -2896,7 +2896,7 @@ export const serializeAws_restJson1DescribeChannelMembershipForAppInstanceUserCo resolvedPath = __resolvedPath(resolvedPath, input, "ChannelArn", () => input.ChannelArn!, "{ChannelArn}", false); const query: any = map({ scope: [, "app-instance-user-membership"], - "app-instance-user-arn": [, input.AppInstanceUserArn!], + "app-instance-user-arn": [, __expectNonNull(input.AppInstanceUserArn!, `AppInstanceUserArn`)], }); let body: any; let { hostname: resolvedHostname } = await context.endpoint(); @@ -2930,7 +2930,7 @@ export const serializeAws_restJson1DescribeChannelModeratedByAppInstanceUserComm resolvedPath = __resolvedPath(resolvedPath, input, "ChannelArn", () => input.ChannelArn!, "{ChannelArn}", false); const query: any = map({ scope: [, "app-instance-user-moderated-channel"], - "app-instance-user-arn": [, input.AppInstanceUserArn!], + "app-instance-user-arn": [, __expectNonNull(input.AppInstanceUserArn!, `AppInstanceUserArn`)], }); let body: any; let { hostname: resolvedHostname } = await context.endpoint(); @@ -4113,7 +4113,7 @@ export const serializeAws_restJson1ListAppInstanceUsersCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/app-instance-users"; const query: any = map({ - "app-instance-arn": [, input.AppInstanceArn!], + "app-instance-arn": [, __expectNonNull(input.AppInstanceArn!, `AppInstanceArn`)], "max-results": [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], "next-token": [, input.NextToken!], }); @@ -4407,7 +4407,7 @@ export const serializeAws_restJson1ListChannelsCommand = async ( }); const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/channels"; const query: any = map({ - "app-instance-arn": [, input.AppInstanceArn!], + "app-instance-arn": [, __expectNonNull(input.AppInstanceArn!, `AppInstanceArn`)], privacy: [, input.Privacy!], "max-results": [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], "next-token": [, input.NextToken!], @@ -4738,7 +4738,7 @@ export const serializeAws_restJson1ListSupportedPhoneNumberCountriesCommand = as const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/phone-number-countries"; const query: any = map({ - "product-type": [, input.ProductType!], + "product-type": [, __expectNonNull(input.ProductType!, `ProductType`)], }); let body: any; return new __HttpRequest({ @@ -4761,7 +4761,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - arn: [, input.ResourceARN!], + arn: [, __expectNonNull(input.ResourceARN!, `ResourceARN`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-cloudfront/src/protocols/Aws_restXml.ts b/clients/client-cloudfront/src/protocols/Aws_restXml.ts index 05a1762f2c2a..0c68066dfe79 100644 --- a/clients/client-cloudfront/src/protocols/Aws_restXml.ts +++ b/clients/client-cloudfront/src/protocols/Aws_restXml.ts @@ -654,7 +654,7 @@ export const serializeAws_restXmlAssociateAliasCommand = async ( false ); const query: any = map({ - Alias: [, input.Alias!], + Alias: [, __expectNonNull(input.Alias!, `Alias`)], }); let body: any; return new __HttpRequest({ @@ -2428,8 +2428,8 @@ export const serializeAws_restXmlListConflictingAliasesCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2020-05-31/conflicting-alias"; const query: any = map({ - DistributionId: [, input.DistributionId!], - Alias: [, input.Alias!], + DistributionId: [, __expectNonNull(input.DistributionId!, `DistributionId`)], + Alias: [, __expectNonNull(input.Alias!, `Alias`)], Marker: [, input.Marker!], MaxItems: [() => input.MaxItems !== void 0, () => input.MaxItems!.toString()], }); @@ -2988,7 +2988,7 @@ export const serializeAws_restXmlListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2020-05-31/tagging"; const query: any = map({ - Resource: [, input.Resource!], + Resource: [, __expectNonNull(input.Resource!, `Resource`)], }); let body: any; return new __HttpRequest({ @@ -3037,7 +3037,7 @@ export const serializeAws_restXmlTagResourceCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2020-05-31/tagging"; const query: any = map({ Operation: [, "Tag"], - Resource: [, input.Resource!], + Resource: [, __expectNonNull(input.Resource!, `Resource`)], }); let body: any; if (input.Tags !== undefined) { @@ -3109,7 +3109,7 @@ export const serializeAws_restXmlUntagResourceCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2020-05-31/tagging"; const query: any = map({ Operation: [, "Untag"], - Resource: [, input.Resource!], + Resource: [, __expectNonNull(input.Resource!, `Resource`)], }); let body: any; if (input.TagKeys !== undefined) { diff --git a/clients/client-cloudsearch-domain/src/protocols/Aws_restJson1.ts b/clients/client-cloudsearch-domain/src/protocols/Aws_restJson1.ts index 15a1600456b9..9464a621db07 100644 --- a/clients/client-cloudsearch-domain/src/protocols/Aws_restJson1.ts +++ b/clients/client-cloudsearch-domain/src/protocols/Aws_restJson1.ts @@ -52,7 +52,7 @@ export const serializeAws_restJson1SearchCommand = async ( fq: [, input.filterQuery!], highlight: [, input.highlight!], partial: [() => input.partial !== void 0, () => input.partial!.toString()], - q: [, input.query!], + q: [, __expectNonNull(input.query!, `query`)], "q.options": [, input.queryOptions!], "q.parser": [, input.queryParser!], return: [, input.return!], @@ -84,8 +84,8 @@ export const serializeAws_restJson1SuggestCommand = async ( const query: any = map({ format: [, "sdk"], pretty: [, "true"], - q: [, input.query!], - suggester: [, input.suggester!], + q: [, __expectNonNull(input.query!, `query`)], + suggester: [, __expectNonNull(input.suggester!, `suggester`)], size: [() => input.size !== void 0, () => input.size!.toString()], }); let body: any; diff --git a/clients/client-codeartifact/src/protocols/Aws_restJson1.ts b/clients/client-codeartifact/src/protocols/Aws_restJson1.ts index f188899f5ced..10b2979f8010 100644 --- a/clients/client-codeartifact/src/protocols/Aws_restJson1.ts +++ b/clients/client-codeartifact/src/protocols/Aws_restJson1.ts @@ -169,10 +169,10 @@ export const serializeAws_restJson1AssociateExternalConnectionCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/repository/external-connection"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - "external-connection": [, input.externalConnection!], + repository: [, __expectNonNull(input.repository!, `repository`)], + "external-connection": [, __expectNonNull(input.externalConnection!, `externalConnection`)], }); let body: any; return new __HttpRequest({ @@ -198,13 +198,13 @@ export const serializeAws_restJson1CopyPackageVersionsCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/package/versions/copy"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - "source-repository": [, input.sourceRepository!], - "destination-repository": [, input.destinationRepository!], - format: [, input.format!], + "source-repository": [, __expectNonNull(input.sourceRepository!, `sourceRepository`)], + "destination-repository": [, __expectNonNull(input.destinationRepository!, `destinationRepository`)], + format: [, __expectNonNull(input.format!, `format`)], namespace: [, input.namespace!], - package: [, input.package!], + package: [, __expectNonNull(input.package!, `package`)], }); let body: any; body = JSON.stringify({ @@ -237,7 +237,7 @@ export const serializeAws_restJson1CreateDomainCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/domain"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], }); let body: any; body = JSON.stringify({ @@ -266,9 +266,9 @@ export const serializeAws_restJson1CreateRepositoryCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/repository"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], + repository: [, __expectNonNull(input.repository!, `repository`)], }); let body: any; body = JSON.stringify({ @@ -298,7 +298,7 @@ export const serializeAws_restJson1DeleteDomainCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/domain"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], }); let body: any; @@ -323,7 +323,7 @@ export const serializeAws_restJson1DeleteDomainPermissionsPolicyCommand = async const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/domain/permissions/policy"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], "policy-revision": [, input.policyRevision!], }); @@ -351,12 +351,12 @@ export const serializeAws_restJson1DeletePackageVersionsCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/package/versions/delete"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - format: [, input.format!], + repository: [, __expectNonNull(input.repository!, `repository`)], + format: [, __expectNonNull(input.format!, `format`)], namespace: [, input.namespace!], - package: [, input.package!], + package: [, __expectNonNull(input.package!, `package`)], }); let body: any; body = JSON.stringify({ @@ -383,9 +383,9 @@ export const serializeAws_restJson1DeleteRepositoryCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/repository"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], + repository: [, __expectNonNull(input.repository!, `repository`)], }); let body: any; return new __HttpRequest({ @@ -409,9 +409,9 @@ export const serializeAws_restJson1DeleteRepositoryPermissionsPolicyCommand = as const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/repository/permissions/policies"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], + repository: [, __expectNonNull(input.repository!, `repository`)], "policy-revision": [, input.policyRevision!], }); let body: any; @@ -435,7 +435,7 @@ export const serializeAws_restJson1DescribeDomainCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/domain"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], }); let body: any; @@ -459,12 +459,12 @@ export const serializeAws_restJson1DescribePackageCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/package"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - format: [, input.format!], + repository: [, __expectNonNull(input.repository!, `repository`)], + format: [, __expectNonNull(input.format!, `format`)], namespace: [, input.namespace!], - package: [, input.package!], + package: [, __expectNonNull(input.package!, `package`)], }); let body: any; return new __HttpRequest({ @@ -487,13 +487,13 @@ export const serializeAws_restJson1DescribePackageVersionCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/package/version"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - format: [, input.format!], + repository: [, __expectNonNull(input.repository!, `repository`)], + format: [, __expectNonNull(input.format!, `format`)], namespace: [, input.namespace!], - package: [, input.package!], - version: [, input.packageVersion!], + package: [, __expectNonNull(input.package!, `package`)], + version: [, __expectNonNull(input.packageVersion!, `packageVersion`)], }); let body: any; return new __HttpRequest({ @@ -516,9 +516,9 @@ export const serializeAws_restJson1DescribeRepositoryCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/repository"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], + repository: [, __expectNonNull(input.repository!, `repository`)], }); let body: any; return new __HttpRequest({ @@ -542,10 +542,10 @@ export const serializeAws_restJson1DisassociateExternalConnectionCommand = async const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/repository/external-connection"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - "external-connection": [, input.externalConnection!], + repository: [, __expectNonNull(input.repository!, `repository`)], + "external-connection": [, __expectNonNull(input.externalConnection!, `externalConnection`)], }); let body: any; return new __HttpRequest({ @@ -571,12 +571,12 @@ export const serializeAws_restJson1DisposePackageVersionsCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/package/versions/dispose"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - format: [, input.format!], + repository: [, __expectNonNull(input.repository!, `repository`)], + format: [, __expectNonNull(input.format!, `format`)], namespace: [, input.namespace!], - package: [, input.package!], + package: [, __expectNonNull(input.package!, `package`)], }); let body: any; body = JSON.stringify({ @@ -607,7 +607,7 @@ export const serializeAws_restJson1GetAuthorizationTokenCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/authorization-token"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], duration: [() => input.durationSeconds !== void 0, () => input.durationSeconds!.toString()], }); @@ -633,7 +633,7 @@ export const serializeAws_restJson1GetDomainPermissionsPolicyCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/domain/permissions/policy"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], }); let body: any; @@ -658,14 +658,14 @@ export const serializeAws_restJson1GetPackageVersionAssetCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/package/version/asset"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - format: [, input.format!], + repository: [, __expectNonNull(input.repository!, `repository`)], + format: [, __expectNonNull(input.format!, `format`)], namespace: [, input.namespace!], - package: [, input.package!], - version: [, input.packageVersion!], - asset: [, input.asset!], + package: [, __expectNonNull(input.package!, `package`)], + version: [, __expectNonNull(input.packageVersion!, `packageVersion`)], + asset: [, __expectNonNull(input.asset!, `asset`)], revision: [, input.packageVersionRevision!], }); let body: any; @@ -690,13 +690,13 @@ export const serializeAws_restJson1GetPackageVersionReadmeCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/package/version/readme"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - format: [, input.format!], + repository: [, __expectNonNull(input.repository!, `repository`)], + format: [, __expectNonNull(input.format!, `format`)], namespace: [, input.namespace!], - package: [, input.package!], - version: [, input.packageVersion!], + package: [, __expectNonNull(input.package!, `package`)], + version: [, __expectNonNull(input.packageVersion!, `packageVersion`)], }); let body: any; return new __HttpRequest({ @@ -720,10 +720,10 @@ export const serializeAws_restJson1GetRepositoryEndpointCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/repository/endpoint"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - format: [, input.format!], + repository: [, __expectNonNull(input.repository!, `repository`)], + format: [, __expectNonNull(input.format!, `format`)], }); let body: any; return new __HttpRequest({ @@ -747,9 +747,9 @@ export const serializeAws_restJson1GetRepositoryPermissionsPolicyCommand = async const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/repository/permissions/policy"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], + repository: [, __expectNonNull(input.repository!, `repository`)], }); let body: any; return new __HttpRequest({ @@ -797,9 +797,9 @@ export const serializeAws_restJson1ListPackagesCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/packages"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], + repository: [, __expectNonNull(input.repository!, `repository`)], format: [, input.format!], namespace: [, input.namespace!], "package-prefix": [, input.packagePrefix!], @@ -830,13 +830,13 @@ export const serializeAws_restJson1ListPackageVersionAssetsCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/package/version/assets"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - format: [, input.format!], + repository: [, __expectNonNull(input.repository!, `repository`)], + format: [, __expectNonNull(input.format!, `format`)], namespace: [, input.namespace!], - package: [, input.package!], - version: [, input.packageVersion!], + package: [, __expectNonNull(input.package!, `package`)], + version: [, __expectNonNull(input.packageVersion!, `packageVersion`)], "max-results": [() => input.maxResults !== void 0, () => input.maxResults!.toString()], "next-token": [, input.nextToken!], }); @@ -862,13 +862,13 @@ export const serializeAws_restJson1ListPackageVersionDependenciesCommand = async const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/package/version/dependencies"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - format: [, input.format!], + repository: [, __expectNonNull(input.repository!, `repository`)], + format: [, __expectNonNull(input.format!, `format`)], namespace: [, input.namespace!], - package: [, input.package!], - version: [, input.packageVersion!], + package: [, __expectNonNull(input.package!, `package`)], + version: [, __expectNonNull(input.packageVersion!, `packageVersion`)], "next-token": [, input.nextToken!], }); let body: any; @@ -892,12 +892,12 @@ export const serializeAws_restJson1ListPackageVersionsCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/package/versions"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - format: [, input.format!], + repository: [, __expectNonNull(input.repository!, `repository`)], + format: [, __expectNonNull(input.format!, `format`)], namespace: [, input.namespace!], - package: [, input.package!], + package: [, __expectNonNull(input.package!, `package`)], status: [, input.status!], sortBy: [, input.sortBy!], "max-results": [() => input.maxResults !== void 0, () => input.maxResults!.toString()], @@ -951,7 +951,7 @@ export const serializeAws_restJson1ListRepositoriesInDomainCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/domain/repositories"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], "administrator-account": [, input.administratorAccount!], "repository-prefix": [, input.repositoryPrefix!], @@ -979,7 +979,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/tags"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; return new __HttpRequest({ @@ -1032,12 +1032,12 @@ export const serializeAws_restJson1PutPackageOriginConfigurationCommand = async }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/package"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - format: [, input.format!], + repository: [, __expectNonNull(input.repository!, `repository`)], + format: [, __expectNonNull(input.format!, `format`)], namespace: [, input.namespace!], - package: [, input.package!], + package: [, __expectNonNull(input.package!, `package`)], }); let body: any; body = JSON.stringify({ @@ -1068,9 +1068,9 @@ export const serializeAws_restJson1PutRepositoryPermissionsPolicyCommand = async const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/repository/permissions/policy"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], + repository: [, __expectNonNull(input.repository!, `repository`)], }); let body: any; body = JSON.stringify({ @@ -1099,7 +1099,7 @@ export const serializeAws_restJson1TagResourceCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/tag"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; body = JSON.stringify({ @@ -1127,7 +1127,7 @@ export const serializeAws_restJson1UntagResourceCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/untag"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; body = JSON.stringify({ @@ -1156,12 +1156,12 @@ export const serializeAws_restJson1UpdatePackageVersionsStatusCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/package/versions/update_status"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], - format: [, input.format!], + repository: [, __expectNonNull(input.repository!, `repository`)], + format: [, __expectNonNull(input.format!, `format`)], namespace: [, input.namespace!], - package: [, input.package!], + package: [, __expectNonNull(input.package!, `package`)], }); let body: any; body = JSON.stringify({ @@ -1194,9 +1194,9 @@ export const serializeAws_restJson1UpdateRepositoryCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/repository"; const query: any = map({ - domain: [, input.domain!], + domain: [, __expectNonNull(input.domain!, `domain`)], "domain-owner": [, input.domainOwner!], - repository: [, input.repository!], + repository: [, __expectNonNull(input.repository!, `repository`)], }); let body: any; body = JSON.stringify({ diff --git a/clients/client-codeguru-reviewer/src/protocols/Aws_restJson1.ts b/clients/client-codeguru-reviewer/src/protocols/Aws_restJson1.ts index 45162254b2c5..c1131c449ec5 100644 --- a/clients/client-codeguru-reviewer/src/protocols/Aws_restJson1.ts +++ b/clients/client-codeguru-reviewer/src/protocols/Aws_restJson1.ts @@ -202,7 +202,7 @@ export const serializeAws_restJson1DescribeRecommendationFeedbackCommand = async false ); const query: any = map({ - RecommendationId: [, input.RecommendationId!], + RecommendationId: [, __expectNonNull(input.RecommendationId!, `RecommendationId`)], UserId: [, input.UserId!], }); let body: any; @@ -291,7 +291,7 @@ export const serializeAws_restJson1ListCodeReviewsCommand = async ( () => input.RepositoryNames !== void 0, () => (input.RepositoryNames! || []).map((_entry) => _entry as any), ], - Type: [, input.Type!], + Type: [, __expectNonNull(input.Type!, `Type`)], MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], NextToken: [, input.NextToken!], }); @@ -492,7 +492,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-codeguruprofiler/src/protocols/Aws_restJson1.ts b/clients/client-codeguruprofiler/src/protocols/Aws_restJson1.ts index bcff52ba4f8d..b89bcd3cb0d3 100644 --- a/clients/client-codeguruprofiler/src/protocols/Aws_restJson1.ts +++ b/clients/client-codeguruprofiler/src/protocols/Aws_restJson1.ts @@ -237,7 +237,7 @@ export const serializeAws_restJson1CreateProfilingGroupCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/profilingGroups"; const query: any = map({ - clientToken: [, input.clientToken!], + clientToken: [, __expectNonNull(input.clientToken!, `clientToken`)], }); let body: any; body = JSON.stringify({ @@ -460,10 +460,13 @@ export const serializeAws_restJson1GetRecommendationsCommand = async ( ); const query: any = map({ startTime: [ - () => input.startTime !== void 0, + __expectNonNull(input.startTime, `startTime`) != null, () => (input.startTime!.toISOString().split(".")[0] + "Z").toString(), ], - endTime: [() => input.endTime !== void 0, () => (input.endTime!.toISOString().split(".")[0] + "Z").toString()], + endTime: [ + __expectNonNull(input.endTime, `endTime`) != null, + () => (input.endTime!.toISOString().split(".")[0] + "Z").toString(), + ], locale: [, input.locale!], }); let body: any; @@ -498,10 +501,13 @@ export const serializeAws_restJson1ListFindingsReportsCommand = async ( ); const query: any = map({ startTime: [ - () => input.startTime !== void 0, + __expectNonNull(input.startTime, `startTime`) != null, () => (input.startTime!.toISOString().split(".")[0] + "Z").toString(), ], - endTime: [() => input.endTime !== void 0, () => (input.endTime!.toISOString().split(".")[0] + "Z").toString()], + endTime: [ + __expectNonNull(input.endTime, `endTime`) != null, + () => (input.endTime!.toISOString().split(".")[0] + "Z").toString(), + ], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], dailyReportsOnly: [() => input.dailyReportsOnly !== void 0, () => input.dailyReportsOnly!.toString()], @@ -538,11 +544,14 @@ export const serializeAws_restJson1ListProfileTimesCommand = async ( ); const query: any = map({ startTime: [ - () => input.startTime !== void 0, + __expectNonNull(input.startTime, `startTime`) != null, () => (input.startTime!.toISOString().split(".")[0] + "Z").toString(), ], - endTime: [() => input.endTime !== void 0, () => (input.endTime!.toISOString().split(".")[0] + "Z").toString()], - period: [, input.period!], + endTime: [ + __expectNonNull(input.endTime, `endTime`) != null, + () => (input.endTime!.toISOString().split(".")[0] + "Z").toString(), + ], + period: [, __expectNonNull(input.period!, `period`)], orderBy: [, input.orderBy!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], nextToken: [, input.nextToken!], @@ -728,7 +737,7 @@ export const serializeAws_restJson1RemovePermissionCommand = async ( ); resolvedPath = __resolvedPath(resolvedPath, input, "actionGroup", () => input.actionGroup!, "{actionGroup}", false); const query: any = map({ - revisionId: [, input.revisionId!], + revisionId: [, __expectNonNull(input.revisionId!, `revisionId`)], }); let body: any; return new __HttpRequest({ @@ -820,7 +829,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-codestar-notifications/src/protocols/Aws_restJson1.ts b/clients/client-codestar-notifications/src/protocols/Aws_restJson1.ts index 2dd16340a947..2563a4d406d4 100644 --- a/clients/client-codestar-notifications/src/protocols/Aws_restJson1.ts +++ b/clients/client-codestar-notifications/src/protocols/Aws_restJson1.ts @@ -367,7 +367,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/untagResource/{Arn}"; resolvedPath = __resolvedPath(resolvedPath, input, "Arn", () => input.Arn!, "{Arn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-connect/src/protocols/Aws_restJson1.ts b/clients/client-connect/src/protocols/Aws_restJson1.ts index 832eb62f08e4..f3e2b5b6257f 100644 --- a/clients/client-connect/src/protocols/Aws_restJson1.ts +++ b/clients/client-connect/src/protocols/Aws_restJson1.ts @@ -2070,7 +2070,7 @@ export const serializeAws_restJson1DescribeInstanceStorageConfigCommand = async false ); const query: any = map({ - resourceType: [, input.ResourceType!], + resourceType: [, __expectNonNull(input.ResourceType!, `ResourceType`)], }); let body: any; return new __HttpRequest({ @@ -2366,7 +2366,7 @@ export const serializeAws_restJson1DisassociateApprovedOriginCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/instance/{InstanceId}/approved-origin"; resolvedPath = __resolvedPath(resolvedPath, input, "InstanceId", () => input.InstanceId!, "{InstanceId}", false); const query: any = map({ - origin: [, input.Origin!], + origin: [, __expectNonNull(input.Origin!, `Origin`)], }); let body: any; return new __HttpRequest({ @@ -2427,7 +2427,7 @@ export const serializeAws_restJson1DisassociateInstanceStorageConfigCommand = as false ); const query: any = map({ - resourceType: [, input.ResourceType!], + resourceType: [, __expectNonNull(input.ResourceType!, `ResourceType`)], }); let body: any; return new __HttpRequest({ @@ -2452,7 +2452,7 @@ export const serializeAws_restJson1DisassociateLambdaFunctionCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/instance/{InstanceId}/lambda-function"; resolvedPath = __resolvedPath(resolvedPath, input, "InstanceId", () => input.InstanceId!, "{InstanceId}", false); const query: any = map({ - functionArn: [, input.FunctionArn!], + functionArn: [, __expectNonNull(input.FunctionArn!, `FunctionArn`)], }); let body: any; return new __HttpRequest({ @@ -2477,8 +2477,8 @@ export const serializeAws_restJson1DisassociateLexBotCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/instance/{InstanceId}/lex-bot"; resolvedPath = __resolvedPath(resolvedPath, input, "InstanceId", () => input.InstanceId!, "{InstanceId}", false); const query: any = map({ - botName: [, input.BotName!], - lexRegion: [, input.LexRegion!], + botName: [, __expectNonNull(input.BotName!, `BotName`)], + lexRegion: [, __expectNonNull(input.LexRegion!, `LexRegion`)], }); let body: any; return new __HttpRequest({ @@ -2511,7 +2511,7 @@ export const serializeAws_restJson1DisassociatePhoneNumberContactFlowCommand = a false ); const query: any = map({ - instanceId: [, input.InstanceId!], + instanceId: [, __expectNonNull(input.InstanceId!, `InstanceId`)], }); let body: any; return new __HttpRequest({ @@ -2918,7 +2918,7 @@ export const serializeAws_restJson1ListBotsCommand = async ( const query: any = map({ nextToken: [, input.NextToken!], maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], - lexVersion: [, input.LexVersion!], + lexVersion: [, __expectNonNull(input.LexVersion!, `LexVersion`)], }); let body: any; return new __HttpRequest({ @@ -3004,7 +3004,7 @@ export const serializeAws_restJson1ListContactReferencesCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "ContactId", () => input.ContactId!, "{ContactId}", false); const query: any = map({ referenceTypes: [ - () => input.ReferenceTypes !== void 0, + __expectNonNull(input.ReferenceTypes, `ReferenceTypes`) != null, () => (input.ReferenceTypes! || []).map((_entry) => _entry as any), ], nextToken: [, input.NextToken!], @@ -3136,7 +3136,7 @@ export const serializeAws_restJson1ListInstanceStorageConfigsCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/instance/{InstanceId}/storage-configs"; resolvedPath = __resolvedPath(resolvedPath, input, "InstanceId", () => input.InstanceId!, "{InstanceId}", false); const query: any = map({ - resourceType: [, input.ResourceType!], + resourceType: [, __expectNonNull(input.ResourceType!, `ResourceType`)], nextToken: [, input.NextToken!], maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], }); @@ -4406,7 +4406,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ @@ -4815,7 +4818,7 @@ export const serializeAws_restJson1UpdateInstanceStorageConfigCommand = async ( false ); const query: any = map({ - resourceType: [, input.ResourceType!], + resourceType: [, __expectNonNull(input.ResourceType!, `ResourceType`)], }); let body: any; body = JSON.stringify({ diff --git a/clients/client-connectcampaigns/src/protocols/Aws_restJson1.ts b/clients/client-connectcampaigns/src/protocols/Aws_restJson1.ts index 300ab9725627..0d120d48cb70 100644 --- a/clients/client-connectcampaigns/src/protocols/Aws_restJson1.ts +++ b/clients/client-connectcampaigns/src/protocols/Aws_restJson1.ts @@ -558,7 +558,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{arn}"; resolvedPath = __resolvedPath(resolvedPath, input, "arn", () => input.arn!, "{arn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-connectcases/src/protocols/Aws_restJson1.ts b/clients/client-connectcases/src/protocols/Aws_restJson1.ts index 44f1cc85a525..eb798b4d970c 100644 --- a/clients/client-connectcases/src/protocols/Aws_restJson1.ts +++ b/clients/client-connectcases/src/protocols/Aws_restJson1.ts @@ -759,7 +759,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{arn}"; resolvedPath = __resolvedPath(resolvedPath, input, "arn", () => input.arn!, "{arn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-customer-profiles/src/protocols/Aws_restJson1.ts b/clients/client-customer-profiles/src/protocols/Aws_restJson1.ts index f720ca34a50b..ec2c89012efd 100644 --- a/clients/client-customer-profiles/src/protocols/Aws_restJson1.ts +++ b/clients/client-customer-profiles/src/protocols/Aws_restJson1.ts @@ -1175,7 +1175,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-databrew/src/protocols/Aws_restJson1.ts b/clients/client-databrew/src/protocols/Aws_restJson1.ts index 92b30e38263e..cea99ff15e85 100644 --- a/clients/client-databrew/src/protocols/Aws_restJson1.ts +++ b/clients/client-databrew/src/protocols/Aws_restJson1.ts @@ -808,7 +808,7 @@ export const serializeAws_restJson1ListRecipeVersionsCommand = async ( const query: any = map({ maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], nextToken: [, input.NextToken!], - name: [, input.Name!], + name: [, __expectNonNull(input.Name!, `Name`)], }); let body: any; return new __HttpRequest({ @@ -1051,7 +1051,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-dataexchange/src/protocols/Aws_restJson1.ts b/clients/client-dataexchange/src/protocols/Aws_restJson1.ts index ef25f0ebd72b..3af06faa4961 100644 --- a/clients/client-dataexchange/src/protocols/Aws_restJson1.ts +++ b/clients/client-dataexchange/src/protocols/Aws_restJson1.ts @@ -722,7 +722,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-detective/src/protocols/Aws_restJson1.ts b/clients/client-detective/src/protocols/Aws_restJson1.ts index c9434d001e2c..3bad40e1eb30 100644 --- a/clients/client-detective/src/protocols/Aws_restJson1.ts +++ b/clients/client-detective/src/protocols/Aws_restJson1.ts @@ -633,7 +633,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-dlm/src/protocols/Aws_restJson1.ts b/clients/client-dlm/src/protocols/Aws_restJson1.ts index 3c981829e69d..b59e43997b66 100644 --- a/clients/client-dlm/src/protocols/Aws_restJson1.ts +++ b/clients/client-dlm/src/protocols/Aws_restJson1.ts @@ -229,7 +229,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-drs/src/protocols/Aws_restJson1.ts b/clients/client-drs/src/protocols/Aws_restJson1.ts index 357fce71f245..638d7bd3f729 100644 --- a/clients/client-drs/src/protocols/Aws_restJson1.ts +++ b/clients/client-drs/src/protocols/Aws_restJson1.ts @@ -919,7 +919,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-ebs/src/protocols/Aws_restJson1.ts b/clients/client-ebs/src/protocols/Aws_restJson1.ts index da966e222e5f..fb2870f6875c 100644 --- a/clients/client-ebs/src/protocols/Aws_restJson1.ts +++ b/clients/client-ebs/src/protocols/Aws_restJson1.ts @@ -92,7 +92,7 @@ export const serializeAws_restJson1GetSnapshotBlockCommand = async ( false ); const query: any = map({ - blockToken: [, input.BlockToken!], + blockToken: [, __expectNonNull(input.BlockToken!, `BlockToken`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-efs/src/protocols/Aws_restJson1.ts b/clients/client-efs/src/protocols/Aws_restJson1.ts index ba7297c9b5cc..2e87761e59be 100644 --- a/clients/client-efs/src/protocols/Aws_restJson1.ts +++ b/clients/client-efs/src/protocols/Aws_restJson1.ts @@ -1010,7 +1010,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/resource-tags/{ResourceId}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceId", () => input.ResourceId!, "{ResourceId}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-eks/src/protocols/Aws_restJson1.ts b/clients/client-eks/src/protocols/Aws_restJson1.ts index 1f1770e55739..1b141281929d 100644 --- a/clients/client-eks/src/protocols/Aws_restJson1.ts +++ b/clients/client-eks/src/protocols/Aws_restJson1.ts @@ -968,7 +968,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-elastic-inference/src/protocols/Aws_restJson1.ts b/clients/client-elastic-inference/src/protocols/Aws_restJson1.ts index 2d2efa624c56..db8b148552a8 100644 --- a/clients/client-elastic-inference/src/protocols/Aws_restJson1.ts +++ b/clients/client-elastic-inference/src/protocols/Aws_restJson1.ts @@ -183,7 +183,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-elasticsearch-service/src/protocols/Aws_restJson1.ts b/clients/client-elasticsearch-service/src/protocols/Aws_restJson1.ts index d8fd49c6736f..8019de483fa7 100644 --- a/clients/client-elasticsearch-service/src/protocols/Aws_restJson1.ts +++ b/clients/client-elasticsearch-service/src/protocols/Aws_restJson1.ts @@ -1295,7 +1295,7 @@ export const serializeAws_restJson1ListTagsCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-01-01/tags"; const query: any = map({ - arn: [, input.ARN!], + arn: [, __expectNonNull(input.ARN!, `ARN`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-emr-containers/src/protocols/Aws_restJson1.ts b/clients/client-emr-containers/src/protocols/Aws_restJson1.ts index 10806f7e5ce3..5e7d3d5a71c6 100644 --- a/clients/client-emr-containers/src/protocols/Aws_restJson1.ts +++ b/clients/client-emr-containers/src/protocols/Aws_restJson1.ts @@ -654,7 +654,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-emr-serverless/src/protocols/Aws_restJson1.ts b/clients/client-emr-serverless/src/protocols/Aws_restJson1.ts index ed2885a66482..1443b29128b7 100644 --- a/clients/client-emr-serverless/src/protocols/Aws_restJson1.ts +++ b/clients/client-emr-serverless/src/protocols/Aws_restJson1.ts @@ -481,7 +481,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-evidently/src/protocols/Aws_restJson1.ts b/clients/client-evidently/src/protocols/Aws_restJson1.ts index 510e9ca793fc..009e4f3660d8 100644 --- a/clients/client-evidently/src/protocols/Aws_restJson1.ts +++ b/clients/client-evidently/src/protocols/Aws_restJson1.ts @@ -753,7 +753,7 @@ export const serializeAws_restJson1ListSegmentReferencesCommand = async ( const query: any = map({ maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], nextToken: [, input.nextToken!], - type: [, input.type!], + type: [, __expectNonNull(input.type!, `type`)], }); let body: any; return new __HttpRequest({ @@ -1015,7 +1015,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-finspace-data/src/protocols/Aws_restJson1.ts b/clients/client-finspace-data/src/protocols/Aws_restJson1.ts index ced70ce5dccb..8721dfedac10 100644 --- a/clients/client-finspace-data/src/protocols/Aws_restJson1.ts +++ b/clients/client-finspace-data/src/protocols/Aws_restJson1.ts @@ -575,7 +575,7 @@ export const serializeAws_restJson1GetProgrammaticAccessCredentialsCommand = asy `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/credentials/programmatic"; const query: any = map({ durationInMinutes: [() => input.durationInMinutes !== void 0, () => input.durationInMinutes!.toString()], - environmentId: [, input.environmentId!], + environmentId: [, __expectNonNull(input.environmentId!, `environmentId`)], }); let body: any; return new __HttpRequest({ @@ -719,7 +719,7 @@ export const serializeAws_restJson1ListPermissionGroupsCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/permission-group"; const query: any = map({ nextToken: [, input.nextToken!], - maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], + maxResults: [__expectNonNull(input.maxResults, `maxResults`) != null, () => input.maxResults!.toString()], }); let body: any; return new __HttpRequest({ @@ -745,7 +745,7 @@ export const serializeAws_restJson1ListPermissionGroupsByUserCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "userId", () => input.userId!, "{userId}", false); const query: any = map({ nextToken: [, input.nextToken!], - maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], + maxResults: [__expectNonNull(input.maxResults, `maxResults`) != null, () => input.maxResults!.toString()], }); let body: any; return new __HttpRequest({ @@ -769,7 +769,7 @@ export const serializeAws_restJson1ListUsersCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/user"; const query: any = map({ nextToken: [, input.nextToken!], - maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], + maxResults: [__expectNonNull(input.maxResults, `maxResults`) != null, () => input.maxResults!.toString()], }); let body: any; return new __HttpRequest({ @@ -803,7 +803,7 @@ export const serializeAws_restJson1ListUsersByPermissionGroupCommand = async ( ); const query: any = map({ nextToken: [, input.nextToken!], - maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], + maxResults: [__expectNonNull(input.maxResults, `maxResults`) != null, () => input.maxResults!.toString()], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-finspace/src/protocols/Aws_restJson1.ts b/clients/client-finspace/src/protocols/Aws_restJson1.ts index 7357fcd2622e..b613d97115e9 100644 --- a/clients/client-finspace/src/protocols/Aws_restJson1.ts +++ b/clients/client-finspace/src/protocols/Aws_restJson1.ts @@ -211,7 +211,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-gamesparks/src/protocols/Aws_restJson1.ts b/clients/client-gamesparks/src/protocols/Aws_restJson1.ts index f51da23ebc8a..170e0c83512f 100644 --- a/clients/client-gamesparks/src/protocols/Aws_restJson1.ts +++ b/clients/client-gamesparks/src/protocols/Aws_restJson1.ts @@ -831,7 +831,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-grafana/src/protocols/Aws_restJson1.ts b/clients/client-grafana/src/protocols/Aws_restJson1.ts index 0328b8f04ee0..b621b59577f2 100644 --- a/clients/client-grafana/src/protocols/Aws_restJson1.ts +++ b/clients/client-grafana/src/protocols/Aws_restJson1.ts @@ -403,7 +403,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-greengrass/src/protocols/Aws_restJson1.ts b/clients/client-greengrass/src/protocols/Aws_restJson1.ts index 92ecb46696d0..b4db4d2c36af 100644 --- a/clients/client-greengrass/src/protocols/Aws_restJson1.ts +++ b/clients/client-greengrass/src/protocols/Aws_restJson1.ts @@ -2764,7 +2764,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-greengrassv2/src/protocols/Aws_restJson1.ts b/clients/client-greengrassv2/src/protocols/Aws_restJson1.ts index 2fa19b459818..6bd61fd9dba7 100644 --- a/clients/client-greengrassv2/src/protocols/Aws_restJson1.ts +++ b/clients/client-greengrassv2/src/protocols/Aws_restJson1.ts @@ -917,7 +917,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-groundstation/src/protocols/Aws_restJson1.ts b/clients/client-groundstation/src/protocols/Aws_restJson1.ts index 89809cd401f5..455d679a5a0d 100644 --- a/clients/client-groundstation/src/protocols/Aws_restJson1.ts +++ b/clients/client-groundstation/src/protocols/Aws_restJson1.ts @@ -806,7 +806,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-guardduty/src/protocols/Aws_restJson1.ts b/clients/client-guardduty/src/protocols/Aws_restJson1.ts index caa0fc922d74..11e4085fef5d 100644 --- a/clients/client-guardduty/src/protocols/Aws_restJson1.ts +++ b/clients/client-guardduty/src/protocols/Aws_restJson1.ts @@ -1764,7 +1764,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-honeycode/src/protocols/Aws_restJson1.ts b/clients/client-honeycode/src/protocols/Aws_restJson1.ts index 05763b1c9e68..86335d7fa791 100644 --- a/clients/client-honeycode/src/protocols/Aws_restJson1.ts +++ b/clients/client-honeycode/src/protocols/Aws_restJson1.ts @@ -519,7 +519,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-imagebuilder/src/protocols/Aws_restJson1.ts b/clients/client-imagebuilder/src/protocols/Aws_restJson1.ts index 0490a9126852..0ec37c54ea8c 100644 --- a/clients/client-imagebuilder/src/protocols/Aws_restJson1.ts +++ b/clients/client-imagebuilder/src/protocols/Aws_restJson1.ts @@ -528,7 +528,7 @@ export const serializeAws_restJson1DeleteComponentCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteComponent"; const query: any = map({ - componentBuildVersionArn: [, input.componentBuildVersionArn!], + componentBuildVersionArn: [, __expectNonNull(input.componentBuildVersionArn!, `componentBuildVersionArn`)], }); let body: any; return new __HttpRequest({ @@ -551,7 +551,7 @@ export const serializeAws_restJson1DeleteContainerRecipeCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteContainerRecipe"; const query: any = map({ - containerRecipeArn: [, input.containerRecipeArn!], + containerRecipeArn: [, __expectNonNull(input.containerRecipeArn!, `containerRecipeArn`)], }); let body: any; return new __HttpRequest({ @@ -575,7 +575,10 @@ export const serializeAws_restJson1DeleteDistributionConfigurationCommand = asyn const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteDistributionConfiguration"; const query: any = map({ - distributionConfigurationArn: [, input.distributionConfigurationArn!], + distributionConfigurationArn: [ + , + __expectNonNull(input.distributionConfigurationArn!, `distributionConfigurationArn`), + ], }); let body: any; return new __HttpRequest({ @@ -598,7 +601,7 @@ export const serializeAws_restJson1DeleteImageCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteImage"; const query: any = map({ - imageBuildVersionArn: [, input.imageBuildVersionArn!], + imageBuildVersionArn: [, __expectNonNull(input.imageBuildVersionArn!, `imageBuildVersionArn`)], }); let body: any; return new __HttpRequest({ @@ -621,7 +624,7 @@ export const serializeAws_restJson1DeleteImagePipelineCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteImagePipeline"; const query: any = map({ - imagePipelineArn: [, input.imagePipelineArn!], + imagePipelineArn: [, __expectNonNull(input.imagePipelineArn!, `imagePipelineArn`)], }); let body: any; return new __HttpRequest({ @@ -644,7 +647,7 @@ export const serializeAws_restJson1DeleteImageRecipeCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteImageRecipe"; const query: any = map({ - imageRecipeArn: [, input.imageRecipeArn!], + imageRecipeArn: [, __expectNonNull(input.imageRecipeArn!, `imageRecipeArn`)], }); let body: any; return new __HttpRequest({ @@ -668,7 +671,10 @@ export const serializeAws_restJson1DeleteInfrastructureConfigurationCommand = as const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DeleteInfrastructureConfiguration"; const query: any = map({ - infrastructureConfigurationArn: [, input.infrastructureConfigurationArn!], + infrastructureConfigurationArn: [ + , + __expectNonNull(input.infrastructureConfigurationArn!, `infrastructureConfigurationArn`), + ], }); let body: any; return new __HttpRequest({ @@ -691,7 +697,7 @@ export const serializeAws_restJson1GetComponentCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetComponent"; const query: any = map({ - componentBuildVersionArn: [, input.componentBuildVersionArn!], + componentBuildVersionArn: [, __expectNonNull(input.componentBuildVersionArn!, `componentBuildVersionArn`)], }); let body: any; return new __HttpRequest({ @@ -714,7 +720,7 @@ export const serializeAws_restJson1GetComponentPolicyCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetComponentPolicy"; const query: any = map({ - componentArn: [, input.componentArn!], + componentArn: [, __expectNonNull(input.componentArn!, `componentArn`)], }); let body: any; return new __HttpRequest({ @@ -737,7 +743,7 @@ export const serializeAws_restJson1GetContainerRecipeCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetContainerRecipe"; const query: any = map({ - containerRecipeArn: [, input.containerRecipeArn!], + containerRecipeArn: [, __expectNonNull(input.containerRecipeArn!, `containerRecipeArn`)], }); let body: any; return new __HttpRequest({ @@ -761,7 +767,7 @@ export const serializeAws_restJson1GetContainerRecipePolicyCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetContainerRecipePolicy"; const query: any = map({ - containerRecipeArn: [, input.containerRecipeArn!], + containerRecipeArn: [, __expectNonNull(input.containerRecipeArn!, `containerRecipeArn`)], }); let body: any; return new __HttpRequest({ @@ -785,7 +791,10 @@ export const serializeAws_restJson1GetDistributionConfigurationCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetDistributionConfiguration"; const query: any = map({ - distributionConfigurationArn: [, input.distributionConfigurationArn!], + distributionConfigurationArn: [ + , + __expectNonNull(input.distributionConfigurationArn!, `distributionConfigurationArn`), + ], }); let body: any; return new __HttpRequest({ @@ -808,7 +817,7 @@ export const serializeAws_restJson1GetImageCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetImage"; const query: any = map({ - imageBuildVersionArn: [, input.imageBuildVersionArn!], + imageBuildVersionArn: [, __expectNonNull(input.imageBuildVersionArn!, `imageBuildVersionArn`)], }); let body: any; return new __HttpRequest({ @@ -831,7 +840,7 @@ export const serializeAws_restJson1GetImagePipelineCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetImagePipeline"; const query: any = map({ - imagePipelineArn: [, input.imagePipelineArn!], + imagePipelineArn: [, __expectNonNull(input.imagePipelineArn!, `imagePipelineArn`)], }); let body: any; return new __HttpRequest({ @@ -854,7 +863,7 @@ export const serializeAws_restJson1GetImagePolicyCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetImagePolicy"; const query: any = map({ - imageArn: [, input.imageArn!], + imageArn: [, __expectNonNull(input.imageArn!, `imageArn`)], }); let body: any; return new __HttpRequest({ @@ -877,7 +886,7 @@ export const serializeAws_restJson1GetImageRecipeCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetImageRecipe"; const query: any = map({ - imageRecipeArn: [, input.imageRecipeArn!], + imageRecipeArn: [, __expectNonNull(input.imageRecipeArn!, `imageRecipeArn`)], }); let body: any; return new __HttpRequest({ @@ -900,7 +909,7 @@ export const serializeAws_restJson1GetImageRecipePolicyCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetImageRecipePolicy"; const query: any = map({ - imageRecipeArn: [, input.imageRecipeArn!], + imageRecipeArn: [, __expectNonNull(input.imageRecipeArn!, `imageRecipeArn`)], }); let body: any; return new __HttpRequest({ @@ -924,7 +933,10 @@ export const serializeAws_restJson1GetInfrastructureConfigurationCommand = async const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/GetInfrastructureConfiguration"; const query: any = map({ - infrastructureConfigurationArn: [, input.infrastructureConfigurationArn!], + infrastructureConfigurationArn: [ + , + __expectNonNull(input.infrastructureConfigurationArn!, `infrastructureConfigurationArn`), + ], }); let body: any; return new __HttpRequest({ @@ -1486,7 +1498,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-inspector2/src/protocols/Aws_restJson1.ts b/clients/client-inspector2/src/protocols/Aws_restJson1.ts index 0ef1b0f9a991..fc9a7753b5d5 100644 --- a/clients/client-inspector2/src/protocols/Aws_restJson1.ts +++ b/clients/client-inspector2/src/protocols/Aws_restJson1.ts @@ -934,7 +934,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-iot-1click-devices-service/src/protocols/Aws_restJson1.ts b/clients/client-iot-1click-devices-service/src/protocols/Aws_restJson1.ts index c054e7a48468..73fc4589b9db 100644 --- a/clients/client-iot-1click-devices-service/src/protocols/Aws_restJson1.ts +++ b/clients/client-iot-1click-devices-service/src/protocols/Aws_restJson1.ts @@ -208,13 +208,13 @@ export const serializeAws_restJson1ListDeviceEventsCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "DeviceId", () => input.DeviceId!, "{DeviceId}", false); const query: any = map({ fromTimeStamp: [ - () => input.FromTimeStamp !== void 0, + __expectNonNull(input.FromTimeStamp, `FromTimeStamp`) != null, () => (input.FromTimeStamp!.toISOString().split(".")[0] + "Z").toString(), ], maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], nextToken: [, input.NextToken!], toTimeStamp: [ - () => input.ToTimeStamp !== void 0, + __expectNonNull(input.ToTimeStamp, `ToTimeStamp`) != null, () => (input.ToTimeStamp!.toISOString().split(".")[0] + "Z").toString(), ], }); @@ -331,7 +331,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-iot-1click-projects/src/protocols/Aws_restJson1.ts b/clients/client-iot-1click-projects/src/protocols/Aws_restJson1.ts index 6abd1ea9469a..aa884a574d33 100644 --- a/clients/client-iot-1click-projects/src/protocols/Aws_restJson1.ts +++ b/clients/client-iot-1click-projects/src/protocols/Aws_restJson1.ts @@ -434,7 +434,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-iot-events/src/protocols/Aws_restJson1.ts b/clients/client-iot-events/src/protocols/Aws_restJson1.ts index 0f3e96e4cda2..963a17655941 100644 --- a/clients/client-iot-events/src/protocols/Aws_restJson1.ts +++ b/clients/client-iot-events/src/protocols/Aws_restJson1.ts @@ -659,7 +659,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; return new __HttpRequest({ @@ -737,7 +737,7 @@ export const serializeAws_restJson1TagResourceCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; body = JSON.stringify({ @@ -763,8 +763,11 @@ export const serializeAws_restJson1UntagResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.resourceArn!], - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-iot-roborunner/src/protocols/Aws_restJson1.ts b/clients/client-iot-roborunner/src/protocols/Aws_restJson1.ts index 34ad222bfd3e..1436c27d00fa 100644 --- a/clients/client-iot-roborunner/src/protocols/Aws_restJson1.ts +++ b/clients/client-iot-roborunner/src/protocols/Aws_restJson1.ts @@ -281,7 +281,7 @@ export const serializeAws_restJson1GetDestinationCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/getDestination"; const query: any = map({ - id: [, input.id!], + id: [, __expectNonNull(input.id!, `id`)], }); let body: any; return new __HttpRequest({ @@ -304,7 +304,7 @@ export const serializeAws_restJson1GetSiteCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/getSite"; const query: any = map({ - id: [, input.id!], + id: [, __expectNonNull(input.id!, `id`)], }); let body: any; return new __HttpRequest({ @@ -327,7 +327,7 @@ export const serializeAws_restJson1GetWorkerCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/getWorker"; const query: any = map({ - id: [, input.id!], + id: [, __expectNonNull(input.id!, `id`)], }); let body: any; return new __HttpRequest({ @@ -350,7 +350,7 @@ export const serializeAws_restJson1GetWorkerFleetCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/getWorkerFleet"; const query: any = map({ - id: [, input.id!], + id: [, __expectNonNull(input.id!, `id`)], }); let body: any; return new __HttpRequest({ @@ -373,7 +373,7 @@ export const serializeAws_restJson1ListDestinationsCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/listDestinations"; const query: any = map({ - site: [, input.site!], + site: [, __expectNonNull(input.site!, `site`)], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], nextToken: [, input.nextToken!], state: [, input.state!], @@ -423,7 +423,7 @@ export const serializeAws_restJson1ListWorkerFleetsCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/listWorkerFleets"; const query: any = map({ - site: [, input.site!], + site: [, __expectNonNull(input.site!, `site`)], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], nextToken: [, input.nextToken!], }); @@ -448,7 +448,7 @@ export const serializeAws_restJson1ListWorkersCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/listWorkers"; const query: any = map({ - site: [, input.site!], + site: [, __expectNonNull(input.site!, `site`)], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], nextToken: [, input.nextToken!], fleet: [, input.fleet!], diff --git a/clients/client-iot-wireless/src/protocols/Aws_restJson1.ts b/clients/client-iot-wireless/src/protocols/Aws_restJson1.ts index ff499edf886f..9bf7aa7ad8af 100644 --- a/clients/client-iot-wireless/src/protocols/Aws_restJson1.ts +++ b/clients/client-iot-wireless/src/protocols/Aws_restJson1.ts @@ -1061,7 +1061,7 @@ export const serializeAws_restJson1DeleteQueuedMessagesCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/wireless-devices/{Id}/data"; resolvedPath = __resolvedPath(resolvedPath, input, "Id", () => input.Id!, "{Id}", false); const query: any = map({ - messageId: [, input.MessageId!], + messageId: [, __expectNonNull(input.MessageId!, `MessageId`)], WirelessDeviceType: [, input.WirelessDeviceType!], }); let body: any; @@ -1196,7 +1196,7 @@ export const serializeAws_restJson1DisassociateAwsAccountFromPartnerAccountComma false ); const query: any = map({ - partnerType: [, input.PartnerType!], + partnerType: [, __expectNonNull(input.PartnerType!, `PartnerType`)], }); let body: any; return new __HttpRequest({ @@ -1556,7 +1556,7 @@ export const serializeAws_restJson1GetPartnerAccountCommand = async ( false ); const query: any = map({ - partnerType: [, input.PartnerType!], + partnerType: [, __expectNonNull(input.PartnerType!, `PartnerType`)], }); let body: any; return new __HttpRequest({ @@ -1588,7 +1588,7 @@ export const serializeAws_restJson1GetPositionCommand = async ( false ); const query: any = map({ - resourceType: [, input.ResourceType!], + resourceType: [, __expectNonNull(input.ResourceType!, `ResourceType`)], }); let body: any; return new __HttpRequest({ @@ -1621,7 +1621,7 @@ export const serializeAws_restJson1GetPositionConfigurationCommand = async ( false ); const query: any = map({ - resourceType: [, input.ResourceType!], + resourceType: [, __expectNonNull(input.ResourceType!, `ResourceType`)], }); let body: any; return new __HttpRequest({ @@ -1646,7 +1646,7 @@ export const serializeAws_restJson1GetResourceEventConfigurationCommand = async `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/event-configurations/{Identifier}"; resolvedPath = __resolvedPath(resolvedPath, input, "Identifier", () => input.Identifier!, "{Identifier}", false); const query: any = map({ - identifierType: [, input.IdentifierType!], + identifierType: [, __expectNonNull(input.IdentifierType!, `IdentifierType`)], partnerType: [, input.PartnerType!], }); let body: any; @@ -1679,7 +1679,7 @@ export const serializeAws_restJson1GetResourceLogLevelCommand = async ( false ); const query: any = map({ - resourceType: [, input.ResourceType!], + resourceType: [, __expectNonNull(input.ResourceType!, `ResourceType`)], }); let body: any; return new __HttpRequest({ @@ -1747,7 +1747,7 @@ export const serializeAws_restJson1GetWirelessDeviceCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/wireless-devices/{Identifier}"; resolvedPath = __resolvedPath(resolvedPath, input, "Identifier", () => input.Identifier!, "{Identifier}", false); const query: any = map({ - identifierType: [, input.IdentifierType!], + identifierType: [, __expectNonNull(input.IdentifierType!, `IdentifierType`)], }); let body: any; return new __HttpRequest({ @@ -1801,7 +1801,7 @@ export const serializeAws_restJson1GetWirelessGatewayCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/wireless-gateways/{Identifier}"; resolvedPath = __resolvedPath(resolvedPath, input, "Identifier", () => input.Identifier!, "{Identifier}", false); const query: any = map({ - identifierType: [, input.IdentifierType!], + identifierType: [, __expectNonNull(input.IdentifierType!, `IdentifierType`)], }); let body: any; return new __HttpRequest({ @@ -1986,7 +1986,7 @@ export const serializeAws_restJson1ListEventConfigurationsCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/event-configurations"; const query: any = map({ - resourceType: [, input.ResourceType!], + resourceType: [, __expectNonNull(input.ResourceType!, `ResourceType`)], maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], nextToken: [, input.NextToken!], }); @@ -2211,7 +2211,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.ResourceArn!], + resourceArn: [, __expectNonNull(input.ResourceArn!, `ResourceArn`)], }); let body: any; return new __HttpRequest({ @@ -2326,7 +2326,7 @@ export const serializeAws_restJson1PutPositionConfigurationCommand = async ( false ); const query: any = map({ - resourceType: [, input.ResourceType!], + resourceType: [, __expectNonNull(input.ResourceType!, `ResourceType`)], }); let body: any; body = JSON.stringify({ @@ -2366,7 +2366,7 @@ export const serializeAws_restJson1PutResourceLogLevelCommand = async ( false ); const query: any = map({ - resourceType: [, input.ResourceType!], + resourceType: [, __expectNonNull(input.ResourceType!, `ResourceType`)], }); let body: any; body = JSON.stringify({ @@ -2423,7 +2423,7 @@ export const serializeAws_restJson1ResetResourceLogLevelCommand = async ( false ); const query: any = map({ - resourceType: [, input.ResourceType!], + resourceType: [, __expectNonNull(input.ResourceType!, `ResourceType`)], }); let body: any; return new __HttpRequest({ @@ -2612,7 +2612,7 @@ export const serializeAws_restJson1TagResourceCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.ResourceArn!], + resourceArn: [, __expectNonNull(input.ResourceArn!, `ResourceArn`)], }); let body: any; body = JSON.stringify({ @@ -2659,8 +2659,11 @@ export const serializeAws_restJson1UntagResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.ResourceArn!], - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + resourceArn: [, __expectNonNull(input.ResourceArn!, `ResourceArn`)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ @@ -2909,7 +2912,7 @@ export const serializeAws_restJson1UpdatePartnerAccountCommand = async ( false ); const query: any = map({ - partnerType: [, input.PartnerType!], + partnerType: [, __expectNonNull(input.PartnerType!, `PartnerType`)], }); let body: any; body = JSON.stringify({ @@ -2946,7 +2949,7 @@ export const serializeAws_restJson1UpdatePositionCommand = async ( false ); const query: any = map({ - resourceType: [, input.ResourceType!], + resourceType: [, __expectNonNull(input.ResourceType!, `ResourceType`)], }); let body: any; body = JSON.stringify({ @@ -2976,7 +2979,7 @@ export const serializeAws_restJson1UpdateResourceEventConfigurationCommand = asy `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/event-configurations/{Identifier}"; resolvedPath = __resolvedPath(resolvedPath, input, "Identifier", () => input.Identifier!, "{Identifier}", false); const query: any = map({ - identifierType: [, input.IdentifierType!], + identifierType: [, __expectNonNull(input.IdentifierType!, `IdentifierType`)], partnerType: [, input.PartnerType!], }); let body: any; diff --git a/clients/client-iot/src/protocols/Aws_restJson1.ts b/clients/client-iot/src/protocols/Aws_restJson1.ts index e00913df506e..d09ddd7af6ae 100644 --- a/clients/client-iot/src/protocols/Aws_restJson1.ts +++ b/clients/client-iot/src/protocols/Aws_restJson1.ts @@ -1103,7 +1103,7 @@ export const serializeAws_restJson1AttachSecurityProfileCommand = async ( false ); const query: any = map({ - securityProfileTargetArn: [, input.securityProfileTargetArn!], + securityProfileTargetArn: [, __expectNonNull(input.securityProfileTargetArn!, `securityProfileTargetArn`)], }); let body: any; return new __HttpRequest({ @@ -3142,8 +3142,8 @@ export const serializeAws_restJson1DeleteV2LoggingLevelCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v2LoggingLevel"; const query: any = map({ - targetType: [, input.targetType!], - targetName: [, input.targetName!], + targetType: [, __expectNonNull(input.targetType!, `targetType`)], + targetName: [, __expectNonNull(input.targetName!, `targetName`)], }); let body: any; return new __HttpRequest({ @@ -4068,7 +4068,7 @@ export const serializeAws_restJson1DetachSecurityProfileCommand = async ( false ); const query: any = map({ - securityProfileTargetArn: [, input.securityProfileTargetArn!], + securityProfileTargetArn: [, __expectNonNull(input.securityProfileTargetArn!, `securityProfileTargetArn`)], }); let body: any; return new __HttpRequest({ @@ -4632,9 +4632,9 @@ export const serializeAws_restJson1ListAuditMitigationActionsExecutionsCommand = const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/audit/mitigationactions/executions"; const query: any = map({ - taskId: [, input.taskId!], + taskId: [, __expectNonNull(input.taskId!, `taskId`)], actionStatus: [, input.actionStatus!], - findingId: [, input.findingId!], + findingId: [, __expectNonNull(input.findingId!, `findingId`)], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], nextToken: [, input.nextToken!], }); @@ -4666,10 +4666,13 @@ export const serializeAws_restJson1ListAuditMitigationActionsTasksCommand = asyn maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], nextToken: [, input.nextToken!], startTime: [ - () => input.startTime !== void 0, + __expectNonNull(input.startTime, `startTime`) != null, () => (input.startTime!.toISOString().split(".")[0] + "Z").toString(), ], - endTime: [() => input.endTime !== void 0, () => (input.endTime!.toISOString().split(".")[0] + "Z").toString()], + endTime: [ + __expectNonNull(input.endTime, `endTime`) != null, + () => (input.endTime!.toISOString().split(".")[0] + "Z").toString(), + ], }); let body: any; return new __HttpRequest({ @@ -4724,10 +4727,13 @@ export const serializeAws_restJson1ListAuditTasksCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/audit/tasks"; const query: any = map({ startTime: [ - () => input.startTime !== void 0, + __expectNonNull(input.startTime, `startTime`) != null, () => (input.startTime!.toISOString().split(".")[0] + "Z").toString(), ], - endTime: [() => input.endTime !== void 0, () => (input.endTime!.toISOString().split(".")[0] + "Z").toString()], + endTime: [ + __expectNonNull(input.endTime, `endTime`) != null, + () => (input.endTime!.toISOString().split(".")[0] + "Z").toString(), + ], taskType: [, input.taskType!], taskStatus: [, input.taskStatus!], nextToken: [, input.nextToken!], @@ -4951,10 +4957,13 @@ export const serializeAws_restJson1ListDetectMitigationActionsTasksCommand = asy maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], nextToken: [, input.nextToken!], startTime: [ - () => input.startTime !== void 0, + __expectNonNull(input.startTime, `startTime`) != null, () => (input.startTime!.toISOString().split(".")[0] + "Z").toString(), ], - endTime: [() => input.endTime !== void 0, () => (input.endTime!.toISOString().split(".")[0] + "Z").toString()], + endTime: [ + __expectNonNull(input.endTime, `endTime`) != null, + () => (input.endTime!.toISOString().split(".")[0] + "Z").toString(), + ], }); let body: any; return new __HttpRequest({ @@ -5206,15 +5215,18 @@ export const serializeAws_restJson1ListMetricValuesCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/metric-values"; const query: any = map({ - thingName: [, input.thingName!], - metricName: [, input.metricName!], + thingName: [, __expectNonNull(input.thingName!, `thingName`)], + metricName: [, __expectNonNull(input.metricName!, `metricName`)], dimensionName: [, input.dimensionName!], dimensionValueOperator: [, input.dimensionValueOperator!], startTime: [ - () => input.startTime !== void 0, + __expectNonNull(input.startTime, `startTime`) != null, () => (input.startTime!.toISOString().split(".")[0] + "Z").toString(), ], - endTime: [() => input.endTime !== void 0, () => (input.endTime!.toISOString().split(".")[0] + "Z").toString()], + endTime: [ + __expectNonNull(input.endTime, `endTime`) != null, + () => (input.endTime!.toISOString().split(".")[0] + "Z").toString(), + ], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], nextToken: [, input.nextToken!], }); @@ -5502,7 +5514,7 @@ export const serializeAws_restJson1ListRelatedResourcesForAuditFindingCommand = const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/audit/relatedResources"; const query: any = map({ - findingId: [, input.findingId!], + findingId: [, __expectNonNull(input.findingId!, `findingId`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -5606,7 +5618,7 @@ export const serializeAws_restJson1ListSecurityProfilesForTargetCommand = async nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], recursive: [() => input.recursive !== void 0, () => input.recursive!.toString()], - securityProfileTargetArn: [, input.securityProfileTargetArn!], + securityProfileTargetArn: [, __expectNonNull(input.securityProfileTargetArn!, `securityProfileTargetArn`)], }); let body: any; return new __HttpRequest({ @@ -5654,7 +5666,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], nextToken: [, input.nextToken!], }); let body: any; @@ -5820,7 +5832,7 @@ export const serializeAws_restJson1ListThingRegistrationTaskReportsCommand = asy "/thing-registration-tasks/{taskId}/reports"; resolvedPath = __resolvedPath(resolvedPath, input, "taskId", () => input.taskId!, "{taskId}", false); const query: any = map({ - reportType: [, input.reportType!], + reportType: [, __expectNonNull(input.reportType!, `reportType`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -6070,10 +6082,13 @@ export const serializeAws_restJson1ListViolationEventsCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/violation-events"; const query: any = map({ startTime: [ - () => input.startTime !== void 0, + __expectNonNull(input.startTime, `startTime`) != null, () => (input.startTime!.toISOString().split(".")[0] + "Z").toString(), ], - endTime: [() => input.endTime !== void 0, () => (input.endTime!.toISOString().split(".")[0] + "Z").toString()], + endTime: [ + __expectNonNull(input.endTime, `endTime`) != null, + () => (input.endTime!.toISOString().split(".")[0] + "Z").toString(), + ], thingName: [, input.thingName!], securityProfileName: [, input.securityProfileName!], behaviorCriteriaType: [, input.behaviorCriteriaType!], @@ -6794,7 +6809,7 @@ export const serializeAws_restJson1TransferCertificateCommand = async ( false ); const query: any = map({ - targetAwsAccount: [, input.targetAwsAccount!], + targetAwsAccount: [, __expectNonNull(input.targetAwsAccount!, `targetAwsAccount`)], }); let body: any; body = JSON.stringify({ @@ -7034,7 +7049,7 @@ export const serializeAws_restJson1UpdateCertificateCommand = async ( false ); const query: any = map({ - newStatus: [, input.newStatus!], + newStatus: [, __expectNonNull(input.newStatus!, `newStatus`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-iotanalytics/src/protocols/Aws_restJson1.ts b/clients/client-iotanalytics/src/protocols/Aws_restJson1.ts index a9989751e9f5..7c5235635e60 100644 --- a/clients/client-iotanalytics/src/protocols/Aws_restJson1.ts +++ b/clients/client-iotanalytics/src/protocols/Aws_restJson1.ts @@ -804,7 +804,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; return new __HttpRequest({ @@ -950,7 +950,7 @@ export const serializeAws_restJson1TagResourceCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; body = JSON.stringify({ @@ -976,8 +976,11 @@ export const serializeAws_restJson1UntagResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.resourceArn!], - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-iotdeviceadvisor/src/protocols/Aws_restJson1.ts b/clients/client-iotdeviceadvisor/src/protocols/Aws_restJson1.ts index affe9bbbac4c..bc37939b0a85 100644 --- a/clients/client-iotdeviceadvisor/src/protocols/Aws_restJson1.ts +++ b/clients/client-iotdeviceadvisor/src/protocols/Aws_restJson1.ts @@ -412,7 +412,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-iotfleethub/src/protocols/Aws_restJson1.ts b/clients/client-iotfleethub/src/protocols/Aws_restJson1.ts index 60bd0cc271ab..74e90ae44afc 100644 --- a/clients/client-iotfleethub/src/protocols/Aws_restJson1.ts +++ b/clients/client-iotfleethub/src/protocols/Aws_restJson1.ts @@ -208,7 +208,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-iotsitewise/src/protocols/Aws_restJson1.ts b/clients/client-iotsitewise/src/protocols/Aws_restJson1.ts index 8c8419fc5128..da3e79e254ef 100644 --- a/clients/client-iotsitewise/src/protocols/Aws_restJson1.ts +++ b/clients/client-iotsitewise/src/protocols/Aws_restJson1.ts @@ -347,9 +347,9 @@ export const serializeAws_restJson1AssociateTimeSeriesToAssetPropertyCommand = a }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/timeseries/associate"; const query: any = map({ - alias: [, input.alias!], - assetId: [, input.assetId!], - propertyId: [, input.propertyId!], + alias: [, __expectNonNull(input.alias!, `alias`)], + assetId: [, __expectNonNull(input.assetId!, `assetId`)], + propertyId: [, __expectNonNull(input.propertyId!, `propertyId`)], }); let body: any; body = JSON.stringify({ @@ -1632,9 +1632,9 @@ export const serializeAws_restJson1DisassociateTimeSeriesFromAssetPropertyComman const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/timeseries/disassociate"; const query: any = map({ - alias: [, input.alias!], - assetId: [, input.assetId!], - propertyId: [, input.propertyId!], + alias: [, __expectNonNull(input.alias!, `alias`)], + assetId: [, __expectNonNull(input.assetId!, `assetId`)], + propertyId: [, __expectNonNull(input.propertyId!, `propertyId`)], }); let body: any; body = JSON.stringify({ @@ -1671,16 +1671,19 @@ export const serializeAws_restJson1GetAssetPropertyAggregatesCommand = async ( propertyId: [, input.propertyId!], propertyAlias: [, input.propertyAlias!], aggregateTypes: [ - () => input.aggregateTypes !== void 0, + __expectNonNull(input.aggregateTypes, `aggregateTypes`) != null, () => (input.aggregateTypes! || []).map((_entry) => _entry as any), ], - resolution: [, input.resolution!], + resolution: [, __expectNonNull(input.resolution!, `resolution`)], qualities: [() => input.qualities !== void 0, () => (input.qualities! || []).map((_entry) => _entry as any)], startDate: [ - () => input.startDate !== void 0, + __expectNonNull(input.startDate, `startDate`) != null, () => (input.startDate!.toISOString().split(".")[0] + "Z").toString(), ], - endDate: [() => input.endDate !== void 0, () => (input.endDate!.toISOString().split(".")[0] + "Z").toString()], + endDate: [ + __expectNonNull(input.endDate, `endDate`) != null, + () => (input.endDate!.toISOString().split(".")[0] + "Z").toString(), + ], timeOrdering: [, input.timeOrdering!], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], @@ -1790,18 +1793,27 @@ export const serializeAws_restJson1GetInterpolatedAssetPropertyValuesCommand = a assetId: [, input.assetId!], propertyId: [, input.propertyId!], propertyAlias: [, input.propertyAlias!], - startTimeInSeconds: [() => input.startTimeInSeconds !== void 0, () => input.startTimeInSeconds!.toString()], + startTimeInSeconds: [ + __expectNonNull(input.startTimeInSeconds, `startTimeInSeconds`) != null, + () => input.startTimeInSeconds!.toString(), + ], startTimeOffsetInNanos: [ () => input.startTimeOffsetInNanos !== void 0, () => input.startTimeOffsetInNanos!.toString(), ], - endTimeInSeconds: [() => input.endTimeInSeconds !== void 0, () => input.endTimeInSeconds!.toString()], + endTimeInSeconds: [ + __expectNonNull(input.endTimeInSeconds, `endTimeInSeconds`) != null, + () => input.endTimeInSeconds!.toString(), + ], endTimeOffsetInNanos: [() => input.endTimeOffsetInNanos !== void 0, () => input.endTimeOffsetInNanos!.toString()], - quality: [, input.quality!], - intervalInSeconds: [() => input.intervalInSeconds !== void 0, () => input.intervalInSeconds!.toString()], + quality: [, __expectNonNull(input.quality!, `quality`)], + intervalInSeconds: [ + __expectNonNull(input.intervalInSeconds, `intervalInSeconds`) != null, + () => input.intervalInSeconds!.toString(), + ], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], - type: [, input.type!], + type: [, __expectNonNull(input.type!, `type`)], intervalWindowInSeconds: [ () => input.intervalWindowInSeconds !== void 0, () => input.intervalWindowInSeconds!.toString(), @@ -1979,7 +1991,7 @@ export const serializeAws_restJson1ListAssetRelationshipsCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/assets/{assetId}/assetRelationships"; resolvedPath = __resolvedPath(resolvedPath, input, "assetId", () => input.assetId!, "{assetId}", false); const query: any = map({ - traversalType: [, input.traversalType!], + traversalType: [, __expectNonNull(input.traversalType!, `traversalType`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -2111,7 +2123,7 @@ export const serializeAws_restJson1ListDashboardsCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/dashboards"; const query: any = map({ - projectId: [, input.projectId!], + projectId: [, __expectNonNull(input.projectId!, `projectId`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -2238,7 +2250,7 @@ export const serializeAws_restJson1ListProjectsCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/projects"; const query: any = map({ - portalId: [, input.portalId!], + portalId: [, __expectNonNull(input.portalId!, `portalId`)], nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], }); @@ -2270,7 +2282,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; let { hostname: resolvedHostname } = await context.endpoint(); @@ -2441,7 +2453,7 @@ export const serializeAws_restJson1TagResourceCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; body = JSON.stringify({ @@ -2474,8 +2486,11 @@ export const serializeAws_restJson1UntagResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceArn: [, input.resourceArn!], - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; let { hostname: resolvedHostname } = await context.endpoint(); diff --git a/clients/client-iottwinmaker/src/protocols/Aws_restJson1.ts b/clients/client-iottwinmaker/src/protocols/Aws_restJson1.ts index 8ccebc837b37..ee9194753ec3 100644 --- a/clients/client-iottwinmaker/src/protocols/Aws_restJson1.ts +++ b/clients/client-iottwinmaker/src/protocols/Aws_restJson1.ts @@ -958,8 +958,11 @@ export const serializeAws_restJson1UntagResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags"; const query: any = map({ - resourceARN: [, input.resourceARN!], - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + resourceARN: [, __expectNonNull(input.resourceARN!, `resourceARN`)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; let { hostname: resolvedHostname } = await context.endpoint(); diff --git a/clients/client-ivs/src/protocols/Aws_restJson1.ts b/clients/client-ivs/src/protocols/Aws_restJson1.ts index d45474b0e827..078ffb1b13be 100644 --- a/clients/client-ivs/src/protocols/Aws_restJson1.ts +++ b/clients/client-ivs/src/protocols/Aws_restJson1.ts @@ -774,7 +774,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-ivschat/src/protocols/Aws_restJson1.ts b/clients/client-ivschat/src/protocols/Aws_restJson1.ts index 15e13c5e4058..55a8cbc58654 100644 --- a/clients/client-ivschat/src/protocols/Aws_restJson1.ts +++ b/clients/client-ivschat/src/protocols/Aws_restJson1.ts @@ -460,7 +460,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-kafka/src/protocols/Aws_restJson1.ts b/clients/client-kafka/src/protocols/Aws_restJson1.ts index bac7400be486..9b8dc912cbe6 100644 --- a/clients/client-kafka/src/protocols/Aws_restJson1.ts +++ b/clients/client-kafka/src/protocols/Aws_restJson1.ts @@ -817,7 +817,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-kafkaconnect/src/protocols/Aws_restJson1.ts b/clients/client-kafkaconnect/src/protocols/Aws_restJson1.ts index e81b7e01331f..b035854ff15b 100644 --- a/clients/client-kafkaconnect/src/protocols/Aws_restJson1.ts +++ b/clients/client-kafkaconnect/src/protocols/Aws_restJson1.ts @@ -452,7 +452,7 @@ export const serializeAws_restJson1UpdateConnectorCommand = async ( false ); const query: any = map({ - currentVersion: [, input.currentVersion!], + currentVersion: [, __expectNonNull(input.currentVersion!, `currentVersion`)], }); let body: any; body = JSON.stringify({ diff --git a/clients/client-lambda/src/protocols/Aws_restJson1.ts b/clients/client-lambda/src/protocols/Aws_restJson1.ts index 2670e76fbc03..1a0178ba6e85 100644 --- a/clients/client-lambda/src/protocols/Aws_restJson1.ts +++ b/clients/client-lambda/src/protocols/Aws_restJson1.ts @@ -894,7 +894,7 @@ export const serializeAws_restJson1DeleteProvisionedConcurrencyConfigCommand = a false ); const query: any = map({ - Qualifier: [, input.Qualifier!], + Qualifier: [, __expectNonNull(input.Qualifier!, `Qualifier`)], }); let body: any; return new __HttpRequest({ @@ -1239,7 +1239,7 @@ export const serializeAws_restJson1GetLayerVersionByArnCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2018-10-31/layers"; const query: any = map({ find: [, "LayerVersion"], - Arn: [, input.Arn!], + Arn: [, __expectNonNull(input.Arn!, `Arn`)], }); let body: any; return new __HttpRequest({ @@ -1335,7 +1335,7 @@ export const serializeAws_restJson1GetProvisionedConcurrencyConfigCommand = asyn false ); const query: any = map({ - Qualifier: [, input.Qualifier!], + Qualifier: [, __expectNonNull(input.Qualifier!, `Qualifier`)], }); let body: any; return new __HttpRequest({ @@ -1985,7 +1985,7 @@ export const serializeAws_restJson1PutProvisionedConcurrencyConfigCommand = asyn false ); const query: any = map({ - Qualifier: [, input.Qualifier!], + Qualifier: [, __expectNonNull(input.Qualifier!, `Qualifier`)], }); let body: any; body = JSON.stringify({ @@ -2111,7 +2111,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2017-03-31/tags/{Resource}"; resolvedPath = __resolvedPath(resolvedPath, input, "Resource", () => input.Resource!, "{Resource}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-lex-model-building-service/src/protocols/Aws_restJson1.ts b/clients/client-lex-model-building-service/src/protocols/Aws_restJson1.ts index 0b5e499818f7..2b45591f595e 100644 --- a/clients/client-lex-model-building-service/src/protocols/Aws_restJson1.ts +++ b/clients/client-lex-model-building-service/src/protocols/Aws_restJson1.ts @@ -672,10 +672,10 @@ export const serializeAws_restJson1GetExportCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/exports"; const query: any = map({ - name: [, input.name!], - version: [, input.version!], - resourceType: [, input.resourceType!], - exportType: [, input.exportType!], + name: [, __expectNonNull(input.name!, `name`)], + version: [, __expectNonNull(input.version!, `version`)], + resourceType: [, __expectNonNull(input.resourceType!, `resourceType`)], + exportType: [, __expectNonNull(input.exportType!, `exportType`)], }); let body: any; return new __HttpRequest({ @@ -915,8 +915,11 @@ export const serializeAws_restJson1GetUtterancesViewCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "botName", () => input.botName!, "{botName}", false); const query: any = map({ view: [, "aggregation"], - bot_versions: [() => input.botVersions !== void 0, () => (input.botVersions! || []).map((_entry) => _entry as any)], - status_type: [, input.statusType!], + bot_versions: [ + __expectNonNull(input.botVersions, `botVersions`) != null, + () => (input.botVersions! || []).map((_entry) => _entry as any), + ], + status_type: [, __expectNonNull(input.statusType!, `statusType`)], }); let body: any; return new __HttpRequest({ @@ -1215,7 +1218,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-lex-models-v2/src/protocols/Aws_restJson1.ts b/clients/client-lex-models-v2/src/protocols/Aws_restJson1.ts index 30b8804e1329..40f5c89fd0b6 100644 --- a/clients/client-lex-models-v2/src/protocols/Aws_restJson1.ts +++ b/clients/client-lex-models-v2/src/protocols/Aws_restJson1.ts @@ -2101,7 +2101,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceARN}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceARN", () => input.resourceARN!, "{resourceARN}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-location/src/protocols/Aws_restJson1.ts b/clients/client-location/src/protocols/Aws_restJson1.ts index 981bfdf20c1c..f9d2f18edf3a 100644 --- a/clients/client-location/src/protocols/Aws_restJson1.ts +++ b/clients/client-location/src/protocols/Aws_restJson1.ts @@ -1886,7 +1886,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; let { hostname: resolvedHostname } = await context.endpoint(); diff --git a/clients/client-lookoutmetrics/src/protocols/Aws_restJson1.ts b/clients/client-lookoutmetrics/src/protocols/Aws_restJson1.ts index 836fa966f509..922d71338043 100644 --- a/clients/client-lookoutmetrics/src/protocols/Aws_restJson1.ts +++ b/clients/client-lookoutmetrics/src/protocols/Aws_restJson1.ts @@ -878,7 +878,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-lookoutvision/src/protocols/Aws_restJson1.ts b/clients/client-lookoutvision/src/protocols/Aws_restJson1.ts index eb018fd7a601..525470139066 100644 --- a/clients/client-lookoutvision/src/protocols/Aws_restJson1.ts +++ b/clients/client-lookoutvision/src/protocols/Aws_restJson1.ts @@ -672,7 +672,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2020-11-20/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-m2/src/protocols/Aws_restJson1.ts b/clients/client-m2/src/protocols/Aws_restJson1.ts index 73fcaff6466a..f8a62e728349 100644 --- a/clients/client-m2/src/protocols/Aws_restJson1.ts +++ b/clients/client-m2/src/protocols/Aws_restJson1.ts @@ -1070,7 +1070,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-macie2/src/protocols/Aws_restJson1.ts b/clients/client-macie2/src/protocols/Aws_restJson1.ts index a7ba2cbe115d..17f439c749b3 100644 --- a/clients/client-macie2/src/protocols/Aws_restJson1.ts +++ b/clients/client-macie2/src/protocols/Aws_restJson1.ts @@ -843,7 +843,7 @@ export const serializeAws_restJson1DisableOrganizationAdminAccountCommand = asyn const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/admin"; const query: any = map({ - adminAccountId: [, input.adminAccountId!], + adminAccountId: [, __expectNonNull(input.adminAccountId!, `adminAccountId`)], }); let body: any; return new __HttpRequest({ @@ -1796,7 +1796,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-managedblockchain/src/protocols/Aws_restJson1.ts b/clients/client-managedblockchain/src/protocols/Aws_restJson1.ts index b6fb31927469..1cb6b8f4d773 100644 --- a/clients/client-managedblockchain/src/protocols/Aws_restJson1.ts +++ b/clients/client-managedblockchain/src/protocols/Aws_restJson1.ts @@ -705,7 +705,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-marketplace-catalog/src/protocols/Aws_restJson1.ts b/clients/client-marketplace-catalog/src/protocols/Aws_restJson1.ts index 59ca71927e9e..2a4994ce17d2 100644 --- a/clients/client-marketplace-catalog/src/protocols/Aws_restJson1.ts +++ b/clients/client-marketplace-catalog/src/protocols/Aws_restJson1.ts @@ -57,8 +57,8 @@ export const serializeAws_restJson1CancelChangeSetCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/CancelChangeSet"; const query: any = map({ - catalog: [, input.Catalog!], - changeSetId: [, input.ChangeSetId!], + catalog: [, __expectNonNull(input.Catalog!, `Catalog`)], + changeSetId: [, __expectNonNull(input.ChangeSetId!, `ChangeSetId`)], }); let body: any; return new __HttpRequest({ @@ -81,8 +81,8 @@ export const serializeAws_restJson1DescribeChangeSetCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DescribeChangeSet"; const query: any = map({ - catalog: [, input.Catalog!], - changeSetId: [, input.ChangeSetId!], + catalog: [, __expectNonNull(input.Catalog!, `Catalog`)], + changeSetId: [, __expectNonNull(input.ChangeSetId!, `ChangeSetId`)], }); let body: any; return new __HttpRequest({ @@ -105,8 +105,8 @@ export const serializeAws_restJson1DescribeEntityCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/DescribeEntity"; const query: any = map({ - catalog: [, input.Catalog!], - entityId: [, input.EntityId!], + catalog: [, __expectNonNull(input.Catalog!, `Catalog`)], + entityId: [, __expectNonNull(input.EntityId!, `EntityId`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-mediaconnect/src/protocols/Aws_restJson1.ts b/clients/client-mediaconnect/src/protocols/Aws_restJson1.ts index 2fe111c06253..49da0e668d73 100644 --- a/clients/client-mediaconnect/src/protocols/Aws_restJson1.ts +++ b/clients/client-mediaconnect/src/protocols/Aws_restJson1.ts @@ -753,7 +753,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-medialive/src/protocols/Aws_restJson1.ts b/clients/client-medialive/src/protocols/Aws_restJson1.ts index 6cb1b3ac3283..d50b15566242 100644 --- a/clients/client-medialive/src/protocols/Aws_restJson1.ts +++ b/clients/client-medialive/src/protocols/Aws_restJson1.ts @@ -997,7 +997,10 @@ export const serializeAws_restJson1DeleteTagsCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/prod/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ @@ -1319,7 +1322,7 @@ export const serializeAws_restJson1ListInputDeviceTransfersCommand = async ( const query: any = map({ maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], nextToken: [, input.NextToken!], - transferType: [, input.TransferType!], + transferType: [, __expectNonNull(input.TransferType!, `TransferType`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-mediapackage-vod/src/protocols/Aws_restJson1.ts b/clients/client-mediapackage-vod/src/protocols/Aws_restJson1.ts index 918039f78a99..30b1bf125aa4 100644 --- a/clients/client-mediapackage-vod/src/protocols/Aws_restJson1.ts +++ b/clients/client-mediapackage-vod/src/protocols/Aws_restJson1.ts @@ -466,7 +466,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-mediapackage/src/protocols/Aws_restJson1.ts b/clients/client-mediapackage/src/protocols/Aws_restJson1.ts index 4eff7ffaa9b6..ab10b19bee02 100644 --- a/clients/client-mediapackage/src/protocols/Aws_restJson1.ts +++ b/clients/client-mediapackage/src/protocols/Aws_restJson1.ts @@ -504,7 +504,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-mediatailor/src/protocols/Aws_restJson1.ts b/clients/client-mediatailor/src/protocols/Aws_restJson1.ts index fa6f7b8faac7..b28242c70adf 100644 --- a/clients/client-mediatailor/src/protocols/Aws_restJson1.ts +++ b/clients/client-mediatailor/src/protocols/Aws_restJson1.ts @@ -901,7 +901,7 @@ export const serializeAws_restJson1ListAlertsCommand = async ( const query: any = map({ maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], nextToken: [, input.NextToken!], - resourceArn: [, input.ResourceArn!], + resourceArn: [, __expectNonNull(input.ResourceArn!, `ResourceArn`)], }); let body: any; return new __HttpRequest({ @@ -1266,7 +1266,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-mgn/src/protocols/Aws_restJson1.ts b/clients/client-mgn/src/protocols/Aws_restJson1.ts index 287d52902d14..0303767abfe6 100644 --- a/clients/client-mgn/src/protocols/Aws_restJson1.ts +++ b/clients/client-mgn/src/protocols/Aws_restJson1.ts @@ -909,7 +909,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-migration-hub-refactor-spaces/src/protocols/Aws_restJson1.ts b/clients/client-migration-hub-refactor-spaces/src/protocols/Aws_restJson1.ts index 7c8c840488d5..d909b2a8af77 100644 --- a/clients/client-migration-hub-refactor-spaces/src/protocols/Aws_restJson1.ts +++ b/clients/client-migration-hub-refactor-spaces/src/protocols/Aws_restJson1.ts @@ -864,7 +864,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-migrationhuborchestrator/src/protocols/Aws_restJson1.ts b/clients/client-migrationhuborchestrator/src/protocols/Aws_restJson1.ts index ce242dfcc43a..92f7e35dd557 100644 --- a/clients/client-migrationhuborchestrator/src/protocols/Aws_restJson1.ts +++ b/clients/client-migrationhuborchestrator/src/protocols/Aws_restJson1.ts @@ -226,8 +226,8 @@ export const serializeAws_restJson1DeleteWorkflowStepCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workflowstep/{id}"; resolvedPath = __resolvedPath(resolvedPath, input, "id", () => input.id!, "{id}", false); const query: any = map({ - stepGroupId: [, input.stepGroupId!], - workflowId: [, input.workflowId!], + stepGroupId: [, __expectNonNull(input.stepGroupId!, `stepGroupId`)], + workflowId: [, __expectNonNull(input.workflowId!, `workflowId`)], }); let body: any; return new __HttpRequest({ @@ -251,7 +251,7 @@ export const serializeAws_restJson1DeleteWorkflowStepGroupCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workflowstepgroup/{id}"; resolvedPath = __resolvedPath(resolvedPath, input, "id", () => input.id!, "{id}", false); const query: any = map({ - workflowId: [, input.workflowId!], + workflowId: [, __expectNonNull(input.workflowId!, `workflowId`)], }); let body: any; return new __HttpRequest({ @@ -296,8 +296,8 @@ export const serializeAws_restJson1GetTemplateStepCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/templatestep/{id}"; resolvedPath = __resolvedPath(resolvedPath, input, "id", () => input.id!, "{id}", false); const query: any = map({ - templateId: [, input.templateId!], - stepGroupId: [, input.stepGroupId!], + templateId: [, __expectNonNull(input.templateId!, `templateId`)], + stepGroupId: [, __expectNonNull(input.stepGroupId!, `stepGroupId`)], }); let body: any; return new __HttpRequest({ @@ -363,8 +363,8 @@ export const serializeAws_restJson1GetWorkflowStepCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workflowstep/{id}"; resolvedPath = __resolvedPath(resolvedPath, input, "id", () => input.id!, "{id}", false); const query: any = map({ - workflowId: [, input.workflowId!], - stepGroupId: [, input.stepGroupId!], + workflowId: [, __expectNonNull(input.workflowId!, `workflowId`)], + stepGroupId: [, __expectNonNull(input.stepGroupId!, `stepGroupId`)], }); let body: any; return new __HttpRequest({ @@ -388,7 +388,7 @@ export const serializeAws_restJson1GetWorkflowStepGroupCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workflowstepgroup/{id}"; resolvedPath = __resolvedPath(resolvedPath, input, "id", () => input.id!, "{id}", false); const query: any = map({ - workflowId: [, input.workflowId!], + workflowId: [, __expectNonNull(input.workflowId!, `workflowId`)], }); let body: any; return new __HttpRequest({ @@ -509,8 +509,8 @@ export const serializeAws_restJson1ListTemplateStepsCommand = async ( const query: any = map({ maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], nextToken: [, input.nextToken!], - templateId: [, input.templateId!], - stepGroupId: [, input.stepGroupId!], + templateId: [, __expectNonNull(input.templateId!, `templateId`)], + stepGroupId: [, __expectNonNull(input.stepGroupId!, `stepGroupId`)], }); let body: any; return new __HttpRequest({ @@ -563,7 +563,7 @@ export const serializeAws_restJson1ListWorkflowStepGroupsCommand = async ( const query: any = map({ nextToken: [, input.nextToken!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], - workflowId: [, input.workflowId!], + workflowId: [, __expectNonNull(input.workflowId!, `workflowId`)], }); let body: any; return new __HttpRequest({ @@ -615,8 +615,8 @@ export const serializeAws_restJson1RetryWorkflowStepCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/retryworkflowstep/{id}"; resolvedPath = __resolvedPath(resolvedPath, input, "id", () => input.id!, "{id}", false); const query: any = map({ - workflowId: [, input.workflowId!], - stepGroupId: [, input.stepGroupId!], + workflowId: [, __expectNonNull(input.workflowId!, `workflowId`)], + stepGroupId: [, __expectNonNull(input.stepGroupId!, `stepGroupId`)], }); let body: any; return new __HttpRequest({ @@ -707,7 +707,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ @@ -803,7 +806,7 @@ export const serializeAws_restJson1UpdateWorkflowStepGroupCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workflowstepgroup/{id}"; resolvedPath = __resolvedPath(resolvedPath, input, "id", () => input.id!, "{id}", false); const query: any = map({ - workflowId: [, input.workflowId!], + workflowId: [, __expectNonNull(input.workflowId!, `workflowId`)], }); let body: any; body = JSON.stringify({ diff --git a/clients/client-mobile/src/protocols/Aws_restJson1.ts b/clients/client-mobile/src/protocols/Aws_restJson1.ts index ba19e2f4518d..ea8807c059c9 100644 --- a/clients/client-mobile/src/protocols/Aws_restJson1.ts +++ b/clients/client-mobile/src/protocols/Aws_restJson1.ts @@ -122,7 +122,7 @@ export const serializeAws_restJson1DescribeProjectCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/project"; const query: any = map({ - projectId: [, input.projectId!], + projectId: [, __expectNonNull(input.projectId!, `projectId`)], syncFromResources: [() => input.syncFromResources !== void 0, () => input.syncFromResources!.toString()], }); let body: any; @@ -241,7 +241,7 @@ export const serializeAws_restJson1UpdateProjectCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/update"; const query: any = map({ - projectId: [, input.projectId!], + projectId: [, __expectNonNull(input.projectId!, `projectId`)], }); let body: any; if (input.contents !== undefined) { diff --git a/clients/client-mq/src/protocols/Aws_restJson1.ts b/clients/client-mq/src/protocols/Aws_restJson1.ts index 07dd543bcaa0..68a3563b9271 100644 --- a/clients/client-mq/src/protocols/Aws_restJson1.ts +++ b/clients/client-mq/src/protocols/Aws_restJson1.ts @@ -259,7 +259,10 @@ export const serializeAws_restJson1DeleteTagsCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-mwaa/src/protocols/Aws_restJson1.ts b/clients/client-mwaa/src/protocols/Aws_restJson1.ts index f740eb8c211c..a9178443ac6c 100644 --- a/clients/client-mwaa/src/protocols/Aws_restJson1.ts +++ b/clients/client-mwaa/src/protocols/Aws_restJson1.ts @@ -372,7 +372,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; let { hostname: resolvedHostname } = await context.endpoint(); diff --git a/clients/client-networkmanager/src/protocols/Aws_restJson1.ts b/clients/client-networkmanager/src/protocols/Aws_restJson1.ts index ae3e00e8799a..211f0a03837b 100644 --- a/clients/client-networkmanager/src/protocols/Aws_restJson1.ts +++ b/clients/client-networkmanager/src/protocols/Aws_restJson1.ts @@ -1345,8 +1345,8 @@ export const serializeAws_restJson1DisassociateLinkCommand = async ( false ); const query: any = map({ - deviceId: [, input.DeviceId!], - linkId: [, input.LinkId!], + deviceId: [, __expectNonNull(input.DeviceId!, `DeviceId`)], + linkId: [, __expectNonNull(input.LinkId!, `LinkId`)], }); let body: any; return new __HttpRequest({ @@ -2794,7 +2794,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-nimble/src/protocols/Aws_restJson1.ts b/clients/client-nimble/src/protocols/Aws_restJson1.ts index d3e9de610385..64690082f618 100644 --- a/clients/client-nimble/src/protocols/Aws_restJson1.ts +++ b/clients/client-nimble/src/protocols/Aws_restJson1.ts @@ -754,11 +754,11 @@ export const serializeAws_restJson1GetLaunchProfileInitializationCommand = async resolvedPath = __resolvedPath(resolvedPath, input, "studioId", () => input.studioId!, "{studioId}", false); const query: any = map({ launchProfileProtocolVersions: [ - () => input.launchProfileProtocolVersions !== void 0, + __expectNonNull(input.launchProfileProtocolVersions, `launchProfileProtocolVersions`) != null, () => (input.launchProfileProtocolVersions! || []).map((_entry) => _entry as any), ], - launchPurpose: [, input.launchPurpose!], - platform: [, input.platform!], + launchPurpose: [, __expectNonNull(input.launchPurpose!, `launchPurpose`)], + platform: [, __expectNonNull(input.platform!, `platform`)], }); let body: any; return new __HttpRequest({ @@ -1400,7 +1400,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2020-08-01/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-opensearch/src/protocols/Aws_restJson1.ts b/clients/client-opensearch/src/protocols/Aws_restJson1.ts index d4b8a68299ab..456bb2812d2b 100644 --- a/clients/client-opensearch/src/protocols/Aws_restJson1.ts +++ b/clients/client-opensearch/src/protocols/Aws_restJson1.ts @@ -1228,7 +1228,7 @@ export const serializeAws_restJson1ListTagsCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2021-01-01/tags"; const query: any = map({ - arn: [, input.ARN!], + arn: [, __expectNonNull(input.ARN!, `ARN`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-outposts/src/protocols/Aws_restJson1.ts b/clients/client-outposts/src/protocols/Aws_restJson1.ts index 76f767b9f142..8c38f3275921 100644 --- a/clients/client-outposts/src/protocols/Aws_restJson1.ts +++ b/clients/client-outposts/src/protocols/Aws_restJson1.ts @@ -390,7 +390,7 @@ export const serializeAws_restJson1GetSiteAddressCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/sites/{SiteId}/address"; resolvedPath = __resolvedPath(resolvedPath, input, "SiteId", () => input.SiteId!, "{SiteId}", false); const query: any = map({ - AddressType: [, input.AddressType!], + AddressType: [, __expectNonNull(input.AddressType!, `AddressType`)], }); let body: any; return new __HttpRequest({ @@ -662,7 +662,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-panorama/src/protocols/Aws_restJson1.ts b/clients/client-panorama/src/protocols/Aws_restJson1.ts index 1cc9782f5458..15f47f8d3869 100644 --- a/clients/client-panorama/src/protocols/Aws_restJson1.ts +++ b/clients/client-panorama/src/protocols/Aws_restJson1.ts @@ -1067,7 +1067,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-pinpoint-email/src/protocols/Aws_restJson1.ts b/clients/client-pinpoint-email/src/protocols/Aws_restJson1.ts index afd0611d8976..2580bab7bbee 100644 --- a/clients/client-pinpoint-email/src/protocols/Aws_restJson1.ts +++ b/clients/client-pinpoint-email/src/protocols/Aws_restJson1.ts @@ -522,7 +522,7 @@ export const serializeAws_restJson1GetBlacklistReportsCommand = async ( "/v1/email/deliverability-dashboard/blacklist-report"; const query: any = map({ BlacklistItemNames: [ - () => input.BlacklistItemNames !== void 0, + __expectNonNull(input.BlacklistItemNames, `BlacklistItemNames`) != null, () => (input.BlacklistItemNames! || []).map((_entry) => _entry as any), ], }); @@ -723,10 +723,13 @@ export const serializeAws_restJson1GetDomainStatisticsReportCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "Domain", () => input.Domain!, "{Domain}", false); const query: any = map({ StartDate: [ - () => input.StartDate !== void 0, + __expectNonNull(input.StartDate, `StartDate`) != null, () => (input.StartDate!.toISOString().split(".")[0] + "Z").toString(), ], - EndDate: [() => input.EndDate !== void 0, () => (input.EndDate!.toISOString().split(".")[0] + "Z").toString()], + EndDate: [ + __expectNonNull(input.EndDate, `EndDate`) != null, + () => (input.EndDate!.toISOString().split(".")[0] + "Z").toString(), + ], }); let body: any; return new __HttpRequest({ @@ -864,10 +867,13 @@ export const serializeAws_restJson1ListDomainDeliverabilityCampaignsCommand = as ); const query: any = map({ StartDate: [ - () => input.StartDate !== void 0, + __expectNonNull(input.StartDate, `StartDate`) != null, () => (input.StartDate!.toISOString().split(".")[0] + "Z").toString(), ], - EndDate: [() => input.EndDate !== void 0, () => (input.EndDate!.toISOString().split(".")[0] + "Z").toString()], + EndDate: [ + __expectNonNull(input.EndDate, `EndDate`) != null, + () => (input.EndDate!.toISOString().split(".")[0] + "Z").toString(), + ], NextToken: [, input.NextToken!], PageSize: [() => input.PageSize !== void 0, () => input.PageSize!.toString()], }); @@ -916,7 +922,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/email/tags"; const query: any = map({ - ResourceArn: [, input.ResourceArn!], + ResourceArn: [, __expectNonNull(input.ResourceArn!, `ResourceArn`)], }); let body: any; return new __HttpRequest({ @@ -1368,8 +1374,11 @@ export const serializeAws_restJson1UntagResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/email/tags"; const query: any = map({ - ResourceArn: [, input.ResourceArn!], - TagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + ResourceArn: [, __expectNonNull(input.ResourceArn!, `ResourceArn`)], + TagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-pinpoint/src/protocols/Aws_restJson1.ts b/clients/client-pinpoint/src/protocols/Aws_restJson1.ts index 5c3e272a97de..a58d72c0d2a0 100644 --- a/clients/client-pinpoint/src/protocols/Aws_restJson1.ts +++ b/clients/client-pinpoint/src/protocols/Aws_restJson1.ts @@ -3433,7 +3433,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v1/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-privatenetworks/src/protocols/Aws_restJson1.ts b/clients/client-privatenetworks/src/protocols/Aws_restJson1.ts index 6c5a61bba862..a8072078991e 100644 --- a/clients/client-privatenetworks/src/protocols/Aws_restJson1.ts +++ b/clients/client-privatenetworks/src/protocols/Aws_restJson1.ts @@ -691,7 +691,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-qldb/src/protocols/Aws_restJson1.ts b/clients/client-qldb/src/protocols/Aws_restJson1.ts index eaceba1a6ae0..bda8078c02bb 100644 --- a/clients/client-qldb/src/protocols/Aws_restJson1.ts +++ b/clients/client-qldb/src/protocols/Aws_restJson1.ts @@ -523,7 +523,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-quicksight/src/protocols/Aws_restJson1.ts b/clients/client-quicksight/src/protocols/Aws_restJson1.ts index ffb5e5ada3d2..9b0d1a73145f 100644 --- a/clients/client-quicksight/src/protocols/Aws_restJson1.ts +++ b/clients/client-quicksight/src/protocols/Aws_restJson1.ts @@ -2770,7 +2770,7 @@ export const serializeAws_restJson1GetDashboardEmbedUrlCommand = async ( ); resolvedPath = __resolvedPath(resolvedPath, input, "DashboardId", () => input.DashboardId!, "{DashboardId}", false); const query: any = map({ - "creds-type": [, input.IdentityType!], + "creds-type": [, __expectNonNull(input.IdentityType!, `IdentityType`)], "session-lifetime": [ () => input.SessionLifetimeInMinutes !== void 0, () => input.SessionLifetimeInMinutes!.toString(), @@ -3919,7 +3919,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/resources/{ResourceArn}/tags"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - keys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + keys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-ram/src/protocols/Aws_restJson1.ts b/clients/client-ram/src/protocols/Aws_restJson1.ts index e690dfac40bb..dbdea7143567 100644 --- a/clients/client-ram/src/protocols/Aws_restJson1.ts +++ b/clients/client-ram/src/protocols/Aws_restJson1.ts @@ -261,7 +261,7 @@ export const serializeAws_restJson1DeleteResourceShareCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/deleteresourceshare"; const query: any = map({ - resourceShareArn: [, input.resourceShareArn!], + resourceShareArn: [, __expectNonNull(input.resourceShareArn!, `resourceShareArn`)], clientToken: [, input.clientToken!], }); let body: any; @@ -726,7 +726,7 @@ export const serializeAws_restJson1PromoteResourceShareCreatedFromPolicyCommand const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/promoteresourcesharecreatedfrompolicy"; const query: any = map({ - resourceShareArn: [, input.resourceShareArn!], + resourceShareArn: [, __expectNonNull(input.resourceShareArn!, `resourceShareArn`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-rbin/src/protocols/Aws_restJson1.ts b/clients/client-rbin/src/protocols/Aws_restJson1.ts index b150c01a0b08..c6c77aac72cb 100644 --- a/clients/client-rbin/src/protocols/Aws_restJson1.ts +++ b/clients/client-rbin/src/protocols/Aws_restJson1.ts @@ -195,7 +195,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-resiliencehub/src/protocols/Aws_restJson1.ts b/clients/client-resiliencehub/src/protocols/Aws_restJson1.ts index c21ab3d85a8f..fd54e9cc82f8 100644 --- a/clients/client-resiliencehub/src/protocols/Aws_restJson1.ts +++ b/clients/client-resiliencehub/src/protocols/Aws_restJson1.ts @@ -829,7 +829,7 @@ export const serializeAws_restJson1ListRecommendationTemplatesCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/list-recommendation-templates"; const query: any = map({ - assessmentArn: [, input.assessmentArn!], + assessmentArn: [, __expectNonNull(input.assessmentArn!, `assessmentArn`)], reverseOrder: [() => input.reverseOrder !== void 0, () => input.reverseOrder!.toString()], status: [() => input.status !== void 0, () => (input.status! || []).map((_entry) => _entry as any)], recommendationTemplateArn: [, input.recommendationTemplateArn!], @@ -1183,7 +1183,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-resource-explorer-2/src/protocols/Aws_restJson1.ts b/clients/client-resource-explorer-2/src/protocols/Aws_restJson1.ts index 49c48605691e..5b52ebca6cf4 100644 --- a/clients/client-resource-explorer-2/src/protocols/Aws_restJson1.ts +++ b/clients/client-resource-explorer-2/src/protocols/Aws_restJson1.ts @@ -475,7 +475,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-robomaker/src/protocols/Aws_restJson1.ts b/clients/client-robomaker/src/protocols/Aws_restJson1.ts index 07aea4e5aff9..76de00657800 100644 --- a/clients/client-robomaker/src/protocols/Aws_restJson1.ts +++ b/clients/client-robomaker/src/protocols/Aws_restJson1.ts @@ -1670,7 +1670,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-rolesanywhere/src/protocols/Aws_restJson1.ts b/clients/client-rolesanywhere/src/protocols/Aws_restJson1.ts index f36c238a131b..1f3127bb5938 100644 --- a/clients/client-rolesanywhere/src/protocols/Aws_restJson1.ts +++ b/clients/client-rolesanywhere/src/protocols/Aws_restJson1.ts @@ -529,7 +529,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/ListTagsForResource"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-route-53/src/protocols/Aws_restXml.ts b/clients/client-route-53/src/protocols/Aws_restXml.ts index 50f937a72a16..740a9fbe7846 100644 --- a/clients/client-route-53/src/protocols/Aws_restXml.ts +++ b/clients/client-route-53/src/protocols/Aws_restXml.ts @@ -1948,8 +1948,8 @@ export const serializeAws_restXmlListHostedZonesByVPCCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2013-04-01/hostedzonesbyvpc"; const query: any = map({ - vpcid: [, input.VPCId!], - vpcregion: [, input.VPCRegion!], + vpcid: [, __expectNonNull(input.VPCId!, `VPCId`)], + vpcregion: [, __expectNonNull(input.VPCRegion!, `VPCRegion`)], maxitems: [() => input.MaxItems !== void 0, () => input.MaxItems!.toString()], nexttoken: [, input.NextToken!], }); @@ -2187,7 +2187,7 @@ export const serializeAws_restXmlListTrafficPolicyInstancesByHostedZoneCommand = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2013-04-01/trafficpolicyinstances/hostedzone"; const query: any = map({ - id: [, input.HostedZoneId!], + id: [, __expectNonNull(input.HostedZoneId!, `HostedZoneId`)], trafficpolicyinstancename: [, input.TrafficPolicyInstanceNameMarker!], trafficpolicyinstancetype: [, input.TrafficPolicyInstanceTypeMarker!], maxitems: [() => input.MaxItems !== void 0, () => input.MaxItems!.toString()], @@ -2215,8 +2215,11 @@ export const serializeAws_restXmlListTrafficPolicyInstancesByPolicyCommand = asy `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2013-04-01/trafficpolicyinstances/trafficpolicy"; const query: any = map({ - id: [, input.TrafficPolicyId!], - version: [() => input.TrafficPolicyVersion !== void 0, () => input.TrafficPolicyVersion!.toString()], + id: [, __expectNonNull(input.TrafficPolicyId!, `TrafficPolicyId`)], + version: [ + __expectNonNull(input.TrafficPolicyVersion, `TrafficPolicyVersion`) != null, + () => input.TrafficPolicyVersion!.toString(), + ], hostedzoneid: [, input.HostedZoneIdMarker!], trafficpolicyinstancename: [, input.TrafficPolicyInstanceNameMarker!], trafficpolicyinstancetype: [, input.TrafficPolicyInstanceTypeMarker!], @@ -2304,9 +2307,9 @@ export const serializeAws_restXmlTestDNSAnswerCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2013-04-01/testdnsanswer"; const query: any = map({ - hostedzoneid: [, input.HostedZoneId!], - recordname: [, input.RecordName!], - recordtype: [, input.RecordType!], + hostedzoneid: [, __expectNonNull(input.HostedZoneId!, `HostedZoneId`)], + recordname: [, __expectNonNull(input.RecordName!, `RecordName`)], + recordtype: [, __expectNonNull(input.RecordType!, `RecordType`)], resolverip: [, input.ResolverIP!], edns0clientsubnetip: [, input.EDNS0ClientSubnetIP!], edns0clientsubnetmask: [, input.EDNS0ClientSubnetMask!], diff --git a/clients/client-route53-recovery-control-config/src/protocols/Aws_restJson1.ts b/clients/client-route53-recovery-control-config/src/protocols/Aws_restJson1.ts index 12c3572c29c3..110a8089d405 100644 --- a/clients/client-route53-recovery-control-config/src/protocols/Aws_restJson1.ts +++ b/clients/client-route53-recovery-control-config/src/protocols/Aws_restJson1.ts @@ -611,7 +611,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - TagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + TagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-route53-recovery-readiness/src/protocols/Aws_restJson1.ts b/clients/client-route53-recovery-readiness/src/protocols/Aws_restJson1.ts index eb31928a5ffc..b2b68c07e5df 100644 --- a/clients/client-route53-recovery-readiness/src/protocols/Aws_restJson1.ts +++ b/clients/client-route53-recovery-readiness/src/protocols/Aws_restJson1.ts @@ -859,7 +859,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-rum/src/protocols/Aws_restJson1.ts b/clients/client-rum/src/protocols/Aws_restJson1.ts index d102b738663f..40b619f12da0 100644 --- a/clients/client-rum/src/protocols/Aws_restJson1.ts +++ b/clients/client-rum/src/protocols/Aws_restJson1.ts @@ -148,10 +148,10 @@ export const serializeAws_restJson1BatchDeleteRumMetricDefinitionsCommand = asyn false ); const query: any = map({ - destination: [, input.Destination!], + destination: [, __expectNonNull(input.Destination!, `Destination`)], destinationArn: [, input.DestinationArn!], metricDefinitionIds: [ - () => input.MetricDefinitionIds !== void 0, + __expectNonNull(input.MetricDefinitionIds, `MetricDefinitionIds`) != null, () => (input.MetricDefinitionIds! || []).map((_entry) => _entry as any), ], }); @@ -185,7 +185,7 @@ export const serializeAws_restJson1BatchGetRumMetricDefinitionsCommand = async ( false ); const query: any = map({ - destination: [, input.Destination!], + destination: [, __expectNonNull(input.Destination!, `Destination`)], destinationArn: [, input.DestinationArn!], maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], nextToken: [, input.NextToken!], @@ -274,7 +274,7 @@ export const serializeAws_restJson1DeleteRumMetricsDestinationCommand = async ( false ); const query: any = map({ - destination: [, input.Destination!], + destination: [, __expectNonNull(input.Destination!, `Destination`)], destinationArn: [, input.DestinationArn!], }); let body: any; @@ -523,7 +523,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-s3-control/src/protocols/Aws_restXml.ts b/clients/client-s3-control/src/protocols/Aws_restXml.ts index b8c8ab3a1da0..4df9e2ea20b6 100644 --- a/clients/client-s3-control/src/protocols/Aws_restXml.ts +++ b/clients/client-s3-control/src/protocols/Aws_restXml.ts @@ -2582,7 +2582,7 @@ export const serializeAws_restXmlUpdateJobPriorityCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v20180820/jobs/{JobId}/priority"; resolvedPath = __resolvedPath(resolvedPath, input, "JobId", () => input.JobId!, "{JobId}", false); const query: any = map({ - priority: [() => input.Priority !== void 0, () => input.Priority!.toString()], + priority: [__expectNonNull(input.Priority, `Priority`) != null, () => input.Priority!.toString()], }); let body: any; let { hostname: resolvedHostname } = await context.endpoint(); @@ -2620,7 +2620,7 @@ export const serializeAws_restXmlUpdateJobStatusCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v20180820/jobs/{JobId}/status"; resolvedPath = __resolvedPath(resolvedPath, input, "JobId", () => input.JobId!, "{JobId}", false); const query: any = map({ - requestedJobStatus: [, input.RequestedJobStatus!], + requestedJobStatus: [, __expectNonNull(input.RequestedJobStatus!, `RequestedJobStatus`)], statusUpdateReason: [, input.StatusUpdateReason!], }); let body: any; diff --git a/clients/client-s3/src/protocols/Aws_restXml.ts b/clients/client-s3/src/protocols/Aws_restXml.ts index ee69e450a5fc..279f1fcc8bbc 100644 --- a/clients/client-s3/src/protocols/Aws_restXml.ts +++ b/clients/client-s3/src/protocols/Aws_restXml.ts @@ -445,7 +445,7 @@ export const serializeAws_restXmlAbortMultipartUploadCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "Key", () => input.Key!, "{Key+}", true); const query: any = map({ "x-id": [, "AbortMultipartUpload"], - uploadId: [, input.UploadId!], + uploadId: [, __expectNonNull(input.UploadId!, `UploadId`)], }); let body: any; return new __HttpRequest({ @@ -482,7 +482,7 @@ export const serializeAws_restXmlCompleteMultipartUploadCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "Key", () => input.Key!, "{Key+}", true); const query: any = map({ "x-id": [, "CompleteMultipartUpload"], - uploadId: [, input.UploadId!], + uploadId: [, __expectNonNull(input.UploadId!, `UploadId`)], }); let body: any; if (input.MultipartUpload !== undefined) { @@ -731,7 +731,7 @@ export const serializeAws_restXmlDeleteBucketAnalyticsConfigurationCommand = asy resolvedPath = __resolvedPath(resolvedPath, input, "Bucket", () => input.Bucket!, "{Bucket}", false); const query: any = map({ analytics: [, ""], - id: [, input.Id!], + id: [, __expectNonNull(input.Id!, `Id`)], }); let body: any; return new __HttpRequest({ @@ -808,7 +808,7 @@ export const serializeAws_restXmlDeleteBucketIntelligentTieringConfigurationComm resolvedPath = __resolvedPath(resolvedPath, input, "Bucket", () => input.Bucket!, "{Bucket}", false); const query: any = map({ "intelligent-tiering": [, ""], - id: [, input.Id!], + id: [, __expectNonNull(input.Id!, `Id`)], }); let body: any; return new __HttpRequest({ @@ -835,7 +835,7 @@ export const serializeAws_restXmlDeleteBucketInventoryConfigurationCommand = asy resolvedPath = __resolvedPath(resolvedPath, input, "Bucket", () => input.Bucket!, "{Bucket}", false); const query: any = map({ inventory: [, ""], - id: [, input.Id!], + id: [, __expectNonNull(input.Id!, `Id`)], }); let body: any; return new __HttpRequest({ @@ -888,7 +888,7 @@ export const serializeAws_restXmlDeleteBucketMetricsConfigurationCommand = async resolvedPath = __resolvedPath(resolvedPath, input, "Bucket", () => input.Bucket!, "{Bucket}", false); const query: any = map({ metrics: [, ""], - id: [, input.Id!], + id: [, __expectNonNull(input.Id!, `Id`)], }); let body: any; return new __HttpRequest({ @@ -1231,7 +1231,7 @@ export const serializeAws_restXmlGetBucketAnalyticsConfigurationCommand = async const query: any = map({ analytics: [, ""], "x-id": [, "GetBucketAnalyticsConfiguration"], - id: [, input.Id!], + id: [, __expectNonNull(input.Id!, `Id`)], }); let body: any; return new __HttpRequest({ @@ -1309,7 +1309,7 @@ export const serializeAws_restXmlGetBucketIntelligentTieringConfigurationCommand const query: any = map({ "intelligent-tiering": [, ""], "x-id": [, "GetBucketIntelligentTieringConfiguration"], - id: [, input.Id!], + id: [, __expectNonNull(input.Id!, `Id`)], }); let body: any; return new __HttpRequest({ @@ -1337,7 +1337,7 @@ export const serializeAws_restXmlGetBucketInventoryConfigurationCommand = async const query: any = map({ inventory: [, ""], "x-id": [, "GetBucketInventoryConfiguration"], - id: [, input.Id!], + id: [, __expectNonNull(input.Id!, `Id`)], }); let body: any; return new __HttpRequest({ @@ -1443,7 +1443,7 @@ export const serializeAws_restXmlGetBucketMetricsConfigurationCommand = async ( const query: any = map({ metrics: [, ""], "x-id": [, "GetBucketMetricsConfiguration"], - id: [, input.Id!], + id: [, __expectNonNull(input.Id!, `Id`)], }); let body: any; return new __HttpRequest({ @@ -2326,7 +2326,7 @@ export const serializeAws_restXmlListPartsCommand = async ( "x-id": [, "ListParts"], "max-parts": [() => input.MaxParts !== void 0, () => input.MaxParts!.toString()], "part-number-marker": [, input.PartNumberMarker!], - uploadId: [, input.UploadId!], + uploadId: [, __expectNonNull(input.UploadId!, `UploadId`)], }); let body: any; return new __HttpRequest({ @@ -2437,7 +2437,7 @@ export const serializeAws_restXmlPutBucketAnalyticsConfigurationCommand = async resolvedPath = __resolvedPath(resolvedPath, input, "Bucket", () => input.Bucket!, "{Bucket}", false); const query: any = map({ analytics: [, ""], - id: [, input.Id!], + id: [, __expectNonNull(input.Id!, `Id`)], }); let body: any; if (input.AnalyticsConfiguration !== undefined) { @@ -2552,7 +2552,7 @@ export const serializeAws_restXmlPutBucketIntelligentTieringConfigurationCommand resolvedPath = __resolvedPath(resolvedPath, input, "Bucket", () => input.Bucket!, "{Bucket}", false); const query: any = map({ "intelligent-tiering": [, ""], - id: [, input.Id!], + id: [, __expectNonNull(input.Id!, `Id`)], }); let body: any; if (input.IntelligentTieringConfiguration !== undefined) { @@ -2590,7 +2590,7 @@ export const serializeAws_restXmlPutBucketInventoryConfigurationCommand = async resolvedPath = __resolvedPath(resolvedPath, input, "Bucket", () => input.Bucket!, "{Bucket}", false); const query: any = map({ inventory: [, ""], - id: [, input.Id!], + id: [, __expectNonNull(input.Id!, `Id`)], }); let body: any; if (input.InventoryConfiguration !== undefined) { @@ -2706,7 +2706,7 @@ export const serializeAws_restXmlPutBucketMetricsConfigurationCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "Bucket", () => input.Bucket!, "{Bucket}", false); const query: any = map({ metrics: [, ""], - id: [, input.Id!], + id: [, __expectNonNull(input.Id!, `Id`)], }); let body: any; if (input.MetricsConfiguration !== undefined) { @@ -3518,8 +3518,8 @@ export const serializeAws_restXmlUploadPartCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "Key", () => input.Key!, "{Key+}", true); const query: any = map({ "x-id": [, "UploadPart"], - partNumber: [() => input.PartNumber !== void 0, () => input.PartNumber!.toString()], - uploadId: [, input.UploadId!], + partNumber: [__expectNonNull(input.PartNumber, `PartNumber`) != null, () => input.PartNumber!.toString()], + uploadId: [, __expectNonNull(input.UploadId!, `UploadId`)], }); let body: any; if (input.Body !== undefined) { @@ -3575,8 +3575,8 @@ export const serializeAws_restXmlUploadPartCopyCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "Key", () => input.Key!, "{Key+}", true); const query: any = map({ "x-id": [, "UploadPartCopy"], - partNumber: [() => input.PartNumber !== void 0, () => input.PartNumber!.toString()], - uploadId: [, input.UploadId!], + partNumber: [__expectNonNull(input.PartNumber, `PartNumber`) != null, () => input.PartNumber!.toString()], + uploadId: [, __expectNonNull(input.UploadId!, `UploadId`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-s3outposts/src/protocols/Aws_restJson1.ts b/clients/client-s3outposts/src/protocols/Aws_restJson1.ts index b50ec6a513c6..75e16053960e 100644 --- a/clients/client-s3outposts/src/protocols/Aws_restJson1.ts +++ b/clients/client-s3outposts/src/protocols/Aws_restJson1.ts @@ -73,8 +73,8 @@ export const serializeAws_restJson1DeleteEndpointCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/S3Outposts/DeleteEndpoint"; const query: any = map({ - endpointId: [, input.EndpointId!], - outpostId: [, input.OutpostId!], + endpointId: [, __expectNonNull(input.EndpointId!, `EndpointId`)], + outpostId: [, __expectNonNull(input.OutpostId!, `OutpostId`)], }); let body: any; return new __HttpRequest({ @@ -125,7 +125,7 @@ export const serializeAws_restJson1ListSharedEndpointsCommand = async ( const query: any = map({ nextToken: [, input.NextToken!], maxResults: [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], - outpostId: [, input.OutpostId!], + outpostId: [, __expectNonNull(input.OutpostId!, `OutpostId`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-sagemaker-a2i-runtime/src/protocols/Aws_restJson1.ts b/clients/client-sagemaker-a2i-runtime/src/protocols/Aws_restJson1.ts index cf5f51beb902..0b10dc14bc9a 100644 --- a/clients/client-sagemaker-a2i-runtime/src/protocols/Aws_restJson1.ts +++ b/clients/client-sagemaker-a2i-runtime/src/protocols/Aws_restJson1.ts @@ -109,7 +109,7 @@ export const serializeAws_restJson1ListHumanLoopsCommand = async ( () => input.CreationTimeBefore !== void 0, () => (input.CreationTimeBefore!.toISOString().split(".")[0] + "Z").toString(), ], - FlowDefinitionArn: [, input.FlowDefinitionArn!], + FlowDefinitionArn: [, __expectNonNull(input.FlowDefinitionArn!, `FlowDefinitionArn`)], SortOrder: [, input.SortOrder!], NextToken: [, input.NextToken!], MaxResults: [() => input.MaxResults !== void 0, () => input.MaxResults!.toString()], diff --git a/clients/client-sagemaker-featurestore-runtime/src/protocols/Aws_restJson1.ts b/clients/client-sagemaker-featurestore-runtime/src/protocols/Aws_restJson1.ts index 6b884d5ea0f1..435bc31647a5 100644 --- a/clients/client-sagemaker-featurestore-runtime/src/protocols/Aws_restJson1.ts +++ b/clients/client-sagemaker-featurestore-runtime/src/protocols/Aws_restJson1.ts @@ -76,8 +76,11 @@ export const serializeAws_restJson1DeleteRecordCommand = async ( false ); const query: any = map({ - RecordIdentifierValueAsString: [, input.RecordIdentifierValueAsString!], - EventTime: [, input.EventTime!], + RecordIdentifierValueAsString: [ + , + __expectNonNull(input.RecordIdentifierValueAsString!, `RecordIdentifierValueAsString`), + ], + EventTime: [, __expectNonNull(input.EventTime!, `EventTime`)], }); let body: any; return new __HttpRequest({ @@ -109,7 +112,10 @@ export const serializeAws_restJson1GetRecordCommand = async ( false ); const query: any = map({ - RecordIdentifierValueAsString: [, input.RecordIdentifierValueAsString!], + RecordIdentifierValueAsString: [ + , + __expectNonNull(input.RecordIdentifierValueAsString!, `RecordIdentifierValueAsString`), + ], FeatureName: [ () => input.FeatureNames !== void 0, () => (input.FeatureNames! || []).map((_entry) => _entry as any), diff --git a/clients/client-scheduler/src/protocols/Aws_restJson1.ts b/clients/client-scheduler/src/protocols/Aws_restJson1.ts index 675fdd2a6610..2f48b477acbc 100644 --- a/clients/client-scheduler/src/protocols/Aws_restJson1.ts +++ b/clients/client-scheduler/src/protocols/Aws_restJson1.ts @@ -333,7 +333,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - TagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + TagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-schemas/src/protocols/Aws_restJson1.ts b/clients/client-schemas/src/protocols/Aws_restJson1.ts index 65b89452a1f5..cdfa8b9e0a6c 100644 --- a/clients/client-schemas/src/protocols/Aws_restJson1.ts +++ b/clients/client-schemas/src/protocols/Aws_restJson1.ts @@ -481,7 +481,7 @@ export const serializeAws_restJson1ExportSchemaCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "SchemaName", () => input.SchemaName!, "{SchemaName}", false); const query: any = map({ schemaVersion: [, input.SchemaVersion!], - type: [, input.Type!], + type: [, __expectNonNull(input.Type!, `Type`)], }); let body: any; return new __HttpRequest({ @@ -805,7 +805,7 @@ export const serializeAws_restJson1SearchSchemasCommand = async ( false ); const query: any = map({ - keywords: [, input.Keywords!], + keywords: [, __expectNonNull(input.Keywords!, `Keywords`)], limit: [() => input.Limit !== void 0, () => input.Limit!.toString()], nextToken: [, input.NextToken!], }); @@ -912,7 +912,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-securityhub/src/protocols/Aws_restJson1.ts b/clients/client-securityhub/src/protocols/Aws_restJson1.ts index 485ada85611f..32201680bc27 100644 --- a/clients/client-securityhub/src/protocols/Aws_restJson1.ts +++ b/clients/client-securityhub/src/protocols/Aws_restJson1.ts @@ -1893,7 +1893,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-service-catalog-appregistry/src/protocols/Aws_restJson1.ts b/clients/client-service-catalog-appregistry/src/protocols/Aws_restJson1.ts index 46674440e098..d319673814ad 100644 --- a/clients/client-service-catalog-appregistry/src/protocols/Aws_restJson1.ts +++ b/clients/client-service-catalog-appregistry/src/protocols/Aws_restJson1.ts @@ -666,7 +666,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-sesv2/src/protocols/Aws_restJson1.ts b/clients/client-sesv2/src/protocols/Aws_restJson1.ts index 236b57cc337b..329be939eed2 100644 --- a/clients/client-sesv2/src/protocols/Aws_restJson1.ts +++ b/clients/client-sesv2/src/protocols/Aws_restJson1.ts @@ -1091,7 +1091,7 @@ export const serializeAws_restJson1GetBlacklistReportsCommand = async ( "/v2/email/deliverability-dashboard/blacklist-report"; const query: any = map({ BlacklistItemNames: [ - () => input.BlacklistItemNames !== void 0, + __expectNonNull(input.BlacklistItemNames, `BlacklistItemNames`) != null, () => (input.BlacklistItemNames! || []).map((_entry) => _entry as any), ], }); @@ -1407,10 +1407,13 @@ export const serializeAws_restJson1GetDomainStatisticsReportCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "Domain", () => input.Domain!, "{Domain}", false); const query: any = map({ StartDate: [ - () => input.StartDate !== void 0, + __expectNonNull(input.StartDate, `StartDate`) != null, () => (input.StartDate!.toISOString().split(".")[0] + "Z").toString(), ], - EndDate: [() => input.EndDate !== void 0, () => (input.EndDate!.toISOString().split(".")[0] + "Z").toString()], + EndDate: [ + __expectNonNull(input.EndDate, `EndDate`) != null, + () => (input.EndDate!.toISOString().split(".")[0] + "Z").toString(), + ], }); let body: any; return new __HttpRequest({ @@ -1745,10 +1748,13 @@ export const serializeAws_restJson1ListDomainDeliverabilityCampaignsCommand = as ); const query: any = map({ StartDate: [ - () => input.StartDate !== void 0, + __expectNonNull(input.StartDate, `StartDate`) != null, () => (input.StartDate!.toISOString().split(".")[0] + "Z").toString(), ], - EndDate: [() => input.EndDate !== void 0, () => (input.EndDate!.toISOString().split(".")[0] + "Z").toString()], + EndDate: [ + __expectNonNull(input.EndDate, `EndDate`) != null, + () => (input.EndDate!.toISOString().split(".")[0] + "Z").toString(), + ], NextToken: [, input.NextToken!], PageSize: [() => input.PageSize !== void 0, () => input.PageSize!.toString()], }); @@ -1908,7 +1914,7 @@ export const serializeAws_restJson1ListTagsForResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v2/email/tags"; const query: any = map({ - ResourceArn: [, input.ResourceArn!], + ResourceArn: [, __expectNonNull(input.ResourceArn!, `ResourceArn`)], }); let body: any; return new __HttpRequest({ @@ -2732,8 +2738,11 @@ export const serializeAws_restJson1UntagResourceCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/v2/email/tags"; const query: any = map({ - ResourceArn: [, input.ResourceArn!], - TagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + ResourceArn: [, __expectNonNull(input.ResourceArn!, `ResourceArn`)], + TagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-signer/src/protocols/Aws_restJson1.ts b/clients/client-signer/src/protocols/Aws_restJson1.ts index d081ef1da55f..d921886b666c 100644 --- a/clients/client-signer/src/protocols/Aws_restJson1.ts +++ b/clients/client-signer/src/protocols/Aws_restJson1.ts @@ -405,7 +405,7 @@ export const serializeAws_restJson1RemoveProfilePermissionCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "profileName", () => input.profileName!, "{profileName}", false); resolvedPath = __resolvedPath(resolvedPath, input, "statementId", () => input.statementId!, "{statementId}", false); const query: any = map({ - revisionId: [, input.revisionId!], + revisionId: [, __expectNonNull(input.revisionId!, `revisionId`)], }); let body: any; return new __HttpRequest({ @@ -537,7 +537,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-snow-device-management/src/protocols/Aws_restJson1.ts b/clients/client-snow-device-management/src/protocols/Aws_restJson1.ts index fa589103a4d5..683a7f49657d 100644 --- a/clients/client-snow-device-management/src/protocols/Aws_restJson1.ts +++ b/clients/client-snow-device-management/src/protocols/Aws_restJson1.ts @@ -302,7 +302,7 @@ export const serializeAws_restJson1ListExecutionsCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/executions"; const query: any = map({ - taskId: [, input.taskId!], + taskId: [, __expectNonNull(input.taskId!, `taskId`)], state: [, input.state!], maxResults: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], nextToken: [, input.nextToken!], @@ -399,7 +399,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-ssm-incidents/src/protocols/Aws_restJson1.ts b/clients/client-ssm-incidents/src/protocols/Aws_restJson1.ts index 0185f04acb6e..3951c154801a 100644 --- a/clients/client-ssm-incidents/src/protocols/Aws_restJson1.ts +++ b/clients/client-ssm-incidents/src/protocols/Aws_restJson1.ts @@ -263,7 +263,7 @@ export const serializeAws_restJson1DeleteReplicationSetCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/deleteReplicationSet"; const query: any = map({ - arn: [, input.arn!], + arn: [, __expectNonNull(input.arn!, `arn`)], }); let body: any; return new __HttpRequest({ @@ -360,7 +360,7 @@ export const serializeAws_restJson1GetIncidentRecordCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/getIncidentRecord"; const query: any = map({ - arn: [, input.arn!], + arn: [, __expectNonNull(input.arn!, `arn`)], }); let body: any; return new __HttpRequest({ @@ -383,7 +383,7 @@ export const serializeAws_restJson1GetReplicationSetCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/getReplicationSet"; const query: any = map({ - arn: [, input.arn!], + arn: [, __expectNonNull(input.arn!, `arn`)], }); let body: any; return new __HttpRequest({ @@ -408,7 +408,7 @@ export const serializeAws_restJson1GetResourcePoliciesCommand = async ( }; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/getResourcePolicies"; const query: any = map({ - resourceArn: [, input.resourceArn!], + resourceArn: [, __expectNonNull(input.resourceArn!, `resourceArn`)], }); let body: any; body = JSON.stringify({ @@ -435,7 +435,7 @@ export const serializeAws_restJson1GetResponsePlanCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/getResponsePlan"; const query: any = map({ - arn: [, input.arn!], + arn: [, __expectNonNull(input.arn!, `arn`)], }); let body: any; return new __HttpRequest({ @@ -458,8 +458,8 @@ export const serializeAws_restJson1GetTimelineEventCommand = async ( const headers: any = {}; const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/getTimelineEvent"; const query: any = map({ - incidentRecordArn: [, input.incidentRecordArn!], - eventId: [, input.eventId!], + incidentRecordArn: [, __expectNonNull(input.incidentRecordArn!, `incidentRecordArn`)], + eventId: [, __expectNonNull(input.eventId!, `eventId`)], }); let body: any; return new __HttpRequest({ @@ -717,7 +717,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-ssm-sap/src/protocols/Aws_restJson1.ts b/clients/client-ssm-sap/src/protocols/Aws_restJson1.ts index 5fe8829a2b15..062592e8969e 100644 --- a/clients/client-ssm-sap/src/protocols/Aws_restJson1.ts +++ b/clients/client-ssm-sap/src/protocols/Aws_restJson1.ts @@ -443,7 +443,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-sso/src/protocols/Aws_restJson1.ts b/clients/client-sso/src/protocols/Aws_restJson1.ts index c1a516d932ad..dc86bd8e93d7 100644 --- a/clients/client-sso/src/protocols/Aws_restJson1.ts +++ b/clients/client-sso/src/protocols/Aws_restJson1.ts @@ -42,8 +42,8 @@ export const serializeAws_restJson1GetRoleCredentialsCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/federation/credentials"; const query: any = map({ - role_name: [, input.roleName!], - account_id: [, input.accountId!], + role_name: [, __expectNonNull(input.roleName!, `roleName`)], + account_id: [, __expectNonNull(input.accountId!, `accountId`)], }); let body: any; return new __HttpRequest({ @@ -70,7 +70,7 @@ export const serializeAws_restJson1ListAccountRolesCommand = async ( const query: any = map({ next_token: [, input.nextToken!], max_result: [() => input.maxResults !== void 0, () => input.maxResults!.toString()], - account_id: [, input.accountId!], + account_id: [, __expectNonNull(input.accountId!, `accountId`)], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-synthetics/src/protocols/Aws_restJson1.ts b/clients/client-synthetics/src/protocols/Aws_restJson1.ts index c150326d3346..af9392e8dfcb 100644 --- a/clients/client-synthetics/src/protocols/Aws_restJson1.ts +++ b/clients/client-synthetics/src/protocols/Aws_restJson1.ts @@ -610,7 +610,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-wellarchitected/src/protocols/Aws_restJson1.ts b/clients/client-wellarchitected/src/protocols/Aws_restJson1.ts index b88dbc1df587..6fb73bd69a7e 100644 --- a/clients/client-wellarchitected/src/protocols/Aws_restJson1.ts +++ b/clients/client-wellarchitected/src/protocols/Aws_restJson1.ts @@ -337,8 +337,8 @@ export const serializeAws_restJson1DeleteLensCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/lenses/{LensAlias}"; resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias!, "{LensAlias}", false); const query: any = map({ - ClientRequestToken: [, input.ClientRequestToken!], - LensStatus: [, input.LensStatus!], + ClientRequestToken: [, __expectNonNull(input.ClientRequestToken!, `ClientRequestToken`)], + LensStatus: [, __expectNonNull(input.LensStatus!, `LensStatus`)], }); let body: any; return new __HttpRequest({ @@ -364,7 +364,7 @@ export const serializeAws_restJson1DeleteLensShareCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "ShareId", () => input.ShareId!, "{ShareId}", false); resolvedPath = __resolvedPath(resolvedPath, input, "LensAlias", () => input.LensAlias!, "{LensAlias}", false); const query: any = map({ - ClientRequestToken: [, input.ClientRequestToken!], + ClientRequestToken: [, __expectNonNull(input.ClientRequestToken!, `ClientRequestToken`)], }); let body: any; return new __HttpRequest({ @@ -388,7 +388,7 @@ export const serializeAws_restJson1DeleteWorkloadCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/workloads/{WorkloadId}"; resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId!, "{WorkloadId}", false); const query: any = map({ - ClientRequestToken: [, input.ClientRequestToken!], + ClientRequestToken: [, __expectNonNull(input.ClientRequestToken!, `ClientRequestToken`)], }); let body: any; return new __HttpRequest({ @@ -414,7 +414,7 @@ export const serializeAws_restJson1DeleteWorkloadShareCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "ShareId", () => input.ShareId!, "{ShareId}", false); resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadId", () => input.WorkloadId!, "{WorkloadId}", false); const query: any = map({ - ClientRequestToken: [, input.ClientRequestToken!], + ClientRequestToken: [, __expectNonNull(input.ClientRequestToken!, `ClientRequestToken`)], }); let body: any; return new __HttpRequest({ @@ -1083,7 +1083,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{WorkloadArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "WorkloadArn", () => input.WorkloadArn!, "{WorkloadArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-wisdom/src/protocols/Aws_restJson1.ts b/clients/client-wisdom/src/protocols/Aws_restJson1.ts index b15dcd301d9b..81b21348610d 100644 --- a/clients/client-wisdom/src/protocols/Aws_restJson1.ts +++ b/clients/client-wisdom/src/protocols/Aws_restJson1.ts @@ -951,7 +951,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn}", false); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-workdocs/src/protocols/Aws_restJson1.ts b/clients/client-workdocs/src/protocols/Aws_restJson1.ts index 1e5e1df98551..2bb847931a63 100644 --- a/clients/client-workdocs/src/protocols/Aws_restJson1.ts +++ b/clients/client-workdocs/src/protocols/Aws_restJson1.ts @@ -557,7 +557,10 @@ export const serializeAws_restJson1DeleteDocumentVersionCommand = async ( resolvedPath = __resolvedPath(resolvedPath, input, "DocumentId", () => input.DocumentId!, "{DocumentId}", false); resolvedPath = __resolvedPath(resolvedPath, input, "VersionId", () => input.VersionId!, "{VersionId}", false); const query: any = map({ - deletePriorVersions: [() => input.DeletePriorVersions !== void 0, () => input.DeletePriorVersions!.toString()], + deletePriorVersions: [ + __expectNonNull(input.DeletePriorVersions, `DeletePriorVersions`) != null, + () => input.DeletePriorVersions!.toString(), + ], }); let body: any; return new __HttpRequest({ @@ -846,7 +849,7 @@ export const serializeAws_restJson1DescribeGroupsCommand = async ( }); const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/api/v1/groups"; const query: any = map({ - searchQuery: [, input.SearchQuery!], + searchQuery: [, __expectNonNull(input.SearchQuery!, `SearchQuery`)], organizationId: [, input.OrganizationId!], marker: [, input.Marker!], limit: [() => input.Limit !== void 0, () => input.Limit!.toString()], diff --git a/clients/client-worklink/src/protocols/Aws_restJson1.ts b/clients/client-worklink/src/protocols/Aws_restJson1.ts index 44dda73ac306..d3501af87f6b 100644 --- a/clients/client-worklink/src/protocols/Aws_restJson1.ts +++ b/clients/client-worklink/src/protocols/Aws_restJson1.ts @@ -796,7 +796,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{ResourceArn}"; resolvedPath = __resolvedPath(resolvedPath, input, "ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); const query: any = map({ - tagKeys: [() => input.TagKeys !== void 0, () => (input.TagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.TagKeys, `TagKeys`) != null, + () => (input.TagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/clients/client-workspaces-web/src/protocols/Aws_restJson1.ts b/clients/client-workspaces-web/src/protocols/Aws_restJson1.ts index 3ffa66db16b3..70fad116fd0f 100644 --- a/clients/client-workspaces-web/src/protocols/Aws_restJson1.ts +++ b/clients/client-workspaces-web/src/protocols/Aws_restJson1.ts @@ -208,7 +208,7 @@ export const serializeAws_restJson1AssociateBrowserSettingsCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/portals/{portalArn+}/browserSettings"; resolvedPath = __resolvedPath(resolvedPath, input, "portalArn", () => input.portalArn!, "{portalArn+}", true); const query: any = map({ - browserSettingsArn: [, input.browserSettingsArn!], + browserSettingsArn: [, __expectNonNull(input.browserSettingsArn!, `browserSettingsArn`)], }); let body: any; return new __HttpRequest({ @@ -233,7 +233,7 @@ export const serializeAws_restJson1AssociateNetworkSettingsCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/portals/{portalArn+}/networkSettings"; resolvedPath = __resolvedPath(resolvedPath, input, "portalArn", () => input.portalArn!, "{portalArn+}", true); const query: any = map({ - networkSettingsArn: [, input.networkSettingsArn!], + networkSettingsArn: [, __expectNonNull(input.networkSettingsArn!, `networkSettingsArn`)], }); let body: any; return new __HttpRequest({ @@ -258,7 +258,7 @@ export const serializeAws_restJson1AssociateTrustStoreCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/portals/{portalArn+}/trustStores"; resolvedPath = __resolvedPath(resolvedPath, input, "portalArn", () => input.portalArn!, "{portalArn+}", true); const query: any = map({ - trustStoreArn: [, input.trustStoreArn!], + trustStoreArn: [, __expectNonNull(input.trustStoreArn!, `trustStoreArn`)], }); let body: any; return new __HttpRequest({ @@ -284,7 +284,10 @@ export const serializeAws_restJson1AssociateUserAccessLoggingSettingsCommand = a "/portals/{portalArn+}/userAccessLoggingSettings"; resolvedPath = __resolvedPath(resolvedPath, input, "portalArn", () => input.portalArn!, "{portalArn+}", true); const query: any = map({ - userAccessLoggingSettingsArn: [, input.userAccessLoggingSettingsArn!], + userAccessLoggingSettingsArn: [ + , + __expectNonNull(input.userAccessLoggingSettingsArn!, `userAccessLoggingSettingsArn`), + ], }); let body: any; return new __HttpRequest({ @@ -309,7 +312,7 @@ export const serializeAws_restJson1AssociateUserSettingsCommand = async ( `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/portals/{portalArn+}/userSettings"; resolvedPath = __resolvedPath(resolvedPath, input, "portalArn", () => input.portalArn!, "{portalArn+}", true); const query: any = map({ - userSettingsArn: [, input.userSettingsArn!], + userSettingsArn: [, __expectNonNull(input.userSettingsArn!, `userSettingsArn`)], }); let body: any; return new __HttpRequest({ @@ -1003,7 +1006,7 @@ export const serializeAws_restJson1GetTrustStoreCertificateCommand = async ( true ); const query: any = map({ - thumbprint: [, input.thumbprint!], + thumbprint: [, __expectNonNull(input.thumbprint!, `thumbprint`)], }); let body: any; return new __HttpRequest({ @@ -1335,7 +1338,10 @@ export const serializeAws_restJson1UntagResourceCommand = async ( let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/tags/{resourceArn+}"; resolvedPath = __resolvedPath(resolvedPath, input, "resourceArn", () => input.resourceArn!, "{resourceArn+}", true); const query: any = map({ - tagKeys: [() => input.tagKeys !== void 0, () => (input.tagKeys! || []).map((_entry) => _entry as any)], + tagKeys: [ + __expectNonNull(input.tagKeys, `tagKeys`) != null, + () => (input.tagKeys! || []).map((_entry) => _entry as any), + ], }); let body: any; return new __HttpRequest({ diff --git a/private/aws-protocoltests-restjson/src/protocols/Aws_restJson1.ts b/private/aws-protocoltests-restjson/src/protocols/Aws_restJson1.ts index d05789fd9a91..6266691e343e 100644 --- a/private/aws-protocoltests-restjson/src/protocols/Aws_restJson1.ts +++ b/private/aws-protocoltests-restjson/src/protocols/Aws_restJson1.ts @@ -2132,7 +2132,7 @@ export const serializeAws_restJson1MalformedTimestampQueryDefaultCommand = async `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/MalformedTimestampQueryDefault"; const query: any = map({ timestamp: [ - () => input.timestamp !== void 0, + __expectNonNull(input.timestamp, `timestamp`) != null, () => (input.timestamp!.toISOString().split(".")[0] + "Z").toString(), ], }); @@ -2158,7 +2158,10 @@ export const serializeAws_restJson1MalformedTimestampQueryEpochCommand = async ( const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/MalformedTimestampQueryEpoch"; const query: any = map({ - timestamp: [() => input.timestamp !== void 0, () => Math.round(input.timestamp!.getTime() / 1000).toString()], + timestamp: [ + __expectNonNull(input.timestamp, `timestamp`) != null, + () => Math.round(input.timestamp!.getTime() / 1000).toString(), + ], }); let body: any; return new __HttpRequest({ @@ -2182,7 +2185,10 @@ export const serializeAws_restJson1MalformedTimestampQueryHttpDateCommand = asyn const resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/MalformedTimestampQueryHttpDate"; const query: any = map({ - timestamp: [() => input.timestamp !== void 0, () => __dateToUtcString(input.timestamp!).toString()], + timestamp: [ + __expectNonNull(input.timestamp, `timestamp`) != null, + () => __dateToUtcString(input.timestamp!).toString(), + ], }); let body: any; return new __HttpRequest({