API Documentation

Integrate EasyTrashMail into your application. Free Tools API and Premium Developer API for advanced features.

Getting Started

Base URL

All API requests are sent to the following base URL:

https://easytrashmail.eu

API Keys

EasyTrashMail offers two types of APIs:

Tools API Key (Free)

For free tools like QR Code Generator, Email Validator, Age Calculator. Available in the dashboard at Tools → API Keys.

Developer API Key (Premium)

For advanced features like Email Management, Custom Domains, Webhooks. Requires Developer Plan. Available in the dashboard at Developer → API Keys.

Authentifizierung

API Keys can be passed in three ways:

1. Header (Recommended)

curl -H "x-api-key: YOUR_API_KEY" \
  https://easytrashmail.eu/api/tools/qr-code?type=url&url=https://example.com

2. Query Parameter

curl "https://easytrashmail.eu/api/tools/qr-code?apikey=YOUR_API_KEY&type=url&url=https://example.com"

3. Request Body (nur POST)

curl -X POST https://easytrashmail.eu/api/tools/qr-code \
  -H "Content-Type: application/json" \
  -d '{"apikey": "YOUR_API_KEY", "type": "url", "url": "https://example.com"}'

Response Format

All API responses use JSON format:

{
  "success": true,
  "data": {
    // Response data
  }
}

On errors, the following format is returned:

{
  "success": false,
  "error": "Error type",
  "message": "Human-readable error message"
}

Tools API (Free)

Note: The Tools API is free and requires a Tools API Key. Most tools have no rate limits for normal usage.

QR Code Generator

Generate QR codes for text, URLs, emails, phone numbers, and WiFi networks.

Endpoint

GET/POST /api/tools/qr-code

Parameter

ParameterTypeRequiredDescription
typestringNotext, url, email, phone, wifi (default: text)
textstringNo*Text for QR code (when type=text)
urlstringNo*URL for QR code (when type=url)
emailstringNo*Email address (when type=email)
phonestringNo*Phone number (when type=phone)
wifiSSIDstringNo*WiFi network name (when type=wifi)
wifiPasswordstringNoWiFi password (when type=wifi)
sizenumberNoSize in pixels (50-2000, default: 256)
formatstringNojson, png, svg (default: json)

Example Request

curl -H "x-api-key: YOUR_TOOLS_API_KEY" \
  "https://easytrashmail.eu/api/tools/qr-code?type=url&url=https://example.com&size=300&format=json"

Example Response

{
  "success": true,
  "data": {
    "value": "https://example.com",
    "type": "url",
    "size": 300,
    "errorCorrectionLevel": "H",
    "dataUrl": "data:image/png;base64,iVBORw0KGgoAAAANS...",
    "format": "png"
  }
}

Email Validator

Validate email addresses according to RFC 5322 standards, extract emails from text, or verify existence.

Endpoint

GET/POST /api/tools/email-validator

Parameter

ParameterTypeRequiredDescription
actionstringNovalidate, extract, verify (default: validate)
emailstringYes*Email address (when action=validate or verify)
textstringYes*Text to extract emails from (when action=extract)

Example: Validation

curl -H "x-api-key: YOUR_TOOLS_API_KEY" \
  "https://easytrashmail.eu/api/tools/email-validator?action=validate&email=test@example.com"

Example: Extraction

curl -H "x-api-key: YOUR_TOOLS_API_KEY" \
  "https://easytrashmail.eu/api/tools/email-validator?action=extract&text=Contact us at support@example.com or info@test.com"

Example Response

{
  "success": true,
  "data": {
    "isValid": true,
    "errors": [],
    "warnings": [],
    "details": {
      "localPart": "test",
      "domain": "example.com",
      "domainParts": ["example", "com"],
      "tld": "com",
      "length": 16
    }
  }
}

Age Calculator

Calculate exact age in years, months, days, and more.

Endpoint

GET/POST /api/tools/age-calculator

Parameter

ParameterTypeRequiredDescription
birthDatestringYesBirth date in YYYY-MM-DD format
referenceDatestringNoReference date in YYYY-MM-DD format (default: today)

Example Request

curl -H "x-api-key: YOUR_TOOLS_API_KEY" \
  "https://easytrashmail.eu/api/tools/age-calculator?birthDate=1990-01-15"

Example Response

{
  "success": true,
  "data": {
    "years": 34,
    "months": 2,
    "days": 15,
    "totalDays": 12450,
    "totalWeeks": 1778,
    "totalMonths": 410,
    "nextBirthday": {
      "days": 293,
      "date": "2025-01-15"
    },
    "zodiacSign": "Capricorn",
    "dayOfWeek": "Monday"
  }
}

Developer API (Premium)

Rate Limits & Quotas

Tools API

  • Free: No fixed rate limits for normal usage
  • • Abuse is automatically detected and blocked
  • • For high volume: Contact our support

Developer API

  • Free Plan: 0 Requests/Day (no access to Developer API)
  • Premium Plan: 0 Requests/Day (no access to Developer API)
  • Developer Plan: 10,000 Requests/Day
  • • Rate limits are displayed in the response header

Rate Limit Headers

X-RateLimit-Limit: 1000
X-RateLimit-Remaining: 950
X-RateLimit-Reset: 1640995200

Support & Resources

Ready to Get Started?

Create your free account and get instant access to the Tools API.