deno on AWS Lambda

The mod.ts offers the Context and Event interfaces for writing handler functions:

import { Context, Event } from "https://deno.land/x/lambda/mod.ts";

export async function handler(event: Event, context: Context) {
  return {
    statusCode: 200,
    body: `Welcome to deno ${Deno.version.deno} 🦕`
  };
}

See the homepage for more info.


The bootstrap script is the entrypoint used by AWS Lambda.

To use the deno custom runtime create a lambda layer with deno-lambda-layer.zip.