Skip to content
zikky0001-droidPublic

About

๐‘ช๐‘น๐‘ฌ๐‘จ๐‘ป๐‘ฌ๐‘ซ ๐‘ฉ๐’€: ยปยป ๐™ณ๐™ด๐š… ๐š‰๐™ธ๐™บ๐™บ๐šˆ ๐šƒ๐™ด๐™ฒ๐™ท ยซยซ

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Latest commit

ย 

History

72 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

ZMAIL Drop

Fast, free, and public temporary mailboxes โ€” with a full REST API for developers.

Live API License Open Source Built by

A lightweight web app and public API for creating disposable email inboxes โ€” no account, no password, no cost. Built by DEV ZIKKY ๐Ÿง‘โ€๐Ÿ’ป.






๐Ÿ› ๏ธ Built With

HTML5 CSS3 JavaScript Node.js Firebase Vercel Font Awesome


๐Ÿšข Deploy to Vercel

Deploy with Vercel


๐Ÿ“ฆ How to Deploy

Option 1 โ€” Deploy with Vercel (Recommended)

The fastest path. No build step required โ€” Vercel just serves the static files and runs your serverless functions.

Steps:

1. Click the **Deploy with Vercel** button above, or go to [vercel.com/new](https://vercel.com/new) and import `zikky0001-droid/zmaildrop`.
2. Vercel auto-detects the project as a static site + serverless functions.
3. **Before clicking Deploy**, open **Environment Variables** and add the 4 required variables (see the [Configuration](#-configuration) section below).
4. Click **Deploy**.
5. Wait ~40 seconds. Your app is live at `https://<your-project>.vercel.app`.

> โš ๏ธ **Do not deploy without setting the environment variables first.** The API will return `firebase: "disabled"` and rate limiting will fall back to in-memory only (which doesn't work across serverless instances).

Option 2 โ€” Manual Deploy

If you prefer the CLI or a different host.

2.1 โ€” Using the Vercel CLI

# 1. Clone the repo
git clone https://github.com/zikky0001-droid/zmaildrop.git
cd zmaildrop

# 2. Install Vercel CLI (if not already installed)
npm i -g vercel

# 3. Log in to Vercel
vercel login

# 4. Add your environment variables
vercel env add PROJECT_KEY
vercel env add EMAIL_KEY
vercel env add PRIVATE_KEY
vercel env add CRON_SECRET

# 5. Deploy to production
vercel --prod

2.2 โ€” Using Any Static Host (Netlify, Cloudflare Pages, GitHub Pages)

ZMAIL Drop is a plain static site with serverless functions. The frontend works on any host, but the /api/v1/* endpoints require Vercel (or a Node-compatible serverless runtime).

If you only need the frontend:

ยท Upload everything inside public/ to your host
ยท Make sure vercel.json and package.json are at the repo root
ยท Point your DNS or subdomain at the host

Note: Without Vercel, the API endpoints won't run โ€” you'd need to host them elsewhere (Cloudflare Workers, Netlify Functions, etc.) and update the frontend URLs accordingly.

Typing SVG

โš™๏ธ Configuration

ZMAIL Drop needs Firebase (for rate limiting + stats) and a cron secret (for the daily cleanup). This section walks you through getting each one.

Step 1 โ€” Create a Firebase Project

1. Go to console.firebase.google.com
2. Click Add project
3. Give it a name (e.g. zmaildrop-prod)
4. Disable Google Analytics (optional)
5. Click Create project and wait for it to finish

Step 2 โ€” Enable Firestore

1. In the Firebase Console, open your new project
2. Left sidebar โ†’ Build โ†’ Firestore Database
3. Click Create database
4. Choose Production mode (recommended โ€” locks down access by default; your backend uses the Admin SDK which bypasses rules)
5. Pick a location close to your users (e.g. nam5 for US, europe-west1 for Europe, asia-south1 for India)
6. Click Enable

โš ๏ธ Location cannot be changed later. Pick carefully.

Step 3 โ€” Generate a Service Account Key

1. In the Firebase Console, click the โš™๏ธ gear icon next to Project Overview
2. Go to Project settings โ†’ Service accounts tab
3. Make sure Firebase Admin SDK is selected
4. Click Generate new private key
5. Confirm โ€” a JSON file downloads to your machine

Open the JSON file. It contains everything you need:

{
  "type": "service_account",
  "project_id": "zmaildrop-prod",
  "private_key_id": "abc...",
  "private_key": "-----BEGIN PRIVATE KEY-----\nMIIEvwIBADANBgkqhkiG9w0BAQEFAAS...\n-----END PRIVATE KEY-----\n",
  "client_email": "firebase-adminsdk-xxxxx@zmaildrop-prod.iam.gserviceaccount.com",
  "client_id": "1234567890",
  ...
}
From this file, copy three values:

What you need Which field in the JSON
Firebase Project ID project_id
Service Account Email client_email
Private Key private_key (the whole value, including -----BEGIN... and ...END-----)

Step 4 โ€” Generate the Cron Secret

Run this in Termux (or any terminal):

echo "zmaildrop$(openssl rand -hex 12 | cut -c1-23)"

Example output:

zmaildropa3f8c2b9d1e6f4a7c8b2d5e

Save this โ€” you'll need it in the next step.

Step 5 โ€” Set Environment Variables

You now have 4 values ready:

PROJECT_KEY=<project_id from Firebase JSON>
EMAIL_KEY=<client_email from Firebase JSON>
PRIVATE_KEY=<private_key from Firebase JSON>
CRON_SECRET=<the random string you just generated>

๐Ÿ…ฐ๏ธ If deploying on Vercel (recommended)

1. In your Vercel project, open Settings โ†’ Environment Variables
2. Add each of the 4 variables:
   ยท Name: PROJECT_KEY โ€” Value: your project ID
   ยท Name: EMAIL_KEY โ€” Value: your service account email
   ยท Name: PRIVATE_KEY โ€” Value: the full private key
   ยท Name: CRON_SECRET โ€” Value: your random secret
3. For each, tick Production, Preview, and Development
4. Click Save for each one
5. Go to Deployments โ†’ click the latest โ†’ Redeploy

โš ๏ธ For PRIVATE_KEY, paste the value with the literal \n characters as text. Do NOT press Enter to make real newlines. The code converts \n to real line breaks automatically.

๐Ÿ…ฑ๏ธ If using GitHub Environment Variables (only for private repos)

If your repo is private and you want CI/CD to inject secrets at build time:

1. In GitHub, go to Settings โ†’ Secrets and variables โ†’ Actions
2. Click New repository secret for each:
   ยท PROJECT_KEY โ†’ your project ID
   ยท EMAIL_KEY โ†’ your service account email
   ยท PRIVATE_KEY โ†’ the full private key
   ยท CRON_SECRET โ†’ your random secret
3. Reference them in any .github/workflows/*.yml file using ${{ secrets.PROJECT_KEY }}

โš ๏ธ Never use GitHub secrets on a public repo. Even though GitHub hides them from public view, forks and logs can leak them. If your repo is public, set env vars ONLY in Vercel.

Step 6 โ€” Verify the Deployment

Once deployed, test the health endpoint:

curl -s "https://<your-project>.vercel.app/api/v1/health" | jq

You want to see:

{
  "ok": true,
  "data": {
    "service": "ZMAIL Drop API",
    "version": "v1",
    "status": "online",
    "firebase": "connected",   โ† โฌ… this is the important one
    ...
  }
}
If firebase shows "disabled", one of your 3 Firebase env vars is missing or misformatted. The most common issue is the PRIVATE_KEY โ€” make sure it:

ยท Includes -----BEGIN PRIVATE KEY----- and -----END PRIVATE KEY-----
ยท Keeps the \n as literal text (no real newlines)
ยท Is not wrapped in quotes

Step 7 โ€” Enable the Daily Cleanup Cron

The project ships with a cron job in vercel.json:

{
  "crons": [
    { "path": "/api/v1/cleanup", "schedule": "0 23 * * *" }
  ]
}

This fires every day at 23:00 UTC = 00:00 Lagos (WAT). Vercel automatically sends the CRON_SECRET header โ€” you don't need to do anything.

To test it manually:

curl -s -H "Authorization: Bearer <your CRON_SECRET>" \
  "https://<your-project>.vercel.app/api/v1/cleanup" | jq

Expected response:

{
  "ok": true,
  "data": {
    "cleaned": 12,
    "batches": 1,
    "collection": "rate_limits",
    "note": "stats/global and system/upstream_lock were NOT touched."
  }
}

๐Ÿงพ Environment Variables at a Glance Variable Where it comes from What it does PROJECT_KEY Firebase JSON โ†’ project_id Identifies your Firebase project EMAIL_KEY Firebase JSON โ†’ client_email Service account that writes to Firestore PRIVATE_KEY Firebase JSON โ†’ private_key Authenticates the service account CRON_SECRET Generated with openssl Protects /api/v1/cleanup from abuse Where to set them:

Deployment Where env vars go
Vercel (any repo) Vercel โ†’ Settings โ†’ Environment Variables โœ…
GitHub (private repo only) GitHub โ†’ Settings โ†’ Secrets and variables
GitHub (public repo) โŒ Never use GitHub secrets โ€” Vercel only
Local development .env file (gitignored)

โœจ Features

For users

  • Instant inboxes โ€” pick a name, get an address, done
  • Live mailbox view โ€” messages appear within a few seconds
  • Rich email rendering โ€” inline images resolved, HTML bodies displayed in a sandboxed iframe
  • Attachment downloads โ€” every file attached to a message, one click away
  • Full message export โ€” download the entire raw email as .eml
  • Zero setup โ€” no account, no password, no profile
  • Mobile-friendly โ€” works on phones, tablets, and desktops
  • Custom 404 page โ€” built in ZMAIL Drop's brand style

For developers

  • REST API โ€” 4 clean endpoints, JSON responses
  • No authentication โ€” no signup, no API key
  • Rate limited โ€” 30 requests/minute per IP, fair use enforced
  • Global throttle โ€” upstream calls never overlap
  • In-memory caching โ€” 3-second TTL on inbox and message reads
  • CID resolution โ€” inline images automatically resolved
  • Attachment detection โ€” flags and pre-extracted data
  • CORS enabled โ€” call from any browser origin

๐Ÿš€ Quick Start

For users

  1. Visit zmaildrop.vercel.app
  2. Click Open a mailbox
  3. Type a name like myname123
  4. Your address becomes myname123@maildrop.cc
  5. Send anything to that address โ€” it appears in your inbox

For developers

# List messages in a mailbox
curl -s "https://zmaildrop.vercel.app/api/v1/inbox?mailbox=myname123" | jq

# Read a single message
curl -s "https://zmaildrop.vercel.app/api/v1/message?mailbox=myname123&id=abc123" | jq

# Delete a message
curl -s -X DELETE "https://zmaildrop.vercel.app/api/v1/message?mailbox=myname123&id=abc123" | jq

Full API docs: zmaildrop.vercel.app/developers.html


๐Ÿ› ๏ธ Tech Stack

Layer Technology Frontend Vanilla HTML, CSS, JavaScript Backend Node.js serverless functions Hosting Vercel Database Firebase Firestore (rate limits, stats) Caching In-memory (per serverless instance) Upstream ZMAIL Drop mail server Fonts Inter, Space Grotesk Design Custom dark glass aesthetic

No frameworks. No build step. Just fast, hand-written code.


๐Ÿ‘จโ€๐Ÿ’ป About the Developer

Dev Zikky is a full-stack developer, builder, and problem-solver from Nigeria. He builds tools that solve real problems โ€” usually from a phone, in Termux, at odd hours. His work spans AI chat assistants, email infrastructure, manga readers, Telegram and WhatsApp bots, and cybersecurity awareness projects.

Philosophy:

"Innovation is not about having all the answers โ€” it's about asking the right questions."

Every project starts the same way: notice something annoying or missing, then build the fix. ZMAIL Drop, ZIKKY AI, Manga Hub, ZQUOTE, and ZMAIL Studio all began as personal needs that turned into public tools.

ยท ๐ŸŒ Portfolio: zikkytech.xo.je ยท ๐Ÿ‘ค About: zmaildrop.vercel.app/owner.html


๐ŸŒŸ Other Projects by Dev Zikky

If you like ZMAIL Drop, here's what else is in the workshop:

๐Ÿค– ZIKKY AI โ€” zikkyai.xo.je

A free AI chat platform. Talk to capable AI models, get coding help, and use features like text-to-speech โ€” all in one place. Create a free account and start chatting. Powered by multi-model orchestration (Gemini, DeepSeek, Meta AI).

๐Ÿ“ง ZMAIL Studio โ€” zmail.zone.id

Where ZMAIL Drop receives, ZMAIL Studio sends. A beautiful workspace for crafting polished personal emails โ€” 7 reusable templates, a rich editor, live preview, and a server-side sending API. Credentials stay on the server, never in the browser.

๐Ÿ“š ZIKKY Manga Hub โ€” zikkymangahub.onrender.com

A free manga reading site with a clean reader, downloads, and bookmarking โ€” built for readers who want a premium-feeling experience without the paywalls.

๐Ÿ’ฌ ZQUOTE โ€” zquote-tau.vercel.app

A Telegram-style quote generator API. Send a username, message, and optional avatar, and get back a rendered, shareable quote image hosted on a CDN. Includes a live preview tester and copy-paste examples for cURL, JavaScript, and Python.

๐Ÿ“ฎ ZDropMail โ€” zdropmail.vercel.app

A separate temporary mailbox service with a different workflow. Where ZMAIL Drop focuses on public, name-your-own inboxes, ZDropMail generates private mailboxes with short lifetimes โ€” perfect when you want something that isn't publicly discoverable by name.

Why two services? Different needs. ZMAIL Drop is fast, public, and name-based (great for quick sign-ups). ZDropMail is private, generated, and lifetime-bound (better for sensitive sign-ups where you don't want anyone guessing your address).

๐ŸŒ ZIKKY Tech Portfolio โ€” zikkytech.xo.je

The complete catalogue of everything Dev Zikky builds โ€” ZIKKY AI v1 & v2, the matrix calculator, Telegram bots, the API gateway, and all projects in development.

๐Ÿ’– Support the Project

ZMAIL Drop is free forever and runs on generosity. Every dollar helps pay for:

ยท Vercel hosting (serverless function invocations)
ยท Firebase Firestore reads/writes (rate limiting + stats)
ยท Domain renewal
ยท Coffee for late-night debugging sessions โ˜•

If the service has been useful to you โ€” whether for one signup or a hundred โ€” consider buying Dev Zikky a coffee to keep it alive for everyone.

How to donate

Contact the developer directly to arrange a donation or sponsorship:

ยท ๐Ÿ‘ค Owner page: zmaildrop.vercel.app/owner.html
ยท ๐Ÿ’ฌ GitHub: @zikky0001-droid
ยท ๐ŸŒ Portfolio: zikkytech.xo.je

Why contact directly? It keeps costs low (no payment processor fees) and lets you ask questions, suggest features, or sponsor a specific improvement.

Not able to donate?

You can still help a lot:

ยท โญ Star the GitHub repo โ€” signals it's worth maintaining ยท ๐Ÿ› Report bugs โ€” makes the service better for everyone ยท ๐Ÿ“ฃ Share it with friends, forums, or developer communities ยท ๐Ÿ’ก Suggest features โ€” many are built on user requests ยท โœ๏ธ Write about it โ€” blog posts and mentions help visibility


๐Ÿ“ Project Structure

zmaildrop/
โ”œโ”€โ”€ api/
โ”‚   โ”œโ”€โ”€ maildrop.js             # Internal proxy for the frontend
โ”‚   โ””โ”€โ”€ v1/
โ”‚       โ”œโ”€โ”€ utils.js            # Shared helpers (Firebase, rate limit, cache)
โ”‚       โ”œโ”€โ”€ health.js           # GET    /api/v1/health
โ”‚       โ”œโ”€โ”€ inbox.js            # GET    /api/v1/inbox?mailbox=:name
โ”‚       โ”œโ”€โ”€ message.js          # GET / DELETE /api/v1/message?mailbox=:name&id=:id
โ”‚       โ””โ”€โ”€ cleanup.js          # Cron-triggered rate-limit wipe
โ”œโ”€โ”€ public/
โ”‚   โ”œโ”€โ”€ index.html              # Homepage
โ”‚   โ”œโ”€โ”€ login.html              # Mailbox picker
โ”‚   โ”œโ”€โ”€ inbox.html              # Message list
โ”‚   โ”œโ”€โ”€ view.html               # Message viewer
โ”‚   โ”œโ”€โ”€ owner.html              # Developer page
โ”‚   โ”œโ”€โ”€ developers.html         # Public API documentation
โ”‚   โ”œโ”€โ”€ 404.html                # Custom not-found page
โ”‚   โ”œโ”€โ”€ script.js               # Frontend logic
โ”‚   โ”œโ”€โ”€ style.css               # Global styles
โ”‚   โ””โ”€โ”€ js/
โ”‚       โ”œโ”€โ”€ clock.js            # Lagos time ticker
โ”‚       โ”œโ”€โ”€ hamburger.js        # Mobile menu
โ”‚       โ””โ”€โ”€ ui.js               # Scroll reveal, counters, etc.
โ”œโ”€โ”€ .env.example                # Environment template
โ”œโ”€โ”€ .gitignore
โ”œโ”€โ”€ LICENSE
โ”œโ”€โ”€ README.md
โ”œโ”€โ”€ package.json
โ””โ”€โ”€ vercel.json

๐Ÿ”Œ Public API (v1)

Base URL: https://zmaildrop.vercel.app/api/v1

Method Endpoint Description
GET /health Service status, uptime, lifetime request count
GET /inbox?mailbox=:name List all messages in a mailbox
GET /message?mailbox=:name&id=:id Read one message (HTML + raw MIME)
DELETE /message?mailbox=:name&id=:id Delete one message

Response envelope

Every response is JSON. Success responses have ok: true and a data field. Errors have ok: false and an error object.

{
  "ok": true,
  "data": { ... },
  "meta": {
    "request_id": "req_b41o301d",
    "timestamp": "2026-09-22T16:25:10.193Z",
    "rate": { "limit": 30, "remaining": 29 }
  }
}

Rate limits ยท 30 requests / minute per IP ยท Exceeding the limit blacks out your IP for 5 minutes ยท Every response includes standard X-RateLimit-* headers ยท 429 responses include Retry-After Error codes

Code Status Meaning
MISSING_MAILBOX 400 The mailbox parameter was omitted
MISSING_ID 400 The id parameter was omitted
INVALID_MAILBOX 400 Mailbox name failed validation
INVALID_ID 400 Message ID failed validation
MESSAGE_NOT_FOUND 404 Message doesn't exist or expired
METHOD_NOT_ALLOWED 405 Wrong HTTP verb
RATE_LIMITED 429 30 req/min exceeded
IP_BLACKLISTED 429 IP temporarily blocked
UPSTREAM_BUSY 503 Server queue is full
UPSTREAM_ERROR 502 ZMAIL Drop mail server failed

๐Ÿง  How It Works

Frontend flow

  1. User picks a mailbox name (login.html)
  2. App redirects to /inbox?mailbox=
  3. script.js calls /api/maildrop?action=inbox&mailbox=
  4. Messages render as cards with View and Delete buttons
  5. Clicking View loads /view?mailbox=&id=
  6. The message viewer fetches the raw email and renders it inside a sandboxed iframe

Backend flow

1. Every request hits a Vercel serverless function
2. utils.js checks rate limits, cache, and the global throttle
3. If cache misses, the request is proxied to the ZMAIL Drop mail server
4. Results are cached in memory for 3 seconds
5. Errors bubble up with clean JSON messages

Rate limiting ยท First 5 requests per IP hit only the in-memory counter ยท Requests 6+ trigger a Firestore transaction for shared state ยท Over 30/min โ†’ blacklisted in Firestore for 5 minutes ยท Cleanup cron wipes rate_limits/ every day at 00:00 Lagos time Upstream throttling The ZMAIL Drop mail server is called at most once every 750 ms globally. This is enforced with a Firestore lock that all serverless instances share โ€” so even if 10 users request at once, only 1 upstream call goes out per 750 ms window. The others wait and then read the fresh cache.


๐Ÿ” Environment Variables

Copy .env.example to .env and fill in: Variable Description PROJECT_KEY Firebase project ID EMAIL_KEY Firebase service account email PRIVATE_KEY Firebase service account private key (with literal \n) CRON_SECRET Secret for authenticating the cleanup cron

For production on Vercel, set these in Settings โ†’ Environment Variables. Do NOT commit your .env file.

Generating CRON_SECRET

echo "zmaildrop$(openssl rand -hex 12 | cut -c1-23)"

๐Ÿšข Deployment

Deploy to Vercel

https://vercel.com/button

1. Fork this repository
2. Import it into Vercel
3. Add the 4 environment variables
4. Deploy โ€” Vercel builds nothing, just serves the static files and functions

Local development

# Install the Vercel CLI
npm i -g vercel

# Clone
git clone https://github.com/zikky0001-droid/zmaildrop.git
cd zmaildrop

# Copy env template
cp .env.example .env
# Then edit .env

# Run locally
vercel dev

The dev server runs at http://localhost:3000.


๐Ÿ”’ Security

ยท No user data stored โ€” mailboxes are anonymous and public
ยท No cookies, no tracking โ€” the app is stateless
ยท Sandboxed iframes โ€” email HTML renders with sandbox and no script execution
ยท Firestore TTL โ€” stale rate-limit docs are wiped daily by the cleanup cron
ยท Secrets stay on the server โ€” the Firebase private key never reaches the browser
ยท Rate limits enforced โ€” abuse protection at both the IP and upstream levels

๐Ÿค Contributing

This project is open source and contributions are welcome.

# 1. Fork the repo
# 2. Create a feature branch
git checkout -b feature/my-improvement

# 3. Make your changes
# 4. Test locally with `vercel dev`
# 5. Commit and push
git commit -m "Add my improvement"
git push origin feature/my-improvement

# 6. Open a Pull Request

Guidelines

ยท Keep the stack minimal โ€” no frameworks ยท Maintain the visual identity (colors, fonts, glass cards) ยท Test on mobile before submitting ยท Update developers.html if you add or change any API endpoint


๐Ÿ“œ License

MIT โ€” see LICENSE for details.

You're free to fork, modify, self-host, and redistribute. Attribution appreciated but not required.


๐Ÿ™ Credits

Built and maintained by Dev Zikky โ€” zikkytech.xo.je

ยท Design & code: Dev Zikky
. Organization: DEV ZIKKY TECH 
ยท API infrastructure: Vercel serverless functions
ยท Persistent state: Firebase Firestore
ยท Upstream mail service: ZMAIL Drop mail server

๐Ÿ“ฌ Contact & Links

Web links โ™ฅ๏ธ

๐ŸŒ Homepage zmaildrop.vercel.app
๐Ÿ“– API Docs zmaildrop.vercel.app/developers.html
๐Ÿ‘ค About Dev Zikky zmaildrop.vercel.app/owner.html
๐Ÿ’ป GitHub github.com/zikky0001-droid/zmaildrop
๐ŸŒŸ Portfolio zikkytech.xo.je
๐Ÿค– ZIKKY AI zikkyai.xo.je
๐Ÿ“ง ZMAIL Studio zmail.zone.id
๐Ÿ“š Manga Hub zikkymangahub.onrender.com
๐Ÿ’ฌ ZQUOTE zquote-tau.vercel.app
๐Ÿ“ฎ ZDropMail zdropmail.vercel.app

โญ If ZMAIL Drop helped you, consider starring the repo or contacting the developer to support its upkeep.

ZMAIL Drop โ€” Simple temporary mail access.

Built with โ˜• and ๐ŸŒ™ by Dev Zikky from Lagos, Nigeria ๐Ÿ‡ณ๐Ÿ‡ฌ

Typing SVG

THANK YOU FOR VISITING, DON'T FORGET TO GIVE ME A STAR

About

๐‘ช๐‘น๐‘ฌ๐‘จ๐‘ป๐‘ฌ๐‘ซ ๐‘ฉ๐’€: ยปยป ๐™ณ๐™ด๐š… ๐š‰๐™ธ๐™บ๐™บ๐šˆ ๐šƒ๐™ด๐™ฒ๐™ท ยซยซ

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages