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

@vigilkids/identity-session

v0.1.2

Published

Product-neutral identity session contracts and server-side session engine

Readme

@vigilkids/identity-session

Product-neutral identity-session contracts and a server-only opaque session engine.

The default export contains browser-safe session, principal, action, and command types. It cannot read or write credentials. Server applications import @vigilkids/identity-session/server and provide four narrow ports for authentication, guest identity, challenges, and account profiles.

import { IdentitySessionEngine } from '@vigilkids/identity-session/server'

const engine = new IdentitySessionEngine({
  productCode: 'alpha',
  clientId: 'alpha-web',
  absoluteTtlMilliseconds: 86_400_000,
  idleTtlMilliseconds: 1_800_000,
  preAuthenticatedTtlMilliseconds: 1_800_000,
  refreshBeforeMilliseconds: 120_000,
  transitionLockTtlMilliseconds: 5_000,
  guestCapabilityPolicy,
  admission,
  cipher,
  repository,
  ports: {
    authentication,
    guest,
    challenge,
    account,
  },
})

Session projections expose only identity state and a stable principal. Product subscriptions, entitlements, credits, devices, and content access belong to a separate product-owned Viewer endpoint.

Guest capability issuance is persisted before the external request, retries reuse the same idempotency key, credentials remain AEAD-sealed, and every credential transition uses repository CAS and rotation.

Server adapters can call refreshAuthorization after a trusted downstream Bearer boundary rejects the current access token. A successful refresh rotates both credentials and the opaque locator. Terminal authentication rejection deletes local authority and requires browser cookie clearing; transient transport, rate-limit, storage, and refresh-lock failures preserve refresh authority. terminateAuthorization provides the matching fail-closed operation when a trusted caller confirms that authorization is no longer usable.