Enterprise Disposable Email REST Gateway
Commercial, high-throughput email verification infrastructure for QA engineers, SaaS platforms, and enterprise automated testing suites. Provision inboxes, extract OTP codes, and simulate millions of user signups with zero maintenance.
https://api.temp-mail.im/v1 API Access Tiers & Pricing
Choose a subscription tier engineered to scale with your automated testing and verification load.
Free / Evaluation
Ideal for individual developers, open-source testing, and staging prototypes.
- ✓ 100 API Calls / minute
- ✓ Standard Receiving Domains
- ✓ Automatic 20-min Expiration
- ✓ JSON REST Endpoints
- ✓ Community Support
Scale & CI/CD
For fast-growing startups and QA teams running continuous Playwright & Cypress suites.
- ✓ 5,000 API Calls / minute
- ✓ Rotating Clean Domain Pool
- ✓ Instant Webhook Push Notifications
- ✓ Built-in OTP Auto-Extraction
- ✓ Dedicated Priority Delivery Queue
- ✓ 99.9% Uptime Guarantee
Dedicated Cloud
For enterprise platforms requiring dedicated IP pools, custom domains, and strict compliance.
- ✓ Unlimited Throughput & Calls
- ✓ Bring Your Own Custom Domains
- ✓ Dedicated Private IP Inbound Nodes
- ✓ 24/7 Dedicated Support & Slack Channel
- ✓ Custom SLA (99.99%) & BAA Agreement
- ✓ Multi-Region Redundancy
Interactive API Gateway Simulator
Simulate REST requests and verify JSON schemas before writing production code.
// Live JSON Gateway response will appear here...
{
"status": "ready",
"message": "Click 'POST /v1/mailboxes/new' to simulate gateway provisioning"
} Standard REST Endpoints
All requests must include standard Bearer Token authentication via the HTTP Authorization header.
/v1/mailboxes/new Creates an ephemeral disposable mailbox on the global gateway. Returns email address and expiration metadata.
Request Headers
| Header | Type | Required | Description |
|---|---|---|---|
Authorization | string | Required | Bearer token in the format Bearer YOUR_API_KEY |
Content-Type | string | Required | Must be application/json |
{
"domain": "getmail.site",
"prefix": "qa-runner" // Optional custom alias
} {
"status": "success",
"data": {
"email": "qa-runner892k@getmail.site",
"mailbox_id": "mbx_live_9a8f2b7c4d1e",
"created_at": "2026-09-23T01:00:00.000Z",
"expires_at": "2026-09-23T01:20:00.000Z",
"retention_seconds": 1200
}
} /v1/mailboxes/:email/messages Retrieves all received messages for an active temporary inbox, with pre-parsed plaintext, sanitized HTML, and automated OTP detection.
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
email | string | Required | The mailbox address (e.g. qa-runner892k@getmail.site) |
{
"status": "success",
"mailbox": "qa-runner892k@getmail.site",
"count": 1,
"messages": [
{
"id": "msg_9f82a1c0d4e5",
"from": "Acme Auth <noreply@example.com>",
"subject": "Your Verification Code is: 582910",
"otp_code": "582910",
"text_body": "Your single-use login code is 582910. Expires in 10 minutes.",
"html_body": "<p>Your single-use login code is <strong>582910</strong>.</p>",
"received_at": "2026-09-23T01:02:15.000Z"
}
]
} /v1/mailboxes/:email Immediately purges all stored emails and removes the mailbox session before standard 20-minute expiration.
{
"status": "success",
"message": "Mailbox and all ephemeral messages purged successfully."
} Multi-Language Code Integration
Drop-in code snippets ready for copy-pasting into your automated tests and CI/CD pipelines.
# 1. Provision a new mailbox via API Gateway
curl -X POST "https://api.temp-mail.im/v1/mailboxes/new" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"domain": "getmail.site"}'
# 2. Poll for incoming messages & OTP verification codes
curl -X GET "https://api.temp-mail.im/v1/mailboxes/qa-bot721@getmail.site/messages" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Accept: application/json" // Production Node.js / Playwright / Cypress Integration
import axios from 'axios';
const API_KEY = process.env.TEMPMAIL_API_KEY || 'YOUR_API_KEY';
const client = axios.create({
baseURL: 'https://api.temp-mail.im/v1',
headers: { 'Authorization': `Bearer ${API_KEY}` }
});
// 1. Create Disposable Inbox
export async function createInbox() {
const res = await client.post('/mailboxes/new');
return res.data; // { email: "...", expires_at: "..." }
}
// 2. Poll for OTP Verification Code
export async function waitForOtp(email, timeoutMs = 30000) {
const start = Date.now();
while (Date.now() - start < timeoutMs) {
const res = await client.get(`/mailboxes/${encodeURIComponent(email)}/messages`);
if (res.data.messages && res.data.messages.length > 0) {
const latest = res.data.messages[0];
const match = latest.text_body.match(/\b\d{4,6}\b/);
if (match) return match[0];
}
await new Promise(r => setTimeout(r, 2000));
}
throw new Error('Verification OTP timeout');
} import time
import re
import requests
API_KEY = "YOUR_API_KEY"
HEADERS = {"Authorization": f"Bearer {API_KEY}", "Content-Type": "application/json"}
BASE_URL = "https://api.temp-mail.im/v1"
# 1. Provision an ephemeral mailbox
def create_mailbox():
response = requests.post(f"{BASE_URL}/mailboxes/new", headers=HEADERS)
response.raise_for_status()
return response.json()
# 2. Extract verification OTP code
def get_verification_otp(email_address, timeout=30):
start = time.time()
while time.time() - start < timeout:
res = requests.get(f"{BASE_URL}/mailboxes/{email_address}/messages", headers=HEADERS)
if res.status_code == 200:
data = res.json()
messages = data.get("messages", [])
if messages:
body = messages[0].get("text_body", "")
otp = re.search(r'\b\d{4,6}\b', body)
if otp:
return otp.group(0)
time.sleep(2)
raise TimeoutError("OTP email did not arrive in time.") package main
import (
"encoding/json"
"fmt"
"net/http"
"time"
)
type MailboxResponse struct {
Email string `json:"email"`
ExpiresAt time.Time `json:"expires_at"`
}
func CreateMailbox(apiKey string) (*MailboxResponse, error) {
req, _ := http.NewRequest("POST", "https://api.temp-mail.im/v1/mailboxes/new", nil)
req.Header.Set("Authorization", "Bearer "+apiKey)
client := &http.Client{Timeout: 10 * time.Second}
resp, err := client.Do(req)
if err != nil {
return nil, err
}
defer resp.Body.Close()
var mb MailboxResponse
if err := json.NewDecoder(resp.Body).Decode(&mb); err != nil {
return nil, err
}
return &mb, nil
} <?php
class TempMailGateway {
private $apiKey;
private $baseUrl = "https://api.temp-mail.im/v1";
public function __construct($apiKey) {
$this->apiKey = $apiKey;
}
public function getMessages($email) {
$url = $this->baseUrl . "/mailboxes/" . urlencode($email) . "/messages";
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"Authorization: Bearer " . $this->apiKey,
"Accept: application/json"
]);
$res = curl_exec($ch);
curl_close($ch);
return json_decode($res, true);
}
}
?> using System;
using System.Net.Http;
using System.Net.Http.Headers;
using System.Text.Json;
using System.Threading.Tasks;
public class TempMailGateway
{
private readonly HttpClient _client;
public TempMailGateway(string apiKey)
{
_client = new HttpClient { BaseAddress = new Uri("https://api.temp-mail.im/v1/") };
_client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", apiKey);
}
public async Task<JsonElement> FetchInboxAsync(string email)
{
var response = await _client.GetAsync($"mailboxes/{Uri.EscapeDataString(email)}/messages");
response.EnsureSuccessStatusCode();
var json = await response.Content.ReadAsStringAsync();
return JsonDocument.Parse(json).RootElement;
}
} Enterprise API Acceptable Use Policy & Legal Shield
The Temp-Mail.im API Gateway is strictly provided for legitimate software quality assurance, automated CI/CD signup testing, security audits, and privacy preservation. Utilizing the API for spam transmission, fraudulent impersonation, or malicious automation is strictly prohibited and results in immediate cryptographic API key revocation without refund.
Ready to Integrate Enterprise Temporary Email?
Get your production API key and automate high-throughput verification pipelines today.