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

@renjfk/opencode-secret-tools

v0.1.1

Published

Configurable secret bridge for OpenCode. Provides list_secrets, get_secret, and clear_secret tools that shell out to any CLI-based secret store with automatic redaction.

Downloads

26

Readme

CI License: MIT npm Downloads

opencode-secret-tools

Configurable secret bridge for OpenCode.

Provides list_secrets, get_secret, and clear_secret tools that shell out to any CLI-based secret store. After a secret is loaded into the environment, a tool.execute.after hook redacts its value from all subsequent tool outputs before they reach the LLM.

Install

Add to your OpenCode config at ~/.config/opencode/config.json:

{
  "plugin": ["@renjfk/opencode-secret-tools"]
}

Configuration

{
  "plugin": [
    [
      "@renjfk/opencode-secret-tools",
      {
        "folder": "Secrets",
        "listCmd": ["rbw", "list", "--fields", "name,folder"],
        "getCmd": ["rbw", "get", "--folder", "Secrets", "{name}"]
      }
    ]
  ]
}

Options

| Option | Required | Description | | --------- | -------- | ----------------------------------------------------------------------------------------- | | listCmd | Yes | Command returning secret names. One per line, or TSV name\tfolder when folder is set. | | getCmd | Yes | Command returning the secret value. {name} is replaced at runtime. | | folder | No | Filter listCmd output to this folder. If omitted, every line is treated as a name. |

Tools

  • list_secrets({}) — run listCmd, parse and filter, return names.
  • get_secret({ name }) — run getCmd with {name} replaced, inject into process.env, track value for redaction.
  • clear_secret({ name }) — delete from process.env, stop tracking.

How it works

  1. User configures listCmd and getCmd for their vault CLI (e.g. rbw, op, gopass).
  2. list_secrets runs listCmd, parses the output (optionally filtering by folder), and returns names.
  3. get_secret runs getCmd with {name} replaced, injects the value into process.env, and tracks it for redaction.
  4. tool.execute.after replaces tracked values with [REDACTED: {name}] in output, title, and metadata of all tools except list_secrets.
  5. clear_secret removes the env var and stops tracking.
  6. Values shorter than 4 characters are not redacted to avoid false positives.

Contributing

opencode-secret-tools is open to contributions and ideas!

Issue conventions

Format: type: brief description

  • feat: new features or functionality
  • fix: bug fixes
  • enhance: improvements to existing features
  • chore: maintenance tasks, dependencies, cleanup
  • docs: documentation updates
  • build: build system, CI/CD changes

Development

npm run test         # node --test
npm run check        # lint + fmt
npm run lint         # oxlint
npm run fmt          # oxfmt --check
npm run fmt:fix      # oxfmt --write

Test local plugin in OpenCode

To test unpublished changes in the OpenCode TUI, point ~/.config/opencode/config.json at the local repo path, not the npm package name:

{
  "plugin": ["/Users/your-user/opencode-secret-tools/index.js"]
}

Release process

Manual releases via opencode; see RELEASE_PROCESS.md.

License

This project is licensed under the MIT License.