npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@telorun/lambda

v0.5.0

Published

Telo AWS Lambda module — per-source handler kinds and the Lambda.Function dispatcher.

Downloads

3,421

Readme

AWS Lambda

Run your Telo manifest as an AWS Lambda function. One manifest equals one Lambda artifact — the manifest declares which AWS event sources the Lambda accepts and what each handler does; Telo owns the AWS-facing transport.

Why use this

  • One artifact, multiple sources — a single Lambda.Function lists HTTP API, SQS, and direct handlers; Telo routes each event to the matching one.
  • Source-shaped handler kindsLambda.HttpApi, Lambda.Sqs, and Lambda.Direct each carry the right matcher, inputs, and returns/catches contract for their source.
  • Two runtime models, one manifest — managed Node.js (nodejs24.x) or custom (provided.al2023 / containers); pick a model by which bootstrap file you copy.
  • Partial-batch SQSLambda.Sqs emits the standard batchItemFailures envelope so retries scope to failed messages.
  • Cold-start friendlyx-telo-scope lets you defer expensive resource init until the first request that needs it.

Kinds

| Kind | Purpose | | --- | --- | | Lambda.Function | Represents the AWS Lambda function (one ARN). Required in every manifest. | | Lambda.HttpApi | API Gateway HTTP API v2 trigger — routes, matchers, returns/catches rendering, CORS. | | Lambda.Sqs | SQS queue trigger with partial-batch-failure support. | | Lambda.Direct | Catch-all for synchronous invokes (SDK, Step Functions, EventBridge Scheduler, internal RPC). | | Lambda.Handler | Abstract dispatch contract every concrete handler kind extends. |

Example

kind: Telo.Application
metadata: { name: my-lambda, version: 1.0.0 }
imports:
  Lambda: aws/[email protected]
  JS: std/[email protected]
targets: [ Main ]
---
kind: JS.Script
metadata: { name: Worker }
code: |
  function main(input) {
    return { ok: true, received: input.payload };
  }
---
kind: Lambda.Direct
metadata: { name: AdminTools }
handler: { kind: JS.Script, name: Worker }
inputs:
  payload: "${{ event }}"
---
kind: Lambda.Function
metadata: { name: Main }
handlers:
  - { kind: Lambda.Direct, name: AdminTools }

Reference

Picking a Handler Kind

| Source | Use | | --- | --- | | HTTP request via API Gateway HTTP API v2 | Lambda.HttpApi | | SQS message batch | Lambda.Sqs | | Synchronous SDK invoke, Step Functions, EventBridge Scheduler, internal RPC | Lambda.Direct |

A single Lambda.Function can list multiple handler kinds. Bind the AWS-side event source mappings (API Gateway, SQS, etc.) to the same Lambda ARN and Telo routes each event to the matching handler:

kind: Lambda.Function
metadata: { name: Main }
handlers:
  - { kind: Lambda.HttpApi, name: WebApi }
  - { kind: Lambda.Sqs, name: OrderProcessor }
  - { kind: Lambda.Direct, name: AdminTools }

Deployment

Telo supports both AWS Lambda runtime models. The manifest is identical across them — you pick a model by which bootstrap file you copy into the artifact.

| Runtime | Bootstrap | When to use | | --- | --- | --- | | Managed Node (nodejs24.x) | cp node_modules/@telorun/lambda/managed.mjs ./index.mjs | Most cases. AWS owns the outer loop and calls your exported handler. | | Custom (provided.al2023 / container image) | cp node_modules/@telorun/lambda/custom.mjs ./bootstrap | Containers, SnapStart-incompatible runtimes, anywhere you want full control over the boot sequence. |

The same manifest runs under either model — Telo detects which one AWS is using and adapts. You only change which bootstrap you copy.

Examples

Working manifests under examples/aws/lambda/:

  • direct.yaml — minimal Lambda.Direct setup.
  • http-api.yaml — two HTTP routes with CORS and structured error rendering.
  • sqs.yaml — SQS batch handling with per-message retry reporting.
  • multi-kind.yaml — one Lambda artifact serving all three event sources.