deno on AWS Lambda

mod.ts exports types, from types.d.ts, for writing handler functions:

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

export async function handler(
  event: APIGatewayProxyEvent,
  context: Context
): Promise<APIGatewayProxyResult> {
  return {
    body: `Welcome to deno ${Deno.version.deno} 🦕`,
    headers: { "content-type": "text/html;charset=utf8" },
    statusCode: 200
  };
}

See deno-lambda repository for more info on running deno on AWS Lambda.


Note: The bootstrap script is the entrypoint used by AWS Lambda.