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

@agentpost-tools/eventwolf-sdk

v0.2.1

Published

A typed client for eventwolf, for servers and browsers: a publisher that retries and holds events, query helpers, an inbox client, and verifyWebhook.

Readme

EventWolf SDK

A typed client for EventWolf's HTTP API, with a publisher that retries and holds events, an inbox client for a principal's notifications, and webhook verification. It runs in Node 24, browsers, and edge runtimes wherever fetch and Web Crypto are available.

npm i @agentpost-tools/eventwolf-sdk

You need an Agentpost workspace and a project key for a project that uses EventWolf. Publish an event from your server with its secret key:

import { createClient } from '@agentpost-tools/eventwolf-sdk';

export async function publishResolved(key: string, requestId: string) {
  const eventwolf = createClient({ token: key });
  const outcome = await eventwolf.events.publish({
    specversion: '1.0',
    source: '/support/backend',
    type: 'request.resolved',
    data: { requestId },
  });
  if (outcome.result === 'rejected') {
    throw new Error(`${outcome.code}: ${outcome.issues.join('; ')}`);
  }
  return outcome.sequence;
}

A rejected publish is a result, not an error. To publish without waiting, createPublisher({ client, source }) fills in each event's ID and time, batches events, and retries through an outage.

Webhooks

@agentpost-tools/eventwolf-sdk/webhooks has verifyWebhook, which checks a delivery's signature against the endpoint's secret and returns its event, or throws WebhookVerificationError. Give it the raw body, before any parsing:

import { verifyWebhook } from '@agentpost-tools/eventwolf-sdk/webhooks';

export async function receive(request: Request, secret: string) {
  const { event, deliveryId } = await verifyWebhook({
    secret,
    headers: request.headers,
    body: await request.text(),
  });
  console.log(deliveryId, event.type, event.sequence);
  return new Response(null, { status: 204 });
}

EventWolf SDK docs cover the client, the publisher, the inbox client, and webhooks.

Changes

On 0.x, changes that break existing calls, exports, types, or publisher behavior bump the minor version; other changes bump the patch.

0.2.0

  • PUT /config answers a stale If-Match with stale_version instead of version_conflict, and PUT /event-types/{type} answers a concurrent edit with stale_version too. On PUT /config, an If-Match of 0, or a malformed one, is invalid_request.
  • An Idempotency-Key belongs to one operation and one caller. A refusal such as not_found or stale_version replays for 24 hours; invalid_request, config_invalid, and invalid_filter run fresh. A blank key, or one over 255 characters, is invalid_request.
  • Publishing an empty batch, and reading or cancelling a missing replay, ask your host's authorization first, so a caller without access gets forbidden.
  • A JSON null request body is invalid_request.
  • eventTypes.list refuses an after longer than 500 characters, the longest event type name.
  • The error check requires message and docs on an error body, and still accepts the Platform's codes such as throttled.
  • EventwolfApiError narrows details by code: after error.code === 'invalid_filter', error.details?.issues is typed (since details is optional), and so is config_invalid's, and a rejected publish's codes carry the rejection. code is EventWolf's codes, the Platform's, and unknown, rather than any string. Code that compared code with a string outside those, or typed a narrowed details itself, may need to change.
  • EventwolfApiError is now a type plus a constructor value rather than a class, so new EventwolfApiError(...) and instanceof EventwolfApiError still work, while class X extends EventwolfApiError no longer works.
  • New type exports: ErrorCode, ErrorDetails, ErrorDetailsOf, PublishRejectionDetails, EventwolfApiErrorCode, and EventwolfApiErrorConstructor.

Proprietary: use with Agentpost's hosted services under LICENSE.md.