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

@upstash/box-cli

v0.1.4

Published

CLI for Upstash Box — REPL-first interface for AI coding agents

Readme

@upstash/box-cli

REPL-first CLI for Upstash Box — create and interact with sandboxed AI coding agents from the terminal.

Installation

npm install -g @upstash/box-cli

Or run directly from the monorepo:

pnpm build
node packages/cli/dist/index.js --help

Authentication

Provide your Upstash Box API token via the --token flag or the UPSTASH_BOX_API_KEY environment variable:

export UPSTASH_BOX_API_KEY=abx_...

Commands

box create

Create a new box and enter an interactive REPL.

box create \
  --agent-model claude/sonnet_4_5 \
  --agent-api-key $CLAUDE_KEY \
  --runtime node \
  --git-token $GITHUB_TOKEN \
  --env NODE_ENV=production \
  --env DEBUG=true

| Flag | Description | | ----------------- | ------------------------------------------------------------------------ | | --token | Upstash Box API token | | --runtime | Runtime environment (node, python, golang, ruby, rust) | | --agent-model | Agent model identifier | | --agent-api-key | Agent API key — Anthropic or OpenAI (required if --agent-model is set) | | --git-token | GitHub personal access token | | --env KEY=VAL | Environment variable (repeatable) |

box connect [box-id]

Connect to an existing box and enter the REPL. If no box ID is given, connects to the most recent box.

box connect box_abc123
box connect  # connects to most recent

box from-snapshot <snapshot-id>

Create a new box from a snapshot and enter the REPL. Accepts the same flags as create.

box from-snapshot snap_abc123 \
  --agent-model claude/sonnet_4_5 \
  --agent-api-key $CLAUDE_KEY

box list

List all boxes.

box list

box get <box-id>

Print box details as JSON.

box get box_abc123

box init-demo

Scaffold a standalone demo project that uses the @upstash/box SDK. Creates a directory with a ready-to-run TypeScript script, .env file, and README.

box init-demo \
  --token $UPSTASH_BOX_API_KEY \
  --agent-model claude/sonnet_4_5 \
  --agent-api-key $CLAUDE_KEY \
  --runtime node \
  --git-token $GITHUB_TOKEN \
  --directory my-demo

| Flag | Description | Default | | ----------------- | -------------------------------------------------- | ---------- | | --token | Upstash Box API token | | | --agent-model | Agent model identifier | | | --agent-api-key | Agent API key (required if --agent-model is set) | | | --runtime | Runtime environment | node | | --git-token | GitHub personal access token | | | --directory | Output directory | box-demo |

After scaffolding, the command offers to run the demo immediately. The generated project includes:

  • main.ts — demo script that creates a box, writes/reads files, executes commands, and cleans up
  • .env — pre-filled environment variables
  • README.md — usage documentation

Interactive REPL

After create, connect, or from-snapshot, you enter an interactive REPL session:

Connected to box box_abc123
Type a prompt to run the agent, or use commands: run, exec, files, git, snapshot, pause, delete, exit

box_abc123> Fix the bug in auth.ts

REPL commands

Any text entered is sent to the agent by default. You can also use explicit commands (with or without a / prefix):

| Command | Description | | ------------------------------ | ---------------------------------------------- | | run <prompt> | Run the agent with a prompt (streaming output) | | exec <command> | Execute a shell command in the box | | files read <path> | Read a file | | files write <path> <content> | Write a file | | files list [path] | List files in a directory | | files upload <local> <dest> | Upload a local file | | files download [path] | Download files from the box | | git clone <repo> [branch] | Clone a repository | | git diff | Show git diff | | git create-pr <title> | Create a pull request | | snapshot [name] | Save a snapshot of the current state | | pause | Pause the box and exit | | delete | Delete the box and exit | | exit | Exit the REPL (box keeps running) |

Examples

box_abc123> Add error handling to the payment service
box_abc123> exec npm test
box_abc123> files list src/
box_abc123> git diff
box_abc123> snapshot before-refactor
box_abc123> exit

License

MIT