{
  "markdown": "# EmptyInbox\n\nDisposable email inbox API for AI agents and developers. Create temporary email addresses, receive messages, and read content — via REST API or MCP server.\n\n**Live at [emptyinbox.me](https://emptyinbox.me)**\n\n## MCP Server (Claude / Claude Code / any MCP agent)\n\n```json\n{\n  \"mcpServers\": {\n    \"emptyinbox\": {\n      \"command\": \"npx\",\n      \"args\": [\"emptyinbox-mcp\"],\n      \"env\": {\n        \"EMPTYINBOX_API_KEY\": \"your_api_key_here\"\n      }\n    }\n  }\n}\n```\n\nGet your API key at https://emptyinbox.me/settings.html\n\n## REST API\n\nBase URL: `https://emptyinbox.me/api`\nAuth: `Authorization: Bearer <api_key>`\nOpenAPI spec: `https://emptyinbox.me/openapi.yaml`\n\n```bash\n# Create an inbox\ncurl -X POST -H \"Authorization: Bearer YOUR_KEY\" https://emptyinbox.me/api/inbox\n\n# List messages — filter to one inbox, only what arrived since the last poll\ncurl -H \"Authorization: Bearer YOUR_KEY\" \\\n  \"https://emptyinbox.me/api/messages?inbox=ADDRESS&since=1711234000&include_body=false\"\n\n# Read a message\ncurl -H \"Authorization: Bearer YOUR_KEY\" https://emptyinbox.me/api/message/MSG_ID\n\n# ...or as flat text, ready to drop into a prompt\ncurl -H \"Authorization: Bearer YOUR_KEY\" \"https://emptyinbox.me/api/message/MSG_ID?format=text\"\n```\n\nEvery message comes back parsed, so nothing has to pick through the HTML:\n\n```json\n{\n  \"subject\": \"Confirm your email address\",\n  \"from_name\": \"Example App\",\n  \"from_email\": \"noreply@example.com\",\n  \"received_at\": \"2024-03-23T21:36:07Z\",\n  \"type\": \"verification\",\n  \"code\": \"482910\",\n  \"action_url\": \"https://example.com/verify?token=abc123\",\n  \"links\": [{ \"url\": \"https://example.com/verify?token=abc123\", \"text\": \"Verify your email\" }],\n  \"preview\": \"Your verification code is 482910. It expires in 10 minutes.\",\n  \"text\": \"Your verification code is 482910. It expires in 10 minutes.\"\n}\n```\n\n`text` is the body flattened to plain text (from the HTML part when there is no text\npart), `code` is the best one-time code found, `action_url` the single link worth\nopening. `?format=raw` still returns the untouched MIME parts.\n\n## Typical agent workflow\n\n1. `POST /api/inbox` → get a disposable address\n2. Use that address in an external signup or verification flow\n3. `GET /api/messages?inbox=<address>&since=<last timestamp>` → poll until the verification email appears\n4. Read `code` or `action_url` straight off the message — the API extracts both\n\n## Local Development\n\n### Backend (Flask, port 5000)\n\n```powershell\ncd api\npipenv install\npipenv run create_db   # first run only — creates SQLite DB\npipenv run dev         # starts python tempmail_api.py with CORS + /api prefix\n```\n\n**`api/.env` for local dev:**\n```env\nDOMAIN=localhost:8000\nSECRET=any_random_string\nFLASK_ENV=development\nBLOCKONOMICS_API_KEY=<key>\nUSDT_RECEIVING_ADDRESS=<address>\nMATCH_CALLBACK=ngrok\n```\n\n### Frontend (static, port 8000)\n\n```powershell\ncd static\npython -m http.server 8000\n```\n\nOpen http://localhost:8000. The JS auto-detects localhost and hits `http://localhost:5000` for the API (`static/utils/constants.js`).\n\n---\n\n## Self-hosting\n\n### Requirements\n- Ubuntu server\n- Python 3 + pipenv\n- Nginx\n- Postfix\n\n### Setup\n\n**1. Clone and configure**\n```bash\ngit clone https://github.com/blockonomics/emptyinbox-me\ncd emptyinbox-me/api\ncp .env.example .env   # fill in your values\n```\n\n**.env variables:**\n```\nDOMAIN=yourdomain.com\nSECRET=your_postfix_webhook_secret\nFLASK_ENV=production\nBLOCKONOMICS_API_KEY=your_blockonomics_api_key\nUSDT_RECEIVING_ADDRESS=your_usdt_address\nMATCH_CALLBACK=https://yourdomain.com/api/payments/callback\n```\n\n**2. Database**\n```bash\npipenv install\npipenv run create_db\n```\n\n**3. Gunicorn**\n```bash\npipenv run start\n```\n\n**4. Nginx**\n```bash\nsudo cp nginx/emptyinbox_nginx.conf /etc/nginx/sites-available/emptyinbox_nginx.conf\nsudo nginx -t && sudo systemctl reload nginx\n```\n\n**5. Postfix**\n```bash\nsudo apt install postfix   # select \"No configuration\"\nsudo cp /usr/share/postfix/main.cf.debian /etc/postfix/main.cf\nsudo postfix/setup_postfix.sh YOUR_HOSTNAME YOUR_DOMAIN YOUR_SECRET\n```\n\n## Pricing\n\n- Free: 5 inboxes per account\n- Paid: 1 USDT per 10 additional inboxes (via Blockonomics — no credit card, no KYC)\n",
  "bytes": 4173,
  "sha": "cca203e0fd614c96217d3652ce9b43e34ce04f1532ffc50a4d2e665a67120072",
  "repo_slug": "blockonomics/emptyinbox-me",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_cnohall_emptyinbox_68966d4f/readme"
}