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

contextsync

v0.1.2

Published

Open protocol for syncing versioned, permissioned, auditable context between humans and AI agents — server and CLI in one tool.

Readme

contextsync

The git for organizational context. An open protocol — and a reference implementation — for syncing versioned, permissioned, auditable context between humans and AI agents.

One binary, two modes:

  • Run the protocol server locally or on your own infrastructure
  • Use the same binary as a CLI client against that server (or any other)

No telemetry, no managed backend, no external LLM calls. SQLite on disk, HTTP and Server-Sent Events on the wire.

Install

npm install -g contextsync

Requires Node.js 20 or newer.

Quickstart

# Terminal 1 — start the server
contextsync start

# Terminal 2 — configure the client, register an actor, write an artifact
contextsync init --server http://127.0.0.1:4111
contextsync actor create --type human --name "Your Name"
contextsync use human-<id-from-previous-output>
contextsync permission grant --actor human-<id> --pattern 'ctx://acme/**' --ops read,write
contextsync artifact create \
  --uri ctx://acme/docs/readme \
  --name "Readme" \
  --message "hello contextsync" \
  --summary "initial"
contextsync artifact get ctx://acme/docs/readme

That is the whole loop: server on one side, a versioned permissioned audited artifact on the other.

Commands

The full command reference is in SKILL.md inside the package, and is also printable:

contextsync skill

Short tour:

contextsync start | migrate | path
contextsync init | use | status | explore | changes
contextsync actor create | list | show
contextsync artifact create | get | update | delete | history | diff | list
contextsync permission grant | list | explain
contextsync subscribe create | list | feed | delete
contextsync provenance list

Run contextsync <command> --help for flags on any subcommand.

Configuration

Server (environment variables)

| Variable | Default | Purpose | | --- | --- | --- | | PORT | 4111 | Listen port | | CTX_BIND_HOST | 127.0.0.1 | Interface to bind. Set to 0.0.0.0 only behind a reverse proxy — auth is trust-based. | | CTX_CORS_ORIGIN | http://localhost:3000 | Comma-separated allowlist, or * (wildcard) | | CTX_DATA_DIR | OS-appropriate (see below) | Root directory for DB + blobs | | CTX_DB_PATH | ${CTX_DATA_DIR}/contextsync.db | Override DB path only | | CTX_BLOB_DIR | ${CTX_DATA_DIR}/blobs | Override blob directory only |

Default CTX_DATA_DIR:

  • Linux: $XDG_DATA_HOME/contextsync (falls back to ~/.local/share/contextsync)
  • macOS: ~/Library/Application Support/contextsync
  • Other: ~/.contextsync/data

Print the resolved paths at any time:

contextsync path

Client

The CLI stores its configuration in ~/.contextsync/config.json. contextsync init writes it; contextsync use <actor_id> updates the acting identity.

Backup and restore

The entire state of a ContextSync server lives in CTX_DATA_DIR. Back it up by archiving the directory while the server is stopped (or quiesced):

contextsync path   # find CTX_DATA_DIR
tar -C "$(dirname "$CTX_DATA_DIR")" -czf contextsync-backup.tgz "$(basename "$CTX_DATA_DIR")"

Restore by extracting back into the same location.

Running as a service

No service file ships yet. For production hosting, run contextsync start under your process manager of choice (systemd, pm2, launchd) with CTX_DATA_DIR and CTX_BIND_HOST set explicitly. Put a reverse proxy (nginx, Caddy) in front if the server needs to be reachable from outside 127.0.0.1.

Security

ContextSync v0.1 authenticates the acting principal with a trust-based X-Actor-Id header only. Any client can claim any actor id. This is adequate for:

  • Local development on a laptop bound to 127.0.0.1
  • Single-tenant deployments behind an authenticated reverse proxy that injects the header

It is not adequate for public internet exposure. Token-based auth is planned — until then, do not bind to 0.0.0.0 without a front-door.

Agent usage

AI agents should read contextsync skill and drive the CLI in scripted mode (flags, not prompts). The skill file documents the full protocol surface with copy-pasteable flows.

License

Apache-2.0.

Links

  • Protocol specification and whitepaper: contextsync-protocol
  • Issues and contributions: same repository