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

jetend

v1.0.4

Published

A lightweight backend toolkit to simplify and accelerate backend development — just like Tailwind, but for backend.

Readme

npm version npm downloads License: MIT

Jetend simplifies backend development with one-liner utilities for routing, database operations (SQL + MongoDB), authentication, validation, responses, and email sending. Think of it as a toolbox for Express developers who want to move fast without reinventing the wheel.


✨ Features

  • ⚡ Minimal routing (get, post, patch, del)
  • 🌱 Start a server with one line (start(port))
  • 🗄️ Database utilities for SQL and MongoDB
  • 🔐 Authentication helpers (bcrypt + JWT)
  • ✅ Request validation with simple rules
  • 📦 Consistent success/error responses
  • 📧 Built-in email sending (Gmail SMTP ready)
  • 🔌 Works seamlessly with Express.js

📦 Installation

npm install jetend

🚀 Quick Start

import { get, post, start } from "jetend";

// Basic routing
get("/hello", ({ res }) => {
  res.json({ message: "Hello from Jetend 🚀" });
});

post("/data", ({ req, res }) => {
  res.status(201).json(req.body);
});

// Start the server
start(3000);
// 🚀 Jetend server running at http://localhost:3000

Run your server with Express, and Jetend plugs right in.


📚 Usage Guide

1. Starting the Server

You can quickly spin up a local server using the start(port) method. Simply pass the desired port number to start listening for incoming requests.

import { start } from "jetend";

const PORT = 3000;
start(PORT); // 🚀 Jetend server running at http://localhost:3000

2. Routing

import { get, post, patch, del } from "jetend";

get("/users", ({ res }) => res.json(users));
post("/users", ({ req, res }) => res.status(201).json(req.body));
patch("/users/:id", ({ req, res }) => res.json({ updated: req.params.id }));
del("/users/:id", ({ req, res }) => res.json({ deleted: req.params.id }));

3. Database

SQL

import db from "jetend";

await db.sql.connect({
  host: "localhost",
  user: "root",
  database: "test",
  password: "1234",
});

const users = await db.sql.query("SELECT * FROM users");

MongoDB

await db.mongo.connect("mongodb://127.0.0.1:27017/test");

const User = db.mongo.model("User", { name: String, email: String });

// CRUD
await db.mongo.create(User, { name: "Alice" });
await db.mongo.read(User, { name: "Alice" });
await db.mongo.update(User, { _id }, { email: "[email protected]" });
await db.mongo.delete(User, { _id });

4. Authentication

import {
  hashPassword,
  comparePassword,
  generateJWT,
  requireAuth,
} from "jetend";

const JWT_SECRET = process.env.JWT_SECRET || "supersecret";

// Signup
const passwordHash = await hashPassword("mypassword");
await db.mongo.create(User, { username, password: passwordHash });

// Login
const ok = await comparePassword(password, user.password);
if (!ok) return error(res, "Invalid credentials", 401);

const token = generateJWT({ id: user._id }, JWT_SECRET, { expiresIn: "2h" });
res.json({ token });

// Protected Route
get("/me", requireAuth(JWT_SECRET), ({ req, res }) => {
  res.json({ user: req.user });
});

5. Validation

import { validate } from "jetend";

validate(req.body, {
  name: "string|required|min:3|max:10",
  email: "email|required",
  password: "string|min:8",
});

6. Responses

import { success, error } from "jetend";

return success(res, "User created", user, 201);
return error(res, "User not found", 404);

7. Email Sending

import { sendEmail } from "jetend";

await sendEmail(
  process.env.EMAIL, // sender
  process.env.APP_PASSWORD, // app password
  "[email protected]",
  "Welcome to Jetend 🚀",
  "<h1>Hello World</h1>",
);