Skip to main content

AWS Lambda

Manage your AWS Lambda's: invoke them, create new ones, update, delete, and much more...


Credential configuration

To configure this credential, you need the Access Key ID and the Secret Access Key of the Programatic access user you want to use. Make sure this user has the required permissions to access Lambda to work properly. If you need to create the user, follow the instructions provided here.

In the extra options field, you can include any of the parameters found here.

Here is an example of a filled credential configuration form in YepCode:

AWS Lambda Snippets available in YepCode editor


The title is the triggering text for YepCode to autocomplete the script.


New integration from credential
const awsLambdaClient = yepcode.integration.awsLambda("credential-slug");
New integration from plain authentication data
const { LambdaClient } = require("@aws-sdk/client-lambda");

const awsLambdaClient = new LambdaClient({
credentials: {
accessKeyId: "accessKeyId",
secretAccessKey: "secretAccessKey",

List Functions

List functions
const { ListFunctionsCommand } = require('@aws-sdk/client-lambda')
const listFunctionsCommand = new ListFunctionsCommand({});

const { Functions } = await awsLambdaClient.send(listFunctionsCommand);
for(const func of Functions) {
console.log(func.FunctionName, func.Description)

Invoke Function

Invoke function
const { InvokeCommand, LogType } = require('@aws-sdk/client-lambda')

try {
const params = {
FunctionName: 'funcName',
Payload: JSON.stringify({ foo: 'bar' }),
LogType: LogType.Tail
const invokeCommand = new InvokeCommand(params)
const { Payload, LogResult } = await awsLambdaClient.send(invokeCommand)
const result = Buffer.from(Payload).toString()
const logs = Buffer.from(LogResult, 'base64').toString()

} catch (error) {
throw error
} finally {
// if you are using a custom http handler, you may call destroy() to close open connections.

Get Function

Get function
const { GetFunctionCommand } = require("@aws-sdk/client-lambda");
const getFunctionCommand = new GetFunctionCommand({ FunctionName: 'funcName' });
const response = await awsLambdaClient.send(getFunctionCommand)