deleteFunction (original) (raw)

Deletes a Lambda function. To delete a specific function version, use the Qualifier parameter. Otherwise, all versions and aliases are deleted. This doesn't require the user to have explicit permissions for DeleteAlias.

To delete Lambda event source mappings that invoke a function, use DeleteEventSourceMapping. For Amazon Web Services services and resources that invoke your function directly, delete the trigger in the service where you originally configured it.

Samples


fun main() { 
   //sampleStart 
   // The following example deletes version 1 of a Lambda function named my function.
lambdaClient.deleteFunction {
    functionName = "my-function"
    qualifier = "1"
} 
   //sampleEnd
}