Quickstart
Start blocking disposable emails in under 60 seconds.
1
Install the package
Terminalbash
npm install @isdisposable/jsAlso works with yarn, pnpm, and bun.
2
Check an email
signup.tstypescript
import { isDisposable } from '@isdisposable/js';
if (isDisposable(email)) {
// Block the signup
throw new Error('Please use a real email address');
}isDisposable() is synchronous and returns a simple boolean. No async, no config, no API key needed.
3
That's it
Your signup flow now blocks 160,000+ known disposable email domains. No API calls, no latency, no cost.
Zero dependencies
The package bundles the entire domain list. It works offline, in serverless functions, edge runtimes, and anywhere Node.js runs.
Bulk checking
Need to check multiple emails at once? Use isDisposableBulk():
bulk.tstypescript
import { isDisposableBulk } from '@isdisposable/js';
const results = isDisposableBulk([
'user@mailinator.com',
'real@gmail.com',
'temp@guerrillamail.com'
]);
// results: [true, false, true]Upgrade to the API
The free package catches known domains. The Pro API catches new disposable services using real-time DNS analysis, risk scoring, and domain age detection.
api-mode.tstypescript
import { createIsDisposable } from '@isdisposable/js';
const checker = createIsDisposable({
apiKey: 'isd_live_xxxxx'
});
const result = await checker.check('test@suspicious-domain.com');
// {
// disposable: true,
// score: 87,
// reason: "suspicious_mx",
// mx_valid: true,
// domain_age_days: 3,
// ...
// }API key required
Get your API key from the dashboard. The Pro plan starts at $9/month with 10,000 checks.