Skip to content

Commit b69398b

Browse files
chore: update generated code
1 parent a94ebac commit b69398b

File tree

274 files changed

+62540
-41388
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

274 files changed

+62540
-41388
lines changed

clients/client-accessanalyzer/protocols/Aws_restJson1.ts

Lines changed: 182 additions & 126 deletions
Large diffs are not rendered by default.

clients/client-acm-pca/protocols/Aws_json1_1.ts

Lines changed: 170 additions & 91 deletions
Large diffs are not rendered by default.

clients/client-acm/protocols/Aws_json1_1.ts

Lines changed: 99 additions & 59 deletions
Large diffs are not rendered by default.

clients/client-alexa-for-business/protocols/Aws_json1_1.ts

Lines changed: 459 additions & 249 deletions
Large diffs are not rendered by default.

clients/client-amp/protocols/Aws_restJson1.ts

Lines changed: 35 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ import {
2222
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
2323
import {
2424
SmithyException as __SmithyException,
25+
expectString as __expectString,
2526
extendedEncodeURIComponent as __extendedEncodeURIComponent,
2627
} from "@aws-sdk/smithy-client";
2728
import {
@@ -191,13 +192,13 @@ export const deserializeAws_restJson1CreateWorkspaceCommand = async (
191192
};
192193
const data: any = await parseBody(output.body, context);
193194
if (data.arn !== undefined && data.arn !== null) {
194-
contents.arn = data.arn;
195+
contents.arn = __expectString(data.arn);
195196
}
196197
if (data.status !== undefined && data.status !== null) {
197198
contents.status = deserializeAws_restJson1WorkspaceStatus(data.status, context);
198199
}
199200
if (data.workspaceId !== undefined && data.workspaceId !== null) {
200-
contents.workspaceId = data.workspaceId;
201+
contents.workspaceId = __expectString(data.workspaceId);
201202
}
202203
return Promise.resolve(contents);
203204
};
@@ -463,7 +464,7 @@ export const deserializeAws_restJson1ListWorkspacesCommand = async (
463464
};
464465
const data: any = await parseBody(output.body, context);
465466
if (data.nextToken !== undefined && data.nextToken !== null) {
466-
contents.nextToken = data.nextToken;
467+
contents.nextToken = __expectString(data.nextToken);
467468
}
468469
if (data.workspaces !== undefined && data.workspaces !== null) {
469470
contents.workspaces = deserializeAws_restJson1WorkspaceSummaryList(data.workspaces, context);
@@ -643,7 +644,7 @@ const deserializeAws_restJson1AccessDeniedExceptionResponse = async (
643644
};
644645
const data: any = parsedOutput.body;
645646
if (data.message !== undefined && data.message !== null) {
646-
contents.message = data.message;
647+
contents.message = __expectString(data.message);
647648
}
648649
return contents;
649650
};
@@ -662,13 +663,13 @@ const deserializeAws_restJson1ConflictExceptionResponse = async (
662663
};
663664
const data: any = parsedOutput.body;
664665
if (data.message !== undefined && data.message !== null) {
665-
contents.message = data.message;
666+
contents.message = __expectString(data.message);
666667
}
667668
if (data.resourceId !== undefined && data.resourceId !== null) {
668-
contents.resourceId = data.resourceId;
669+
contents.resourceId = __expectString(data.resourceId);
669670
}
670671
if (data.resourceType !== undefined && data.resourceType !== null) {
671-
contents.resourceType = data.resourceType;
672+
contents.resourceType = __expectString(data.resourceType);
672673
}
673674
return contents;
674675
};
@@ -690,7 +691,7 @@ const deserializeAws_restJson1InternalServerExceptionResponse = async (
690691
}
691692
const data: any = parsedOutput.body;
692693
if (data.message !== undefined && data.message !== null) {
693-
contents.message = data.message;
694+
contents.message = __expectString(data.message);
694695
}
695696
return contents;
696697
};
@@ -709,13 +710,13 @@ const deserializeAws_restJson1ResourceNotFoundExceptionResponse = async (
709710
};
710711
const data: any = parsedOutput.body;
711712
if (data.message !== undefined && data.message !== null) {
712-
contents.message = data.message;
713+
contents.message = __expectString(data.message);
713714
}
714715
if (data.resourceId !== undefined && data.resourceId !== null) {
715-
contents.resourceId = data.resourceId;
716+
contents.resourceId = __expectString(data.resourceId);
716717
}
717718
if (data.resourceType !== undefined && data.resourceType !== null) {
718-
contents.resourceType = data.resourceType;
719+
contents.resourceType = __expectString(data.resourceType);
719720
}
720721
return contents;
721722
};
@@ -736,19 +737,19 @@ const deserializeAws_restJson1ServiceQuotaExceededExceptionResponse = async (
736737
};
737738
const data: any = parsedOutput.body;
738739
if (data.message !== undefined && data.message !== null) {
739-
contents.message = data.message;
740+
contents.message = __expectString(data.message);
740741
}
741742
if (data.quotaCode !== undefined && data.quotaCode !== null) {
742-
contents.quotaCode = data.quotaCode;
743+
contents.quotaCode = __expectString(data.quotaCode);
743744
}
744745
if (data.resourceId !== undefined && data.resourceId !== null) {
745-
contents.resourceId = data.resourceId;
746+
contents.resourceId = __expectString(data.resourceId);
746747
}
747748
if (data.resourceType !== undefined && data.resourceType !== null) {
748-
contents.resourceType = data.resourceType;
749+
contents.resourceType = __expectString(data.resourceType);
749750
}
750751
if (data.serviceCode !== undefined && data.serviceCode !== null) {
751-
contents.serviceCode = data.serviceCode;
752+
contents.serviceCode = __expectString(data.serviceCode);
752753
}
753754
return contents;
754755
};
@@ -772,13 +773,13 @@ const deserializeAws_restJson1ThrottlingExceptionResponse = async (
772773
}
773774
const data: any = parsedOutput.body;
774775
if (data.message !== undefined && data.message !== null) {
775-
contents.message = data.message;
776+
contents.message = __expectString(data.message);
776777
}
777778
if (data.quotaCode !== undefined && data.quotaCode !== null) {
778-
contents.quotaCode = data.quotaCode;
779+
contents.quotaCode = __expectString(data.quotaCode);
779780
}
780781
if (data.serviceCode !== undefined && data.serviceCode !== null) {
781-
contents.serviceCode = data.serviceCode;
782+
contents.serviceCode = __expectString(data.serviceCode);
782783
}
783784
return contents;
784785
};
@@ -800,10 +801,10 @@ const deserializeAws_restJson1ValidationExceptionResponse = async (
800801
contents.fieldList = deserializeAws_restJson1ValidationExceptionFieldList(data.fieldList, context);
801802
}
802803
if (data.message !== undefined && data.message !== null) {
803-
contents.message = data.message;
804+
contents.message = __expectString(data.message);
804805
}
805806
if (data.reason !== undefined && data.reason !== null) {
806-
contents.reason = data.reason;
807+
contents.reason = __expectString(data.reason);
807808
}
808809
return contents;
809810
};
@@ -813,8 +814,8 @@ const deserializeAws_restJson1ValidationExceptionField = (
813814
context: __SerdeContext
814815
): ValidationExceptionField => {
815816
return {
816-
message: output.message !== undefined && output.message !== null ? output.message : undefined,
817-
name: output.name !== undefined && output.name !== null ? output.name : undefined,
817+
message: output.message !== undefined && output.message !== null ? __expectString(output.message) : undefined,
818+
name: output.name !== undefined && output.name !== null ? __expectString(output.name) : undefined,
818819
} as any;
819820
};
820821

@@ -834,34 +835,36 @@ const deserializeAws_restJson1ValidationExceptionFieldList = (
834835

835836
const deserializeAws_restJson1WorkspaceDescription = (output: any, context: __SerdeContext): WorkspaceDescription => {
836837
return {
837-
alias: output.alias !== undefined && output.alias !== null ? output.alias : undefined,
838-
arn: output.arn !== undefined && output.arn !== null ? output.arn : undefined,
838+
alias: output.alias !== undefined && output.alias !== null ? __expectString(output.alias) : undefined,
839+
arn: output.arn !== undefined && output.arn !== null ? __expectString(output.arn) : undefined,
839840
createdAt:
840841
output.createdAt !== undefined && output.createdAt !== null
841842
? new Date(Math.round(output.createdAt * 1000))
842843
: undefined,
843844
prometheusEndpoint:
844845
output.prometheusEndpoint !== undefined && output.prometheusEndpoint !== null
845-
? output.prometheusEndpoint
846+
? __expectString(output.prometheusEndpoint)
846847
: undefined,
847848
status:
848849
output.status !== undefined && output.status !== null
849850
? deserializeAws_restJson1WorkspaceStatus(output.status, context)
850851
: undefined,
851-
workspaceId: output.workspaceId !== undefined && output.workspaceId !== null ? output.workspaceId : undefined,
852+
workspaceId:
853+
output.workspaceId !== undefined && output.workspaceId !== null ? __expectString(output.workspaceId) : undefined,
852854
} as any;
853855
};
854856

855857
const deserializeAws_restJson1WorkspaceStatus = (output: any, context: __SerdeContext): WorkspaceStatus => {
856858
return {
857-
statusCode: output.statusCode !== undefined && output.statusCode !== null ? output.statusCode : undefined,
859+
statusCode:
860+
output.statusCode !== undefined && output.statusCode !== null ? __expectString(output.statusCode) : undefined,
858861
} as any;
859862
};
860863

861864
const deserializeAws_restJson1WorkspaceSummary = (output: any, context: __SerdeContext): WorkspaceSummary => {
862865
return {
863-
alias: output.alias !== undefined && output.alias !== null ? output.alias : undefined,
864-
arn: output.arn !== undefined && output.arn !== null ? output.arn : undefined,
866+
alias: output.alias !== undefined && output.alias !== null ? __expectString(output.alias) : undefined,
867+
arn: output.arn !== undefined && output.arn !== null ? __expectString(output.arn) : undefined,
865868
createdAt:
866869
output.createdAt !== undefined && output.createdAt !== null
867870
? new Date(Math.round(output.createdAt * 1000))
@@ -870,7 +873,8 @@ const deserializeAws_restJson1WorkspaceSummary = (output: any, context: __SerdeC
870873
output.status !== undefined && output.status !== null
871874
? deserializeAws_restJson1WorkspaceStatus(output.status, context)
872875
: undefined,
873-
workspaceId: output.workspaceId !== undefined && output.workspaceId !== null ? output.workspaceId : undefined,
876+
workspaceId:
877+
output.workspaceId !== undefined && output.workspaceId !== null ? __expectString(output.workspaceId) : undefined,
874878
} as any;
875879
};
876880

0 commit comments

Comments
 (0)