Skip to main content

disposable-emails

Weed out disposable email providers with ease 🚀

Installation

You can install this package using PyPI:

pip3 install disposable-emails

There are no dependencies. You don't need Django, Flask or any third-party API.

How to use

Check an email:

>>> from disposable_emails import is_disposable_email
>>> is_disposable_email('john.smith@mailforspam.com')
True
>>> is_disposable_email('john.smith@gmail.com')
False

Check a domain:

>>> from disposable_emails import is_disposable_domain
>>> is_disposable_domain('temp-mail.com')
True
>>> is_disposable_domain('kremlin.ru')
False

Using Django? There is a form validator which you can use with forms:

from django import forms
from disposable_emails.contrib.django import disposable_validator

class FooForm(forms.Form):
    email = forms.EmailField(
        label="Email",
        max_length=254,
        validators=[disposable_validator]
    )

And with models:

from django import models
from disposable_emails.contrib.django import disposable_validator

class FooModel(models.Model):
    email = models.EmailField(validators=[disposable_validator])

Credits

This package uses disposable by @andreis as a source of disposable email services.

Contributions

Code contributions are welcome! Just drop a pull request.

Metadata

Release files for disposable-emails 1.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for disposable-emails 1.1.0
File Size Uploaded Provenance Actions
disposable-emails-1.1.0.tar.gz 818.1 kB Without provenance Details for disposable-emails-1.1.0.tar.gz

Release files / disposable-emails-1.1.0.tar.gz

Download URL disposable-emails-1.1.0.tar.gz
Size 818.1 kB
Tags Source
SHA-256 checksum
How to use checksums
3961a9b7c764ee2e2fc97b4671fbe92389e5d6ecfaf28a57792605412e374ed2
BLAKE2b-256 checksum
How to use checksums
9b30f89efba4108f5cbd5421c429c4d9a15f009ea51bbc2304000e7e0eb42321
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.13

Security for disposable-emails 1.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page