@aws-sdk/client-lambda 3.55.0 → 3.65.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.
Files changed (48) hide show
  1. package/CHANGELOG.md +30 -0
  2. package/dist-cjs/Lambda.js +75 -0
  3. package/dist-cjs/commands/CreateFunctionUrlConfigCommand.js +36 -0
  4. package/dist-cjs/commands/DeleteFunctionUrlConfigCommand.js +36 -0
  5. package/dist-cjs/commands/GetFunctionUrlConfigCommand.js +36 -0
  6. package/dist-cjs/commands/ListFunctionUrlConfigsCommand.js +36 -0
  7. package/dist-cjs/commands/UpdateFunctionUrlConfigCommand.js +36 -0
  8. package/dist-cjs/commands/index.js +5 -0
  9. package/dist-cjs/models/models_0.js +81 -4
  10. package/dist-cjs/pagination/ListFunctionUrlConfigsPaginator.js +35 -0
  11. package/dist-cjs/pagination/index.js +1 -0
  12. package/dist-cjs/protocols/Aws_restJson1.js +626 -3
  13. package/dist-es/Lambda.js +75 -0
  14. package/dist-es/commands/CreateFunctionUrlConfigCommand.js +39 -0
  15. package/dist-es/commands/DeleteFunctionUrlConfigCommand.js +39 -0
  16. package/dist-es/commands/GetFunctionUrlConfigCommand.js +39 -0
  17. package/dist-es/commands/ListFunctionUrlConfigsCommand.js +39 -0
  18. package/dist-es/commands/UpdateFunctionUrlConfigCommand.js +39 -0
  19. package/dist-es/commands/index.js +5 -0
  20. package/dist-es/models/models_0.js +53 -0
  21. package/dist-es/pagination/ListFunctionUrlConfigsPaginator.js +74 -0
  22. package/dist-es/pagination/index.js +1 -0
  23. package/dist-es/protocols/Aws_restJson1.js +756 -27
  24. package/dist-types/Lambda.d.ts +37 -0
  25. package/dist-types/LambdaClient.d.ts +7 -2
  26. package/dist-types/commands/CreateFunctionUrlConfigCommand.d.ts +36 -0
  27. package/dist-types/commands/DeleteFunctionUrlConfigCommand.d.ts +36 -0
  28. package/dist-types/commands/GetFunctionUrlConfigCommand.d.ts +35 -0
  29. package/dist-types/commands/ListFunctionUrlConfigsCommand.d.ts +35 -0
  30. package/dist-types/commands/UpdateFunctionUrlConfigCommand.d.ts +35 -0
  31. package/dist-types/commands/index.d.ts +5 -0
  32. package/dist-types/models/models_0.d.ts +439 -0
  33. package/dist-types/pagination/ListFunctionUrlConfigsPaginator.d.ts +4 -0
  34. package/dist-types/pagination/index.d.ts +1 -0
  35. package/dist-types/protocols/Aws_restJson1.d.ts +15 -0
  36. package/dist-types/ts3.4/Lambda.d.ts +25 -0
  37. package/dist-types/ts3.4/LambdaClient.d.ts +7 -2
  38. package/dist-types/ts3.4/commands/CreateFunctionUrlConfigCommand.d.ts +17 -0
  39. package/dist-types/ts3.4/commands/DeleteFunctionUrlConfigCommand.d.ts +17 -0
  40. package/dist-types/ts3.4/commands/GetFunctionUrlConfigCommand.d.ts +17 -0
  41. package/dist-types/ts3.4/commands/ListFunctionUrlConfigsCommand.d.ts +17 -0
  42. package/dist-types/ts3.4/commands/UpdateFunctionUrlConfigCommand.d.ts +17 -0
  43. package/dist-types/ts3.4/commands/index.d.ts +5 -0
  44. package/dist-types/ts3.4/models/models_0.d.ts +181 -0
  45. package/dist-types/ts3.4/pagination/ListFunctionUrlConfigsPaginator.d.ts +4 -0
  46. package/dist-types/ts3.4/pagination/index.d.ts +1 -0
  47. package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +15 -0
  48. package/package.json +18 -18
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.serializeAws_restJson1RemovePermissionCommand = exports.serializeAws_restJson1RemoveLayerVersionPermissionCommand = exports.serializeAws_restJson1PutProvisionedConcurrencyConfigCommand = exports.serializeAws_restJson1PutFunctionEventInvokeConfigCommand = exports.serializeAws_restJson1PutFunctionConcurrencyCommand = exports.serializeAws_restJson1PutFunctionCodeSigningConfigCommand = exports.serializeAws_restJson1PublishVersionCommand = exports.serializeAws_restJson1PublishLayerVersionCommand = exports.serializeAws_restJson1ListVersionsByFunctionCommand = exports.serializeAws_restJson1ListTagsCommand = exports.serializeAws_restJson1ListProvisionedConcurrencyConfigsCommand = exports.serializeAws_restJson1ListLayerVersionsCommand = exports.serializeAws_restJson1ListLayersCommand = exports.serializeAws_restJson1ListFunctionsByCodeSigningConfigCommand = exports.serializeAws_restJson1ListFunctionsCommand = exports.serializeAws_restJson1ListFunctionEventInvokeConfigsCommand = exports.serializeAws_restJson1ListEventSourceMappingsCommand = exports.serializeAws_restJson1ListCodeSigningConfigsCommand = exports.serializeAws_restJson1ListAliasesCommand = exports.serializeAws_restJson1InvokeAsyncCommand = exports.serializeAws_restJson1InvokeCommand = exports.serializeAws_restJson1GetProvisionedConcurrencyConfigCommand = exports.serializeAws_restJson1GetPolicyCommand = exports.serializeAws_restJson1GetLayerVersionPolicyCommand = exports.serializeAws_restJson1GetLayerVersionByArnCommand = exports.serializeAws_restJson1GetLayerVersionCommand = exports.serializeAws_restJson1GetFunctionEventInvokeConfigCommand = exports.serializeAws_restJson1GetFunctionConfigurationCommand = exports.serializeAws_restJson1GetFunctionConcurrencyCommand = exports.serializeAws_restJson1GetFunctionCodeSigningConfigCommand = exports.serializeAws_restJson1GetFunctionCommand = exports.serializeAws_restJson1GetEventSourceMappingCommand = exports.serializeAws_restJson1GetCodeSigningConfigCommand = exports.serializeAws_restJson1GetAliasCommand = exports.serializeAws_restJson1GetAccountSettingsCommand = exports.serializeAws_restJson1DeleteProvisionedConcurrencyConfigCommand = exports.serializeAws_restJson1DeleteLayerVersionCommand = exports.serializeAws_restJson1DeleteFunctionEventInvokeConfigCommand = exports.serializeAws_restJson1DeleteFunctionConcurrencyCommand = exports.serializeAws_restJson1DeleteFunctionCodeSigningConfigCommand = exports.serializeAws_restJson1DeleteFunctionCommand = exports.serializeAws_restJson1DeleteEventSourceMappingCommand = exports.serializeAws_restJson1DeleteCodeSigningConfigCommand = exports.serializeAws_restJson1DeleteAliasCommand = exports.serializeAws_restJson1CreateFunctionCommand = exports.serializeAws_restJson1CreateEventSourceMappingCommand = exports.serializeAws_restJson1CreateCodeSigningConfigCommand = exports.serializeAws_restJson1CreateAliasCommand = exports.serializeAws_restJson1AddPermissionCommand = exports.serializeAws_restJson1AddLayerVersionPermissionCommand = void 0;
4
- exports.deserializeAws_restJson1ListVersionsByFunctionCommand = exports.deserializeAws_restJson1ListTagsCommand = exports.deserializeAws_restJson1ListProvisionedConcurrencyConfigsCommand = exports.deserializeAws_restJson1ListLayerVersionsCommand = exports.deserializeAws_restJson1ListLayersCommand = exports.deserializeAws_restJson1ListFunctionsByCodeSigningConfigCommand = exports.deserializeAws_restJson1ListFunctionsCommand = exports.deserializeAws_restJson1ListFunctionEventInvokeConfigsCommand = exports.deserializeAws_restJson1ListEventSourceMappingsCommand = exports.deserializeAws_restJson1ListCodeSigningConfigsCommand = exports.deserializeAws_restJson1ListAliasesCommand = exports.deserializeAws_restJson1InvokeAsyncCommand = exports.deserializeAws_restJson1InvokeCommand = exports.deserializeAws_restJson1GetProvisionedConcurrencyConfigCommand = exports.deserializeAws_restJson1GetPolicyCommand = exports.deserializeAws_restJson1GetLayerVersionPolicyCommand = exports.deserializeAws_restJson1GetLayerVersionByArnCommand = exports.deserializeAws_restJson1GetLayerVersionCommand = exports.deserializeAws_restJson1GetFunctionEventInvokeConfigCommand = exports.deserializeAws_restJson1GetFunctionConfigurationCommand = exports.deserializeAws_restJson1GetFunctionConcurrencyCommand = exports.deserializeAws_restJson1GetFunctionCodeSigningConfigCommand = exports.deserializeAws_restJson1GetFunctionCommand = exports.deserializeAws_restJson1GetEventSourceMappingCommand = exports.deserializeAws_restJson1GetCodeSigningConfigCommand = exports.deserializeAws_restJson1GetAliasCommand = exports.deserializeAws_restJson1GetAccountSettingsCommand = exports.deserializeAws_restJson1DeleteProvisionedConcurrencyConfigCommand = exports.deserializeAws_restJson1DeleteLayerVersionCommand = exports.deserializeAws_restJson1DeleteFunctionEventInvokeConfigCommand = exports.deserializeAws_restJson1DeleteFunctionConcurrencyCommand = exports.deserializeAws_restJson1DeleteFunctionCodeSigningConfigCommand = exports.deserializeAws_restJson1DeleteFunctionCommand = exports.deserializeAws_restJson1DeleteEventSourceMappingCommand = exports.deserializeAws_restJson1DeleteCodeSigningConfigCommand = exports.deserializeAws_restJson1DeleteAliasCommand = exports.deserializeAws_restJson1CreateFunctionCommand = exports.deserializeAws_restJson1CreateEventSourceMappingCommand = exports.deserializeAws_restJson1CreateCodeSigningConfigCommand = exports.deserializeAws_restJson1CreateAliasCommand = exports.deserializeAws_restJson1AddPermissionCommand = exports.deserializeAws_restJson1AddLayerVersionPermissionCommand = exports.serializeAws_restJson1UpdateFunctionEventInvokeConfigCommand = exports.serializeAws_restJson1UpdateFunctionConfigurationCommand = exports.serializeAws_restJson1UpdateFunctionCodeCommand = exports.serializeAws_restJson1UpdateEventSourceMappingCommand = exports.serializeAws_restJson1UpdateCodeSigningConfigCommand = exports.serializeAws_restJson1UpdateAliasCommand = exports.serializeAws_restJson1UntagResourceCommand = exports.serializeAws_restJson1TagResourceCommand = void 0;
5
- exports.deserializeAws_restJson1UpdateFunctionEventInvokeConfigCommand = exports.deserializeAws_restJson1UpdateFunctionConfigurationCommand = exports.deserializeAws_restJson1UpdateFunctionCodeCommand = exports.deserializeAws_restJson1UpdateEventSourceMappingCommand = exports.deserializeAws_restJson1UpdateCodeSigningConfigCommand = exports.deserializeAws_restJson1UpdateAliasCommand = exports.deserializeAws_restJson1UntagResourceCommand = exports.deserializeAws_restJson1TagResourceCommand = exports.deserializeAws_restJson1RemovePermissionCommand = exports.deserializeAws_restJson1RemoveLayerVersionPermissionCommand = exports.deserializeAws_restJson1PutProvisionedConcurrencyConfigCommand = exports.deserializeAws_restJson1PutFunctionEventInvokeConfigCommand = exports.deserializeAws_restJson1PutFunctionConcurrencyCommand = exports.deserializeAws_restJson1PutFunctionCodeSigningConfigCommand = exports.deserializeAws_restJson1PublishVersionCommand = exports.deserializeAws_restJson1PublishLayerVersionCommand = void 0;
3
+ exports.serializeAws_restJson1PutFunctionConcurrencyCommand = exports.serializeAws_restJson1PutFunctionCodeSigningConfigCommand = exports.serializeAws_restJson1PublishVersionCommand = exports.serializeAws_restJson1PublishLayerVersionCommand = exports.serializeAws_restJson1ListVersionsByFunctionCommand = exports.serializeAws_restJson1ListTagsCommand = exports.serializeAws_restJson1ListProvisionedConcurrencyConfigsCommand = exports.serializeAws_restJson1ListLayerVersionsCommand = exports.serializeAws_restJson1ListLayersCommand = exports.serializeAws_restJson1ListFunctionUrlConfigsCommand = exports.serializeAws_restJson1ListFunctionsByCodeSigningConfigCommand = exports.serializeAws_restJson1ListFunctionsCommand = exports.serializeAws_restJson1ListFunctionEventInvokeConfigsCommand = exports.serializeAws_restJson1ListEventSourceMappingsCommand = exports.serializeAws_restJson1ListCodeSigningConfigsCommand = exports.serializeAws_restJson1ListAliasesCommand = exports.serializeAws_restJson1InvokeAsyncCommand = exports.serializeAws_restJson1InvokeCommand = exports.serializeAws_restJson1GetProvisionedConcurrencyConfigCommand = exports.serializeAws_restJson1GetPolicyCommand = exports.serializeAws_restJson1GetLayerVersionPolicyCommand = exports.serializeAws_restJson1GetLayerVersionByArnCommand = exports.serializeAws_restJson1GetLayerVersionCommand = exports.serializeAws_restJson1GetFunctionUrlConfigCommand = exports.serializeAws_restJson1GetFunctionEventInvokeConfigCommand = exports.serializeAws_restJson1GetFunctionConfigurationCommand = exports.serializeAws_restJson1GetFunctionConcurrencyCommand = exports.serializeAws_restJson1GetFunctionCodeSigningConfigCommand = exports.serializeAws_restJson1GetFunctionCommand = exports.serializeAws_restJson1GetEventSourceMappingCommand = exports.serializeAws_restJson1GetCodeSigningConfigCommand = exports.serializeAws_restJson1GetAliasCommand = exports.serializeAws_restJson1GetAccountSettingsCommand = exports.serializeAws_restJson1DeleteProvisionedConcurrencyConfigCommand = exports.serializeAws_restJson1DeleteLayerVersionCommand = exports.serializeAws_restJson1DeleteFunctionUrlConfigCommand = exports.serializeAws_restJson1DeleteFunctionEventInvokeConfigCommand = exports.serializeAws_restJson1DeleteFunctionConcurrencyCommand = exports.serializeAws_restJson1DeleteFunctionCodeSigningConfigCommand = exports.serializeAws_restJson1DeleteFunctionCommand = exports.serializeAws_restJson1DeleteEventSourceMappingCommand = exports.serializeAws_restJson1DeleteCodeSigningConfigCommand = exports.serializeAws_restJson1DeleteAliasCommand = exports.serializeAws_restJson1CreateFunctionUrlConfigCommand = exports.serializeAws_restJson1CreateFunctionCommand = exports.serializeAws_restJson1CreateEventSourceMappingCommand = exports.serializeAws_restJson1CreateCodeSigningConfigCommand = exports.serializeAws_restJson1CreateAliasCommand = exports.serializeAws_restJson1AddPermissionCommand = exports.serializeAws_restJson1AddLayerVersionPermissionCommand = void 0;
4
+ exports.deserializeAws_restJson1ListEventSourceMappingsCommand = exports.deserializeAws_restJson1ListCodeSigningConfigsCommand = exports.deserializeAws_restJson1ListAliasesCommand = exports.deserializeAws_restJson1InvokeAsyncCommand = exports.deserializeAws_restJson1InvokeCommand = exports.deserializeAws_restJson1GetProvisionedConcurrencyConfigCommand = exports.deserializeAws_restJson1GetPolicyCommand = exports.deserializeAws_restJson1GetLayerVersionPolicyCommand = exports.deserializeAws_restJson1GetLayerVersionByArnCommand = exports.deserializeAws_restJson1GetLayerVersionCommand = exports.deserializeAws_restJson1GetFunctionUrlConfigCommand = exports.deserializeAws_restJson1GetFunctionEventInvokeConfigCommand = exports.deserializeAws_restJson1GetFunctionConfigurationCommand = exports.deserializeAws_restJson1GetFunctionConcurrencyCommand = exports.deserializeAws_restJson1GetFunctionCodeSigningConfigCommand = exports.deserializeAws_restJson1GetFunctionCommand = exports.deserializeAws_restJson1GetEventSourceMappingCommand = exports.deserializeAws_restJson1GetCodeSigningConfigCommand = exports.deserializeAws_restJson1GetAliasCommand = exports.deserializeAws_restJson1GetAccountSettingsCommand = exports.deserializeAws_restJson1DeleteProvisionedConcurrencyConfigCommand = exports.deserializeAws_restJson1DeleteLayerVersionCommand = exports.deserializeAws_restJson1DeleteFunctionUrlConfigCommand = exports.deserializeAws_restJson1DeleteFunctionEventInvokeConfigCommand = exports.deserializeAws_restJson1DeleteFunctionConcurrencyCommand = exports.deserializeAws_restJson1DeleteFunctionCodeSigningConfigCommand = exports.deserializeAws_restJson1DeleteFunctionCommand = exports.deserializeAws_restJson1DeleteEventSourceMappingCommand = exports.deserializeAws_restJson1DeleteCodeSigningConfigCommand = exports.deserializeAws_restJson1DeleteAliasCommand = exports.deserializeAws_restJson1CreateFunctionUrlConfigCommand = exports.deserializeAws_restJson1CreateFunctionCommand = exports.deserializeAws_restJson1CreateEventSourceMappingCommand = exports.deserializeAws_restJson1CreateCodeSigningConfigCommand = exports.deserializeAws_restJson1CreateAliasCommand = exports.deserializeAws_restJson1AddPermissionCommand = exports.deserializeAws_restJson1AddLayerVersionPermissionCommand = exports.serializeAws_restJson1UpdateFunctionUrlConfigCommand = exports.serializeAws_restJson1UpdateFunctionEventInvokeConfigCommand = exports.serializeAws_restJson1UpdateFunctionConfigurationCommand = exports.serializeAws_restJson1UpdateFunctionCodeCommand = exports.serializeAws_restJson1UpdateEventSourceMappingCommand = exports.serializeAws_restJson1UpdateCodeSigningConfigCommand = exports.serializeAws_restJson1UpdateAliasCommand = exports.serializeAws_restJson1UntagResourceCommand = exports.serializeAws_restJson1TagResourceCommand = exports.serializeAws_restJson1RemovePermissionCommand = exports.serializeAws_restJson1RemoveLayerVersionPermissionCommand = exports.serializeAws_restJson1PutProvisionedConcurrencyConfigCommand = exports.serializeAws_restJson1PutFunctionEventInvokeConfigCommand = void 0;
5
+ exports.deserializeAws_restJson1UpdateFunctionUrlConfigCommand = exports.deserializeAws_restJson1UpdateFunctionEventInvokeConfigCommand = exports.deserializeAws_restJson1UpdateFunctionConfigurationCommand = exports.deserializeAws_restJson1UpdateFunctionCodeCommand = exports.deserializeAws_restJson1UpdateEventSourceMappingCommand = exports.deserializeAws_restJson1UpdateCodeSigningConfigCommand = exports.deserializeAws_restJson1UpdateAliasCommand = exports.deserializeAws_restJson1UntagResourceCommand = exports.deserializeAws_restJson1TagResourceCommand = exports.deserializeAws_restJson1RemovePermissionCommand = exports.deserializeAws_restJson1RemoveLayerVersionPermissionCommand = exports.deserializeAws_restJson1PutProvisionedConcurrencyConfigCommand = exports.deserializeAws_restJson1PutFunctionEventInvokeConfigCommand = exports.deserializeAws_restJson1PutFunctionConcurrencyCommand = exports.deserializeAws_restJson1PutFunctionCodeSigningConfigCommand = exports.deserializeAws_restJson1PublishVersionCommand = exports.deserializeAws_restJson1PublishLayerVersionCommand = exports.deserializeAws_restJson1ListVersionsByFunctionCommand = exports.deserializeAws_restJson1ListTagsCommand = exports.deserializeAws_restJson1ListProvisionedConcurrencyConfigsCommand = exports.deserializeAws_restJson1ListLayerVersionsCommand = exports.deserializeAws_restJson1ListLayersCommand = exports.deserializeAws_restJson1ListFunctionUrlConfigsCommand = exports.deserializeAws_restJson1ListFunctionsByCodeSigningConfigCommand = exports.deserializeAws_restJson1ListFunctionsCommand = exports.deserializeAws_restJson1ListFunctionEventInvokeConfigsCommand = void 0;
6
6
  const protocol_http_1 = require("@aws-sdk/protocol-http");
7
7
  const smithy_client_1 = require("@aws-sdk/smithy-client");
8
8
  const LambdaServiceException_1 = require("../models/LambdaServiceException");
@@ -82,6 +82,8 @@ const serializeAws_restJson1AddPermissionCommand = async (input, context) => {
82
82
  ...(input.Action !== undefined && input.Action !== null && { Action: input.Action }),
83
83
  ...(input.EventSourceToken !== undefined &&
84
84
  input.EventSourceToken !== null && { EventSourceToken: input.EventSourceToken }),
85
+ ...(input.FunctionUrlAuthType !== undefined &&
86
+ input.FunctionUrlAuthType !== null && { FunctionUrlAuthType: input.FunctionUrlAuthType }),
85
87
  ...(input.Principal !== undefined && input.Principal !== null && { Principal: input.Principal }),
86
88
  ...(input.PrincipalOrgID !== undefined &&
87
89
  input.PrincipalOrgID !== null && { PrincipalOrgID: input.PrincipalOrgID }),
@@ -262,6 +264,10 @@ const serializeAws_restJson1CreateFunctionCommand = async (input, context) => {
262
264
  ...(input.Description !== undefined && input.Description !== null && { Description: input.Description }),
263
265
  ...(input.Environment !== undefined &&
264
266
  input.Environment !== null && { Environment: serializeAws_restJson1Environment(input.Environment, context) }),
267
+ ...(input.EphemeralStorage !== undefined &&
268
+ input.EphemeralStorage !== null && {
269
+ EphemeralStorage: serializeAws_restJson1EphemeralStorage(input.EphemeralStorage, context),
270
+ }),
265
271
  ...(input.FileSystemConfigs !== undefined &&
266
272
  input.FileSystemConfigs !== null && {
267
273
  FileSystemConfigs: serializeAws_restJson1FileSystemConfigList(input.FileSystemConfigs, context),
@@ -298,6 +304,42 @@ const serializeAws_restJson1CreateFunctionCommand = async (input, context) => {
298
304
  });
299
305
  };
300
306
  exports.serializeAws_restJson1CreateFunctionCommand = serializeAws_restJson1CreateFunctionCommand;
307
+ const serializeAws_restJson1CreateFunctionUrlConfigCommand = async (input, context) => {
308
+ const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
309
+ const headers = {
310
+ "content-type": "application/json",
311
+ };
312
+ let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/2021-10-31/functions/{FunctionName}/url";
313
+ if (input.FunctionName !== undefined) {
314
+ const labelValue = input.FunctionName;
315
+ if (labelValue.length <= 0) {
316
+ throw new Error("Empty value provided for input HTTP label: FunctionName.");
317
+ }
318
+ resolvedPath = resolvedPath.replace("{FunctionName}", (0, smithy_client_1.extendedEncodeURIComponent)(labelValue));
319
+ }
320
+ else {
321
+ throw new Error("No value provided for input HTTP label: FunctionName.");
322
+ }
323
+ const query = {
324
+ ...(input.Qualifier !== undefined && { Qualifier: input.Qualifier }),
325
+ };
326
+ let body;
327
+ body = JSON.stringify({
328
+ ...(input.AuthType !== undefined && input.AuthType !== null && { AuthType: input.AuthType }),
329
+ ...(input.Cors !== undefined && input.Cors !== null && { Cors: serializeAws_restJson1Cors(input.Cors, context) }),
330
+ });
331
+ return new protocol_http_1.HttpRequest({
332
+ protocol,
333
+ hostname,
334
+ port,
335
+ method: "POST",
336
+ headers,
337
+ path: resolvedPath,
338
+ query,
339
+ body,
340
+ });
341
+ };
342
+ exports.serializeAws_restJson1CreateFunctionUrlConfigCommand = serializeAws_restJson1CreateFunctionUrlConfigCommand;
301
343
  const serializeAws_restJson1DeleteAliasCommand = async (input, context) => {
302
344
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
303
345
  const headers = {};
@@ -503,6 +545,36 @@ const serializeAws_restJson1DeleteFunctionEventInvokeConfigCommand = async (inpu
503
545
  });
504
546
  };
505
547
  exports.serializeAws_restJson1DeleteFunctionEventInvokeConfigCommand = serializeAws_restJson1DeleteFunctionEventInvokeConfigCommand;
548
+ const serializeAws_restJson1DeleteFunctionUrlConfigCommand = async (input, context) => {
549
+ const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
550
+ const headers = {};
551
+ let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/2021-10-31/functions/{FunctionName}/url";
552
+ if (input.FunctionName !== undefined) {
553
+ const labelValue = input.FunctionName;
554
+ if (labelValue.length <= 0) {
555
+ throw new Error("Empty value provided for input HTTP label: FunctionName.");
556
+ }
557
+ resolvedPath = resolvedPath.replace("{FunctionName}", (0, smithy_client_1.extendedEncodeURIComponent)(labelValue));
558
+ }
559
+ else {
560
+ throw new Error("No value provided for input HTTP label: FunctionName.");
561
+ }
562
+ const query = {
563
+ ...(input.Qualifier !== undefined && { Qualifier: input.Qualifier }),
564
+ };
565
+ let body;
566
+ return new protocol_http_1.HttpRequest({
567
+ protocol,
568
+ hostname,
569
+ port,
570
+ method: "DELETE",
571
+ headers,
572
+ path: resolvedPath,
573
+ query,
574
+ body,
575
+ });
576
+ };
577
+ exports.serializeAws_restJson1DeleteFunctionUrlConfigCommand = serializeAws_restJson1DeleteFunctionUrlConfigCommand;
506
578
  const serializeAws_restJson1DeleteLayerVersionCommand = async (input, context) => {
507
579
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
508
580
  const headers = {};
@@ -826,6 +898,36 @@ const serializeAws_restJson1GetFunctionEventInvokeConfigCommand = async (input,
826
898
  });
827
899
  };
828
900
  exports.serializeAws_restJson1GetFunctionEventInvokeConfigCommand = serializeAws_restJson1GetFunctionEventInvokeConfigCommand;
901
+ const serializeAws_restJson1GetFunctionUrlConfigCommand = async (input, context) => {
902
+ const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
903
+ const headers = {};
904
+ let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/2021-10-31/functions/{FunctionName}/url";
905
+ if (input.FunctionName !== undefined) {
906
+ const labelValue = input.FunctionName;
907
+ if (labelValue.length <= 0) {
908
+ throw new Error("Empty value provided for input HTTP label: FunctionName.");
909
+ }
910
+ resolvedPath = resolvedPath.replace("{FunctionName}", (0, smithy_client_1.extendedEncodeURIComponent)(labelValue));
911
+ }
912
+ else {
913
+ throw new Error("No value provided for input HTTP label: FunctionName.");
914
+ }
915
+ const query = {
916
+ ...(input.Qualifier !== undefined && { Qualifier: input.Qualifier }),
917
+ };
918
+ let body;
919
+ return new protocol_http_1.HttpRequest({
920
+ protocol,
921
+ hostname,
922
+ port,
923
+ method: "GET",
924
+ headers,
925
+ path: resolvedPath,
926
+ query,
927
+ body,
928
+ });
929
+ };
930
+ exports.serializeAws_restJson1GetFunctionUrlConfigCommand = serializeAws_restJson1GetFunctionUrlConfigCommand;
829
931
  const serializeAws_restJson1GetLayerVersionCommand = async (input, context) => {
830
932
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
831
933
  const headers = {};
@@ -1218,6 +1320,37 @@ const serializeAws_restJson1ListFunctionsByCodeSigningConfigCommand = async (inp
1218
1320
  });
1219
1321
  };
1220
1322
  exports.serializeAws_restJson1ListFunctionsByCodeSigningConfigCommand = serializeAws_restJson1ListFunctionsByCodeSigningConfigCommand;
1323
+ const serializeAws_restJson1ListFunctionUrlConfigsCommand = async (input, context) => {
1324
+ const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
1325
+ const headers = {};
1326
+ let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/2021-10-31/functions/{FunctionName}/urls";
1327
+ if (input.FunctionName !== undefined) {
1328
+ const labelValue = input.FunctionName;
1329
+ if (labelValue.length <= 0) {
1330
+ throw new Error("Empty value provided for input HTTP label: FunctionName.");
1331
+ }
1332
+ resolvedPath = resolvedPath.replace("{FunctionName}", (0, smithy_client_1.extendedEncodeURIComponent)(labelValue));
1333
+ }
1334
+ else {
1335
+ throw new Error("No value provided for input HTTP label: FunctionName.");
1336
+ }
1337
+ const query = {
1338
+ ...(input.Marker !== undefined && { Marker: input.Marker }),
1339
+ ...(input.MaxItems !== undefined && { MaxItems: input.MaxItems.toString() }),
1340
+ };
1341
+ let body;
1342
+ return new protocol_http_1.HttpRequest({
1343
+ protocol,
1344
+ hostname,
1345
+ port,
1346
+ method: "GET",
1347
+ headers,
1348
+ path: resolvedPath,
1349
+ query,
1350
+ body,
1351
+ });
1352
+ };
1353
+ exports.serializeAws_restJson1ListFunctionUrlConfigsCommand = serializeAws_restJson1ListFunctionUrlConfigsCommand;
1221
1354
  const serializeAws_restJson1ListLayersCommand = async (input, context) => {
1222
1355
  const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
1223
1356
  const headers = {};
@@ -1966,6 +2099,10 @@ const serializeAws_restJson1UpdateFunctionConfigurationCommand = async (input, c
1966
2099
  ...(input.Description !== undefined && input.Description !== null && { Description: input.Description }),
1967
2100
  ...(input.Environment !== undefined &&
1968
2101
  input.Environment !== null && { Environment: serializeAws_restJson1Environment(input.Environment, context) }),
2102
+ ...(input.EphemeralStorage !== undefined &&
2103
+ input.EphemeralStorage !== null && {
2104
+ EphemeralStorage: serializeAws_restJson1EphemeralStorage(input.EphemeralStorage, context),
2105
+ }),
1969
2106
  ...(input.FileSystemConfigs !== undefined &&
1970
2107
  input.FileSystemConfigs !== null && {
1971
2108
  FileSystemConfigs: serializeAws_restJson1FileSystemConfigList(input.FileSystemConfigs, context),
@@ -2042,6 +2179,42 @@ const serializeAws_restJson1UpdateFunctionEventInvokeConfigCommand = async (inpu
2042
2179
  });
2043
2180
  };
2044
2181
  exports.serializeAws_restJson1UpdateFunctionEventInvokeConfigCommand = serializeAws_restJson1UpdateFunctionEventInvokeConfigCommand;
2182
+ const serializeAws_restJson1UpdateFunctionUrlConfigCommand = async (input, context) => {
2183
+ const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
2184
+ const headers = {
2185
+ "content-type": "application/json",
2186
+ };
2187
+ let resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/2021-10-31/functions/{FunctionName}/url";
2188
+ if (input.FunctionName !== undefined) {
2189
+ const labelValue = input.FunctionName;
2190
+ if (labelValue.length <= 0) {
2191
+ throw new Error("Empty value provided for input HTTP label: FunctionName.");
2192
+ }
2193
+ resolvedPath = resolvedPath.replace("{FunctionName}", (0, smithy_client_1.extendedEncodeURIComponent)(labelValue));
2194
+ }
2195
+ else {
2196
+ throw new Error("No value provided for input HTTP label: FunctionName.");
2197
+ }
2198
+ const query = {
2199
+ ...(input.Qualifier !== undefined && { Qualifier: input.Qualifier }),
2200
+ };
2201
+ let body;
2202
+ body = JSON.stringify({
2203
+ ...(input.AuthType !== undefined && input.AuthType !== null && { AuthType: input.AuthType }),
2204
+ ...(input.Cors !== undefined && input.Cors !== null && { Cors: serializeAws_restJson1Cors(input.Cors, context) }),
2205
+ });
2206
+ return new protocol_http_1.HttpRequest({
2207
+ protocol,
2208
+ hostname,
2209
+ port,
2210
+ method: "PUT",
2211
+ headers,
2212
+ path: resolvedPath,
2213
+ query,
2214
+ body,
2215
+ });
2216
+ };
2217
+ exports.serializeAws_restJson1UpdateFunctionUrlConfigCommand = serializeAws_restJson1UpdateFunctionUrlConfigCommand;
2045
2218
  const deserializeAws_restJson1AddLayerVersionPermissionCommand = async (output, context) => {
2046
2219
  if (output.statusCode !== 201 && output.statusCode >= 300) {
2047
2220
  return deserializeAws_restJson1AddLayerVersionPermissionCommandError(output, context);
@@ -2414,6 +2587,7 @@ const deserializeAws_restJson1CreateFunctionCommand = async (output, context) =>
2414
2587
  DeadLetterConfig: undefined,
2415
2588
  Description: undefined,
2416
2589
  Environment: undefined,
2590
+ EphemeralStorage: undefined,
2417
2591
  FileSystemConfigs: undefined,
2418
2592
  FunctionArn: undefined,
2419
2593
  FunctionName: undefined,
@@ -2460,6 +2634,9 @@ const deserializeAws_restJson1CreateFunctionCommand = async (output, context) =>
2460
2634
  if (data.Environment !== undefined && data.Environment !== null) {
2461
2635
  contents.Environment = deserializeAws_restJson1EnvironmentResponse(data.Environment, context);
2462
2636
  }
2637
+ if (data.EphemeralStorage !== undefined && data.EphemeralStorage !== null) {
2638
+ contents.EphemeralStorage = deserializeAws_restJson1EphemeralStorage(data.EphemeralStorage, context);
2639
+ }
2463
2640
  if (data.FileSystemConfigs !== undefined && data.FileSystemConfigs !== null) {
2464
2641
  contents.FileSystemConfigs = deserializeAws_restJson1FileSystemConfigList(data.FileSystemConfigs, context);
2465
2642
  }
@@ -2587,6 +2764,71 @@ const deserializeAws_restJson1CreateFunctionCommandError = async (output, contex
2587
2764
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2588
2765
  }
2589
2766
  };
2767
+ const deserializeAws_restJson1CreateFunctionUrlConfigCommand = async (output, context) => {
2768
+ if (output.statusCode !== 201 && output.statusCode >= 300) {
2769
+ return deserializeAws_restJson1CreateFunctionUrlConfigCommandError(output, context);
2770
+ }
2771
+ const contents = {
2772
+ $metadata: deserializeMetadata(output),
2773
+ AuthType: undefined,
2774
+ Cors: undefined,
2775
+ CreationTime: undefined,
2776
+ FunctionArn: undefined,
2777
+ FunctionUrl: undefined,
2778
+ };
2779
+ const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
2780
+ if (data.AuthType !== undefined && data.AuthType !== null) {
2781
+ contents.AuthType = (0, smithy_client_1.expectString)(data.AuthType);
2782
+ }
2783
+ if (data.Cors !== undefined && data.Cors !== null) {
2784
+ contents.Cors = deserializeAws_restJson1Cors(data.Cors, context);
2785
+ }
2786
+ if (data.CreationTime !== undefined && data.CreationTime !== null) {
2787
+ contents.CreationTime = (0, smithy_client_1.expectString)(data.CreationTime);
2788
+ }
2789
+ if (data.FunctionArn !== undefined && data.FunctionArn !== null) {
2790
+ contents.FunctionArn = (0, smithy_client_1.expectString)(data.FunctionArn);
2791
+ }
2792
+ if (data.FunctionUrl !== undefined && data.FunctionUrl !== null) {
2793
+ contents.FunctionUrl = (0, smithy_client_1.expectString)(data.FunctionUrl);
2794
+ }
2795
+ return Promise.resolve(contents);
2796
+ };
2797
+ exports.deserializeAws_restJson1CreateFunctionUrlConfigCommand = deserializeAws_restJson1CreateFunctionUrlConfigCommand;
2798
+ const deserializeAws_restJson1CreateFunctionUrlConfigCommandError = async (output, context) => {
2799
+ const parsedOutput = {
2800
+ ...output,
2801
+ body: await parseBody(output.body, context),
2802
+ };
2803
+ let response;
2804
+ let errorCode = "UnknownError";
2805
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2806
+ switch (errorCode) {
2807
+ case "InvalidParameterValueException":
2808
+ case "com.amazonaws.lambda#InvalidParameterValueException":
2809
+ throw await deserializeAws_restJson1InvalidParameterValueExceptionResponse(parsedOutput, context);
2810
+ case "ResourceConflictException":
2811
+ case "com.amazonaws.lambda#ResourceConflictException":
2812
+ throw await deserializeAws_restJson1ResourceConflictExceptionResponse(parsedOutput, context);
2813
+ case "ResourceNotFoundException":
2814
+ case "com.amazonaws.lambda#ResourceNotFoundException":
2815
+ throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
2816
+ case "ServiceException":
2817
+ case "com.amazonaws.lambda#ServiceException":
2818
+ throw await deserializeAws_restJson1ServiceExceptionResponse(parsedOutput, context);
2819
+ case "TooManyRequestsException":
2820
+ case "com.amazonaws.lambda#TooManyRequestsException":
2821
+ throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
2822
+ default:
2823
+ const parsedBody = parsedOutput.body;
2824
+ response = new LambdaServiceException_1.LambdaServiceException({
2825
+ name: parsedBody.code || parsedBody.Code || errorCode,
2826
+ $fault: "client",
2827
+ $metadata: deserializeMetadata(output),
2828
+ });
2829
+ throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2830
+ }
2831
+ };
2590
2832
  const deserializeAws_restJson1DeleteAliasCommand = async (output, context) => {
2591
2833
  if (output.statusCode !== 204 && output.statusCode >= 300) {
2592
2834
  return deserializeAws_restJson1DeleteAliasCommandError(output, context);
@@ -2991,6 +3233,48 @@ const deserializeAws_restJson1DeleteFunctionEventInvokeConfigCommandError = asyn
2991
3233
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2992
3234
  }
2993
3235
  };
3236
+ const deserializeAws_restJson1DeleteFunctionUrlConfigCommand = async (output, context) => {
3237
+ if (output.statusCode !== 204 && output.statusCode >= 300) {
3238
+ return deserializeAws_restJson1DeleteFunctionUrlConfigCommandError(output, context);
3239
+ }
3240
+ const contents = {
3241
+ $metadata: deserializeMetadata(output),
3242
+ };
3243
+ await collectBody(output.body, context);
3244
+ return Promise.resolve(contents);
3245
+ };
3246
+ exports.deserializeAws_restJson1DeleteFunctionUrlConfigCommand = deserializeAws_restJson1DeleteFunctionUrlConfigCommand;
3247
+ const deserializeAws_restJson1DeleteFunctionUrlConfigCommandError = async (output, context) => {
3248
+ const parsedOutput = {
3249
+ ...output,
3250
+ body: await parseBody(output.body, context),
3251
+ };
3252
+ let response;
3253
+ let errorCode = "UnknownError";
3254
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3255
+ switch (errorCode) {
3256
+ case "ResourceConflictException":
3257
+ case "com.amazonaws.lambda#ResourceConflictException":
3258
+ throw await deserializeAws_restJson1ResourceConflictExceptionResponse(parsedOutput, context);
3259
+ case "ResourceNotFoundException":
3260
+ case "com.amazonaws.lambda#ResourceNotFoundException":
3261
+ throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
3262
+ case "ServiceException":
3263
+ case "com.amazonaws.lambda#ServiceException":
3264
+ throw await deserializeAws_restJson1ServiceExceptionResponse(parsedOutput, context);
3265
+ case "TooManyRequestsException":
3266
+ case "com.amazonaws.lambda#TooManyRequestsException":
3267
+ throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
3268
+ default:
3269
+ const parsedBody = parsedOutput.body;
3270
+ response = new LambdaServiceException_1.LambdaServiceException({
3271
+ name: parsedBody.code || parsedBody.Code || errorCode,
3272
+ $fault: "client",
3273
+ $metadata: deserializeMetadata(output),
3274
+ });
3275
+ throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
3276
+ }
3277
+ };
2994
3278
  const deserializeAws_restJson1DeleteLayerVersionCommand = async (output, context) => {
2995
3279
  if (output.statusCode !== 204 && output.statusCode >= 300) {
2996
3280
  return deserializeAws_restJson1DeleteLayerVersionCommandError(output, context);
@@ -3525,6 +3809,7 @@ const deserializeAws_restJson1GetFunctionConfigurationCommand = async (output, c
3525
3809
  DeadLetterConfig: undefined,
3526
3810
  Description: undefined,
3527
3811
  Environment: undefined,
3812
+ EphemeralStorage: undefined,
3528
3813
  FileSystemConfigs: undefined,
3529
3814
  FunctionArn: undefined,
3530
3815
  FunctionName: undefined,
@@ -3571,6 +3856,9 @@ const deserializeAws_restJson1GetFunctionConfigurationCommand = async (output, c
3571
3856
  if (data.Environment !== undefined && data.Environment !== null) {
3572
3857
  contents.Environment = deserializeAws_restJson1EnvironmentResponse(data.Environment, context);
3573
3858
  }
3859
+ if (data.EphemeralStorage !== undefined && data.EphemeralStorage !== null) {
3860
+ contents.EphemeralStorage = deserializeAws_restJson1EphemeralStorage(data.EphemeralStorage, context);
3861
+ }
3574
3862
  if (data.FileSystemConfigs !== undefined && data.FileSystemConfigs !== null) {
3575
3863
  contents.FileSystemConfigs = deserializeAws_restJson1FileSystemConfigList(data.FileSystemConfigs, context);
3576
3864
  }
@@ -3745,6 +4033,72 @@ const deserializeAws_restJson1GetFunctionEventInvokeConfigCommandError = async (
3745
4033
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
3746
4034
  }
3747
4035
  };
4036
+ const deserializeAws_restJson1GetFunctionUrlConfigCommand = async (output, context) => {
4037
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
4038
+ return deserializeAws_restJson1GetFunctionUrlConfigCommandError(output, context);
4039
+ }
4040
+ const contents = {
4041
+ $metadata: deserializeMetadata(output),
4042
+ AuthType: undefined,
4043
+ Cors: undefined,
4044
+ CreationTime: undefined,
4045
+ FunctionArn: undefined,
4046
+ FunctionUrl: undefined,
4047
+ LastModifiedTime: undefined,
4048
+ };
4049
+ const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
4050
+ if (data.AuthType !== undefined && data.AuthType !== null) {
4051
+ contents.AuthType = (0, smithy_client_1.expectString)(data.AuthType);
4052
+ }
4053
+ if (data.Cors !== undefined && data.Cors !== null) {
4054
+ contents.Cors = deserializeAws_restJson1Cors(data.Cors, context);
4055
+ }
4056
+ if (data.CreationTime !== undefined && data.CreationTime !== null) {
4057
+ contents.CreationTime = (0, smithy_client_1.expectString)(data.CreationTime);
4058
+ }
4059
+ if (data.FunctionArn !== undefined && data.FunctionArn !== null) {
4060
+ contents.FunctionArn = (0, smithy_client_1.expectString)(data.FunctionArn);
4061
+ }
4062
+ if (data.FunctionUrl !== undefined && data.FunctionUrl !== null) {
4063
+ contents.FunctionUrl = (0, smithy_client_1.expectString)(data.FunctionUrl);
4064
+ }
4065
+ if (data.LastModifiedTime !== undefined && data.LastModifiedTime !== null) {
4066
+ contents.LastModifiedTime = (0, smithy_client_1.expectString)(data.LastModifiedTime);
4067
+ }
4068
+ return Promise.resolve(contents);
4069
+ };
4070
+ exports.deserializeAws_restJson1GetFunctionUrlConfigCommand = deserializeAws_restJson1GetFunctionUrlConfigCommand;
4071
+ const deserializeAws_restJson1GetFunctionUrlConfigCommandError = async (output, context) => {
4072
+ const parsedOutput = {
4073
+ ...output,
4074
+ body: await parseBody(output.body, context),
4075
+ };
4076
+ let response;
4077
+ let errorCode = "UnknownError";
4078
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
4079
+ switch (errorCode) {
4080
+ case "InvalidParameterValueException":
4081
+ case "com.amazonaws.lambda#InvalidParameterValueException":
4082
+ throw await deserializeAws_restJson1InvalidParameterValueExceptionResponse(parsedOutput, context);
4083
+ case "ResourceNotFoundException":
4084
+ case "com.amazonaws.lambda#ResourceNotFoundException":
4085
+ throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
4086
+ case "ServiceException":
4087
+ case "com.amazonaws.lambda#ServiceException":
4088
+ throw await deserializeAws_restJson1ServiceExceptionResponse(parsedOutput, context);
4089
+ case "TooManyRequestsException":
4090
+ case "com.amazonaws.lambda#TooManyRequestsException":
4091
+ throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
4092
+ default:
4093
+ const parsedBody = parsedOutput.body;
4094
+ response = new LambdaServiceException_1.LambdaServiceException({
4095
+ name: parsedBody.code || parsedBody.Code || errorCode,
4096
+ $fault: "client",
4097
+ $metadata: deserializeMetadata(output),
4098
+ });
4099
+ throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
4100
+ }
4101
+ };
3748
4102
  const deserializeAws_restJson1GetLayerVersionCommand = async (output, context) => {
3749
4103
  if (output.statusCode !== 200 && output.statusCode >= 300) {
3750
4104
  return deserializeAws_restJson1GetLayerVersionCommandError(output, context);
@@ -4536,6 +4890,56 @@ const deserializeAws_restJson1ListFunctionsByCodeSigningConfigCommandError = asy
4536
4890
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
4537
4891
  }
4538
4892
  };
4893
+ const deserializeAws_restJson1ListFunctionUrlConfigsCommand = async (output, context) => {
4894
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
4895
+ return deserializeAws_restJson1ListFunctionUrlConfigsCommandError(output, context);
4896
+ }
4897
+ const contents = {
4898
+ $metadata: deserializeMetadata(output),
4899
+ FunctionUrlConfigs: undefined,
4900
+ NextMarker: undefined,
4901
+ };
4902
+ const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
4903
+ if (data.FunctionUrlConfigs !== undefined && data.FunctionUrlConfigs !== null) {
4904
+ contents.FunctionUrlConfigs = deserializeAws_restJson1FunctionUrlConfigList(data.FunctionUrlConfigs, context);
4905
+ }
4906
+ if (data.NextMarker !== undefined && data.NextMarker !== null) {
4907
+ contents.NextMarker = (0, smithy_client_1.expectString)(data.NextMarker);
4908
+ }
4909
+ return Promise.resolve(contents);
4910
+ };
4911
+ exports.deserializeAws_restJson1ListFunctionUrlConfigsCommand = deserializeAws_restJson1ListFunctionUrlConfigsCommand;
4912
+ const deserializeAws_restJson1ListFunctionUrlConfigsCommandError = async (output, context) => {
4913
+ const parsedOutput = {
4914
+ ...output,
4915
+ body: await parseBody(output.body, context),
4916
+ };
4917
+ let response;
4918
+ let errorCode = "UnknownError";
4919
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
4920
+ switch (errorCode) {
4921
+ case "InvalidParameterValueException":
4922
+ case "com.amazonaws.lambda#InvalidParameterValueException":
4923
+ throw await deserializeAws_restJson1InvalidParameterValueExceptionResponse(parsedOutput, context);
4924
+ case "ResourceNotFoundException":
4925
+ case "com.amazonaws.lambda#ResourceNotFoundException":
4926
+ throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
4927
+ case "ServiceException":
4928
+ case "com.amazonaws.lambda#ServiceException":
4929
+ throw await deserializeAws_restJson1ServiceExceptionResponse(parsedOutput, context);
4930
+ case "TooManyRequestsException":
4931
+ case "com.amazonaws.lambda#TooManyRequestsException":
4932
+ throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
4933
+ default:
4934
+ const parsedBody = parsedOutput.body;
4935
+ response = new LambdaServiceException_1.LambdaServiceException({
4936
+ name: parsedBody.code || parsedBody.Code || errorCode,
4937
+ $fault: "client",
4938
+ $metadata: deserializeMetadata(output),
4939
+ });
4940
+ throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
4941
+ }
4942
+ };
4539
4943
  const deserializeAws_restJson1ListLayersCommand = async (output, context) => {
4540
4944
  if (output.statusCode !== 200 && output.statusCode >= 300) {
4541
4945
  return deserializeAws_restJson1ListLayersCommandError(output, context);
@@ -4872,6 +5276,7 @@ const deserializeAws_restJson1PublishVersionCommand = async (output, context) =>
4872
5276
  DeadLetterConfig: undefined,
4873
5277
  Description: undefined,
4874
5278
  Environment: undefined,
5279
+ EphemeralStorage: undefined,
4875
5280
  FileSystemConfigs: undefined,
4876
5281
  FunctionArn: undefined,
4877
5282
  FunctionName: undefined,
@@ -4918,6 +5323,9 @@ const deserializeAws_restJson1PublishVersionCommand = async (output, context) =>
4918
5323
  if (data.Environment !== undefined && data.Environment !== null) {
4919
5324
  contents.Environment = deserializeAws_restJson1EnvironmentResponse(data.Environment, context);
4920
5325
  }
5326
+ if (data.EphemeralStorage !== undefined && data.EphemeralStorage !== null) {
5327
+ contents.EphemeralStorage = deserializeAws_restJson1EphemeralStorage(data.EphemeralStorage, context);
5328
+ }
4921
5329
  if (data.FileSystemConfigs !== undefined && data.FileSystemConfigs !== null) {
4922
5330
  contents.FileSystemConfigs = deserializeAws_restJson1FileSystemConfigList(data.FileSystemConfigs, context);
4923
5331
  }
@@ -5728,6 +6136,7 @@ const deserializeAws_restJson1UpdateFunctionCodeCommand = async (output, context
5728
6136
  DeadLetterConfig: undefined,
5729
6137
  Description: undefined,
5730
6138
  Environment: undefined,
6139
+ EphemeralStorage: undefined,
5731
6140
  FileSystemConfigs: undefined,
5732
6141
  FunctionArn: undefined,
5733
6142
  FunctionName: undefined,
@@ -5774,6 +6183,9 @@ const deserializeAws_restJson1UpdateFunctionCodeCommand = async (output, context
5774
6183
  if (data.Environment !== undefined && data.Environment !== null) {
5775
6184
  contents.Environment = deserializeAws_restJson1EnvironmentResponse(data.Environment, context);
5776
6185
  }
6186
+ if (data.EphemeralStorage !== undefined && data.EphemeralStorage !== null) {
6187
+ contents.EphemeralStorage = deserializeAws_restJson1EphemeralStorage(data.EphemeralStorage, context);
6188
+ }
5777
6189
  if (data.FileSystemConfigs !== undefined && data.FileSystemConfigs !== null) {
5778
6190
  contents.FileSystemConfigs = deserializeAws_restJson1FileSystemConfigList(data.FileSystemConfigs, context);
5779
6191
  }
@@ -5916,6 +6328,7 @@ const deserializeAws_restJson1UpdateFunctionConfigurationCommand = async (output
5916
6328
  DeadLetterConfig: undefined,
5917
6329
  Description: undefined,
5918
6330
  Environment: undefined,
6331
+ EphemeralStorage: undefined,
5919
6332
  FileSystemConfigs: undefined,
5920
6333
  FunctionArn: undefined,
5921
6334
  FunctionName: undefined,
@@ -5962,6 +6375,9 @@ const deserializeAws_restJson1UpdateFunctionConfigurationCommand = async (output
5962
6375
  if (data.Environment !== undefined && data.Environment !== null) {
5963
6376
  contents.Environment = deserializeAws_restJson1EnvironmentResponse(data.Environment, context);
5964
6377
  }
6378
+ if (data.EphemeralStorage !== undefined && data.EphemeralStorage !== null) {
6379
+ contents.EphemeralStorage = deserializeAws_restJson1EphemeralStorage(data.EphemeralStorage, context);
6380
+ }
5965
6381
  if (data.FileSystemConfigs !== undefined && data.FileSystemConfigs !== null) {
5966
6382
  contents.FileSystemConfigs = deserializeAws_restJson1FileSystemConfigList(data.FileSystemConfigs, context);
5967
6383
  }
@@ -6154,6 +6570,75 @@ const deserializeAws_restJson1UpdateFunctionEventInvokeConfigCommandError = asyn
6154
6570
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
6155
6571
  }
6156
6572
  };
6573
+ const deserializeAws_restJson1UpdateFunctionUrlConfigCommand = async (output, context) => {
6574
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
6575
+ return deserializeAws_restJson1UpdateFunctionUrlConfigCommandError(output, context);
6576
+ }
6577
+ const contents = {
6578
+ $metadata: deserializeMetadata(output),
6579
+ AuthType: undefined,
6580
+ Cors: undefined,
6581
+ CreationTime: undefined,
6582
+ FunctionArn: undefined,
6583
+ FunctionUrl: undefined,
6584
+ LastModifiedTime: undefined,
6585
+ };
6586
+ const data = (0, smithy_client_1.expectNonNull)((0, smithy_client_1.expectObject)(await parseBody(output.body, context)), "body");
6587
+ if (data.AuthType !== undefined && data.AuthType !== null) {
6588
+ contents.AuthType = (0, smithy_client_1.expectString)(data.AuthType);
6589
+ }
6590
+ if (data.Cors !== undefined && data.Cors !== null) {
6591
+ contents.Cors = deserializeAws_restJson1Cors(data.Cors, context);
6592
+ }
6593
+ if (data.CreationTime !== undefined && data.CreationTime !== null) {
6594
+ contents.CreationTime = (0, smithy_client_1.expectString)(data.CreationTime);
6595
+ }
6596
+ if (data.FunctionArn !== undefined && data.FunctionArn !== null) {
6597
+ contents.FunctionArn = (0, smithy_client_1.expectString)(data.FunctionArn);
6598
+ }
6599
+ if (data.FunctionUrl !== undefined && data.FunctionUrl !== null) {
6600
+ contents.FunctionUrl = (0, smithy_client_1.expectString)(data.FunctionUrl);
6601
+ }
6602
+ if (data.LastModifiedTime !== undefined && data.LastModifiedTime !== null) {
6603
+ contents.LastModifiedTime = (0, smithy_client_1.expectString)(data.LastModifiedTime);
6604
+ }
6605
+ return Promise.resolve(contents);
6606
+ };
6607
+ exports.deserializeAws_restJson1UpdateFunctionUrlConfigCommand = deserializeAws_restJson1UpdateFunctionUrlConfigCommand;
6608
+ const deserializeAws_restJson1UpdateFunctionUrlConfigCommandError = async (output, context) => {
6609
+ const parsedOutput = {
6610
+ ...output,
6611
+ body: await parseBody(output.body, context),
6612
+ };
6613
+ let response;
6614
+ let errorCode = "UnknownError";
6615
+ errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
6616
+ switch (errorCode) {
6617
+ case "InvalidParameterValueException":
6618
+ case "com.amazonaws.lambda#InvalidParameterValueException":
6619
+ throw await deserializeAws_restJson1InvalidParameterValueExceptionResponse(parsedOutput, context);
6620
+ case "ResourceConflictException":
6621
+ case "com.amazonaws.lambda#ResourceConflictException":
6622
+ throw await deserializeAws_restJson1ResourceConflictExceptionResponse(parsedOutput, context);
6623
+ case "ResourceNotFoundException":
6624
+ case "com.amazonaws.lambda#ResourceNotFoundException":
6625
+ throw await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context);
6626
+ case "ServiceException":
6627
+ case "com.amazonaws.lambda#ServiceException":
6628
+ throw await deserializeAws_restJson1ServiceExceptionResponse(parsedOutput, context);
6629
+ case "TooManyRequestsException":
6630
+ case "com.amazonaws.lambda#TooManyRequestsException":
6631
+ throw await deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context);
6632
+ default:
6633
+ const parsedBody = parsedOutput.body;
6634
+ response = new LambdaServiceException_1.LambdaServiceException({
6635
+ name: parsedBody.code || parsedBody.Code || errorCode,
6636
+ $fault: "client",
6637
+ $metadata: deserializeMetadata(output),
6638
+ });
6639
+ throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
6640
+ }
6641
+ };
6157
6642
  const deserializeAws_restJson1CodeSigningConfigNotFoundExceptionResponse = async (parsedOutput, context) => {
6158
6643
  const contents = {};
6159
6644
  const data = parsedOutput.body;
@@ -6700,6 +7185,26 @@ const serializeAws_restJson1AllowedPublishers = (input, context) => {
6700
7185
  }),
6701
7186
  };
6702
7187
  };
7188
+ const serializeAws_restJson1AllowMethodsList = (input, context) => {
7189
+ return input
7190
+ .filter((e) => e != null)
7191
+ .map((entry) => {
7192
+ if (entry === null) {
7193
+ return null;
7194
+ }
7195
+ return entry;
7196
+ });
7197
+ };
7198
+ const serializeAws_restJson1AllowOriginsList = (input, context) => {
7199
+ return input
7200
+ .filter((e) => e != null)
7201
+ .map((entry) => {
7202
+ if (entry === null) {
7203
+ return null;
7204
+ }
7205
+ return entry;
7206
+ });
7207
+ };
6703
7208
  const serializeAws_restJson1ArchitecturesList = (input, context) => {
6704
7209
  return input
6705
7210
  .filter((e) => e != null)
@@ -6738,6 +7243,27 @@ const serializeAws_restJson1CompatibleRuntimes = (input, context) => {
6738
7243
  return entry;
6739
7244
  });
6740
7245
  };
7246
+ const serializeAws_restJson1Cors = (input, context) => {
7247
+ return {
7248
+ ...(input.AllowCredentials !== undefined &&
7249
+ input.AllowCredentials !== null && { AllowCredentials: input.AllowCredentials }),
7250
+ ...(input.AllowHeaders !== undefined &&
7251
+ input.AllowHeaders !== null && { AllowHeaders: serializeAws_restJson1HeadersList(input.AllowHeaders, context) }),
7252
+ ...(input.AllowMethods !== undefined &&
7253
+ input.AllowMethods !== null && {
7254
+ AllowMethods: serializeAws_restJson1AllowMethodsList(input.AllowMethods, context),
7255
+ }),
7256
+ ...(input.AllowOrigins !== undefined &&
7257
+ input.AllowOrigins !== null && {
7258
+ AllowOrigins: serializeAws_restJson1AllowOriginsList(input.AllowOrigins, context),
7259
+ }),
7260
+ ...(input.ExposeHeaders !== undefined &&
7261
+ input.ExposeHeaders !== null && {
7262
+ ExposeHeaders: serializeAws_restJson1HeadersList(input.ExposeHeaders, context),
7263
+ }),
7264
+ ...(input.MaxAge !== undefined && input.MaxAge !== null && { MaxAge: input.MaxAge }),
7265
+ };
7266
+ };
6741
7267
  const serializeAws_restJson1DeadLetterConfig = (input, context) => {
6742
7268
  return {
6743
7269
  ...(input.TargetArn !== undefined && input.TargetArn !== null && { TargetArn: input.TargetArn }),
@@ -6789,6 +7315,11 @@ const serializeAws_restJson1EnvironmentVariables = (input, context) => {
6789
7315
  };
6790
7316
  }, {});
6791
7317
  };
7318
+ const serializeAws_restJson1EphemeralStorage = (input, context) => {
7319
+ return {
7320
+ ...(input.Size !== undefined && input.Size !== null && { Size: input.Size }),
7321
+ };
7322
+ };
6792
7323
  const serializeAws_restJson1FileSystemConfig = (input, context) => {
6793
7324
  return {
6794
7325
  ...(input.Arn !== undefined && input.Arn !== null && { Arn: input.Arn }),
@@ -6847,6 +7378,16 @@ const serializeAws_restJson1FunctionResponseTypeList = (input, context) => {
6847
7378
  return entry;
6848
7379
  });
6849
7380
  };
7381
+ const serializeAws_restJson1HeadersList = (input, context) => {
7382
+ return input
7383
+ .filter((e) => e != null)
7384
+ .map((entry) => {
7385
+ if (entry === null) {
7386
+ return null;
7387
+ }
7388
+ return entry;
7389
+ });
7390
+ };
6850
7391
  const serializeAws_restJson1ImageConfig = (input, context) => {
6851
7392
  return {
6852
7393
  ...(input.Command !== undefined &&
@@ -7057,6 +7598,28 @@ const deserializeAws_restJson1AllowedPublishers = (output, context) => {
7057
7598
  : undefined,
7058
7599
  };
7059
7600
  };
7601
+ const deserializeAws_restJson1AllowMethodsList = (output, context) => {
7602
+ const retVal = (output || [])
7603
+ .filter((e) => e != null)
7604
+ .map((entry) => {
7605
+ if (entry === null) {
7606
+ return null;
7607
+ }
7608
+ return (0, smithy_client_1.expectString)(entry);
7609
+ });
7610
+ return retVal;
7611
+ };
7612
+ const deserializeAws_restJson1AllowOriginsList = (output, context) => {
7613
+ const retVal = (output || [])
7614
+ .filter((e) => e != null)
7615
+ .map((entry) => {
7616
+ if (entry === null) {
7617
+ return null;
7618
+ }
7619
+ return (0, smithy_client_1.expectString)(entry);
7620
+ });
7621
+ return retVal;
7622
+ };
7060
7623
  const deserializeAws_restJson1ArchitecturesList = (output, context) => {
7061
7624
  const retVal = (output || [])
7062
7625
  .filter((e) => e != null)
@@ -7125,6 +7688,24 @@ const deserializeAws_restJson1Concurrency = (output, context) => {
7125
7688
  ReservedConcurrentExecutions: (0, smithy_client_1.expectInt32)(output.ReservedConcurrentExecutions),
7126
7689
  };
7127
7690
  };
7691
+ const deserializeAws_restJson1Cors = (output, context) => {
7692
+ return {
7693
+ AllowCredentials: (0, smithy_client_1.expectBoolean)(output.AllowCredentials),
7694
+ AllowHeaders: output.AllowHeaders !== undefined && output.AllowHeaders !== null
7695
+ ? deserializeAws_restJson1HeadersList(output.AllowHeaders, context)
7696
+ : undefined,
7697
+ AllowMethods: output.AllowMethods !== undefined && output.AllowMethods !== null
7698
+ ? deserializeAws_restJson1AllowMethodsList(output.AllowMethods, context)
7699
+ : undefined,
7700
+ AllowOrigins: output.AllowOrigins !== undefined && output.AllowOrigins !== null
7701
+ ? deserializeAws_restJson1AllowOriginsList(output.AllowOrigins, context)
7702
+ : undefined,
7703
+ ExposeHeaders: output.ExposeHeaders !== undefined && output.ExposeHeaders !== null
7704
+ ? deserializeAws_restJson1HeadersList(output.ExposeHeaders, context)
7705
+ : undefined,
7706
+ MaxAge: (0, smithy_client_1.expectInt32)(output.MaxAge),
7707
+ };
7708
+ };
7128
7709
  const deserializeAws_restJson1DeadLetterConfig = (output, context) => {
7129
7710
  return {
7130
7711
  TargetArn: (0, smithy_client_1.expectString)(output.TargetArn),
@@ -7189,6 +7770,11 @@ const deserializeAws_restJson1EnvironmentVariables = (output, context) => {
7189
7770
  };
7190
7771
  }, {});
7191
7772
  };
7773
+ const deserializeAws_restJson1EphemeralStorage = (output, context) => {
7774
+ return {
7775
+ Size: (0, smithy_client_1.expectInt32)(output.Size),
7776
+ };
7777
+ };
7192
7778
  const deserializeAws_restJson1EventSourceMappingConfiguration = (output, context) => {
7193
7779
  return {
7194
7780
  BatchSize: (0, smithy_client_1.expectInt32)(output.BatchSize),
@@ -7318,6 +7904,9 @@ const deserializeAws_restJson1FunctionConfiguration = (output, context) => {
7318
7904
  Environment: output.Environment !== undefined && output.Environment !== null
7319
7905
  ? deserializeAws_restJson1EnvironmentResponse(output.Environment, context)
7320
7906
  : undefined,
7907
+ EphemeralStorage: output.EphemeralStorage !== undefined && output.EphemeralStorage !== null
7908
+ ? deserializeAws_restJson1EphemeralStorage(output.EphemeralStorage, context)
7909
+ : undefined,
7321
7910
  FileSystemConfigs: output.FileSystemConfigs !== undefined && output.FileSystemConfigs !== null
7322
7911
  ? deserializeAws_restJson1FileSystemConfigList(output.FileSystemConfigs, context)
7323
7912
  : undefined,
@@ -7402,6 +7991,40 @@ const deserializeAws_restJson1FunctionResponseTypeList = (output, context) => {
7402
7991
  });
7403
7992
  return retVal;
7404
7993
  };
7994
+ const deserializeAws_restJson1FunctionUrlConfig = (output, context) => {
7995
+ return {
7996
+ AuthType: (0, smithy_client_1.expectString)(output.AuthType),
7997
+ Cors: output.Cors !== undefined && output.Cors !== null
7998
+ ? deserializeAws_restJson1Cors(output.Cors, context)
7999
+ : undefined,
8000
+ CreationTime: (0, smithy_client_1.expectString)(output.CreationTime),
8001
+ FunctionArn: (0, smithy_client_1.expectString)(output.FunctionArn),
8002
+ FunctionUrl: (0, smithy_client_1.expectString)(output.FunctionUrl),
8003
+ LastModifiedTime: (0, smithy_client_1.expectString)(output.LastModifiedTime),
8004
+ };
8005
+ };
8006
+ const deserializeAws_restJson1FunctionUrlConfigList = (output, context) => {
8007
+ const retVal = (output || [])
8008
+ .filter((e) => e != null)
8009
+ .map((entry) => {
8010
+ if (entry === null) {
8011
+ return null;
8012
+ }
8013
+ return deserializeAws_restJson1FunctionUrlConfig(entry, context);
8014
+ });
8015
+ return retVal;
8016
+ };
8017
+ const deserializeAws_restJson1HeadersList = (output, context) => {
8018
+ const retVal = (output || [])
8019
+ .filter((e) => e != null)
8020
+ .map((entry) => {
8021
+ if (entry === null) {
8022
+ return null;
8023
+ }
8024
+ return (0, smithy_client_1.expectString)(entry);
8025
+ });
8026
+ return retVal;
8027
+ };
7405
8028
  const deserializeAws_restJson1ImageConfig = (output, context) => {
7406
8029
  return {
7407
8030
  Command: output.Command !== undefined && output.Command !== null