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

@degenai/cli

v0.6.3

Published

CLI for deGenAi Art — AI image & video generation paid via x402 (USDC on Base). Interactive menu + scriptable subcommands. Generate images (nano-banana, pro, seedream, gpt-image-2), videos (Veo 3, Grok), upscale, remove backgrounds, magic eraser.

Downloads

1,921

Readme

@degenai/cli

AI image generation, upscaling, and editing — paid per call in USDC on Base via x402. No accounts, no API keys, no signups. Just a Base wallet with USDC.

Install

npm install -g @degenai/cli

Requires Node.js 18+.

Quick start

# 1. Set a Base wallet (HOT wallet — fund with $5–10 only, never your main wallet)
export DEGENAI_PRIVATE_KEY=0x...                    # macOS / Linux
$env:DEGENAI_PRIVATE_KEY = "0x..."                  # Windows PowerShell

# 2. Verify setup, balances, and API reachability
degenai init

# 3. Generate — cheapest first
degenai generate -p "neon cyberpunk cat" --flow -m nano-banana -a 16:9 -o cat.png   # $0.005
degenai generate -p "neon cyberpunk cat" -o cat.png                                  # $0.015 (default)

That's it — payment, image, save. No further setup.

Two cheap paths

  • nano-banana or pro via the Flow path — $0.005 per image (cheapest). Add --flow plus -m nano-banana or -m pro, plus -a 16:9 / 9:16 / 4:3 / 3:4. Always 1K. The CLI validates these constraints before sending payment, so no USDC is spent on a misconfigured call.
  • gpt-image-2 — $0.015 per image (default). Plain degenai generate -p "…" with no extra flags hits gpt-image-2. Any aspect ratio, 1K.

Windows PowerShell users

If degenai --version prints UnauthorizedAccess / running scripts is disabled on this system, your PowerShell is blocking unsigned .ps1 shims that npm installs. Two options:

  • Use Git Bash / cmd / Windows Terminal with bash — the CLI works there with no changes.
  • Or unblock PowerShell once (per-user, safe):
    Set-ExecutionPolicy -Scope CurrentUser RemoteSigned

This is a Windows-wide policy, not a @degenai/cli issue — it affects all globally-installed npm CLIs the same way.

Hot-wallet warning

DEGENAI_PRIVATE_KEY is read on every command. Use a dedicated wallet with only enough USDC for what you intend to spend (a few dollars). Never paste your main / hardware-wallet private key. If the env var leaks (shell history, CI logs, malicious package), the funds in that wallet are lost.

Commands

degenai init

Setup check: validates DEGENAI_PRIVATE_KEY, derives your address, queries USDC + ETH balances on Base, and confirms the API is reachable.

degenai pricing

Lists current per-service pricing from the live API.

degenai generate

degenai generate -p "<prompt>" [--flow] [-m <model>] [-a <ratio>] [-r <res>] [-i <input>] [-o <out>]
  • --flow$0.005 path. Requires -m nano-banana or -m pro, and -a 16:9 / 9:16 / 4:3 / 3:4. Always 1K.
  • -m, --model — default gpt-image-2 ($0.015). Others: nano-banana ($0.05) · seedream ($0.10) · pro ($0.15) · gpt-image ($0.15)
  • -a, --aspectAuto (default), 1:1, 16:9, 9:16, 4:3, 3:4, …
  • -r, --resolution1K (default), 2K, 4K (4K only on pro; ignored on --flow)
  • -i, --image — input image for img2img; repeat flag for multiple inputs

degenai upscale

degenai upscale -i in.png -s 4 -o big.png        # 2x ($0.05) or 4x ($0.10)

degenai remove-bg

degenai remove-bg -i in.png -o transparent.png   # $0.02

degenai magic-eraser

degenai magic-eraser -i in.png -k mask.png -o out.png   # $0.02 (white in mask = erase)

Environment variables

| Variable | Required | Default | Purpose | |---|---|---|---| | DEGENAI_PRIVATE_KEY | yes (except pricing / init info) | — | Base wallet that pays via x402 | | DEGENAI_API_URL | no | https://aibasegen.vercel.app | Override API host (self-hosted / staging) | | BASE_RPC_URL | no | https://mainnet.base.org | Custom Base RPC for init balance checks |

How payment works

Each command opens an HTTPS request to the API, receives an HTTP 402 Payment Required response with payment requirements, signs an EIP-3009 USDC transferWithAuthorization with your private key, retries the request with the signed X-PAYMENT header, and the server settles on Base before returning your result. You only pay on success — settlement runs before the expensive AI work, and the response is HTTP-streamed back. Powered by @x402/fetch.

Web playground & alternatives

  • Browser (no CLI, no private key paste): https://aibasegen.vercel.app
  • MCP server (Claude / Cursor): coming soon

License

MIT