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

@agentproto/secrets

v0.2.0

Published

@agentproto/secrets — AIP-19 SECRETS.md reference implementation. A workspace-level manifest format for declaring secret slugs, their purpose, access grants, and audit metadata — without ever storing the values themselves. Hosts resolve slugs against a re

Readme

@agentproto/secrets

AIP-19 SECRETS.md reference implementation. A workspace-level manifest format for declaring secret slugs, their purpose, access grants, and audit metadata — without ever storing the values themselves. Hosts resolve slugs against a real vault at reveal time.

Status: 0.1.0-alpha. Generated by scripts/scaffold-aip.mjsbuild() and validate() bodies are TODOs.

Spec: https://agentproto.sh/docs/aip-19

Usage

import { defineSecrets } from "@agentproto/secrets"

const x = defineSecrets({
  id: "my-secrets",
  description: "Short purpose.",
  // ...
})

Exposure surface (@agentproto/secrets/exposure)

The manifest says which secrets exist; an exposure says how a resolved secret reaches a runtime. SecretExposure is a discriminated union — one kind per delivery mechanism, so consumers filter with the isExposureKind guard and handle each with one switch case:

| kind | Delivers the secret as… | | --- | --- | | env | an environment variable on the agent process | | file | a file written into the workspace | | egress-substitute | a $$SECRET[NAME]$$ placeholder substituted on egress | | mcp-header | an HTTP auth header on an MCP server's transport |

import { isExposureKind, type SecretExposure } from "@agentproto/secrets/exposure"

const headerExposures = exposures.filter(e => isExposureKind(e, "mcp-header"))

mcp-header — brokered MCP auth

interface McpHeaderExposure {
  kind: "mcp-header"
  credentialPath: string   // broker path: "<providerId>" or "<providerId>/<account>"
  server?: string          // optional upstream override, forwarded to the broker
}

resolveMcpHeaderExposure(exposure, resolver, { signal }) turns that path into a ready-to-use header map. The resolver is a structural McpHeaderResolver (resolveHeaders({ path, server?, signal? })) — the CredentialBroker from @agentproto/auth satisfies it with no adapter, so this package stays dependency-free of auth while still driving it.

Every resolved header value is run through assertSafeSecretValue before return — a value containing CR/LF/NUL is rejected, closing off header-injection (a smuggled newline can't append extra header lines onto the transport).

import { resolveMcpHeaderExposure } from "@agentproto/secrets/exposure"
import { CredentialBroker } from "@agentproto/auth"

const headers = await resolveMcpHeaderExposure(exposure, broker, { signal })
// → { Authorization: "Bearer …" }, guarded

The same guard (assertSafeSecretValue) and the $$SECRET[NAME]$$ engine (substituteSecrets, SECRET_PLACEHOLDER_PATTERN, formatPlaceholder) are exported from this subpath for the egress-substitute path.

License

MIT — see LICENSE.