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

@wanglinsaputra/tempmail-wrapper

v1.2.0

Published

Unified Node.js wrapper for 16 temporary email services. Zero deps, native fetch.

Readme

📦 JavaScript — TempMail Unofficial Wrappers

JavaScript/Node.js wrapper for 16 temporary email services. Zero API keys. Native fetch.

Prerequisites

  • Node.js 18+ (uses native fetch, zero dependencies)

Installation

npm install tempmail-wrapper

Local (dev / monorepo):

npm install ./path/to/tempmail-wrapper

Environment Setup

Copy .env.example to .env and fill in your values:

cp .env.example .env

| Variable | Required | Description | |----------|:---:|-------------| | RESEND_API_KEY | For E2E tests | Resend API key for test email delivery. Get at resend.com. |

Quick Start

import { createProvider } from 'tempmail-wrapper';

const client = createProvider('mail.tm');
const email = await client.generateEmail();
console.log(email);

const msg = await client.waitForEmail(email);
if (msg) {
  const detail = await client.readMessage(`${msg.id}:${email}`);
  console.log(detail.subject, detail.bodyText);
}

Dropmail Captcha Solver Chain

Dropmail requires solving a captcha to create sessions. You can provide a chain of solver functions — each is tried in order until one returns text.

Default: Built-in PaddleOCR via HuggingFace space (no config needed).

import { Dropmail, paddleOcrSolver } from 'tempmail-wrapper/providers';
import { writeFileSync } from 'fs';
import { createInterface } from 'readline';

// Default: uses PaddleOCR via HuggingFace
const dropmailDefault = new Dropmail();

// Manual solver: show image, user types text
async function manualSolver(imgBytes) {
  writeFileSync('captcha.png', Buffer.from(imgBytes));
  const rl = createInterface({ input: process.stdin, output: process.stdout });
  return new Promise(resolve => {
    rl.question('Enter captcha text: ', text => {
      rl.close();
      resolve(text);
    });
  });
}

// External service (e.g., 2captcha)
async function externalSolver(imgBytes) {
  // Upload to 2captcha API, wait for result
  // Return the solved text or null on failure
  return null;
}

// Chain: try external first, then PaddleOCR, then manual
const dropmail = new Dropmail({
  solvers: [externalSolver, paddleOcrSolver, manualSolver]
});

Each solver receives the captcha image as Uint8Array and returns string | null. Return null to pass to the next solver in the chain.

Supported Providers

v1.0.0 Providers (5)

| Provider | Factory Name | Requires API Key | Notes | |----------|:---:|:---:|:---:| | Mail.tm | mail.tm | No | Account-based | | GuerrillaMail | guerrillamail | No | Session cookies | | YOPmail | yopmail | No | HTML scraping | | Dropmail.me | dropmail | No | GraphQL | | 1secemail | 1secemail | No | REST API |

v1.1.0 Providers (11)

| Provider | Factory Name | Requires API Key | Notes | |----------|:---:|:---:|:---:| | emailfake | emailfake | No | HTML scraping, surl cookie | | generator.email | generator.email | No | HTML scraping, surl cookie | | email-temp.com | email-temp | No | HTML scraping, surl cookie | | zoromail | zoromail | No | REST API | | tempmail.lol | tempmail.lol | No | REST API, token-based | | tempmailc | tempmailc | No | REST API | | temp-mail.io | temp-mail.io | No | REST API, Bearer token | | tempmail.plus | tempmail.plus | No | REST API, email query | | mailnesia | mailnesia | No | HTML scraping (rate-limited) | | 10minutemail | 10minutemail | No | REST API, cookie session | | ncaori | ncaori | No | REST API (nca.my.id) |

API Reference

Interface / Contract

Factory: createProvider(name, config?) returns a TempMailProvider instance.

| Method | Returns | Description | |--------|---------|-------------| | generateEmail() | Promise<string> | Create a new temp address | | getInbox(email) | Promise<Message[]> | List messages | | readMessage(id) | Promise<MessageDetail> | Read full message | | deleteEmail(email) | Promise<boolean> | Delete the address | | waitForEmail(email, timeoutMs?, intervalMs?) | Promise<Message \| null> | Poll for first message |

Data Models

  • Message: { id, sender, subject, date }
  • MessageDetail (extends Message): { bodyText, bodyHtml, attachments }

Errors

  • TempMailError — base error
  • RateLimitError — 429, has .retryAfterMs
  • NotFoundError — 404

Running Tests

node --test tests/e2e.test.js

Real HTTP calls against live APIs. No mocks. See TEST_REPORT.md for latest results.

E2E tests use Resend API to send test emails. Set RESEND_API_KEY in .env before running.

Examples

See examples/ directory.

Links

License

Apache License 2.0 — see ../LICENSE and ../NOTICE.