PUT /2015-03-31/functions/{FunctionName}/configuration
Modify the version-specific settings of a Lambda function.
When you update a function, Lambda provisions an instance of the function and its supporting resources. If your function connects to a VPC, this process can take a minute. During this time, you can't modify the function, but you can still invoke it. The LastUpdateStatus
, LastUpdateStatusReason
, and LastUpdateStatusReasonCode
fields in the response from GetFunctionConfiguration indicate when the update is complete and the function is processing events with the new configuration. For more information, see Lambda function states.
These settings can vary between versions of a function and are locked when you publish a version. You can't modify the configuration of a published version, only the unpublished version.
To configure function concurrency, use PutFunctionConcurrency. To grant invoke permissions to an Amazon Web Services account or Amazon Web Service, use AddPermission.
Servers
- https://lambda.{region}.amazonaws.com
- https://lambda.{region}.amazonaws.com.cn
Path parameters
Name | Type | Required | Description |
---|---|---|---|
FunctionName |
String | Yes |
The name of the Lambda function. Name formats
The length constraint applies only to the full ARN. If you specify only the function name, it is limited to 64 characters in length. |
Request headers
Name | Type | Required | Description |
---|---|---|---|
X-Amz-Content-Sha256 |
String | No | |
X-Amz-Credential |
String | No | |
Content-Type |
String | Yes |
The media type of the request body.
Default value: "application/json" |
X-Amz-Date |
String | No | |
X-Amz-Algorithm |
String | No | |
X-Amz-SignedHeaders |
String | No | |
X-Amz-Security-Token |
String | No | |
X-Amz-Signature |
String | No |
Request body fields
Name | Type | Required | Description |
---|---|---|---|
Environment |
Object | No |
A function's environment variable settings. You can use environment variables to adjust your function's behavior without updating code. An environment variable is a pair of strings that are stored in a function's version-specific configuration. |
Runtime |
String | No |
The identifier of the function's runtime. Runtime is required if the deployment package is a .zip file archive. The following list includes deprecated runtimes. For more information, see Runtime deprecation policy. Possible values:
|
Layers[] |
Array | No |
A list of function layers to add to the function's execution environment. Specify each layer by its ARN, including the version. |
KMSKeyArn |
String | No |
The ARN of the Key Management Service (KMS) customer managed key that's used to encrypt your function's environment variables. When Lambda SnapStart is activated, this key is also used to encrypt your function's snapshot. If you don't provide a customer managed key, Lambda uses a default service key. |
DeadLetterConfig |
Object | No |
The dead-letter queue for failed asynchronous invocations. |
DeadLetterConfig.TargetArn |
String | No |
The Amazon Resource Name (ARN) of an Amazon SQS queue or Amazon SNS topic. |
FileSystemConfigs[] |
Array | No |
Connection settings for an Amazon EFS file system. |
FileSystemConfigs[].Arn |
String | Yes |
The Amazon Resource Name (ARN) of the Amazon EFS access point that provides access to the file system. |
FileSystemConfigs[].LocalMountPath |
String | Yes |
The path where the function can access the file system, starting with |
Role |
String | No |
The Amazon Resource Name (ARN) of the function's execution role. |
Description |
String | No |
A description of the function. |
VpcConfig |
Object | No |
The VPC security groups and subnets that are attached to a Lambda function. For more information, see Configuring a Lambda function to access resources in a VPC. |
VpcConfig.SubnetIds[] |
Array | No |
A list of VPC subnet IDs. |
VpcConfig.SecurityGroupIds[] |
Array | No |
A list of VPC security group IDs. |
ImageConfig |
Object | No |
Configuration values that override the container image Dockerfile settings. For more information, see Container image settings. |
ImageConfig.EntryPoint[] |
Array | No |
Specifies the entry point to their application, which is typically the location of the runtime executable. |
ImageConfig.WorkingDirectory |
String | No |
Specifies the working directory. |
ImageConfig.Command[] |
Array | No |
Specifies parameters that you want to pass in with ENTRYPOINT. |
Timeout |
Integer | No |
The amount of time (in seconds) that Lambda allows a function to run before stopping it. The default is 3 seconds. The maximum allowed value is 900 seconds. For more information, see Lambda execution environment. |
EphemeralStorage |
Object | No |
The size of the function's |
EphemeralStorage.Size |
Integer | No |
The size of the function's |
RevisionId |
String | No |
Update the function only if the revision ID matches the ID that's specified. Use this option to avoid modifying a function that has changed since you last read it. |
MemorySize |
Integer | No |
The amount of memory available to the function at runtime. Increasing the function memory also increases its CPU allocation. The default value is 128 MB. The value can be any multiple of 1 MB. |
TracingConfig |
Object | No |
The function's X-Ray tracing configuration. To sample and record incoming requests, set |
TracingConfig.Mode |
String | No |
The tracing mode. Possible values:
|
SnapStart |
Object | No |
The function's Lambda SnapStart setting. Set SnapStart is supported with the |
SnapStart.ApplyOn |
String | No |
Set to Possible values:
|
Handler |
String | No |
The name of the method within your code that Lambda calls to run your function. Handler is required if the deployment package is a .zip file archive. The format includes the file name. It can also include namespaces and other qualifiers, depending on the runtime. For more information, see Lambda programming model. |
How to start integrating
- Add HTTP Task to your workflow definition.
- Search for the API you want to integrate with and click on the name.
- This loads the API reference documentation and prepares the Http request settings.
- Click Test request to test run your request to the API and see the API's response.