@aws-sdk/client-lambda 3.654.0 → 3.656.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/dist-cjs/index.js +31 -24
- package/dist-es/models/models_0.js +14 -14
- package/dist-es/protocols/Aws_restJson1.js +10 -3
- package/dist-types/commands/AddLayerVersionPermissionCommand.d.ts +21 -0
- package/dist-types/commands/AddPermissionCommand.d.ts +46 -1
- package/dist-types/commands/CreateAliasCommand.d.ts +23 -0
- package/dist-types/commands/CreateCodeSigningConfigCommand.d.ts +3 -0
- package/dist-types/commands/CreateEventSourceMappingCommand.d.ts +28 -0
- package/dist-types/commands/CreateFunctionCommand.d.ts +64 -0
- package/dist-types/commands/DeleteAliasCommand.d.ts +12 -0
- package/dist-types/commands/DeleteEventSourceMappingCommand.d.ts +23 -0
- package/dist-types/commands/DeleteFunctionCommand.d.ts +12 -0
- package/dist-types/commands/DeleteFunctionConcurrencyCommand.d.ts +11 -0
- package/dist-types/commands/DeleteFunctionEventInvokeConfigCommand.d.ts +12 -0
- package/dist-types/commands/DeleteLayerVersionCommand.d.ts +12 -0
- package/dist-types/commands/DeleteProvisionedConcurrencyConfigCommand.d.ts +12 -0
- package/dist-types/commands/DeleteResourcePolicyCommand.d.ts +5 -1
- package/dist-types/commands/GetAccountSettingsCommand.d.ts +24 -0
- package/dist-types/commands/GetAliasCommand.d.ts +21 -0
- package/dist-types/commands/GetEventSourceMappingCommand.d.ts +28 -0
- package/dist-types/commands/GetFunctionCommand.d.ts +50 -0
- package/dist-types/commands/GetFunctionConcurrencyCommand.d.ts +16 -0
- package/dist-types/commands/GetFunctionConfigurationCommand.d.ts +41 -0
- package/dist-types/commands/GetFunctionEventInvokeConfigCommand.d.ts +26 -0
- package/dist-types/commands/GetLayerVersionByArnCommand.d.ts +28 -0
- package/dist-types/commands/GetLayerVersionCommand.d.ts +31 -0
- package/dist-types/commands/GetPolicyCommand.d.ts +18 -0
- package/dist-types/commands/GetProvisionedConcurrencyConfigCommand.d.ts +42 -0
- package/dist-types/commands/GetPublicAccessBlockConfigCommand.d.ts +5 -1
- package/dist-types/commands/GetResourcePolicyCommand.d.ts +5 -1
- package/dist-types/commands/InvokeAsyncCommand.d.ts +17 -0
- package/dist-types/commands/InvokeCommand.d.ts +39 -0
- package/dist-types/commands/ListAliasesCommand.d.ts +36 -0
- package/dist-types/commands/ListEventSourceMappingsCommand.d.ts +27 -0
- package/dist-types/commands/ListFunctionEventInvokeConfigsCommand.d.ts +29 -0
- package/dist-types/commands/ListFunctionsCommand.d.ts +57 -0
- package/dist-types/commands/ListLayerVersionsCommand.d.ts +35 -0
- package/dist-types/commands/ListLayersCommand.d.ts +31 -0
- package/dist-types/commands/ListProvisionedConcurrencyConfigsCommand.d.ts +33 -0
- package/dist-types/commands/ListTagsCommand.d.ts +21 -2
- package/dist-types/commands/ListVersionsByFunctionCommand.d.ts +67 -0
- package/dist-types/commands/PublishLayerVersionCommand.d.ts +40 -0
- package/dist-types/commands/PublishVersionCommand.d.ts +42 -0
- package/dist-types/commands/PutFunctionConcurrencyCommand.d.ts +17 -0
- package/dist-types/commands/PutFunctionEventInvokeConfigCommand.d.ts +25 -0
- package/dist-types/commands/PutProvisionedConcurrencyConfigCommand.d.ts +21 -0
- package/dist-types/commands/PutPublicAccessBlockConfigCommand.d.ts +5 -1
- package/dist-types/commands/PutResourcePolicyCommand.d.ts +5 -1
- package/dist-types/commands/RemoveLayerVersionPermissionCommand.d.ts +13 -0
- package/dist-types/commands/RemovePermissionCommand.d.ts +18 -0
- package/dist-types/commands/TagResourceCommand.d.ts +15 -1
- package/dist-types/commands/UntagResourceCommand.d.ts +15 -1
- package/dist-types/commands/UpdateAliasCommand.d.ts +32 -0
- package/dist-types/commands/UpdateEventSourceMappingCommand.d.ts +27 -0
- package/dist-types/commands/UpdateFunctionCodeCommand.d.ts +33 -0
- package/dist-types/commands/UpdateFunctionConfigurationCommand.d.ts +32 -0
- package/dist-types/commands/UpdateFunctionEventInvokeConfigCommand.d.ts +30 -0
- package/dist-types/models/models_0.d.ts +42 -27
- package/dist-types/ts3.4/models/models_0.d.ts +12 -9
- package/package.json +1 -1
package/dist-cjs/index.js
CHANGED
|
@@ -527,6 +527,25 @@ var FunctionUrlAuthType = {
|
|
|
527
527
|
AWS_IAM: "AWS_IAM",
|
|
528
528
|
NONE: "NONE"
|
|
529
529
|
};
|
|
530
|
+
var _PublicPolicyException = class _PublicPolicyException extends LambdaServiceException {
|
|
531
|
+
/**
|
|
532
|
+
* @internal
|
|
533
|
+
*/
|
|
534
|
+
constructor(opts) {
|
|
535
|
+
super({
|
|
536
|
+
name: "PublicPolicyException",
|
|
537
|
+
$fault: "client",
|
|
538
|
+
...opts
|
|
539
|
+
});
|
|
540
|
+
this.name = "PublicPolicyException";
|
|
541
|
+
this.$fault = "client";
|
|
542
|
+
Object.setPrototypeOf(this, _PublicPolicyException.prototype);
|
|
543
|
+
this.Type = opts.Type;
|
|
544
|
+
this.Message = opts.Message;
|
|
545
|
+
}
|
|
546
|
+
};
|
|
547
|
+
__name(_PublicPolicyException, "PublicPolicyException");
|
|
548
|
+
var PublicPolicyException = _PublicPolicyException;
|
|
530
549
|
var ApplicationLogLevel = {
|
|
531
550
|
Debug: "DEBUG",
|
|
532
551
|
Error: "ERROR",
|
|
@@ -1321,25 +1340,6 @@ var InvokeWithResponseStreamResponseEvent;
|
|
|
1321
1340
|
var FunctionVersion = {
|
|
1322
1341
|
ALL: "ALL"
|
|
1323
1342
|
};
|
|
1324
|
-
var _PublicPolicyException = class _PublicPolicyException extends LambdaServiceException {
|
|
1325
|
-
/**
|
|
1326
|
-
* @internal
|
|
1327
|
-
*/
|
|
1328
|
-
constructor(opts) {
|
|
1329
|
-
super({
|
|
1330
|
-
name: "PublicPolicyException",
|
|
1331
|
-
$fault: "client",
|
|
1332
|
-
...opts
|
|
1333
|
-
});
|
|
1334
|
-
this.name = "PublicPolicyException";
|
|
1335
|
-
this.$fault = "client";
|
|
1336
|
-
Object.setPrototypeOf(this, _PublicPolicyException.prototype);
|
|
1337
|
-
this.Type = opts.Type;
|
|
1338
|
-
this.Message = opts.Message;
|
|
1339
|
-
}
|
|
1340
|
-
};
|
|
1341
|
-
__name(_PublicPolicyException, "PublicPolicyException");
|
|
1342
|
-
var PublicPolicyException = _PublicPolicyException;
|
|
1343
1343
|
var FunctionCodeFilterSensitiveLog = /* @__PURE__ */ __name((obj) => ({
|
|
1344
1344
|
...obj,
|
|
1345
1345
|
...obj.ZipFile && { ZipFile: import_smithy_client.SENSITIVE_STRING }
|
|
@@ -1529,7 +1529,8 @@ var se_CreateCodeSigningConfigCommand = /* @__PURE__ */ __name(async (input, con
|
|
|
1529
1529
|
(0, import_smithy_client.take)(input, {
|
|
1530
1530
|
AllowedPublishers: (_) => (0, import_smithy_client._json)(_),
|
|
1531
1531
|
CodeSigningPolicies: (_) => (0, import_smithy_client._json)(_),
|
|
1532
|
-
Description: []
|
|
1532
|
+
Description: [],
|
|
1533
|
+
Tags: (_) => (0, import_smithy_client._json)(_)
|
|
1533
1534
|
})
|
|
1534
1535
|
);
|
|
1535
1536
|
b.m("POST").h(headers).b(body);
|
|
@@ -1566,6 +1567,7 @@ var se_CreateEventSourceMappingCommand = /* @__PURE__ */ __name(async (input, co
|
|
|
1566
1567
|
SourceAccessConfigurations: (_) => (0, import_smithy_client._json)(_),
|
|
1567
1568
|
StartingPosition: [],
|
|
1568
1569
|
StartingPositionTimestamp: (_) => _.getTime() / 1e3,
|
|
1570
|
+
Tags: (_) => (0, import_smithy_client._json)(_),
|
|
1569
1571
|
Topics: (_) => (0, import_smithy_client._json)(_),
|
|
1570
1572
|
TumblingWindowInSeconds: []
|
|
1571
1573
|
})
|
|
@@ -2640,6 +2642,7 @@ var de_CreateEventSourceMappingCommand = /* @__PURE__ */ __name(async (output, c
|
|
|
2640
2642
|
DestinationConfig: import_smithy_client._json,
|
|
2641
2643
|
DocumentDBEventSourceConfig: import_smithy_client._json,
|
|
2642
2644
|
EventSourceArn: import_smithy_client.expectString,
|
|
2645
|
+
EventSourceMappingArn: import_smithy_client.expectString,
|
|
2643
2646
|
FilterCriteria: import_smithy_client._json,
|
|
2644
2647
|
FilterCriteriaError: import_smithy_client._json,
|
|
2645
2648
|
FunctionArn: import_smithy_client.expectString,
|
|
@@ -2770,6 +2773,7 @@ var de_DeleteEventSourceMappingCommand = /* @__PURE__ */ __name(async (output, c
|
|
|
2770
2773
|
DestinationConfig: import_smithy_client._json,
|
|
2771
2774
|
DocumentDBEventSourceConfig: import_smithy_client._json,
|
|
2772
2775
|
EventSourceArn: import_smithy_client.expectString,
|
|
2776
|
+
EventSourceMappingArn: import_smithy_client.expectString,
|
|
2773
2777
|
FilterCriteria: import_smithy_client._json,
|
|
2774
2778
|
FilterCriteriaError: import_smithy_client._json,
|
|
2775
2779
|
FunctionArn: import_smithy_client.expectString,
|
|
@@ -2940,6 +2944,7 @@ var de_GetEventSourceMappingCommand = /* @__PURE__ */ __name(async (output, cont
|
|
|
2940
2944
|
DestinationConfig: import_smithy_client._json,
|
|
2941
2945
|
DocumentDBEventSourceConfig: import_smithy_client._json,
|
|
2942
2946
|
EventSourceArn: import_smithy_client.expectString,
|
|
2947
|
+
EventSourceMappingArn: import_smithy_client.expectString,
|
|
2943
2948
|
FilterCriteria: import_smithy_client._json,
|
|
2944
2949
|
FilterCriteriaError: import_smithy_client._json,
|
|
2945
2950
|
FunctionArn: import_smithy_client.expectString,
|
|
@@ -3761,6 +3766,7 @@ var de_UpdateEventSourceMappingCommand = /* @__PURE__ */ __name(async (output, c
|
|
|
3761
3766
|
DestinationConfig: import_smithy_client._json,
|
|
3762
3767
|
DocumentDBEventSourceConfig: import_smithy_client._json,
|
|
3763
3768
|
EventSourceArn: import_smithy_client.expectString,
|
|
3769
|
+
EventSourceMappingArn: import_smithy_client.expectString,
|
|
3764
3770
|
FilterCriteria: import_smithy_client._json,
|
|
3765
3771
|
FilterCriteriaError: import_smithy_client._json,
|
|
3766
3772
|
FunctionArn: import_smithy_client.expectString,
|
|
@@ -3952,6 +3958,9 @@ var de_CommandError = /* @__PURE__ */ __name(async (output, context) => {
|
|
|
3952
3958
|
case "TooManyRequestsException":
|
|
3953
3959
|
case "com.amazonaws.lambda#TooManyRequestsException":
|
|
3954
3960
|
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
3961
|
+
case "PublicPolicyException":
|
|
3962
|
+
case "com.amazonaws.lambda#PublicPolicyException":
|
|
3963
|
+
throw await de_PublicPolicyExceptionRes(parsedOutput, context);
|
|
3955
3964
|
case "CodeSigningConfigNotFoundException":
|
|
3956
3965
|
case "com.amazonaws.lambda#CodeSigningConfigNotFoundException":
|
|
3957
3966
|
throw await de_CodeSigningConfigNotFoundExceptionRes(parsedOutput, context);
|
|
@@ -4045,9 +4054,6 @@ var de_CommandError = /* @__PURE__ */ __name(async (output, context) => {
|
|
|
4045
4054
|
case "UnsupportedMediaTypeException":
|
|
4046
4055
|
case "com.amazonaws.lambda#UnsupportedMediaTypeException":
|
|
4047
4056
|
throw await de_UnsupportedMediaTypeExceptionRes(parsedOutput, context);
|
|
4048
|
-
case "PublicPolicyException":
|
|
4049
|
-
case "com.amazonaws.lambda#PublicPolicyException":
|
|
4050
|
-
throw await de_PublicPolicyExceptionRes(parsedOutput, context);
|
|
4051
4057
|
default:
|
|
4052
4058
|
const parsedBody = parsedOutput.body;
|
|
4053
4059
|
return throwDefaultError({
|
|
@@ -4703,6 +4709,7 @@ var de_EventSourceMappingConfiguration = /* @__PURE__ */ __name((output, context
|
|
|
4703
4709
|
DestinationConfig: import_smithy_client._json,
|
|
4704
4710
|
DocumentDBEventSourceConfig: import_smithy_client._json,
|
|
4705
4711
|
EventSourceArn: import_smithy_client.expectString,
|
|
4712
|
+
EventSourceMappingArn: import_smithy_client.expectString,
|
|
4706
4713
|
FilterCriteria: import_smithy_client._json,
|
|
4707
4714
|
FilterCriteriaError: import_smithy_client._json,
|
|
4708
4715
|
FunctionArn: import_smithy_client.expectString,
|
|
@@ -6323,6 +6330,7 @@ var waitUntilPublishedVersionActive = /* @__PURE__ */ __name(async (params, inpu
|
|
|
6323
6330
|
ThrottleReason,
|
|
6324
6331
|
TooManyRequestsException,
|
|
6325
6332
|
FunctionUrlAuthType,
|
|
6333
|
+
PublicPolicyException,
|
|
6326
6334
|
ApplicationLogLevel,
|
|
6327
6335
|
Architecture,
|
|
6328
6336
|
CodeSigningPolicy,
|
|
@@ -6382,7 +6390,6 @@ var waitUntilPublishedVersionActive = /* @__PURE__ */ __name(async (params, inpu
|
|
|
6382
6390
|
ResponseStreamingInvocationType,
|
|
6383
6391
|
InvokeWithResponseStreamResponseEvent,
|
|
6384
6392
|
FunctionVersion,
|
|
6385
|
-
PublicPolicyException,
|
|
6386
6393
|
FunctionCodeFilterSensitiveLog,
|
|
6387
6394
|
EnvironmentFilterSensitiveLog,
|
|
6388
6395
|
CreateFunctionRequestFilterSensitiveLog,
|
|
@@ -107,6 +107,20 @@ export const FunctionUrlAuthType = {
|
|
|
107
107
|
AWS_IAM: "AWS_IAM",
|
|
108
108
|
NONE: "NONE",
|
|
109
109
|
};
|
|
110
|
+
export class PublicPolicyException extends __BaseException {
|
|
111
|
+
constructor(opts) {
|
|
112
|
+
super({
|
|
113
|
+
name: "PublicPolicyException",
|
|
114
|
+
$fault: "client",
|
|
115
|
+
...opts,
|
|
116
|
+
});
|
|
117
|
+
this.name = "PublicPolicyException";
|
|
118
|
+
this.$fault = "client";
|
|
119
|
+
Object.setPrototypeOf(this, PublicPolicyException.prototype);
|
|
120
|
+
this.Type = opts.Type;
|
|
121
|
+
this.Message = opts.Message;
|
|
122
|
+
}
|
|
123
|
+
}
|
|
110
124
|
export const ApplicationLogLevel = {
|
|
111
125
|
Debug: "DEBUG",
|
|
112
126
|
Error: "ERROR",
|
|
@@ -746,20 +760,6 @@ export var InvokeWithResponseStreamResponseEvent;
|
|
|
746
760
|
export const FunctionVersion = {
|
|
747
761
|
ALL: "ALL",
|
|
748
762
|
};
|
|
749
|
-
export class PublicPolicyException extends __BaseException {
|
|
750
|
-
constructor(opts) {
|
|
751
|
-
super({
|
|
752
|
-
name: "PublicPolicyException",
|
|
753
|
-
$fault: "client",
|
|
754
|
-
...opts,
|
|
755
|
-
});
|
|
756
|
-
this.name = "PublicPolicyException";
|
|
757
|
-
this.$fault = "client";
|
|
758
|
-
Object.setPrototypeOf(this, PublicPolicyException.prototype);
|
|
759
|
-
this.Type = opts.Type;
|
|
760
|
-
this.Message = opts.Message;
|
|
761
|
-
}
|
|
762
|
-
}
|
|
763
763
|
export const FunctionCodeFilterSensitiveLog = (obj) => ({
|
|
764
764
|
...obj,
|
|
765
765
|
...(obj.ZipFile && { ZipFile: SENSITIVE_STRING }),
|
|
@@ -77,6 +77,7 @@ export const se_CreateCodeSigningConfigCommand = async (input, context) => {
|
|
|
77
77
|
AllowedPublishers: (_) => _json(_),
|
|
78
78
|
CodeSigningPolicies: (_) => _json(_),
|
|
79
79
|
Description: [],
|
|
80
|
+
Tags: (_) => _json(_),
|
|
80
81
|
}));
|
|
81
82
|
b.m("POST").h(headers).b(body);
|
|
82
83
|
return b.build();
|
|
@@ -111,6 +112,7 @@ export const se_CreateEventSourceMappingCommand = async (input, context) => {
|
|
|
111
112
|
SourceAccessConfigurations: (_) => _json(_),
|
|
112
113
|
StartingPosition: [],
|
|
113
114
|
StartingPositionTimestamp: (_) => _.getTime() / 1000,
|
|
115
|
+
Tags: (_) => _json(_),
|
|
114
116
|
Topics: (_) => _json(_),
|
|
115
117
|
TumblingWindowInSeconds: [],
|
|
116
118
|
}));
|
|
@@ -1144,6 +1146,7 @@ export const de_CreateEventSourceMappingCommand = async (output, context) => {
|
|
|
1144
1146
|
DestinationConfig: _json,
|
|
1145
1147
|
DocumentDBEventSourceConfig: _json,
|
|
1146
1148
|
EventSourceArn: __expectString,
|
|
1149
|
+
EventSourceMappingArn: __expectString,
|
|
1147
1150
|
FilterCriteria: _json,
|
|
1148
1151
|
FilterCriteriaError: _json,
|
|
1149
1152
|
FunctionArn: __expectString,
|
|
@@ -1274,6 +1277,7 @@ export const de_DeleteEventSourceMappingCommand = async (output, context) => {
|
|
|
1274
1277
|
DestinationConfig: _json,
|
|
1275
1278
|
DocumentDBEventSourceConfig: _json,
|
|
1276
1279
|
EventSourceArn: __expectString,
|
|
1280
|
+
EventSourceMappingArn: __expectString,
|
|
1277
1281
|
FilterCriteria: _json,
|
|
1278
1282
|
FilterCriteriaError: _json,
|
|
1279
1283
|
FunctionArn: __expectString,
|
|
@@ -1444,6 +1448,7 @@ export const de_GetEventSourceMappingCommand = async (output, context) => {
|
|
|
1444
1448
|
DestinationConfig: _json,
|
|
1445
1449
|
DocumentDBEventSourceConfig: _json,
|
|
1446
1450
|
EventSourceArn: __expectString,
|
|
1451
|
+
EventSourceMappingArn: __expectString,
|
|
1447
1452
|
FilterCriteria: _json,
|
|
1448
1453
|
FilterCriteriaError: _json,
|
|
1449
1454
|
FunctionArn: __expectString,
|
|
@@ -2265,6 +2270,7 @@ export const de_UpdateEventSourceMappingCommand = async (output, context) => {
|
|
|
2265
2270
|
DestinationConfig: _json,
|
|
2266
2271
|
DocumentDBEventSourceConfig: _json,
|
|
2267
2272
|
EventSourceArn: __expectString,
|
|
2273
|
+
EventSourceMappingArn: __expectString,
|
|
2268
2274
|
FilterCriteria: _json,
|
|
2269
2275
|
FilterCriteriaError: _json,
|
|
2270
2276
|
FunctionArn: __expectString,
|
|
@@ -2456,6 +2462,9 @@ const de_CommandError = async (output, context) => {
|
|
|
2456
2462
|
case "TooManyRequestsException":
|
|
2457
2463
|
case "com.amazonaws.lambda#TooManyRequestsException":
|
|
2458
2464
|
throw await de_TooManyRequestsExceptionRes(parsedOutput, context);
|
|
2465
|
+
case "PublicPolicyException":
|
|
2466
|
+
case "com.amazonaws.lambda#PublicPolicyException":
|
|
2467
|
+
throw await de_PublicPolicyExceptionRes(parsedOutput, context);
|
|
2459
2468
|
case "CodeSigningConfigNotFoundException":
|
|
2460
2469
|
case "com.amazonaws.lambda#CodeSigningConfigNotFoundException":
|
|
2461
2470
|
throw await de_CodeSigningConfigNotFoundExceptionRes(parsedOutput, context);
|
|
@@ -2549,9 +2558,6 @@ const de_CommandError = async (output, context) => {
|
|
|
2549
2558
|
case "UnsupportedMediaTypeException":
|
|
2550
2559
|
case "com.amazonaws.lambda#UnsupportedMediaTypeException":
|
|
2551
2560
|
throw await de_UnsupportedMediaTypeExceptionRes(parsedOutput, context);
|
|
2552
|
-
case "PublicPolicyException":
|
|
2553
|
-
case "com.amazonaws.lambda#PublicPolicyException":
|
|
2554
|
-
throw await de_PublicPolicyExceptionRes(parsedOutput, context);
|
|
2555
2561
|
default:
|
|
2556
2562
|
const parsedBody = parsedOutput.body;
|
|
2557
2563
|
return throwDefaultError({
|
|
@@ -3209,6 +3215,7 @@ const de_EventSourceMappingConfiguration = (output, context) => {
|
|
|
3209
3215
|
DestinationConfig: _json,
|
|
3210
3216
|
DocumentDBEventSourceConfig: _json,
|
|
3211
3217
|
EventSourceArn: __expectString,
|
|
3218
|
+
EventSourceMappingArn: __expectString,
|
|
3212
3219
|
FilterCriteria: _json,
|
|
3213
3220
|
FilterCriteriaError: _json,
|
|
3214
3221
|
FunctionArn: __expectString,
|
|
@@ -98,6 +98,27 @@ declare const AddLayerVersionPermissionCommand_base: {
|
|
|
98
98
|
* <p>Base exception class for all service exceptions from Lambda service.</p>
|
|
99
99
|
*
|
|
100
100
|
* @public
|
|
101
|
+
* @example To add permissions to a layer version
|
|
102
|
+
* ```javascript
|
|
103
|
+
* // The following example grants permission for the account 223456789012 to use version 1 of a layer named my-layer.
|
|
104
|
+
* const input = {
|
|
105
|
+
* "Action": "lambda:GetLayerVersion",
|
|
106
|
+
* "LayerName": "my-layer",
|
|
107
|
+
* "Principal": "223456789012",
|
|
108
|
+
* "StatementId": "xaccount",
|
|
109
|
+
* "VersionNumber": 1
|
|
110
|
+
* };
|
|
111
|
+
* const command = new AddLayerVersionPermissionCommand(input);
|
|
112
|
+
* const response = await client.send(command);
|
|
113
|
+
* /* response ==
|
|
114
|
+
* {
|
|
115
|
+
* "RevisionId": "35d87451-f796-4a3f-a618-95a3671b0a0c",
|
|
116
|
+
* "Statement": "{\"Sid\":\"xaccount\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::223456789012:root\"},\"Action\":\"lambda:GetLayerVersion\",\"Resource\":\"arn:aws:lambda:us-east-2:123456789012:layer:my-layer:1\"}"
|
|
117
|
+
* }
|
|
118
|
+
* *\/
|
|
119
|
+
* // example id: to-add-permissions-to-a-layer-version-1586479797163
|
|
120
|
+
* ```
|
|
121
|
+
*
|
|
101
122
|
*/
|
|
102
123
|
export declare class AddLayerVersionPermissionCommand extends AddLayerVersionPermissionCommand_base {
|
|
103
124
|
/** @internal type navigation helper, not in runtime. */
|
|
@@ -27,7 +27,7 @@ declare const AddPermissionCommand_base: {
|
|
|
27
27
|
getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
|
|
28
28
|
};
|
|
29
29
|
/**
|
|
30
|
-
* <p>Grants
|
|
30
|
+
* <p>Grants a <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_principal.html#Principal_specifying">principal</a>
|
|
31
31
|
* permission to use a function. You can apply the policy at the function level, or specify a qualifier to restrict
|
|
32
32
|
* access to a single version or alias. If you use a qualifier, the invoker must use the full Amazon Resource Name
|
|
33
33
|
* (ARN) of that version or alias to invoke the function. Note: Lambda does not support adding policies
|
|
@@ -92,6 +92,11 @@ declare const AddPermissionCommand_base: {
|
|
|
92
92
|
* </li>
|
|
93
93
|
* </ul>
|
|
94
94
|
*
|
|
95
|
+
* @throws {@link PublicPolicyException} (client fault)
|
|
96
|
+
* <p>Lambda prevented your policy from being created because it would grant public access to your function. If you intended to
|
|
97
|
+
* create a public policy, use the <a>PutPublicAccessBlockConfig</a> API action to configure your function's public-access settings
|
|
98
|
+
* to allow public policies.</p>
|
|
99
|
+
*
|
|
95
100
|
* @throws {@link ResourceConflictException} (client fault)
|
|
96
101
|
* <p>The resource already exists, or another operation is in progress.</p>
|
|
97
102
|
*
|
|
@@ -108,6 +113,46 @@ declare const AddPermissionCommand_base: {
|
|
|
108
113
|
* <p>Base exception class for all service exceptions from Lambda service.</p>
|
|
109
114
|
*
|
|
110
115
|
* @public
|
|
116
|
+
* @example To grant Amazon S3 permission to invoke a function
|
|
117
|
+
* ```javascript
|
|
118
|
+
* // The following example adds permission for Amazon S3 to invoke a Lambda function named my-function for notifications from a bucket named my-bucket-1xpuxmplzrlbh in account 123456789012.
|
|
119
|
+
* const input = {
|
|
120
|
+
* "Action": "lambda:InvokeFunction",
|
|
121
|
+
* "FunctionName": "my-function",
|
|
122
|
+
* "Principal": "s3.amazonaws.com",
|
|
123
|
+
* "SourceAccount": "123456789012",
|
|
124
|
+
* "SourceArn": "arn:aws:s3:::my-bucket-1xpuxmplzrlbh/*",
|
|
125
|
+
* "StatementId": "s3"
|
|
126
|
+
* };
|
|
127
|
+
* const command = new AddPermissionCommand(input);
|
|
128
|
+
* const response = await client.send(command);
|
|
129
|
+
* /* response ==
|
|
130
|
+
* {
|
|
131
|
+
* "Statement": "{\"Sid\":\"s3\",\"Effect\":\"Allow\",\"Principal\":{\"Service\":\"s3.amazonaws.com\"},\"Action\":\"lambda:InvokeFunction\",\"Resource\":\"arn:aws:lambda:us-east-2:123456789012:function:my-function\",\"Condition\":{\"StringEquals\":{\"AWS:SourceAccount\":\"123456789012\"},\"ArnLike\":{\"AWS:SourceArn\":\"arn:aws:s3:::my-bucket-1xpuxmplzrlbh\"}}}"
|
|
132
|
+
* }
|
|
133
|
+
* *\/
|
|
134
|
+
* // example id: add-permission-1474651469455
|
|
135
|
+
* ```
|
|
136
|
+
*
|
|
137
|
+
* @example To grant another account permission to invoke a function
|
|
138
|
+
* ```javascript
|
|
139
|
+
* // The following example adds permission for account 223456789012 invoke a Lambda function named my-function.
|
|
140
|
+
* const input = {
|
|
141
|
+
* "Action": "lambda:InvokeFunction",
|
|
142
|
+
* "FunctionName": "my-function",
|
|
143
|
+
* "Principal": "223456789012",
|
|
144
|
+
* "StatementId": "xaccount"
|
|
145
|
+
* };
|
|
146
|
+
* const command = new AddPermissionCommand(input);
|
|
147
|
+
* const response = await client.send(command);
|
|
148
|
+
* /* response ==
|
|
149
|
+
* {
|
|
150
|
+
* "Statement": "{\"Sid\":\"xaccount\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::223456789012:root\"},\"Action\":\"lambda:InvokeFunction\",\"Resource\":\"arn:aws:lambda:us-east-2:123456789012:function:my-function\"}"
|
|
151
|
+
* }
|
|
152
|
+
* *\/
|
|
153
|
+
* // example id: add-permission-1474651469456
|
|
154
|
+
* ```
|
|
155
|
+
*
|
|
111
156
|
*/
|
|
112
157
|
export declare class AddPermissionCommand extends AddPermissionCommand_base {
|
|
113
158
|
/** @internal type navigation helper, not in runtime. */
|
|
@@ -92,6 +92,29 @@ declare const CreateAliasCommand_base: {
|
|
|
92
92
|
* <p>Base exception class for all service exceptions from Lambda service.</p>
|
|
93
93
|
*
|
|
94
94
|
* @public
|
|
95
|
+
* @example To create an alias for a Lambda function
|
|
96
|
+
* ```javascript
|
|
97
|
+
* // The following example creates an alias named LIVE that points to version 1 of the my-function Lambda function.
|
|
98
|
+
* const input = {
|
|
99
|
+
* "Description": "alias for live version of function",
|
|
100
|
+
* "FunctionName": "my-function",
|
|
101
|
+
* "FunctionVersion": "1",
|
|
102
|
+
* "Name": "LIVE"
|
|
103
|
+
* };
|
|
104
|
+
* const command = new CreateAliasCommand(input);
|
|
105
|
+
* const response = await client.send(command);
|
|
106
|
+
* /* response ==
|
|
107
|
+
* {
|
|
108
|
+
* "AliasArn": "arn:aws:lambda:us-east-2:123456789012:function:my-function:LIVE",
|
|
109
|
+
* "Description": "alias for live version of function",
|
|
110
|
+
* "FunctionVersion": "1",
|
|
111
|
+
* "Name": "LIVE",
|
|
112
|
+
* "RevisionId": "873282ed-xmpl-4dc8-a069-d0c647e470c6"
|
|
113
|
+
* }
|
|
114
|
+
* *\/
|
|
115
|
+
* // example id: to-create-an-alias-for-a-lambda-function-1586480324259
|
|
116
|
+
* ```
|
|
117
|
+
*
|
|
95
118
|
*/
|
|
96
119
|
export declare class CreateAliasCommand extends CreateAliasCommand_base {
|
|
97
120
|
/** @internal type navigation helper, not in runtime. */
|
|
@@ -46,6 +46,9 @@ declare const CreateCodeSigningConfigCommand_base: {
|
|
|
46
46
|
* CodeSigningPolicies: { // CodeSigningPolicies
|
|
47
47
|
* UntrustedArtifactOnDeployment: "Warn" || "Enforce",
|
|
48
48
|
* },
|
|
49
|
+
* Tags: { // Tags
|
|
50
|
+
* "<keys>": "STRING_VALUE",
|
|
51
|
+
* },
|
|
49
52
|
* };
|
|
50
53
|
* const command = new CreateCodeSigningConfigCommand(input);
|
|
51
54
|
* const response = await client.send(command);
|
|
@@ -174,6 +174,9 @@ declare const CreateEventSourceMappingCommand_base: {
|
|
|
174
174
|
* MaximumRecordAgeInSeconds: Number("int"),
|
|
175
175
|
* BisectBatchOnFunctionError: true || false,
|
|
176
176
|
* MaximumRetryAttempts: Number("int"),
|
|
177
|
+
* Tags: { // Tags
|
|
178
|
+
* "<keys>": "STRING_VALUE",
|
|
179
|
+
* },
|
|
177
180
|
* TumblingWindowInSeconds: Number("int"),
|
|
178
181
|
* Topics: [ // Topics
|
|
179
182
|
* "STRING_VALUE",
|
|
@@ -288,6 +291,7 @@ declare const CreateEventSourceMappingCommand_base: {
|
|
|
288
291
|
* // ErrorCode: "STRING_VALUE",
|
|
289
292
|
* // Message: "STRING_VALUE",
|
|
290
293
|
* // },
|
|
294
|
+
* // EventSourceMappingArn: "STRING_VALUE",
|
|
291
295
|
* // };
|
|
292
296
|
*
|
|
293
297
|
* ```
|
|
@@ -317,6 +321,30 @@ declare const CreateEventSourceMappingCommand_base: {
|
|
|
317
321
|
* <p>Base exception class for all service exceptions from Lambda service.</p>
|
|
318
322
|
*
|
|
319
323
|
* @public
|
|
324
|
+
* @example To create a mapping between an event source and an AWS Lambda function
|
|
325
|
+
* ```javascript
|
|
326
|
+
* // The following example creates a mapping between an SQS queue and the my-function Lambda function.
|
|
327
|
+
* const input = {
|
|
328
|
+
* "BatchSize": 5,
|
|
329
|
+
* "EventSourceArn": "arn:aws:sqs:us-west-2:123456789012:my-queue",
|
|
330
|
+
* "FunctionName": "my-function"
|
|
331
|
+
* };
|
|
332
|
+
* const command = new CreateEventSourceMappingCommand(input);
|
|
333
|
+
* const response = await client.send(command);
|
|
334
|
+
* /* response ==
|
|
335
|
+
* {
|
|
336
|
+
* "BatchSize": 5,
|
|
337
|
+
* "EventSourceArn": "arn:aws:sqs:us-west-2:123456789012:my-queue",
|
|
338
|
+
* "FunctionArn": "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
|
339
|
+
* "LastModified": 1569284520.333,
|
|
340
|
+
* "State": "Creating",
|
|
341
|
+
* "StateTransitionReason": "USER_INITIATED",
|
|
342
|
+
* "UUID": "a1b2c3d4-5678-90ab-cdef-11111EXAMPLE"
|
|
343
|
+
* }
|
|
344
|
+
* *\/
|
|
345
|
+
* // example id: to-create-a-mapping-between-an-event-source-and-an-aws-lambda-function-1586480555467
|
|
346
|
+
* ```
|
|
347
|
+
*
|
|
320
348
|
*/
|
|
321
349
|
export declare class CreateEventSourceMappingCommand extends CreateEventSourceMappingCommand_base {
|
|
322
350
|
/** @internal type navigation helper, not in runtime. */
|
|
@@ -294,6 +294,70 @@ declare const CreateFunctionCommand_base: {
|
|
|
294
294
|
* <p>Base exception class for all service exceptions from Lambda service.</p>
|
|
295
295
|
*
|
|
296
296
|
* @public
|
|
297
|
+
* @example To create a function
|
|
298
|
+
* ```javascript
|
|
299
|
+
* // The following example creates a function with a deployment package in Amazon S3 and enables X-Ray tracing and environment variable encryption.
|
|
300
|
+
* const input = {
|
|
301
|
+
* "Code": {
|
|
302
|
+
* "S3Bucket": "my-bucket-1xpuxmplzrlbh",
|
|
303
|
+
* "S3Key": "function.zip"
|
|
304
|
+
* },
|
|
305
|
+
* "Description": "Process image objects from Amazon S3.",
|
|
306
|
+
* "Environment": {
|
|
307
|
+
* "Variables": {
|
|
308
|
+
* "BUCKET": "my-bucket-1xpuxmplzrlbh",
|
|
309
|
+
* "PREFIX": "inbound"
|
|
310
|
+
* }
|
|
311
|
+
* },
|
|
312
|
+
* "FunctionName": "my-function",
|
|
313
|
+
* "Handler": "index.handler",
|
|
314
|
+
* "KMSKeyArn": "arn:aws:kms:us-west-2:123456789012:key/b0844d6c-xmpl-4463-97a4-d49f50839966",
|
|
315
|
+
* "MemorySize": 256,
|
|
316
|
+
* "Publish": true,
|
|
317
|
+
* "Role": "arn:aws:iam::123456789012:role/lambda-role",
|
|
318
|
+
* "Runtime": "nodejs12.x",
|
|
319
|
+
* "Tags": {
|
|
320
|
+
* "DEPARTMENT": "Assets"
|
|
321
|
+
* },
|
|
322
|
+
* "Timeout": 15,
|
|
323
|
+
* "TracingConfig": {
|
|
324
|
+
* "Mode": "Active"
|
|
325
|
+
* }
|
|
326
|
+
* };
|
|
327
|
+
* const command = new CreateFunctionCommand(input);
|
|
328
|
+
* const response = await client.send(command);
|
|
329
|
+
* /* response ==
|
|
330
|
+
* {
|
|
331
|
+
* "CodeSha256": "YFgDgEKG3ugvF1+pX64gV6tu9qNuIYNUdgJm8nCxsm4=",
|
|
332
|
+
* "CodeSize": 5797206,
|
|
333
|
+
* "Description": "Process image objects from Amazon S3.",
|
|
334
|
+
* "Environment": {
|
|
335
|
+
* "Variables": {
|
|
336
|
+
* "BUCKET": "my-bucket-1xpuxmplzrlbh",
|
|
337
|
+
* "PREFIX": "inbound"
|
|
338
|
+
* }
|
|
339
|
+
* },
|
|
340
|
+
* "FunctionArn": "arn:aws:lambda:us-west-2:123456789012:function:my-function",
|
|
341
|
+
* "FunctionName": "my-function",
|
|
342
|
+
* "Handler": "index.handler",
|
|
343
|
+
* "KMSKeyArn": "arn:aws:kms:us-west-2:123456789012:key/b0844d6c-xmpl-4463-97a4-d49f50839966",
|
|
344
|
+
* "LastModified": "2020-04-10T19:06:32.563+0000",
|
|
345
|
+
* "LastUpdateStatus": "Successful",
|
|
346
|
+
* "MemorySize": 256,
|
|
347
|
+
* "RevisionId": "b75dcd81-xmpl-48a8-a75a-93ba8b5b9727",
|
|
348
|
+
* "Role": "arn:aws:iam::123456789012:role/lambda-role",
|
|
349
|
+
* "Runtime": "nodejs12.x",
|
|
350
|
+
* "State": "Active",
|
|
351
|
+
* "Timeout": 15,
|
|
352
|
+
* "TracingConfig": {
|
|
353
|
+
* "Mode": "Active"
|
|
354
|
+
* },
|
|
355
|
+
* "Version": "1"
|
|
356
|
+
* }
|
|
357
|
+
* *\/
|
|
358
|
+
* // example id: to-create-a-function-1586492061186
|
|
359
|
+
* ```
|
|
360
|
+
*
|
|
297
361
|
*/
|
|
298
362
|
export declare class CreateFunctionCommand extends CreateFunctionCommand_base {
|
|
299
363
|
/** @internal type navigation helper, not in runtime. */
|
|
@@ -66,6 +66,18 @@ declare const DeleteAliasCommand_base: {
|
|
|
66
66
|
* <p>Base exception class for all service exceptions from Lambda service.</p>
|
|
67
67
|
*
|
|
68
68
|
* @public
|
|
69
|
+
* @example To delete a Lambda function alias
|
|
70
|
+
* ```javascript
|
|
71
|
+
* // The following example deletes an alias named BLUE from a function named my-function
|
|
72
|
+
* const input = {
|
|
73
|
+
* "FunctionName": "my-function",
|
|
74
|
+
* "Name": "BLUE"
|
|
75
|
+
* };
|
|
76
|
+
* const command = new DeleteAliasCommand(input);
|
|
77
|
+
* await client.send(command);
|
|
78
|
+
* // example id: to-delete-a-lambda-function-alias-1481660370804
|
|
79
|
+
* ```
|
|
80
|
+
*
|
|
69
81
|
*/
|
|
70
82
|
export declare class DeleteAliasCommand extends DeleteAliasCommand_base {
|
|
71
83
|
/** @internal type navigation helper, not in runtime. */
|
|
@@ -115,6 +115,7 @@ declare const DeleteEventSourceMappingCommand_base: {
|
|
|
115
115
|
* // ErrorCode: "STRING_VALUE",
|
|
116
116
|
* // Message: "STRING_VALUE",
|
|
117
117
|
* // },
|
|
118
|
+
* // EventSourceMappingArn: "STRING_VALUE",
|
|
118
119
|
* // };
|
|
119
120
|
*
|
|
120
121
|
* ```
|
|
@@ -148,6 +149,28 @@ declare const DeleteEventSourceMappingCommand_base: {
|
|
|
148
149
|
* <p>Base exception class for all service exceptions from Lambda service.</p>
|
|
149
150
|
*
|
|
150
151
|
* @public
|
|
152
|
+
* @example To delete a Lambda function event source mapping
|
|
153
|
+
* ```javascript
|
|
154
|
+
* // The following example deletes an event source mapping. To get a mapping's UUID, use ListEventSourceMappings.
|
|
155
|
+
* const input = {
|
|
156
|
+
* "UUID": "14e0db71-xmpl-4eb5-b481-8945cf9d10c2"
|
|
157
|
+
* };
|
|
158
|
+
* const command = new DeleteEventSourceMappingCommand(input);
|
|
159
|
+
* const response = await client.send(command);
|
|
160
|
+
* /* response ==
|
|
161
|
+
* {
|
|
162
|
+
* "BatchSize": 5,
|
|
163
|
+
* "EventSourceArn": "arn:aws:sqs:us-west-2:123456789012:my-queue",
|
|
164
|
+
* "FunctionArn": "arn:aws:lambda:us-east-2:123456789012:function:my-function",
|
|
165
|
+
* "LastModified": "${timestamp}",
|
|
166
|
+
* "State": "Enabled",
|
|
167
|
+
* "StateTransitionReason": "USER_INITIATED",
|
|
168
|
+
* "UUID": "14e0db71-xmpl-4eb5-b481-8945cf9d10c2"
|
|
169
|
+
* }
|
|
170
|
+
* *\/
|
|
171
|
+
* // example id: to-delete-a-lambda-function-event-source-mapping-1481658973862
|
|
172
|
+
* ```
|
|
173
|
+
*
|
|
151
174
|
*/
|
|
152
175
|
export declare class DeleteEventSourceMappingCommand extends DeleteEventSourceMappingCommand_base {
|
|
153
176
|
/** @internal type navigation helper, not in runtime. */
|
|
@@ -73,6 +73,18 @@ declare const DeleteFunctionCommand_base: {
|
|
|
73
73
|
* <p>Base exception class for all service exceptions from Lambda service.</p>
|
|
74
74
|
*
|
|
75
75
|
* @public
|
|
76
|
+
* @example To delete a version of a Lambda function
|
|
77
|
+
* ```javascript
|
|
78
|
+
* // The following example deletes version 1 of a Lambda function named my-function.
|
|
79
|
+
* const input = {
|
|
80
|
+
* "FunctionName": "my-function",
|
|
81
|
+
* "Qualifier": "1"
|
|
82
|
+
* };
|
|
83
|
+
* const command = new DeleteFunctionCommand(input);
|
|
84
|
+
* await client.send(command);
|
|
85
|
+
* // example id: to-delete-a-lambda-function-1481648553696
|
|
86
|
+
* ```
|
|
87
|
+
*
|
|
76
88
|
*/
|
|
77
89
|
export declare class DeleteFunctionCommand extends DeleteFunctionCommand_base {
|
|
78
90
|
/** @internal type navigation helper, not in runtime. */
|
|
@@ -68,6 +68,17 @@ declare const DeleteFunctionConcurrencyCommand_base: {
|
|
|
68
68
|
* <p>Base exception class for all service exceptions from Lambda service.</p>
|
|
69
69
|
*
|
|
70
70
|
* @public
|
|
71
|
+
* @example To remove the reserved concurrent execution limit from a function
|
|
72
|
+
* ```javascript
|
|
73
|
+
* // The following example deletes the reserved concurrent execution limit from a function named my-function.
|
|
74
|
+
* const input = {
|
|
75
|
+
* "FunctionName": "my-function"
|
|
76
|
+
* };
|
|
77
|
+
* const command = new DeleteFunctionConcurrencyCommand(input);
|
|
78
|
+
* await client.send(command);
|
|
79
|
+
* // example id: to-remove-the-reserved-concurrent-execution-limit-from-a-function-1586480714680
|
|
80
|
+
* ```
|
|
81
|
+
*
|
|
71
82
|
*/
|
|
72
83
|
export declare class DeleteFunctionConcurrencyCommand extends DeleteFunctionConcurrencyCommand_base {
|
|
73
84
|
/** @internal type navigation helper, not in runtime. */
|
|
@@ -70,6 +70,18 @@ declare const DeleteFunctionEventInvokeConfigCommand_base: {
|
|
|
70
70
|
* <p>Base exception class for all service exceptions from Lambda service.</p>
|
|
71
71
|
*
|
|
72
72
|
* @public
|
|
73
|
+
* @example To delete an asynchronous invocation configuration
|
|
74
|
+
* ```javascript
|
|
75
|
+
* // The following example deletes the asynchronous invocation configuration for the GREEN alias of a function named my-function.
|
|
76
|
+
* const input = {
|
|
77
|
+
* "FunctionName": "my-function",
|
|
78
|
+
* "Qualifier": "GREEN"
|
|
79
|
+
* };
|
|
80
|
+
* const command = new DeleteFunctionEventInvokeConfigCommand(input);
|
|
81
|
+
* await client.send(command);
|
|
82
|
+
* // example id: to-delete-an-asynchronous-invocation-configuration-1586481102187
|
|
83
|
+
* ```
|
|
84
|
+
*
|
|
73
85
|
*/
|
|
74
86
|
export declare class DeleteFunctionEventInvokeConfigCommand extends DeleteFunctionEventInvokeConfigCommand_base {
|
|
75
87
|
/** @internal type navigation helper, not in runtime. */
|
|
@@ -62,6 +62,18 @@ declare const DeleteLayerVersionCommand_base: {
|
|
|
62
62
|
* <p>Base exception class for all service exceptions from Lambda service.</p>
|
|
63
63
|
*
|
|
64
64
|
* @public
|
|
65
|
+
* @example To delete a version of a Lambda layer
|
|
66
|
+
* ```javascript
|
|
67
|
+
* // The following example deletes version 2 of a layer named my-layer.
|
|
68
|
+
* const input = {
|
|
69
|
+
* "LayerName": "my-layer",
|
|
70
|
+
* "VersionNumber": 2
|
|
71
|
+
* };
|
|
72
|
+
* const command = new DeleteLayerVersionCommand(input);
|
|
73
|
+
* await client.send(command);
|
|
74
|
+
* // example id: to-delete-a-version-of-a-lambda-layer-1586481157547
|
|
75
|
+
* ```
|
|
76
|
+
*
|
|
65
77
|
*/
|
|
66
78
|
export declare class DeleteLayerVersionCommand extends DeleteLayerVersionCommand_base {
|
|
67
79
|
/** @internal type navigation helper, not in runtime. */
|