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

opentest.live

v1.1.0

Published

AI-powered API testing CLI that analyzes your codebase, discovers routes, handles OTP verification, and generates intelligent test cases automatically

Readme

OpenTest.live CLI

AI-powered API testing that analyzes your codebase, discovers routes, infers schemas, and generates intelligent test cases automatically.

npm version License: MIT


🚀 Quick Start

Run this one command in your API project directory:

npx opentest.live launch

That's it! The CLI will:

  • ✅ Analyze your codebase and discover all API routes
  • ✅ Infer request/response schemas with high accuracy
  • ✅ Open https://opentest.live in your browser
  • ✅ Import all endpoints to your workspace
  • ✅ Watch for code changes in real-time

📦 Installation

Option 1: Use with npx (Recommended)

No installation needed:

cd /path/to/your-api-project
npx opentest.live launch

Option 2: Global Installation

npm install -g opentest.live
opentest launch

✨ Features

🔍 Intelligent Route Discovery

  • Automatically scans your codebase for API endpoints
  • Supports Express, Fastify, Koa, Hapi, and more
  • Detects route prefixes from server.js mounting
  • Discovers both controller-based and inline handlers

🧠 Smart Schema Inference

Extracts schemas with confidence scoring (0-1.0):

  1. Zod validators (0.95 confidence) - z.object({ ... })
  2. Joi validators (0.9 confidence) - Joi.object({ ... })
  3. express-validator (0.9 confidence) - body('email').isEmail()
  4. Code analysis (0.6 confidence) - Infers from req.body usage
  5. Heuristics (0.5 confidence) - Common auth patterns only

Features:

  • ✅ Follows imports across files (resolves import { schema } from './validators')
  • ✅ Detects multipart/form-data (file uploads)
  • ✅ Infers response shapes from res.json() calls
  • ✅ Parses inline route handlers
  • ✅ Fails closed (returns null instead of inventing fields)

🔐 Authentication Detection

  • Auto-discovers login, signup, OTP verification endpoints
  • Marks protected routes requiring authentication
  • Generates auth headers in cURL commands

📡 Real-Time Sync

  • Watches your codebase for changes
  • Auto-updates the web dashboard when routes/schemas change
  • No manual re-import needed

🎨 Beautiful cURL Generation

# JSON endpoint
curl -X POST https://api.example.com/auth/login \
  -H "Content-Type: application/json" \
  -d '{"email":"[email protected]","password":"your_password"}'

# File upload (auto-detected)
curl -X POST https://api.example.com/upload \
  -F "file=@/path/to/file" \
  -F "description=My upload"

📚 Usage Examples

Basic Usage (Current Directory)

npx opentest.live launch

Analyze Specific Directory

npx opentest.live launch --dir ./backend

Verbose Logging (Debug)

npx opentest.live launch --verbose

Local Development (Custom URLs)

npx opentest.live launch \
  --backend http://localhost:2003 \
  --frontend http://localhost:3002

🎯 How It Works

1. Codebase Analysis (2-5 seconds)

The CLI scans your project:

  • Parses server.js to find route mounting points
  • Discovers route files (*Routes.js, *Controller.js)
  • Extracts HTTP methods, paths, handlers

2. Schema Extraction

For each route, the CLI:

  • Checks for Zod/Joi/express-validator schemas
  • Follows imports to find schema definitions
  • Parses controller code for req.body usage
  • Infers response shapes from res.json() calls
  • Assigns confidence score based on extraction method

3. Browser Launch & Auth

  • Opens https://opentest.live/launch?session=<id>
  • You login/signup on the web interface
  • Your workspace ID is sent to the CLI automatically

4. Import & Sync

  • All discovered endpoints imported to your workspace
  • Each endpoint includes:
    • HTTP method, path, description
    • Request schema (params, query, body, headers)
    • Response schema
    • cURL example
    • Confidence score and schema source
  • CLI watches for file changes and syncs updates

📊 Schema Confidence Levels

Each endpoint includes metadata:

{
  "path": "/api/v1/users",
  "method": "POST",
  "requestSchema": { "body": { ... } },
  "meta": {
    "source": "zod",
    "confidence": 0.95
  }
}

Confidence Guide

| Confidence | Source | Meaning | |------------|--------|---------| | 0.95-1.0 | zod, joi | ✅ Explicit validator - highly accurate | | 0.9 | express-validator | ✅ Validator chain - very accurate | | 0.6-0.8 | body-reads, inline-handler | ⚠️ Inferred from code - good accuracy | | 0.5-0.59 | heuristic | ℹ️ Pattern-based - auth endpoints only |


🛠️ Supported Frameworks

  • Express.js (fully supported)
  • Fastify (supported)
  • Koa (supported)
  • Hapi (supported)
  • 🚧 NestJS (coming soon)
  • 🚧 Next.js API Routes (coming soon)

🔧 Configuration

CLI Options

| Option | Description | Default | |--------|-------------|---------| | -d, --dir <directory> | Directory to analyze | Current directory | | -b, --backend <url> | Backend API URL | https://flux-backend-production-ca39.up.railway.app | | -f, --frontend <url> | Frontend URL | https://opentest.live | | -v, --verbose | Enable verbose logging | false |

Environment Variables

# Override default URLs
export OPENTEST_BACKEND_URL=https://flux-backend-production-ca39.up.railway.app
export OPENTEST_FRONTEND_URL=https://opentest.live

📖 Documentation


🐛 Troubleshooting

"Session not found"

Cause: Session expired (5 minute timeout)
Solution: Run npx opentest.live launch again

"No routes found"

Cause: CLI couldn't find route definitions
Solution:

  • Ensure you're in the project root directory
  • Check that route files follow naming conventions (*Routes.js, *Controller.js)
  • Use --verbose to see what files are being scanned

Browser doesn't open

Cause: System couldn't launch default browser
Solution: Copy/paste the URL from the terminal

Low schema confidence

Cause: No explicit validators found
Solution: Add Zod, Joi, or express-validator to your routes for higher accuracy


🤝 Contributing

We welcome contributions! Please see CONTRIBUTING.md for guidelines.


📝 License

MIT © OpenTest.live


🙏 Acknowledgments

Built with:


📧 Support


Made with ❤️ by the OpenTest.live team