@aws-sdk/client-amplifybackend 3.121.0 → 3.130.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +27 -0
- package/dist-cjs/protocols/Aws_restJson1.js +182 -285
- package/dist-es/protocols/Aws_restJson1.js +125 -228
- package/package.json +26 -26
|
@@ -35,8 +35,7 @@ const serializeAws_restJson1CloneBackendCommand = async (input, context) => {
|
|
|
35
35
|
}
|
|
36
36
|
let body;
|
|
37
37
|
body = JSON.stringify({
|
|
38
|
-
...(input.TargetEnvironmentName
|
|
39
|
-
input.TargetEnvironmentName !== null && { targetEnvironmentName: input.TargetEnvironmentName }),
|
|
38
|
+
...(input.TargetEnvironmentName != null && { targetEnvironmentName: input.TargetEnvironmentName }),
|
|
40
39
|
});
|
|
41
40
|
return new protocol_http_1.HttpRequest({
|
|
42
41
|
protocol,
|
|
@@ -57,15 +56,13 @@ const serializeAws_restJson1CreateBackendCommand = async (input, context) => {
|
|
|
57
56
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/backend";
|
|
58
57
|
let body;
|
|
59
58
|
body = JSON.stringify({
|
|
60
|
-
...(input.AppId
|
|
61
|
-
...(input.AppName
|
|
62
|
-
...(input.BackendEnvironmentName
|
|
63
|
-
|
|
64
|
-
...(input.ResourceConfig !== undefined &&
|
|
65
|
-
input.ResourceConfig !== null && {
|
|
59
|
+
...(input.AppId != null && { appId: input.AppId }),
|
|
60
|
+
...(input.AppName != null && { appName: input.AppName }),
|
|
61
|
+
...(input.BackendEnvironmentName != null && { backendEnvironmentName: input.BackendEnvironmentName }),
|
|
62
|
+
...(input.ResourceConfig != null && {
|
|
66
63
|
resourceConfig: serializeAws_restJson1ResourceConfig(input.ResourceConfig, context),
|
|
67
64
|
}),
|
|
68
|
-
...(input.ResourceName
|
|
65
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
69
66
|
});
|
|
70
67
|
return new protocol_http_1.HttpRequest({
|
|
71
68
|
protocol,
|
|
@@ -96,13 +93,11 @@ const serializeAws_restJson1CreateBackendAPICommand = async (input, context) =>
|
|
|
96
93
|
}
|
|
97
94
|
let body;
|
|
98
95
|
body = JSON.stringify({
|
|
99
|
-
...(input.BackendEnvironmentName
|
|
100
|
-
|
|
101
|
-
...(input.ResourceConfig !== undefined &&
|
|
102
|
-
input.ResourceConfig !== null && {
|
|
96
|
+
...(input.BackendEnvironmentName != null && { backendEnvironmentName: input.BackendEnvironmentName }),
|
|
97
|
+
...(input.ResourceConfig != null && {
|
|
103
98
|
resourceConfig: serializeAws_restJson1BackendAPIResourceConfig(input.ResourceConfig, context),
|
|
104
99
|
}),
|
|
105
|
-
...(input.ResourceName
|
|
100
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
106
101
|
});
|
|
107
102
|
return new protocol_http_1.HttpRequest({
|
|
108
103
|
protocol,
|
|
@@ -133,13 +128,11 @@ const serializeAws_restJson1CreateBackendAuthCommand = async (input, context) =>
|
|
|
133
128
|
}
|
|
134
129
|
let body;
|
|
135
130
|
body = JSON.stringify({
|
|
136
|
-
...(input.BackendEnvironmentName
|
|
137
|
-
|
|
138
|
-
...(input.ResourceConfig !== undefined &&
|
|
139
|
-
input.ResourceConfig !== null && {
|
|
131
|
+
...(input.BackendEnvironmentName != null && { backendEnvironmentName: input.BackendEnvironmentName }),
|
|
132
|
+
...(input.ResourceConfig != null && {
|
|
140
133
|
resourceConfig: serializeAws_restJson1CreateBackendAuthResourceConfig(input.ResourceConfig, context),
|
|
141
134
|
}),
|
|
142
|
-
...(input.ResourceName
|
|
135
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
143
136
|
});
|
|
144
137
|
return new protocol_http_1.HttpRequest({
|
|
145
138
|
protocol,
|
|
@@ -170,8 +163,7 @@ const serializeAws_restJson1CreateBackendConfigCommand = async (input, context)
|
|
|
170
163
|
}
|
|
171
164
|
let body;
|
|
172
165
|
body = JSON.stringify({
|
|
173
|
-
...(input.BackendManagerAppId
|
|
174
|
-
input.BackendManagerAppId !== null && { backendManagerAppId: input.BackendManagerAppId }),
|
|
166
|
+
...(input.BackendManagerAppId != null && { backendManagerAppId: input.BackendManagerAppId }),
|
|
175
167
|
});
|
|
176
168
|
return new protocol_http_1.HttpRequest({
|
|
177
169
|
protocol,
|
|
@@ -202,13 +194,11 @@ const serializeAws_restJson1CreateBackendStorageCommand = async (input, context)
|
|
|
202
194
|
}
|
|
203
195
|
let body;
|
|
204
196
|
body = JSON.stringify({
|
|
205
|
-
...(input.BackendEnvironmentName
|
|
206
|
-
|
|
207
|
-
...(input.ResourceConfig !== undefined &&
|
|
208
|
-
input.ResourceConfig !== null && {
|
|
197
|
+
...(input.BackendEnvironmentName != null && { backendEnvironmentName: input.BackendEnvironmentName }),
|
|
198
|
+
...(input.ResourceConfig != null && {
|
|
209
199
|
resourceConfig: serializeAws_restJson1CreateBackendStorageResourceConfig(input.ResourceConfig, context),
|
|
210
200
|
}),
|
|
211
|
-
...(input.ResourceName
|
|
201
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
212
202
|
});
|
|
213
203
|
return new protocol_http_1.HttpRequest({
|
|
214
204
|
protocol,
|
|
@@ -313,11 +303,10 @@ const serializeAws_restJson1DeleteBackendAPICommand = async (input, context) =>
|
|
|
313
303
|
}
|
|
314
304
|
let body;
|
|
315
305
|
body = JSON.stringify({
|
|
316
|
-
...(input.ResourceConfig
|
|
317
|
-
input.ResourceConfig !== null && {
|
|
306
|
+
...(input.ResourceConfig != null && {
|
|
318
307
|
resourceConfig: serializeAws_restJson1BackendAPIResourceConfig(input.ResourceConfig, context),
|
|
319
308
|
}),
|
|
320
|
-
...(input.ResourceName
|
|
309
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
321
310
|
});
|
|
322
311
|
return new protocol_http_1.HttpRequest({
|
|
323
312
|
protocol,
|
|
@@ -359,7 +348,7 @@ const serializeAws_restJson1DeleteBackendAuthCommand = async (input, context) =>
|
|
|
359
348
|
}
|
|
360
349
|
let body;
|
|
361
350
|
body = JSON.stringify({
|
|
362
|
-
...(input.ResourceName
|
|
351
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
363
352
|
});
|
|
364
353
|
return new protocol_http_1.HttpRequest({
|
|
365
354
|
protocol,
|
|
@@ -401,8 +390,8 @@ const serializeAws_restJson1DeleteBackendStorageCommand = async (input, context)
|
|
|
401
390
|
}
|
|
402
391
|
let body;
|
|
403
392
|
body = JSON.stringify({
|
|
404
|
-
...(input.ResourceName
|
|
405
|
-
...(input.ServiceName
|
|
393
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
394
|
+
...(input.ServiceName != null && { serviceName: input.ServiceName }),
|
|
406
395
|
});
|
|
407
396
|
return new protocol_http_1.HttpRequest({
|
|
408
397
|
protocol,
|
|
@@ -481,7 +470,7 @@ const serializeAws_restJson1GenerateBackendAPIModelsCommand = async (input, cont
|
|
|
481
470
|
}
|
|
482
471
|
let body;
|
|
483
472
|
body = JSON.stringify({
|
|
484
|
-
...(input.ResourceName
|
|
473
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
485
474
|
});
|
|
486
475
|
return new protocol_http_1.HttpRequest({
|
|
487
476
|
protocol,
|
|
@@ -512,8 +501,7 @@ const serializeAws_restJson1GetBackendCommand = async (input, context) => {
|
|
|
512
501
|
}
|
|
513
502
|
let body;
|
|
514
503
|
body = JSON.stringify({
|
|
515
|
-
...(input.BackendEnvironmentName
|
|
516
|
-
input.BackendEnvironmentName !== null && { backendEnvironmentName: input.BackendEnvironmentName }),
|
|
504
|
+
...(input.BackendEnvironmentName != null && { backendEnvironmentName: input.BackendEnvironmentName }),
|
|
517
505
|
});
|
|
518
506
|
return new protocol_http_1.HttpRequest({
|
|
519
507
|
protocol,
|
|
@@ -555,11 +543,10 @@ const serializeAws_restJson1GetBackendAPICommand = async (input, context) => {
|
|
|
555
543
|
}
|
|
556
544
|
let body;
|
|
557
545
|
body = JSON.stringify({
|
|
558
|
-
...(input.ResourceConfig
|
|
559
|
-
input.ResourceConfig !== null && {
|
|
546
|
+
...(input.ResourceConfig != null && {
|
|
560
547
|
resourceConfig: serializeAws_restJson1BackendAPIResourceConfig(input.ResourceConfig, context),
|
|
561
548
|
}),
|
|
562
|
-
...(input.ResourceName
|
|
549
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
563
550
|
});
|
|
564
551
|
return new protocol_http_1.HttpRequest({
|
|
565
552
|
protocol,
|
|
@@ -601,7 +588,7 @@ const serializeAws_restJson1GetBackendAPIModelsCommand = async (input, context)
|
|
|
601
588
|
}
|
|
602
589
|
let body;
|
|
603
590
|
body = JSON.stringify({
|
|
604
|
-
...(input.ResourceName
|
|
591
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
605
592
|
});
|
|
606
593
|
return new protocol_http_1.HttpRequest({
|
|
607
594
|
protocol,
|
|
@@ -643,7 +630,7 @@ const serializeAws_restJson1GetBackendAuthCommand = async (input, context) => {
|
|
|
643
630
|
}
|
|
644
631
|
let body;
|
|
645
632
|
body = JSON.stringify({
|
|
646
|
-
...(input.ResourceName
|
|
633
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
647
634
|
});
|
|
648
635
|
return new protocol_http_1.HttpRequest({
|
|
649
636
|
protocol,
|
|
@@ -732,7 +719,7 @@ const serializeAws_restJson1GetBackendStorageCommand = async (input, context) =>
|
|
|
732
719
|
}
|
|
733
720
|
let body;
|
|
734
721
|
body = JSON.stringify({
|
|
735
|
-
...(input.ResourceName
|
|
722
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
736
723
|
});
|
|
737
724
|
return new protocol_http_1.HttpRequest({
|
|
738
725
|
protocol,
|
|
@@ -810,12 +797,10 @@ const serializeAws_restJson1ImportBackendAuthCommand = async (input, context) =>
|
|
|
810
797
|
}
|
|
811
798
|
let body;
|
|
812
799
|
body = JSON.stringify({
|
|
813
|
-
...(input.IdentityPoolId
|
|
814
|
-
|
|
815
|
-
...(input.
|
|
816
|
-
|
|
817
|
-
...(input.UserPoolId !== undefined && input.UserPoolId !== null && { userPoolId: input.UserPoolId }),
|
|
818
|
-
...(input.WebClientId !== undefined && input.WebClientId !== null && { webClientId: input.WebClientId }),
|
|
800
|
+
...(input.IdentityPoolId != null && { identityPoolId: input.IdentityPoolId }),
|
|
801
|
+
...(input.NativeClientId != null && { nativeClientId: input.NativeClientId }),
|
|
802
|
+
...(input.UserPoolId != null && { userPoolId: input.UserPoolId }),
|
|
803
|
+
...(input.WebClientId != null && { webClientId: input.WebClientId }),
|
|
819
804
|
});
|
|
820
805
|
return new protocol_http_1.HttpRequest({
|
|
821
806
|
protocol,
|
|
@@ -857,8 +842,8 @@ const serializeAws_restJson1ImportBackendStorageCommand = async (input, context)
|
|
|
857
842
|
}
|
|
858
843
|
let body;
|
|
859
844
|
body = JSON.stringify({
|
|
860
|
-
...(input.BucketName
|
|
861
|
-
...(input.ServiceName
|
|
845
|
+
...(input.BucketName != null && { bucketName: input.BucketName }),
|
|
846
|
+
...(input.ServiceName != null && { serviceName: input.ServiceName }),
|
|
862
847
|
});
|
|
863
848
|
return new protocol_http_1.HttpRequest({
|
|
864
849
|
protocol,
|
|
@@ -900,11 +885,11 @@ const serializeAws_restJson1ListBackendJobsCommand = async (input, context) => {
|
|
|
900
885
|
}
|
|
901
886
|
let body;
|
|
902
887
|
body = JSON.stringify({
|
|
903
|
-
...(input.JobId
|
|
904
|
-
...(input.MaxResults
|
|
905
|
-
...(input.NextToken
|
|
906
|
-
...(input.Operation
|
|
907
|
-
...(input.Status
|
|
888
|
+
...(input.JobId != null && { jobId: input.JobId }),
|
|
889
|
+
...(input.MaxResults != null && { maxResults: input.MaxResults }),
|
|
890
|
+
...(input.NextToken != null && { nextToken: input.NextToken }),
|
|
891
|
+
...(input.Operation != null && { operation: input.Operation }),
|
|
892
|
+
...(input.Status != null && { status: input.Status }),
|
|
908
893
|
});
|
|
909
894
|
return new protocol_http_1.HttpRequest({
|
|
910
895
|
protocol,
|
|
@@ -925,7 +910,7 @@ const serializeAws_restJson1ListS3BucketsCommand = async (input, context) => {
|
|
|
925
910
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/s3Buckets";
|
|
926
911
|
let body;
|
|
927
912
|
body = JSON.stringify({
|
|
928
|
-
...(input.NextToken
|
|
913
|
+
...(input.NextToken != null && { nextToken: input.NextToken }),
|
|
929
914
|
});
|
|
930
915
|
return new protocol_http_1.HttpRequest({
|
|
931
916
|
protocol,
|
|
@@ -956,8 +941,7 @@ const serializeAws_restJson1RemoveAllBackendsCommand = async (input, context) =>
|
|
|
956
941
|
}
|
|
957
942
|
let body;
|
|
958
943
|
body = JSON.stringify({
|
|
959
|
-
...(input.CleanAmplifyApp
|
|
960
|
-
input.CleanAmplifyApp !== null && { cleanAmplifyApp: input.CleanAmplifyApp }),
|
|
944
|
+
...(input.CleanAmplifyApp != null && { cleanAmplifyApp: input.CleanAmplifyApp }),
|
|
961
945
|
});
|
|
962
946
|
return new protocol_http_1.HttpRequest({
|
|
963
947
|
protocol,
|
|
@@ -1025,11 +1009,10 @@ const serializeAws_restJson1UpdateBackendAPICommand = async (input, context) =>
|
|
|
1025
1009
|
}
|
|
1026
1010
|
let body;
|
|
1027
1011
|
body = JSON.stringify({
|
|
1028
|
-
...(input.ResourceConfig
|
|
1029
|
-
input.ResourceConfig !== null && {
|
|
1012
|
+
...(input.ResourceConfig != null && {
|
|
1030
1013
|
resourceConfig: serializeAws_restJson1BackendAPIResourceConfig(input.ResourceConfig, context),
|
|
1031
1014
|
}),
|
|
1032
|
-
...(input.ResourceName
|
|
1015
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
1033
1016
|
});
|
|
1034
1017
|
return new protocol_http_1.HttpRequest({
|
|
1035
1018
|
protocol,
|
|
@@ -1071,11 +1054,10 @@ const serializeAws_restJson1UpdateBackendAuthCommand = async (input, context) =>
|
|
|
1071
1054
|
}
|
|
1072
1055
|
let body;
|
|
1073
1056
|
body = JSON.stringify({
|
|
1074
|
-
...(input.ResourceConfig
|
|
1075
|
-
input.ResourceConfig !== null && {
|
|
1057
|
+
...(input.ResourceConfig != null && {
|
|
1076
1058
|
resourceConfig: serializeAws_restJson1UpdateBackendAuthResourceConfig(input.ResourceConfig, context),
|
|
1077
1059
|
}),
|
|
1078
|
-
...(input.ResourceName
|
|
1060
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
1079
1061
|
});
|
|
1080
1062
|
return new protocol_http_1.HttpRequest({
|
|
1081
1063
|
protocol,
|
|
@@ -1106,8 +1088,7 @@ const serializeAws_restJson1UpdateBackendConfigCommand = async (input, context)
|
|
|
1106
1088
|
}
|
|
1107
1089
|
let body;
|
|
1108
1090
|
body = JSON.stringify({
|
|
1109
|
-
...(input.LoginAuthConfig
|
|
1110
|
-
input.LoginAuthConfig !== null && {
|
|
1091
|
+
...(input.LoginAuthConfig != null && {
|
|
1111
1092
|
loginAuthConfig: serializeAws_restJson1LoginAuthConfigReqObj(input.LoginAuthConfig, context),
|
|
1112
1093
|
}),
|
|
1113
1094
|
});
|
|
@@ -1161,8 +1142,8 @@ const serializeAws_restJson1UpdateBackendJobCommand = async (input, context) =>
|
|
|
1161
1142
|
}
|
|
1162
1143
|
let body;
|
|
1163
1144
|
body = JSON.stringify({
|
|
1164
|
-
...(input.Operation
|
|
1165
|
-
...(input.Status
|
|
1145
|
+
...(input.Operation != null && { operation: input.Operation }),
|
|
1146
|
+
...(input.Status != null && { status: input.Status }),
|
|
1166
1147
|
});
|
|
1167
1148
|
return new protocol_http_1.HttpRequest({
|
|
1168
1149
|
protocol,
|
|
@@ -1204,11 +1185,10 @@ const serializeAws_restJson1UpdateBackendStorageCommand = async (input, context)
|
|
|
1204
1185
|
}
|
|
1205
1186
|
let body;
|
|
1206
1187
|
body = JSON.stringify({
|
|
1207
|
-
...(input.ResourceConfig
|
|
1208
|
-
input.ResourceConfig !== null && {
|
|
1188
|
+
...(input.ResourceConfig != null && {
|
|
1209
1189
|
resourceConfig: serializeAws_restJson1UpdateBackendStorageResourceConfig(input.ResourceConfig, context),
|
|
1210
1190
|
}),
|
|
1211
|
-
...(input.ResourceName
|
|
1191
|
+
...(input.ResourceName != null && { resourceName: input.ResourceName }),
|
|
1212
1192
|
});
|
|
1213
1193
|
return new protocol_http_1.HttpRequest({
|
|
1214
1194
|
protocol,
|
|
@@ -3202,208 +3182,170 @@ const deserializeAws_restJson1TooManyRequestsExceptionResponse = async (parsedOu
|
|
|
3202
3182
|
};
|
|
3203
3183
|
const serializeAws_restJson1BackendAPIAppSyncAuthSettings = (input, context) => {
|
|
3204
3184
|
return {
|
|
3205
|
-
...(input.CognitoUserPoolId
|
|
3206
|
-
|
|
3207
|
-
...(input.
|
|
3208
|
-
...(input.
|
|
3209
|
-
|
|
3210
|
-
...(input.
|
|
3211
|
-
...(input.
|
|
3212
|
-
|
|
3213
|
-
...(input.OpenIDIatTTL !== undefined && input.OpenIDIatTTL !== null && { openIDIatTTL: input.OpenIDIatTTL }),
|
|
3214
|
-
...(input.OpenIDIssueURL !== undefined &&
|
|
3215
|
-
input.OpenIDIssueURL !== null && { openIDIssueURL: input.OpenIDIssueURL }),
|
|
3216
|
-
...(input.OpenIDProviderName !== undefined &&
|
|
3217
|
-
input.OpenIDProviderName !== null && { openIDProviderName: input.OpenIDProviderName }),
|
|
3185
|
+
...(input.CognitoUserPoolId != null && { cognitoUserPoolId: input.CognitoUserPoolId }),
|
|
3186
|
+
...(input.Description != null && { description: input.Description }),
|
|
3187
|
+
...(input.ExpirationTime != null && { expirationTime: (0, smithy_client_1.serializeFloat)(input.ExpirationTime) }),
|
|
3188
|
+
...(input.OpenIDAuthTTL != null && { openIDAuthTTL: input.OpenIDAuthTTL }),
|
|
3189
|
+
...(input.OpenIDClientId != null && { openIDClientId: input.OpenIDClientId }),
|
|
3190
|
+
...(input.OpenIDIatTTL != null && { openIDIatTTL: input.OpenIDIatTTL }),
|
|
3191
|
+
...(input.OpenIDIssueURL != null && { openIDIssueURL: input.OpenIDIssueURL }),
|
|
3192
|
+
...(input.OpenIDProviderName != null && { openIDProviderName: input.OpenIDProviderName }),
|
|
3218
3193
|
};
|
|
3219
3194
|
};
|
|
3220
3195
|
const serializeAws_restJson1BackendAPIAuthType = (input, context) => {
|
|
3221
3196
|
return {
|
|
3222
|
-
...(input.Mode
|
|
3223
|
-
...(input.Settings
|
|
3224
|
-
input.Settings !== null && {
|
|
3197
|
+
...(input.Mode != null && { mode: input.Mode }),
|
|
3198
|
+
...(input.Settings != null && {
|
|
3225
3199
|
settings: serializeAws_restJson1BackendAPIAppSyncAuthSettings(input.Settings, context),
|
|
3226
3200
|
}),
|
|
3227
3201
|
};
|
|
3228
3202
|
};
|
|
3229
3203
|
const serializeAws_restJson1BackendAPIConflictResolution = (input, context) => {
|
|
3230
3204
|
return {
|
|
3231
|
-
...(input.ResolutionStrategy
|
|
3232
|
-
input.ResolutionStrategy !== null && { resolutionStrategy: input.ResolutionStrategy }),
|
|
3205
|
+
...(input.ResolutionStrategy != null && { resolutionStrategy: input.ResolutionStrategy }),
|
|
3233
3206
|
};
|
|
3234
3207
|
};
|
|
3235
3208
|
const serializeAws_restJson1BackendAPIResourceConfig = (input, context) => {
|
|
3236
3209
|
return {
|
|
3237
|
-
...(input.AdditionalAuthTypes
|
|
3238
|
-
input.AdditionalAuthTypes !== null && {
|
|
3210
|
+
...(input.AdditionalAuthTypes != null && {
|
|
3239
3211
|
additionalAuthTypes: serializeAws_restJson1ListOfBackendAPIAuthType(input.AdditionalAuthTypes, context),
|
|
3240
3212
|
}),
|
|
3241
|
-
...(input.ApiName
|
|
3242
|
-
...(input.ConflictResolution
|
|
3243
|
-
input.ConflictResolution !== null && {
|
|
3213
|
+
...(input.ApiName != null && { apiName: input.ApiName }),
|
|
3214
|
+
...(input.ConflictResolution != null && {
|
|
3244
3215
|
conflictResolution: serializeAws_restJson1BackendAPIConflictResolution(input.ConflictResolution, context),
|
|
3245
3216
|
}),
|
|
3246
|
-
...(input.DefaultAuthType
|
|
3247
|
-
input.DefaultAuthType !== null && {
|
|
3217
|
+
...(input.DefaultAuthType != null && {
|
|
3248
3218
|
defaultAuthType: serializeAws_restJson1BackendAPIAuthType(input.DefaultAuthType, context),
|
|
3249
3219
|
}),
|
|
3250
|
-
...(input.Service
|
|
3251
|
-
...(input.TransformSchema
|
|
3252
|
-
input.TransformSchema !== null && { transformSchema: input.TransformSchema }),
|
|
3220
|
+
...(input.Service != null && { service: input.Service }),
|
|
3221
|
+
...(input.TransformSchema != null && { transformSchema: input.TransformSchema }),
|
|
3253
3222
|
};
|
|
3254
3223
|
};
|
|
3255
3224
|
const serializeAws_restJson1BackendAuthAppleProviderConfig = (input, context) => {
|
|
3256
3225
|
return {
|
|
3257
|
-
...(input.ClientId
|
|
3258
|
-
...(input.KeyId
|
|
3259
|
-
...(input.PrivateKey
|
|
3260
|
-
...(input.TeamId
|
|
3226
|
+
...(input.ClientId != null && { client_id: input.ClientId }),
|
|
3227
|
+
...(input.KeyId != null && { key_id: input.KeyId }),
|
|
3228
|
+
...(input.PrivateKey != null && { private_key: input.PrivateKey }),
|
|
3229
|
+
...(input.TeamId != null && { team_id: input.TeamId }),
|
|
3261
3230
|
};
|
|
3262
3231
|
};
|
|
3263
3232
|
const serializeAws_restJson1BackendAuthSocialProviderConfig = (input, context) => {
|
|
3264
3233
|
return {
|
|
3265
|
-
...(input.ClientId
|
|
3266
|
-
...(input.ClientSecret
|
|
3234
|
+
...(input.ClientId != null && { client_id: input.ClientId }),
|
|
3235
|
+
...(input.ClientSecret != null && { client_secret: input.ClientSecret }),
|
|
3267
3236
|
};
|
|
3268
3237
|
};
|
|
3269
3238
|
const serializeAws_restJson1BackendStoragePermissions = (input, context) => {
|
|
3270
3239
|
return {
|
|
3271
|
-
...(input.Authenticated
|
|
3272
|
-
input.Authenticated !== null && {
|
|
3240
|
+
...(input.Authenticated != null && {
|
|
3273
3241
|
authenticated: serializeAws_restJson1ListOfAuthenticatedElement(input.Authenticated, context),
|
|
3274
3242
|
}),
|
|
3275
|
-
...(input.UnAuthenticated
|
|
3276
|
-
input.UnAuthenticated !== null && {
|
|
3243
|
+
...(input.UnAuthenticated != null && {
|
|
3277
3244
|
unAuthenticated: serializeAws_restJson1ListOfUnAuthenticatedElement(input.UnAuthenticated, context),
|
|
3278
3245
|
}),
|
|
3279
3246
|
};
|
|
3280
3247
|
};
|
|
3281
3248
|
const serializeAws_restJson1CreateBackendAuthForgotPasswordConfig = (input, context) => {
|
|
3282
3249
|
return {
|
|
3283
|
-
...(input.DeliveryMethod
|
|
3284
|
-
|
|
3285
|
-
...(input.EmailSettings !== undefined &&
|
|
3286
|
-
input.EmailSettings !== null && {
|
|
3250
|
+
...(input.DeliveryMethod != null && { deliveryMethod: input.DeliveryMethod }),
|
|
3251
|
+
...(input.EmailSettings != null && {
|
|
3287
3252
|
emailSettings: serializeAws_restJson1EmailSettings(input.EmailSettings, context),
|
|
3288
3253
|
}),
|
|
3289
|
-
...(input.SmsSettings
|
|
3290
|
-
input.SmsSettings !== null && { smsSettings: serializeAws_restJson1SmsSettings(input.SmsSettings, context) }),
|
|
3254
|
+
...(input.SmsSettings != null && { smsSettings: serializeAws_restJson1SmsSettings(input.SmsSettings, context) }),
|
|
3291
3255
|
};
|
|
3292
3256
|
};
|
|
3293
3257
|
const serializeAws_restJson1CreateBackendAuthIdentityPoolConfig = (input, context) => {
|
|
3294
3258
|
return {
|
|
3295
|
-
...(input.IdentityPoolName
|
|
3296
|
-
|
|
3297
|
-
...(input.UnauthenticatedLogin !== undefined &&
|
|
3298
|
-
input.UnauthenticatedLogin !== null && { unauthenticatedLogin: input.UnauthenticatedLogin }),
|
|
3259
|
+
...(input.IdentityPoolName != null && { identityPoolName: input.IdentityPoolName }),
|
|
3260
|
+
...(input.UnauthenticatedLogin != null && { unauthenticatedLogin: input.UnauthenticatedLogin }),
|
|
3299
3261
|
};
|
|
3300
3262
|
};
|
|
3301
3263
|
const serializeAws_restJson1CreateBackendAuthMFAConfig = (input, context) => {
|
|
3302
3264
|
return {
|
|
3303
|
-
...(input.MFAMode
|
|
3304
|
-
...(input.Settings
|
|
3305
|
-
input.Settings !== null && { settings: serializeAws_restJson1Settings(input.Settings, context) }),
|
|
3265
|
+
...(input.MFAMode != null && { MFAMode: input.MFAMode }),
|
|
3266
|
+
...(input.Settings != null && { settings: serializeAws_restJson1Settings(input.Settings, context) }),
|
|
3306
3267
|
};
|
|
3307
3268
|
};
|
|
3308
3269
|
const serializeAws_restJson1CreateBackendAuthOAuthConfig = (input, context) => {
|
|
3309
3270
|
return {
|
|
3310
|
-
...(input.DomainPrefix
|
|
3311
|
-
...(input.OAuthGrantType
|
|
3312
|
-
|
|
3313
|
-
...(input.OAuthScopes !== undefined &&
|
|
3314
|
-
input.OAuthScopes !== null && {
|
|
3271
|
+
...(input.DomainPrefix != null && { domainPrefix: input.DomainPrefix }),
|
|
3272
|
+
...(input.OAuthGrantType != null && { oAuthGrantType: input.OAuthGrantType }),
|
|
3273
|
+
...(input.OAuthScopes != null && {
|
|
3315
3274
|
oAuthScopes: serializeAws_restJson1ListOfOAuthScopesElement(input.OAuthScopes, context),
|
|
3316
3275
|
}),
|
|
3317
|
-
...(input.RedirectSignInURIs
|
|
3318
|
-
input.RedirectSignInURIs !== null && {
|
|
3276
|
+
...(input.RedirectSignInURIs != null && {
|
|
3319
3277
|
redirectSignInURIs: serializeAws_restJson1ListOf__string(input.RedirectSignInURIs, context),
|
|
3320
3278
|
}),
|
|
3321
|
-
...(input.RedirectSignOutURIs
|
|
3322
|
-
input.RedirectSignOutURIs !== null && {
|
|
3279
|
+
...(input.RedirectSignOutURIs != null && {
|
|
3323
3280
|
redirectSignOutURIs: serializeAws_restJson1ListOf__string(input.RedirectSignOutURIs, context),
|
|
3324
3281
|
}),
|
|
3325
|
-
...(input.SocialProviderSettings
|
|
3326
|
-
input.SocialProviderSettings !== null && {
|
|
3282
|
+
...(input.SocialProviderSettings != null && {
|
|
3327
3283
|
socialProviderSettings: serializeAws_restJson1SocialProviderSettings(input.SocialProviderSettings, context),
|
|
3328
3284
|
}),
|
|
3329
3285
|
};
|
|
3330
3286
|
};
|
|
3331
3287
|
const serializeAws_restJson1CreateBackendAuthPasswordPolicyConfig = (input, context) => {
|
|
3332
3288
|
return {
|
|
3333
|
-
...(input.AdditionalConstraints
|
|
3334
|
-
input.AdditionalConstraints !== null && {
|
|
3289
|
+
...(input.AdditionalConstraints != null && {
|
|
3335
3290
|
additionalConstraints: serializeAws_restJson1ListOfAdditionalConstraintsElement(input.AdditionalConstraints, context),
|
|
3336
3291
|
}),
|
|
3337
|
-
...(input.MinimumLength
|
|
3338
|
-
input.MinimumLength !== null && { minimumLength: (0, smithy_client_1.serializeFloat)(input.MinimumLength) }),
|
|
3292
|
+
...(input.MinimumLength != null && { minimumLength: (0, smithy_client_1.serializeFloat)(input.MinimumLength) }),
|
|
3339
3293
|
};
|
|
3340
3294
|
};
|
|
3341
3295
|
const serializeAws_restJson1CreateBackendAuthResourceConfig = (input, context) => {
|
|
3342
3296
|
return {
|
|
3343
|
-
...(input.AuthResources
|
|
3344
|
-
...(input.IdentityPoolConfigs
|
|
3345
|
-
input.IdentityPoolConfigs !== null && {
|
|
3297
|
+
...(input.AuthResources != null && { authResources: input.AuthResources }),
|
|
3298
|
+
...(input.IdentityPoolConfigs != null && {
|
|
3346
3299
|
identityPoolConfigs: serializeAws_restJson1CreateBackendAuthIdentityPoolConfig(input.IdentityPoolConfigs, context),
|
|
3347
3300
|
}),
|
|
3348
|
-
...(input.Service
|
|
3349
|
-
...(input.UserPoolConfigs
|
|
3350
|
-
input.UserPoolConfigs !== null && {
|
|
3301
|
+
...(input.Service != null && { service: input.Service }),
|
|
3302
|
+
...(input.UserPoolConfigs != null && {
|
|
3351
3303
|
userPoolConfigs: serializeAws_restJson1CreateBackendAuthUserPoolConfig(input.UserPoolConfigs, context),
|
|
3352
3304
|
}),
|
|
3353
3305
|
};
|
|
3354
3306
|
};
|
|
3355
3307
|
const serializeAws_restJson1CreateBackendAuthUserPoolConfig = (input, context) => {
|
|
3356
3308
|
return {
|
|
3357
|
-
...(input.ForgotPassword
|
|
3358
|
-
input.ForgotPassword !== null && {
|
|
3309
|
+
...(input.ForgotPassword != null && {
|
|
3359
3310
|
forgotPassword: serializeAws_restJson1CreateBackendAuthForgotPasswordConfig(input.ForgotPassword, context),
|
|
3360
3311
|
}),
|
|
3361
|
-
...(input.Mfa
|
|
3362
|
-
|
|
3363
|
-
...(input.
|
|
3364
|
-
input.OAuth !== null && { oAuth: serializeAws_restJson1CreateBackendAuthOAuthConfig(input.OAuth, context) }),
|
|
3365
|
-
...(input.PasswordPolicy !== undefined &&
|
|
3366
|
-
input.PasswordPolicy !== null && {
|
|
3312
|
+
...(input.Mfa != null && { mfa: serializeAws_restJson1CreateBackendAuthMFAConfig(input.Mfa, context) }),
|
|
3313
|
+
...(input.OAuth != null && { oAuth: serializeAws_restJson1CreateBackendAuthOAuthConfig(input.OAuth, context) }),
|
|
3314
|
+
...(input.PasswordPolicy != null && {
|
|
3367
3315
|
passwordPolicy: serializeAws_restJson1CreateBackendAuthPasswordPolicyConfig(input.PasswordPolicy, context),
|
|
3368
3316
|
}),
|
|
3369
|
-
...(input.RequiredSignUpAttributes
|
|
3370
|
-
input.RequiredSignUpAttributes !== null && {
|
|
3317
|
+
...(input.RequiredSignUpAttributes != null && {
|
|
3371
3318
|
requiredSignUpAttributes: serializeAws_restJson1ListOfRequiredSignUpAttributesElement(input.RequiredSignUpAttributes, context),
|
|
3372
3319
|
}),
|
|
3373
|
-
...(input.SignInMethod
|
|
3374
|
-
...(input.UserPoolName
|
|
3375
|
-
...(input.VerificationMessage
|
|
3376
|
-
input.VerificationMessage !== null && {
|
|
3320
|
+
...(input.SignInMethod != null && { signInMethod: input.SignInMethod }),
|
|
3321
|
+
...(input.UserPoolName != null && { userPoolName: input.UserPoolName }),
|
|
3322
|
+
...(input.VerificationMessage != null && {
|
|
3377
3323
|
verificationMessage: serializeAws_restJson1CreateBackendAuthVerificationMessageConfig(input.VerificationMessage, context),
|
|
3378
3324
|
}),
|
|
3379
3325
|
};
|
|
3380
3326
|
};
|
|
3381
3327
|
const serializeAws_restJson1CreateBackendAuthVerificationMessageConfig = (input, context) => {
|
|
3382
3328
|
return {
|
|
3383
|
-
...(input.DeliveryMethod
|
|
3384
|
-
|
|
3385
|
-
...(input.EmailSettings !== undefined &&
|
|
3386
|
-
input.EmailSettings !== null && {
|
|
3329
|
+
...(input.DeliveryMethod != null && { deliveryMethod: input.DeliveryMethod }),
|
|
3330
|
+
...(input.EmailSettings != null && {
|
|
3387
3331
|
emailSettings: serializeAws_restJson1EmailSettings(input.EmailSettings, context),
|
|
3388
3332
|
}),
|
|
3389
|
-
...(input.SmsSettings
|
|
3390
|
-
input.SmsSettings !== null && { smsSettings: serializeAws_restJson1SmsSettings(input.SmsSettings, context) }),
|
|
3333
|
+
...(input.SmsSettings != null && { smsSettings: serializeAws_restJson1SmsSettings(input.SmsSettings, context) }),
|
|
3391
3334
|
};
|
|
3392
3335
|
};
|
|
3393
3336
|
const serializeAws_restJson1CreateBackendStorageResourceConfig = (input, context) => {
|
|
3394
3337
|
return {
|
|
3395
|
-
...(input.BucketName
|
|
3396
|
-
...(input.Permissions
|
|
3397
|
-
input.Permissions !== null && {
|
|
3338
|
+
...(input.BucketName != null && { bucketName: input.BucketName }),
|
|
3339
|
+
...(input.Permissions != null && {
|
|
3398
3340
|
permissions: serializeAws_restJson1BackendStoragePermissions(input.Permissions, context),
|
|
3399
3341
|
}),
|
|
3400
|
-
...(input.ServiceName
|
|
3342
|
+
...(input.ServiceName != null && { serviceName: input.ServiceName }),
|
|
3401
3343
|
};
|
|
3402
3344
|
};
|
|
3403
3345
|
const serializeAws_restJson1EmailSettings = (input, context) => {
|
|
3404
3346
|
return {
|
|
3405
|
-
...(input.EmailMessage
|
|
3406
|
-
...(input.EmailSubject
|
|
3347
|
+
...(input.EmailMessage != null && { emailMessage: input.EmailMessage }),
|
|
3348
|
+
...(input.EmailSubject != null && { emailSubject: input.EmailSubject }),
|
|
3407
3349
|
};
|
|
3408
3350
|
};
|
|
3409
3351
|
const serializeAws_restJson1ListOf__string = (input, context) => {
|
|
@@ -3488,14 +3430,10 @@ const serializeAws_restJson1ListOfUnAuthenticatedElement = (input, context) => {
|
|
|
3488
3430
|
};
|
|
3489
3431
|
const serializeAws_restJson1LoginAuthConfigReqObj = (input, context) => {
|
|
3490
3432
|
return {
|
|
3491
|
-
...(input.AwsCognitoIdentityPoolId
|
|
3492
|
-
|
|
3493
|
-
...(input.
|
|
3494
|
-
|
|
3495
|
-
...(input.AwsUserPoolsId !== undefined &&
|
|
3496
|
-
input.AwsUserPoolsId !== null && { aws_user_pools_id: input.AwsUserPoolsId }),
|
|
3497
|
-
...(input.AwsUserPoolsWebClientId !== undefined &&
|
|
3498
|
-
input.AwsUserPoolsWebClientId !== null && { aws_user_pools_web_client_id: input.AwsUserPoolsWebClientId }),
|
|
3433
|
+
...(input.AwsCognitoIdentityPoolId != null && { aws_cognito_identity_pool_id: input.AwsCognitoIdentityPoolId }),
|
|
3434
|
+
...(input.AwsCognitoRegion != null && { aws_cognito_region: input.AwsCognitoRegion }),
|
|
3435
|
+
...(input.AwsUserPoolsId != null && { aws_user_pools_id: input.AwsUserPoolsId }),
|
|
3436
|
+
...(input.AwsUserPoolsWebClientId != null && { aws_user_pools_web_client_id: input.AwsUserPoolsWebClientId }),
|
|
3499
3437
|
};
|
|
3500
3438
|
};
|
|
3501
3439
|
const serializeAws_restJson1ResourceConfig = (input, context) => {
|
|
@@ -3503,147 +3441,119 @@ const serializeAws_restJson1ResourceConfig = (input, context) => {
|
|
|
3503
3441
|
};
|
|
3504
3442
|
const serializeAws_restJson1Settings = (input, context) => {
|
|
3505
3443
|
return {
|
|
3506
|
-
...(input.MfaTypes
|
|
3507
|
-
|
|
3508
|
-
...(input.SmsMessage !== undefined && input.SmsMessage !== null && { smsMessage: input.SmsMessage }),
|
|
3444
|
+
...(input.MfaTypes != null && { mfaTypes: serializeAws_restJson1ListOfMfaTypesElement(input.MfaTypes, context) }),
|
|
3445
|
+
...(input.SmsMessage != null && { smsMessage: input.SmsMessage }),
|
|
3509
3446
|
};
|
|
3510
3447
|
};
|
|
3511
3448
|
const serializeAws_restJson1SmsSettings = (input, context) => {
|
|
3512
3449
|
return {
|
|
3513
|
-
...(input.SmsMessage
|
|
3450
|
+
...(input.SmsMessage != null && { smsMessage: input.SmsMessage }),
|
|
3514
3451
|
};
|
|
3515
3452
|
};
|
|
3516
3453
|
const serializeAws_restJson1SocialProviderSettings = (input, context) => {
|
|
3517
3454
|
return {
|
|
3518
|
-
...(input.Facebook
|
|
3519
|
-
input.Facebook !== null && {
|
|
3455
|
+
...(input.Facebook != null && {
|
|
3520
3456
|
Facebook: serializeAws_restJson1BackendAuthSocialProviderConfig(input.Facebook, context),
|
|
3521
3457
|
}),
|
|
3522
|
-
...(input.Google
|
|
3523
|
-
input.Google !== null && {
|
|
3458
|
+
...(input.Google != null && {
|
|
3524
3459
|
Google: serializeAws_restJson1BackendAuthSocialProviderConfig(input.Google, context),
|
|
3525
3460
|
}),
|
|
3526
|
-
...(input.LoginWithAmazon
|
|
3527
|
-
input.LoginWithAmazon !== null && {
|
|
3461
|
+
...(input.LoginWithAmazon != null && {
|
|
3528
3462
|
LoginWithAmazon: serializeAws_restJson1BackendAuthSocialProviderConfig(input.LoginWithAmazon, context),
|
|
3529
3463
|
}),
|
|
3530
|
-
...(input.SignInWithApple
|
|
3531
|
-
input.SignInWithApple !== null && {
|
|
3464
|
+
...(input.SignInWithApple != null && {
|
|
3532
3465
|
SignInWithApple: serializeAws_restJson1BackendAuthAppleProviderConfig(input.SignInWithApple, context),
|
|
3533
3466
|
}),
|
|
3534
3467
|
};
|
|
3535
3468
|
};
|
|
3536
3469
|
const serializeAws_restJson1UpdateBackendAuthForgotPasswordConfig = (input, context) => {
|
|
3537
3470
|
return {
|
|
3538
|
-
...(input.DeliveryMethod
|
|
3539
|
-
|
|
3540
|
-
...(input.EmailSettings !== undefined &&
|
|
3541
|
-
input.EmailSettings !== null && {
|
|
3471
|
+
...(input.DeliveryMethod != null && { deliveryMethod: input.DeliveryMethod }),
|
|
3472
|
+
...(input.EmailSettings != null && {
|
|
3542
3473
|
emailSettings: serializeAws_restJson1EmailSettings(input.EmailSettings, context),
|
|
3543
3474
|
}),
|
|
3544
|
-
...(input.SmsSettings
|
|
3545
|
-
input.SmsSettings !== null && { smsSettings: serializeAws_restJson1SmsSettings(input.SmsSettings, context) }),
|
|
3475
|
+
...(input.SmsSettings != null && { smsSettings: serializeAws_restJson1SmsSettings(input.SmsSettings, context) }),
|
|
3546
3476
|
};
|
|
3547
3477
|
};
|
|
3548
3478
|
const serializeAws_restJson1UpdateBackendAuthIdentityPoolConfig = (input, context) => {
|
|
3549
3479
|
return {
|
|
3550
|
-
...(input.UnauthenticatedLogin
|
|
3551
|
-
input.UnauthenticatedLogin !== null && { unauthenticatedLogin: input.UnauthenticatedLogin }),
|
|
3480
|
+
...(input.UnauthenticatedLogin != null && { unauthenticatedLogin: input.UnauthenticatedLogin }),
|
|
3552
3481
|
};
|
|
3553
3482
|
};
|
|
3554
3483
|
const serializeAws_restJson1UpdateBackendAuthMFAConfig = (input, context) => {
|
|
3555
3484
|
return {
|
|
3556
|
-
...(input.MFAMode
|
|
3557
|
-
...(input.Settings
|
|
3558
|
-
input.Settings !== null && { settings: serializeAws_restJson1Settings(input.Settings, context) }),
|
|
3485
|
+
...(input.MFAMode != null && { MFAMode: input.MFAMode }),
|
|
3486
|
+
...(input.Settings != null && { settings: serializeAws_restJson1Settings(input.Settings, context) }),
|
|
3559
3487
|
};
|
|
3560
3488
|
};
|
|
3561
3489
|
const serializeAws_restJson1UpdateBackendAuthOAuthConfig = (input, context) => {
|
|
3562
3490
|
return {
|
|
3563
|
-
...(input.DomainPrefix
|
|
3564
|
-
...(input.OAuthGrantType
|
|
3565
|
-
|
|
3566
|
-
...(input.OAuthScopes !== undefined &&
|
|
3567
|
-
input.OAuthScopes !== null && {
|
|
3491
|
+
...(input.DomainPrefix != null && { domainPrefix: input.DomainPrefix }),
|
|
3492
|
+
...(input.OAuthGrantType != null && { oAuthGrantType: input.OAuthGrantType }),
|
|
3493
|
+
...(input.OAuthScopes != null && {
|
|
3568
3494
|
oAuthScopes: serializeAws_restJson1ListOfOAuthScopesElement(input.OAuthScopes, context),
|
|
3569
3495
|
}),
|
|
3570
|
-
...(input.RedirectSignInURIs
|
|
3571
|
-
input.RedirectSignInURIs !== null && {
|
|
3496
|
+
...(input.RedirectSignInURIs != null && {
|
|
3572
3497
|
redirectSignInURIs: serializeAws_restJson1ListOf__string(input.RedirectSignInURIs, context),
|
|
3573
3498
|
}),
|
|
3574
|
-
...(input.RedirectSignOutURIs
|
|
3575
|
-
input.RedirectSignOutURIs !== null && {
|
|
3499
|
+
...(input.RedirectSignOutURIs != null && {
|
|
3576
3500
|
redirectSignOutURIs: serializeAws_restJson1ListOf__string(input.RedirectSignOutURIs, context),
|
|
3577
3501
|
}),
|
|
3578
|
-
...(input.SocialProviderSettings
|
|
3579
|
-
input.SocialProviderSettings !== null && {
|
|
3502
|
+
...(input.SocialProviderSettings != null && {
|
|
3580
3503
|
socialProviderSettings: serializeAws_restJson1SocialProviderSettings(input.SocialProviderSettings, context),
|
|
3581
3504
|
}),
|
|
3582
3505
|
};
|
|
3583
3506
|
};
|
|
3584
3507
|
const serializeAws_restJson1UpdateBackendAuthPasswordPolicyConfig = (input, context) => {
|
|
3585
3508
|
return {
|
|
3586
|
-
...(input.AdditionalConstraints
|
|
3587
|
-
input.AdditionalConstraints !== null && {
|
|
3509
|
+
...(input.AdditionalConstraints != null && {
|
|
3588
3510
|
additionalConstraints: serializeAws_restJson1ListOfAdditionalConstraintsElement(input.AdditionalConstraints, context),
|
|
3589
3511
|
}),
|
|
3590
|
-
...(input.MinimumLength
|
|
3591
|
-
input.MinimumLength !== null && { minimumLength: (0, smithy_client_1.serializeFloat)(input.MinimumLength) }),
|
|
3512
|
+
...(input.MinimumLength != null && { minimumLength: (0, smithy_client_1.serializeFloat)(input.MinimumLength) }),
|
|
3592
3513
|
};
|
|
3593
3514
|
};
|
|
3594
3515
|
const serializeAws_restJson1UpdateBackendAuthResourceConfig = (input, context) => {
|
|
3595
3516
|
return {
|
|
3596
|
-
...(input.AuthResources
|
|
3597
|
-
...(input.IdentityPoolConfigs
|
|
3598
|
-
input.IdentityPoolConfigs !== null && {
|
|
3517
|
+
...(input.AuthResources != null && { authResources: input.AuthResources }),
|
|
3518
|
+
...(input.IdentityPoolConfigs != null && {
|
|
3599
3519
|
identityPoolConfigs: serializeAws_restJson1UpdateBackendAuthIdentityPoolConfig(input.IdentityPoolConfigs, context),
|
|
3600
3520
|
}),
|
|
3601
|
-
...(input.Service
|
|
3602
|
-
...(input.UserPoolConfigs
|
|
3603
|
-
input.UserPoolConfigs !== null && {
|
|
3521
|
+
...(input.Service != null && { service: input.Service }),
|
|
3522
|
+
...(input.UserPoolConfigs != null && {
|
|
3604
3523
|
userPoolConfigs: serializeAws_restJson1UpdateBackendAuthUserPoolConfig(input.UserPoolConfigs, context),
|
|
3605
3524
|
}),
|
|
3606
3525
|
};
|
|
3607
3526
|
};
|
|
3608
3527
|
const serializeAws_restJson1UpdateBackendAuthUserPoolConfig = (input, context) => {
|
|
3609
3528
|
return {
|
|
3610
|
-
...(input.ForgotPassword
|
|
3611
|
-
input.ForgotPassword !== null && {
|
|
3529
|
+
...(input.ForgotPassword != null && {
|
|
3612
3530
|
forgotPassword: serializeAws_restJson1UpdateBackendAuthForgotPasswordConfig(input.ForgotPassword, context),
|
|
3613
3531
|
}),
|
|
3614
|
-
...(input.Mfa
|
|
3615
|
-
|
|
3616
|
-
...(input.
|
|
3617
|
-
input.OAuth !== null && { oAuth: serializeAws_restJson1UpdateBackendAuthOAuthConfig(input.OAuth, context) }),
|
|
3618
|
-
...(input.PasswordPolicy !== undefined &&
|
|
3619
|
-
input.PasswordPolicy !== null && {
|
|
3532
|
+
...(input.Mfa != null && { mfa: serializeAws_restJson1UpdateBackendAuthMFAConfig(input.Mfa, context) }),
|
|
3533
|
+
...(input.OAuth != null && { oAuth: serializeAws_restJson1UpdateBackendAuthOAuthConfig(input.OAuth, context) }),
|
|
3534
|
+
...(input.PasswordPolicy != null && {
|
|
3620
3535
|
passwordPolicy: serializeAws_restJson1UpdateBackendAuthPasswordPolicyConfig(input.PasswordPolicy, context),
|
|
3621
3536
|
}),
|
|
3622
|
-
...(input.VerificationMessage
|
|
3623
|
-
input.VerificationMessage !== null && {
|
|
3537
|
+
...(input.VerificationMessage != null && {
|
|
3624
3538
|
verificationMessage: serializeAws_restJson1UpdateBackendAuthVerificationMessageConfig(input.VerificationMessage, context),
|
|
3625
3539
|
}),
|
|
3626
3540
|
};
|
|
3627
3541
|
};
|
|
3628
3542
|
const serializeAws_restJson1UpdateBackendAuthVerificationMessageConfig = (input, context) => {
|
|
3629
3543
|
return {
|
|
3630
|
-
...(input.DeliveryMethod
|
|
3631
|
-
|
|
3632
|
-
...(input.EmailSettings !== undefined &&
|
|
3633
|
-
input.EmailSettings !== null && {
|
|
3544
|
+
...(input.DeliveryMethod != null && { deliveryMethod: input.DeliveryMethod }),
|
|
3545
|
+
...(input.EmailSettings != null && {
|
|
3634
3546
|
emailSettings: serializeAws_restJson1EmailSettings(input.EmailSettings, context),
|
|
3635
3547
|
}),
|
|
3636
|
-
...(input.SmsSettings
|
|
3637
|
-
input.SmsSettings !== null && { smsSettings: serializeAws_restJson1SmsSettings(input.SmsSettings, context) }),
|
|
3548
|
+
...(input.SmsSettings != null && { smsSettings: serializeAws_restJson1SmsSettings(input.SmsSettings, context) }),
|
|
3638
3549
|
};
|
|
3639
3550
|
};
|
|
3640
3551
|
const serializeAws_restJson1UpdateBackendStorageResourceConfig = (input, context) => {
|
|
3641
3552
|
return {
|
|
3642
|
-
...(input.Permissions
|
|
3643
|
-
input.Permissions !== null && {
|
|
3553
|
+
...(input.Permissions != null && {
|
|
3644
3554
|
permissions: serializeAws_restJson1BackendStoragePermissions(input.Permissions, context),
|
|
3645
3555
|
}),
|
|
3646
|
-
...(input.ServiceName
|
|
3556
|
+
...(input.ServiceName != null && { serviceName: input.ServiceName }),
|
|
3647
3557
|
};
|
|
3648
3558
|
};
|
|
3649
3559
|
const deserializeAws_restJson1BackendAPIAppSyncAuthSettings = (output, context) => {
|
|
@@ -3661,7 +3571,7 @@ const deserializeAws_restJson1BackendAPIAppSyncAuthSettings = (output, context)
|
|
|
3661
3571
|
const deserializeAws_restJson1BackendAPIAuthType = (output, context) => {
|
|
3662
3572
|
return {
|
|
3663
3573
|
Mode: (0, smithy_client_1.expectString)(output.mode),
|
|
3664
|
-
Settings: output.settings
|
|
3574
|
+
Settings: output.settings != null
|
|
3665
3575
|
? deserializeAws_restJson1BackendAPIAppSyncAuthSettings(output.settings, context)
|
|
3666
3576
|
: undefined,
|
|
3667
3577
|
};
|
|
@@ -3673,14 +3583,14 @@ const deserializeAws_restJson1BackendAPIConflictResolution = (output, context) =
|
|
|
3673
3583
|
};
|
|
3674
3584
|
const deserializeAws_restJson1BackendAPIResourceConfig = (output, context) => {
|
|
3675
3585
|
return {
|
|
3676
|
-
AdditionalAuthTypes: output.additionalAuthTypes
|
|
3586
|
+
AdditionalAuthTypes: output.additionalAuthTypes != null
|
|
3677
3587
|
? deserializeAws_restJson1ListOfBackendAPIAuthType(output.additionalAuthTypes, context)
|
|
3678
3588
|
: undefined,
|
|
3679
3589
|
ApiName: (0, smithy_client_1.expectString)(output.apiName),
|
|
3680
|
-
ConflictResolution: output.conflictResolution
|
|
3590
|
+
ConflictResolution: output.conflictResolution != null
|
|
3681
3591
|
? deserializeAws_restJson1BackendAPIConflictResolution(output.conflictResolution, context)
|
|
3682
3592
|
: undefined,
|
|
3683
|
-
DefaultAuthType: output.defaultAuthType
|
|
3593
|
+
DefaultAuthType: output.defaultAuthType != null
|
|
3684
3594
|
? deserializeAws_restJson1BackendAPIAuthType(output.defaultAuthType, context)
|
|
3685
3595
|
: undefined,
|
|
3686
3596
|
Service: (0, smithy_client_1.expectString)(output.service),
|
|
@@ -3715,10 +3625,10 @@ const deserializeAws_restJson1BackendJobRespObj = (output, context) => {
|
|
|
3715
3625
|
};
|
|
3716
3626
|
const deserializeAws_restJson1BackendStoragePermissions = (output, context) => {
|
|
3717
3627
|
return {
|
|
3718
|
-
Authenticated: output.authenticated
|
|
3628
|
+
Authenticated: output.authenticated != null
|
|
3719
3629
|
? deserializeAws_restJson1ListOfAuthenticatedElement(output.authenticated, context)
|
|
3720
3630
|
: undefined,
|
|
3721
|
-
UnAuthenticated: output.unAuthenticated
|
|
3631
|
+
UnAuthenticated: output.unAuthenticated != null
|
|
3722
3632
|
? deserializeAws_restJson1ListOfUnAuthenticatedElement(output.unAuthenticated, context)
|
|
3723
3633
|
: undefined,
|
|
3724
3634
|
};
|
|
@@ -3726,12 +3636,8 @@ const deserializeAws_restJson1BackendStoragePermissions = (output, context) => {
|
|
|
3726
3636
|
const deserializeAws_restJson1CreateBackendAuthForgotPasswordConfig = (output, context) => {
|
|
3727
3637
|
return {
|
|
3728
3638
|
DeliveryMethod: (0, smithy_client_1.expectString)(output.deliveryMethod),
|
|
3729
|
-
EmailSettings: output.emailSettings
|
|
3730
|
-
|
|
3731
|
-
: undefined,
|
|
3732
|
-
SmsSettings: output.smsSettings !== undefined && output.smsSettings !== null
|
|
3733
|
-
? deserializeAws_restJson1SmsSettings(output.smsSettings, context)
|
|
3734
|
-
: undefined,
|
|
3639
|
+
EmailSettings: output.emailSettings != null ? deserializeAws_restJson1EmailSettings(output.emailSettings, context) : undefined,
|
|
3640
|
+
SmsSettings: output.smsSettings != null ? deserializeAws_restJson1SmsSettings(output.smsSettings, context) : undefined,
|
|
3735
3641
|
};
|
|
3736
3642
|
};
|
|
3737
3643
|
const deserializeAws_restJson1CreateBackendAuthIdentityPoolConfig = (output, context) => {
|
|
@@ -3743,32 +3649,30 @@ const deserializeAws_restJson1CreateBackendAuthIdentityPoolConfig = (output, con
|
|
|
3743
3649
|
const deserializeAws_restJson1CreateBackendAuthMFAConfig = (output, context) => {
|
|
3744
3650
|
return {
|
|
3745
3651
|
MFAMode: (0, smithy_client_1.expectString)(output.MFAMode),
|
|
3746
|
-
Settings: output.settings
|
|
3747
|
-
? deserializeAws_restJson1Settings(output.settings, context)
|
|
3748
|
-
: undefined,
|
|
3652
|
+
Settings: output.settings != null ? deserializeAws_restJson1Settings(output.settings, context) : undefined,
|
|
3749
3653
|
};
|
|
3750
3654
|
};
|
|
3751
3655
|
const deserializeAws_restJson1CreateBackendAuthOAuthConfig = (output, context) => {
|
|
3752
3656
|
return {
|
|
3753
3657
|
DomainPrefix: (0, smithy_client_1.expectString)(output.domainPrefix),
|
|
3754
3658
|
OAuthGrantType: (0, smithy_client_1.expectString)(output.oAuthGrantType),
|
|
3755
|
-
OAuthScopes: output.oAuthScopes
|
|
3659
|
+
OAuthScopes: output.oAuthScopes != null
|
|
3756
3660
|
? deserializeAws_restJson1ListOfOAuthScopesElement(output.oAuthScopes, context)
|
|
3757
3661
|
: undefined,
|
|
3758
|
-
RedirectSignInURIs: output.redirectSignInURIs
|
|
3662
|
+
RedirectSignInURIs: output.redirectSignInURIs != null
|
|
3759
3663
|
? deserializeAws_restJson1ListOf__string(output.redirectSignInURIs, context)
|
|
3760
3664
|
: undefined,
|
|
3761
|
-
RedirectSignOutURIs: output.redirectSignOutURIs
|
|
3665
|
+
RedirectSignOutURIs: output.redirectSignOutURIs != null
|
|
3762
3666
|
? deserializeAws_restJson1ListOf__string(output.redirectSignOutURIs, context)
|
|
3763
3667
|
: undefined,
|
|
3764
|
-
SocialProviderSettings: output.socialProviderSettings
|
|
3668
|
+
SocialProviderSettings: output.socialProviderSettings != null
|
|
3765
3669
|
? deserializeAws_restJson1SocialProviderSettings(output.socialProviderSettings, context)
|
|
3766
3670
|
: undefined,
|
|
3767
3671
|
};
|
|
3768
3672
|
};
|
|
3769
3673
|
const deserializeAws_restJson1CreateBackendAuthPasswordPolicyConfig = (output, context) => {
|
|
3770
3674
|
return {
|
|
3771
|
-
AdditionalConstraints: output.additionalConstraints
|
|
3675
|
+
AdditionalConstraints: output.additionalConstraints != null
|
|
3772
3676
|
? deserializeAws_restJson1ListOfAdditionalConstraintsElement(output.additionalConstraints, context)
|
|
3773
3677
|
: undefined,
|
|
3774
3678
|
MinimumLength: (0, smithy_client_1.limitedParseDouble)(output.minimumLength),
|
|
@@ -3777,35 +3681,31 @@ const deserializeAws_restJson1CreateBackendAuthPasswordPolicyConfig = (output, c
|
|
|
3777
3681
|
const deserializeAws_restJson1CreateBackendAuthResourceConfig = (output, context) => {
|
|
3778
3682
|
return {
|
|
3779
3683
|
AuthResources: (0, smithy_client_1.expectString)(output.authResources),
|
|
3780
|
-
IdentityPoolConfigs: output.identityPoolConfigs
|
|
3684
|
+
IdentityPoolConfigs: output.identityPoolConfigs != null
|
|
3781
3685
|
? deserializeAws_restJson1CreateBackendAuthIdentityPoolConfig(output.identityPoolConfigs, context)
|
|
3782
3686
|
: undefined,
|
|
3783
3687
|
Service: (0, smithy_client_1.expectString)(output.service),
|
|
3784
|
-
UserPoolConfigs: output.userPoolConfigs
|
|
3688
|
+
UserPoolConfigs: output.userPoolConfigs != null
|
|
3785
3689
|
? deserializeAws_restJson1CreateBackendAuthUserPoolConfig(output.userPoolConfigs, context)
|
|
3786
3690
|
: undefined,
|
|
3787
3691
|
};
|
|
3788
3692
|
};
|
|
3789
3693
|
const deserializeAws_restJson1CreateBackendAuthUserPoolConfig = (output, context) => {
|
|
3790
3694
|
return {
|
|
3791
|
-
ForgotPassword: output.forgotPassword
|
|
3695
|
+
ForgotPassword: output.forgotPassword != null
|
|
3792
3696
|
? deserializeAws_restJson1CreateBackendAuthForgotPasswordConfig(output.forgotPassword, context)
|
|
3793
3697
|
: undefined,
|
|
3794
|
-
Mfa: output.mfa
|
|
3795
|
-
|
|
3796
|
-
|
|
3797
|
-
OAuth: output.oAuth !== undefined && output.oAuth !== null
|
|
3798
|
-
? deserializeAws_restJson1CreateBackendAuthOAuthConfig(output.oAuth, context)
|
|
3799
|
-
: undefined,
|
|
3800
|
-
PasswordPolicy: output.passwordPolicy !== undefined && output.passwordPolicy !== null
|
|
3698
|
+
Mfa: output.mfa != null ? deserializeAws_restJson1CreateBackendAuthMFAConfig(output.mfa, context) : undefined,
|
|
3699
|
+
OAuth: output.oAuth != null ? deserializeAws_restJson1CreateBackendAuthOAuthConfig(output.oAuth, context) : undefined,
|
|
3700
|
+
PasswordPolicy: output.passwordPolicy != null
|
|
3801
3701
|
? deserializeAws_restJson1CreateBackendAuthPasswordPolicyConfig(output.passwordPolicy, context)
|
|
3802
3702
|
: undefined,
|
|
3803
|
-
RequiredSignUpAttributes: output.requiredSignUpAttributes
|
|
3703
|
+
RequiredSignUpAttributes: output.requiredSignUpAttributes != null
|
|
3804
3704
|
? deserializeAws_restJson1ListOfRequiredSignUpAttributesElement(output.requiredSignUpAttributes, context)
|
|
3805
3705
|
: undefined,
|
|
3806
3706
|
SignInMethod: (0, smithy_client_1.expectString)(output.signInMethod),
|
|
3807
3707
|
UserPoolName: (0, smithy_client_1.expectString)(output.userPoolName),
|
|
3808
|
-
VerificationMessage: output.verificationMessage
|
|
3708
|
+
VerificationMessage: output.verificationMessage != null
|
|
3809
3709
|
? deserializeAws_restJson1CreateBackendAuthVerificationMessageConfig(output.verificationMessage, context)
|
|
3810
3710
|
: undefined,
|
|
3811
3711
|
};
|
|
@@ -3813,12 +3713,8 @@ const deserializeAws_restJson1CreateBackendAuthUserPoolConfig = (output, context
|
|
|
3813
3713
|
const deserializeAws_restJson1CreateBackendAuthVerificationMessageConfig = (output, context) => {
|
|
3814
3714
|
return {
|
|
3815
3715
|
DeliveryMethod: (0, smithy_client_1.expectString)(output.deliveryMethod),
|
|
3816
|
-
EmailSettings: output.emailSettings
|
|
3817
|
-
|
|
3818
|
-
: undefined,
|
|
3819
|
-
SmsSettings: output.smsSettings !== undefined && output.smsSettings !== null
|
|
3820
|
-
? deserializeAws_restJson1SmsSettings(output.smsSettings, context)
|
|
3821
|
-
: undefined,
|
|
3716
|
+
EmailSettings: output.emailSettings != null ? deserializeAws_restJson1EmailSettings(output.emailSettings, context) : undefined,
|
|
3717
|
+
SmsSettings: output.smsSettings != null ? deserializeAws_restJson1SmsSettings(output.smsSettings, context) : undefined,
|
|
3822
3718
|
};
|
|
3823
3719
|
};
|
|
3824
3720
|
const deserializeAws_restJson1EmailSettings = (output, context) => {
|
|
@@ -3831,7 +3727,7 @@ const deserializeAws_restJson1GetBackendStorageResourceConfig = (output, context
|
|
|
3831
3727
|
return {
|
|
3832
3728
|
BucketName: (0, smithy_client_1.expectString)(output.bucketName),
|
|
3833
3729
|
Imported: (0, smithy_client_1.expectBoolean)(output.imported),
|
|
3834
|
-
Permissions: output.permissions
|
|
3730
|
+
Permissions: output.permissions != null
|
|
3835
3731
|
? deserializeAws_restJson1BackendStoragePermissions(output.permissions, context)
|
|
3836
3732
|
: undefined,
|
|
3837
3733
|
ServiceName: (0, smithy_client_1.expectString)(output.serviceName),
|
|
@@ -3963,9 +3859,7 @@ const deserializeAws_restJson1S3BucketInfo = (output, context) => {
|
|
|
3963
3859
|
};
|
|
3964
3860
|
const deserializeAws_restJson1Settings = (output, context) => {
|
|
3965
3861
|
return {
|
|
3966
|
-
MfaTypes: output.mfaTypes
|
|
3967
|
-
? deserializeAws_restJson1ListOfMfaTypesElement(output.mfaTypes, context)
|
|
3968
|
-
: undefined,
|
|
3862
|
+
MfaTypes: output.mfaTypes != null ? deserializeAws_restJson1ListOfMfaTypesElement(output.mfaTypes, context) : undefined,
|
|
3969
3863
|
SmsMessage: (0, smithy_client_1.expectString)(output.smsMessage),
|
|
3970
3864
|
};
|
|
3971
3865
|
};
|
|
@@ -3976,16 +3870,16 @@ const deserializeAws_restJson1SmsSettings = (output, context) => {
|
|
|
3976
3870
|
};
|
|
3977
3871
|
const deserializeAws_restJson1SocialProviderSettings = (output, context) => {
|
|
3978
3872
|
return {
|
|
3979
|
-
Facebook: output.Facebook
|
|
3873
|
+
Facebook: output.Facebook != null
|
|
3980
3874
|
? deserializeAws_restJson1BackendAuthSocialProviderConfig(output.Facebook, context)
|
|
3981
3875
|
: undefined,
|
|
3982
|
-
Google: output.Google
|
|
3876
|
+
Google: output.Google != null
|
|
3983
3877
|
? deserializeAws_restJson1BackendAuthSocialProviderConfig(output.Google, context)
|
|
3984
3878
|
: undefined,
|
|
3985
|
-
LoginWithAmazon: output.LoginWithAmazon
|
|
3879
|
+
LoginWithAmazon: output.LoginWithAmazon != null
|
|
3986
3880
|
? deserializeAws_restJson1BackendAuthSocialProviderConfig(output.LoginWithAmazon, context)
|
|
3987
3881
|
: undefined,
|
|
3988
|
-
SignInWithApple: output.SignInWithApple
|
|
3882
|
+
SignInWithApple: output.SignInWithApple != null
|
|
3989
3883
|
? deserializeAws_restJson1BackendAuthAppleProviderConfig(output.SignInWithApple, context)
|
|
3990
3884
|
: undefined,
|
|
3991
3885
|
};
|
|
@@ -4021,6 +3915,9 @@ const loadRestJsonErrorCode = (output, data) => {
|
|
|
4021
3915
|
const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
|
|
4022
3916
|
const sanitizeErrorCode = (rawValue) => {
|
|
4023
3917
|
let cleanValue = rawValue;
|
|
3918
|
+
if (typeof cleanValue === "number") {
|
|
3919
|
+
cleanValue = cleanValue.toString();
|
|
3920
|
+
}
|
|
4024
3921
|
if (cleanValue.indexOf(":") >= 0) {
|
|
4025
3922
|
cleanValue = cleanValue.split(":")[0];
|
|
4026
3923
|
}
|