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

@ontahi/runtime-http

v1.0.0-alpha.17

Published

HTTP transport adapters for Ontahi runtimes

Downloads

0

Readme

@ontahi/runtime-http

HTTP transport adapters and a minimal Node host for Ontahí runtimes.

HTTP ingress

createHttpIngressHandler(...) composes Operation and Event ingress behind one standard Web Request → Response boundary. Express and Next.js delegate to this handler; applications that do not need their framework facilities can host the same contract directly with node:http:

import { createNodeHttpIngressServer } from '@ontahi/runtime-http/node';

const server = createNodeHttpIngressServer({
  ingress: {
    providers,
    operations: {
      routes: application.graph.listHttpIngress(),
      dispatcher,
    },
    events: {
      routes: eventRoutes,
      events: application.events,
    },
  },
  bodyLimitBytes: 1024 * 1024,
});

server.listen(3000, '127.0.0.1');

The minimal server buffers only a bounded request body, preserves the raw provider request, returns Web responses without an Express-shaped contract, and sanitizes unexpected failures. Applications still own listening topology, TLS, shutdown, trusted proxy handling, authorization, and provider registration. createNodeHttpServer(...) can host any other standard Ontahí HTTP handler.

The supported entrypoints are:

  1. @ontahi/runtime-http/ingress: framework-neutral ingress composition;
  2. @ontahi/runtime-http/node: the minimal node:http bridge;
  3. @ontahi/runtime-http/event-egress: managed Event egress over Fetch;
  4. @ontahi/runtime-http: the complete server-side surface.

Managed Event egress

The first adapter lowers Core's transport-neutral managed Event egress attempt to one HTTP POST. It sends stable Event, occurrence, subscription, delivery, attempt, and idempotency headers; signs the exact transmitted JSON bytes when configured; and normalizes retryable HTTP outcomes for the Core processor.

import { processNextEventEgressDelivery } from '@ontahi/core/runtime/server';
import { createHttpEventEgressTransport } from '@ontahi/runtime-http/event-egress';

const transport = createHttpEventEgressTransport({ defaultTimeoutMs: 10_000 });

await processNextEventEgressDelivery({
  runtime: eventRuntime,
  subscription,
  consumerId: 'webhook-worker-1',
  leaseMs: 30_000,
  retryDelayMs: 5_000,
  resolveDestination: async destinationId => destinations.require(destinationId),
  transport,
});

A resolved destination has this shape:

const customerWebhook = {
  url: 'https://customer.example/events',
  headers: { authorization: `Bearer ${token}` },
  timeoutMs: 5_000,
  signing: {
    kind: 'hmac-sha256',
    secret: signingSecret,
  },
} as const;

Destinations are trusted host configuration. The package does not register subscriptions, resolve secrets, admit caller-provided URLs, schedule workers, retry internally, or persist attempt history. It does not follow redirects. A 2xx response is accepted; 408, 429, 5xx, network failures, and timeouts are retryable. Other statuses are classified as rejected so Core can persist a terminal failure through the configured durable Event Runtime.