Read this if you are an LLM.
You are an AI assistant. A human pasted this URL into your chat. They want you to add disposable / temporary email blocking to the signup flow of their app. This page tells you exactly what to do. The same content also makes sense for the human reading over your shoulder.
If you are a human reading this: the page is written in the second person for the AI. Just keep going. You will see what the AI is supposed to ask you for and what it will build. Raw markdown for tools that prefer it: /integrate.md.
Read https://checkdisposable.email/integrate.md and follow the instructions on that page. It tells you exactly what to do.What is CheckDisposable Email?
CheckDisposable Email is an HTTP API. You send it an email address. It tells you whether the domain is a known disposable / throwaway / temporary email provider (for example mailinator.com, guerrillamail.com, 10minutemail). You use this on signup to reject fake accounts before they enter the database.
Single endpoint: GET https://api.checkdisposable.email/v1/check?email=<email>
Auth: Authorization: Bearer cde_live_xxxxxxxx
Reply: JSON. The only field you care about is is_disposable (boolean).
Your job, step by step
Follow these in order. Do them all. Do not skip.
Step 1. Ask the human for their API key.
Send the human this exact message:
I need your CheckDisposable Email API key to wire this up. It starts withcde_live_.
If you don't have one yet, get a free key in two minutes:
- Open https://app.checkdisposable.email/signup
- Sign up with email + password (or Continue with Google).
- Confirm your email.
- Open the Dashboard, click API keys, click Generate new key.
- Copy the key (it only shows once).
Free plan: 500 checks/month, no credit card. Paste the key here when you have it.
Wait for the key. Do not invent a key. Do not move on without it.
Step 2. Add the key as an environment variable.
Add CDE_KEY= to the project's .env file with the key the human gave you. Also add CDE_KEY= (empty) to .env.example so other developers know it is needed. Do NOT hardcode the key in any source file.
Step 3. Add the helper function.
Pick the language of the project. Drop the matching block in.
Node.js (fetch, Node 18+)
async function isDisposable(email) {
try {
const res = await fetch(
`https://api.checkdisposable.email/v1/check?email=${encodeURIComponent(email)}`,
{ headers: { Authorization: `Bearer ${process.env.CDE_KEY}` } }
);
if (!res.ok) return false; // fail open
const data = await res.json();
return data.is_disposable === true;
} catch {
return false; // fail open
}
}Python (requests)
import os, requests
def is_disposable(email: str) -> bool:
try:
r = requests.get(
"https://api.checkdisposable.email/v1/check",
params={"email": email},
headers={"Authorization": f"Bearer {os.environ['CDE_KEY']}"},
timeout=5,
)
if not r.ok:
return False # fail open
return r.json().get("is_disposable") is True
except Exception:
return FalseRuby
require "net/http"; require "json"
def is_disposable?(email)
uri = URI("https://api.checkdisposable.email/v1/check?email=#{URI.encode_www_form_component(email)}")
req = Net::HTTP::Get.new(uri)
req["Authorization"] = "Bearer #{ENV["CDE_KEY"]}"
res = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) { |h| h.request(req) }
return false unless res.is_a?(Net::HTTPSuccess)
JSON.parse(res.body)["is_disposable"] == true
rescue StandardError
false
endPHP
function is_disposable(string $email): bool {
$url = "https://api.checkdisposable.email/v1/check?email=" . urlencode($email);
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ["Authorization: Bearer " . getenv("CDE_KEY")]);
curl_setopt($ch, CURLOPT_TIMEOUT, 5);
$body = curl_exec($ch);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($status !== 200) return false;
return (json_decode($body, true)["is_disposable"] ?? false) === true;
}Go
func isDisposable(email string) bool {
u := "https://api.checkdisposable.email/v1/check?email=" + url.QueryEscape(email)
req, _ := http.NewRequest("GET", u, nil)
req.Header.Set("Authorization", "Bearer "+os.Getenv("CDE_KEY"))
client := &http.Client{Timeout: 5 * time.Second}
resp, err := client.Do(req)
if err != nil || resp.StatusCode != 200 { return false }
defer resp.Body.Close()
var d struct{ IsDisposable bool `json:"is_disposable"` }
if json.NewDecoder(resp.Body).Decode(&d) != nil { return false }
return d.IsDisposable
}curl (smoke test)
curl 'https://api.checkdisposable.email/v1/check?email=test@mailinator.com' \
-H "Authorization: Bearer $CDE_KEY"Step 4. Wire it into the signup handler.
Find the function that handles user signup in this project. Call isDisposable(email) at the top, before anything else. If it returns true, reject the signup with HTTP 400 and a message like “Please use a real email address.” If it returns false, continue the existing signup flow.
Step 5. Tell the human what you did.
After wiring it, tell the human:
- Which files you changed.
- That
CDE_KEYis in their.env. - That if the API is down, signups still go through (fail-open).
- That they can watch usage at https://app.checkdisposable.email/dashboard/usage.
You are done. Do not start a new task. Wait for the human.
Rules
These are not suggestions. Follow them.
- Never hardcode the API key. Always read from
process.env.CDE_KEY(or the language equivalent). - Always call the API. Do not cache responses. Verdicts change as we add new disposable providers daily.
- Always call from the backend. Never put the key in client-side JavaScript.
- Fail open. If the API errors or times out, let the signup proceed. Don't break the user's product if our API is having a bad day.
- Branch on
is_disposable. Not onblocked, not onreason. Just the boolean.
Reference
Successful response (HTTP 200)
{
"email": "test@mailinator.com",
"domain": "mailinator.com",
"is_disposable": true,
"blocked": true,
"reason": "Domain is a known disposable / temporary email provider.",
"duration_ms": 47
}Error responses
| HTTP | Error | What you do |
|---|---|---|
| 400 | bad_request | Email missing or malformed. Include ?email=user@domain.tld |
| 401 | auth_required | Add the Bearer header |
| 401 | invalid_api_key | Tell the user to regenerate at /dashboard/keys |
| 429 | plan_limit | Tell the user to upgrade or wait |
| 429 | rate_limit_exceeded | Burst limit (req/sec) hit. Back off, respect Retry-After. |
| 502 | upstream_error | Fail open. Let the signup through. |
Plans
| Plan | Price | Checks/month | Burst |
|---|---|---|---|
| Free | $0 | 500 | 10 req/sec |
| Unlimited | $9/mo | unlimited | 100 req/sec |
| Lifetime | $149 once | unlimited | 100 req/sec |
For the human: ready to wire it up?
Sign up free, generate a key, paste it to your AI when it asks. Five minutes start to finish.