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

@softsquirrel/mailcaptcha

v1.0.3

Published

A Captcha that makes everything easier!

Downloads

75

Readme

mailCaptcha

mailCaptcha is a Nodejs library that helps people by using a captcha! Just install, learn, and code!

how it works

So basically it uses Nodemailer and a random number generator to send a random 6 digit code to the user. No, it does not send your passwords and account data to me!, feel free to inspect the code!

Recent Updates - 1.0.3

  • Added Support For Custom Subjects
  • Added Support For HTML messages only!

Upcoming Updates

  • No upcoming updates, we could use some feedback in the issues section!

Credits

  • Me.

How to use!

Almost forgot! So here is the how to use it:

Install/require

var verify = require('@softsquirrel/mailcaptcha')

Require readline Require readline to use as input, you can also use other methods of input besides prompt or alert, they will not work

const readline = require("readline");
const rl = readline.createInterface({
 input: process.stdin,
 output: process.stdout
});

Make the functions to see to deal with if the user entered the code in correctly These functions will be executed wether the user entered the code correctly or not

function correct() {
  console.log('Verified!')
}
function incorrect() {
  console.log('Incorrect Code')
}

Authorize ourselves with Google Go enable less secure apps here for this to work

verify.authentication("Your Email", "Your Password");  /*REMEBER TO ENABLE LESS SECURE APPS*/

Ask the user their Email, and send the code Use readline to ask the user for their email, to do this, use the verify.sendCode to send the code!

rl.question("Enter your email:", ans => {
  verify.sendCode(ans)
}

Ask the user to enter the code they recieved Here, we use readline to see if the user entred the code in correctly, then it will execute one of the 2 functions.

rl.question("Enter your email:", ans => {
  verify.sendCode(ans)
  rl.question("Enter the Code we sent you :", ans => {
    verify.verify(ans, correct, incorrect)
  })
})

Run the code and you are done!

Functions

verify.authentication(yourEmail, yourPassword)

Use this code to authenticate the account that will send the code! To do this you must also turn off less secure apps here.

================================================================

verify.sendCode(target)

Replace target with a valid email adress to send the code.

================================================================

verify.verify(Code, correct, incorrect)

Ok, so the computer will look at the Code paramter and check if it matches the code sent. The correct parameter is actually a function. if the code matches the code sent, then this function will get executed. Same thing for the incorrect function except that will get executed if the code sent does not match the one the user put in.

================================================================

verify.createCode(customCode)

Just replace the customCode parameter with a variable! Use it like this:

verify.createCode("myCode") //Create the code
verify.verify(code) //Verifies the code! If you do not use the customCode function, it will just give you a random 6 digit code

================================================================

verify.message(message)

Now you can add custom messages! Here is how to use it:

verify.message("Hello! Here is your verification code: --CODE--")

When the message is sent, it will replace --CODE-- with the code! If you do not want a custom message, just dont call the message function! And we recently added HTML support! If you can, you can send an HTML file!

================================================================ verify.subject(subject) Like the one above, this works the same Except its for email subjects! Just replace the subject parameter with your email subject!

Known Bugs

  • No known bugs!

If you notice any bugs, report it to bugs! You can also send feedback in the issues section!

Our Website