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

@skillstew/common

v1.0.44

Published

A shared npm package containing event definitions used across all services. It defines the canonical event names, Zod payload schemas, and the `AppEvent` envelope type.

Readme

Common Package (@skillstew/common)

A shared npm package containing event definitions used across all services. It defines the canonical event names, Zod payload schemas, and the AppEvent envelope type.

Published to: npm (@skillstew/common)
Package Manager: npm
Version: patch-bumped on each publish via npm run pub

What It Exports

AppEvent<T>

The envelope type for all inter-service events:

interface AppEvent<T extends EventName> {
  eventId: string;
  eventName: T;
  timestamp: string; // ISO format
  producer: string; // service that emitted the event
  data: EventPayload<T>; // Zod-validated payload
  traceId?: string;
}

CreateEvent(eventName, data, producer, traceId?)

Factory function that builds an AppEvent with a random UUID and ISO timestamp.

EventSchemas

A single object mapping every event name to its Zod schema. Used by outbox workers to validate payloads before publishing, and by consumers to parse incoming events.

EventName / EventPayload<T>

Derived types — EventName is the union of all event name strings, and EventPayload<T> infers the payload type from the corresponding Zod schema.

Event Catalog

User Events

| Event Name | Payload Fields | | --------------------- | ------------------------------------------------------------------- | | user.registered | id, email | | user.verified | id | | user.profileUpdated | id, name?, username?, location?, languages?, avatarKey? |

Skill Events

| Event Name | Payload Fields | | ---------------------- | ---------------------------------------------------------- | | skill.created | id, name, normalizedName, alternateNames, status | | skill.updated | Same as skill.created | | skill.deleted | id | | skill.profileUpdated | userId, offered[{id, name}], wanted[{id, name}] |

Connection Events

| Event Name | Payload Fields | | ---------------------- | ----------------------------------------------------------------------------------------------------- | | connection.requested | connectionId, requesterId, requesterUsername?, recipientId, recipientUsername?, timestamp | | connection.accepted | connectionId, accepterId, accepterUsername?, requesterId, requesterUsername?, timestamp | | connection.rejected | connectionId, rejecterId, rejecterUsername?, requesterId, requesterUsername?, timestamp |

Adding a New Event

  1. Create or update a Zod schema in src/events/schemas/
  2. Add the event name → schema mapping to the schema group object (e.g., UserEventSchemas)
  3. The event name is automatically available in EventName, and the payload type is inferred from the schema
  4. Run npm run pub to patch-bump, build, and publish

Directory Structure

common/src/
├── index.ts                 # Re-exports everything
└── events/
    ├── AppEvent.ts           # AppEvent<T> interface
    ├── CreateEvent.ts        # Factory function
    ├── EventMap.ts           # EventSchemas, EventName, EventPayload<T>
    └── schemas/
        ├── userEventsSchema.ts              # user.registered, user.verified, user.profileUpdated
        ├── skillsEventSchemas.ts            # skill.created, skill.updated, skill.deleted, skill.profileUpdated
        └── userConnectionEventSchemas.ts    # connection.requested, connection.accepted, connection.rejected