E-Mail-Health-Monitoring über die Public API von Nova Uptime: Integrationsleitfaden für Entwickler
Baue mit der REST-API von Nova Uptime ein eigenes E-Mail-Health-Monitoring in deine Plattform. Kompletter Guide mit Code-Beispielen, Rate Limits und.
Warum die API von Nova Uptime für E-Mail-Health-Monitoring nutzen?#
Wenn du Kunden-Domains verwaltest (SaaS-Plattform, Hosting-Anbieter, Agentur), musst du die E-Mail-Health über alle hinweg programmatisch prüfen.
Drei Ansätze:
- Manuell: Jede Domain im Dashboard von Nova Uptime checken. Nicht skalierbar.
- WHOIS-Abfragen: Eigenes Parsing für DKIM/SPF/DMARC schreiben. Komplex, unzuverlässig.
- Nova Uptime Public API: REST-API, die die ganze Komplexität abnimmt. Skalierbar, zuverlässig, gepflegt.
Dieser Guide deckt den API-Ansatz ab.
API-Überblick#
Base URL: https://api.novauptime.com/api/v1
Authentifizierung: X-API-Key Header
Rate Limits: 50 Requests/Stunde im kostenlosen Tier, 1.000/Stunde in den kostenpflichtigen Plänen
Response-Format:
{
"success": true,
"data": { ... },
"message": "Optional message"
}
Schritt 1: Generiere deinen API-Key#
- Logge dich auf go.novauptime.com ein
- Settings → API Keys
- Klicke auf "Generate New Key"
- Kopiere den 20-stelligen Key (z. B.
abc123def456ghi789jk) - Speichere ihn sicher (nicht ins Git committen!)
Environment-Variable:
export NOVAUPTIME_API_KEY="abc123def456ghi789jk"
Schritt 2: E-Mail-Health für eine Domain prüfen#
Endpoint: GET /domains/{domain}/email-health
Beispiel-Request:
curl -H "X-API-Key: abc123def456ghi789jk" \
https://api.novauptime.com/api/v1/domains/example.com/email-health
Response:
{
"success": true,
"data": {
"domain": "example.com",
"score": 92,
"grade": "A",
"timestamp": "2026-02-20T10:30:00Z",
"records": {
"mx": {
"status": "configured",
"value": "mail.example.com"
},
"spf": {
"status": "configured",
"value": "v=spf1 include:sendgrid.net -all",
"lookups": 4
},
"dkim": {
"status": "configured",
"selectors": ["s1", "s2"],
"configured_count": 2
},
"dmarc": {
"status": "configured",
"policy": "reject"
},
"blacklist": {
"status": "clean",
"checked_against": 4,
"listed_on": 0
}
},
"recommendations": [
{
"type": "warning",
"message": "SPF record has 4 lookups (limit is 10). Consider consolidating includes.",
"action": "Use SPF flattening service or consolidate email providers"
}
]
}
}
Praxis-Use-Cases#
Use Case 1: Agentur-Dashboard#
Du bist eine Agentur und betreust 100+ Kunden-Websites. Du willst jedem Kunden seine E-Mail-Health im eigenen Dashboard zeigen.
Implementierung:
// Express.js route to fetch email health
app.get("/client/:clientId/email-health", async (req, res) => {
const clientId = req.params.clientId;
// Get client's domain from database
const client = await Client.findById(clientId);
const domain = client.primaryDomain;
// Fetch email health from Nova Uptime
const response = await fetch(
`https://api.novauptime.com/api/v1/domains/${domain}/email-health`,
{
headers: { "X-API-Key": process.env.NOVAUPTIME_API_KEY }
}
);
const emailHealth = await response.json();
// Return to frontend
res.json(emailHealth.data);
});
Use Case 2: Automatisches E-Mail-Health-Scoring#
Bewerte alle Kunden-Domains und alarmiere bei Verschlechterung.
Implementierung:
// Cron job: Check all domains daily
async function dailyEmailHealthAudit() {
const domains = await Domain.find();
for (const domain of domains) {
// Fetch current score
const current = await fetchEmailHealth(domain.name);
// Compare to previous day
const previous = await EmailHealthHistory.findLatest(domain.name);
if (current.data.score < previous.score - 5) {
// Score dropped >5 points, alert
await sendSlackAlert({
domain: domain.name,
oldScore: previous.score,
newScore: current.data.score,
change: current.data.score - previous.score
});
}
// Store history
await EmailHealthHistory.create({
domain: domain.name,
score: current.data.score,
timestamp: new Date()
});
}
}
Use Case 3: Bulk-Domain-Audit#
Du hast einen Wettbewerber übernommen. 50 neue Kunden-Domains. Du willst den E-Mail-Health-Status für alle.
Implementierung:
// Fetch email health for 50 domains
async function auditAcquiredDomains(acquiredDomains) {
const results = [];
// Fetch with concurrency limit (5 at a time)
for (const domain of acquiredDomains) {
const health = await fetchEmailHealth(domain);
results.push({
domain,
score: health.data.score,
grade: health.data.grade,
issues: health.data.recommendations
});
}
// Export to CSV
const csv = convertToCSV(results);
fs.writeFileSync("email-health-audit.csv", csv);
// Summary: 40 domains healthy, 10 need fixes
console.log(`Healthy: ${results.filter(r => r.score > 80).length}`);
console.log(`Need fixes: ${results.filter(r => r.score < 80).length}`);
}
API-Patterns für die Production#
Pattern 1: Caching mit Ablaufzeit#
Rufe die API nicht bei jedem Request auf. Cache die Ergebnisse lokal.
const redis = require("redis");
const client = redis.createClient();
async function getEmailHealthCached(domain, maxAge = 3600) {
// Try cache first
const cached = await client.get(`email-health:${domain}`);
if (cached) {
return JSON.parse(cached);
}
// Cache miss, fetch from API
const health = await fetchEmailHealth(domain);
// Store in cache for 1 hour
await client.setex(
`email-health:${domain}`,
maxAge,
JSON.stringify(health.data)
);
return health.data;
}
Pattern 2: Rate-Limit-Handling#
Die API von Nova Uptime hat Rate Limits. Geh damit sauber um.
async function fetchWithRetry(domain, maxRetries = 3) {
for (let i = 0; i < maxRetries; i++) {
try {
const response = await fetch(
`https://api.novauptime.com/api/v1/domains/${domain}/email-health`,
{
headers: { "X-API-Key": process.env.NOVAUPTIME_API_KEY },
timeout: 10000
}
);
if (response.status === 429) {
// Rate limited, wait before retry
const retryAfter = response.headers.get("Retry-After") || (2 ** i);
console.log(`Rate limited. Retrying in ${retryAfter}s`);
await new Promise(r => setTimeout(r, retryAfter * 1000));
continue;
}
if (!response.ok) throw new Error(`HTTP ${response.status}`);
return await response.json();
} catch (error) {
if (i === maxRetries - 1) throw error;
console.log(`Attempt ${i + 1} failed, retrying...`);
await new Promise(r => setTimeout(r, (2 ** i) * 1000));
}
}
}
Pattern 3: Batch-Verarbeitung#
Wenn du 100+ Domains prüfst, fasse Requests effizient zusammen.
async function batchEmailHealthCheck(domains) {
const batchSize = 10; // 10 concurrent requests
const results = [];
for (let i = 0; i < domains.length; i += batchSize) {
const batch = domains.slice(i, i + batchSize);
// Process batch concurrently
const batchResults = await Promise.all(
batch.map(domain => fetchEmailHealth(domain))
);
results.push(...batchResults);
// Log progress
console.log(`Processed ${Math.min(i + batchSize, domains.length)}/${domains.length}`);
}
return results;
}
Pattern 4: Ergebnisse lokal speichern#
Speichere E-Mail-Health-Ergebnisse in deiner eigenen Datenbank für historisches Tracking.
// Database model
const EmailHealthSchema = {
domain: String,
score: Number,
grade: String,
records: {
mx: Object,
spf: Object,
dkim: Object,
dmarc: Object,
blacklist: Object
},
timestamp: Date,
createdAt: Date
};
async function storeEmailHealth(domain) {
const health = await fetchEmailHealth(domain);
// Store in DB
const record = new EmailHealthLog({
domain,
score: health.data.score,
grade: health.data.grade,
records: health.data.records,
timestamp: new Date(health.data.timestamp),
createdAt: new Date()
});
await record.save();
return record;
}
Pattern 5: Alerts bei Veränderungen#
Tracke Veränderungen und benachrichtige das Team, wenn etwas kaputtgeht.
async function monitorEmailHealth(domain) {
const current = await getEmailHealthCached(domain);
const previous = await EmailHealthLog.findLatest(domain);
if (!previous) {
// First check, just store it
await storeEmailHealth(domain);
return;
}
// Detect changes
const scoreChange = current.score - previous.score;
if (scoreChange < -10) {
// Major degradation
await alertSlack({
channel: "#email-alerts",
message: `
${domain}: Email health degraded
Previous: ${previous.score} (${previous.grade})
Current: ${current.score} (${current.grade})
Change: ${scoreChange < 0 ? "" : "+"}${scoreChange}
Issues: ${current.recommendations.map(r => r.message).join("\n")}
`
});
}
}
Error-Handling#
Häufige Fehlerszenarien:
async function robustEmailHealthCheck(domain) {
try {
const health = await fetchWithRetry(domain);
return health.data;
} catch (error) {
if (error.code === "ENOTFOUND") {
// Domain doesn't exist
console.error(`Domain ${domain} not found`);
return null;
} else if (error.statusCode === 401) {
// Invalid API key
console.error("Invalid Nova Uptime API key");
return null;
} else if (error.statusCode === 429) {
// Rate limited (even after retries)
console.error("Rate limit exceeded");
return null;
} else {
// Unknown error
console.error(`Error checking ${domain}: ${error.message}`);
return null;
}
}
}
Frontend-Integration#
React-Component-Beispiel#
import { useState, useEffect } from 'react';
function EmailHealthCard({ domain }) {
const [health, setHealth] = useState(null);
const [loading, setLoading] = useState(true);
const [error, setError] = useState(null);
useEffect(() => {
async function fetchHealth() {
try {
const response = await fetch(`/api/email-health/${domain}`);
const data = await response.json();
setHealth(data);
} catch (err) {
setError(err.message);
} finally {
setLoading(false);
}
}
fetchHealth();
}, [domain]);
if (loading) return <div>Loading...</div>;
if (error) return <div>Error: {error}</div>;
return (
<div className="email-health-card">
<h3>{domain}</h3>
<div className={`score score-${health.grade}`}>
{health.score}/100 ({health.grade})
</div>
<div className="records">
{Object.entries(health.records).map(([key, value]) => (
<div key={key} className={`record ${value.status}`}>
<strong>{key.toUpperCase()}</strong>: {value.status}
</div>
))}
</div>
{health.recommendations.length > 0 && (
<div className="recommendations">
<h4>Recommendations:</h4>
<ul>
{health.recommendations.map((rec, i) => (
<li key={i} className={rec.type}>
{rec.message}
</li>
))}
</ul>
</div>
)}
</div>
);
}
API-Dokumentations-Referenz#
Base URL: https://api.novauptime.com/api/v1
Endpoints:
GET /domains/{domain}/email-health
→ Check email health for domain
→ Rate limit: 50/hour (free), 1000/hour (paid)
→ Response: Email health score, grade, records, recommendations
GET /domains/{domain}/incidents
→ Get last 20 downtime incidents
→ Optional param: limit, offset
GET /domains/{domain}/history
→ Get check history (configurable hours, max 720h)
→ Optional params: hours (default 168), limit (default 500)
GET /domains
→ List user's domains (paginated, max 50/page)
→ Optional params: page, limit
Best Practices#
- Aggressiv cachen: Die E-Mail-Health ändert sich nicht oft. Cache für 1-24 Stunden.
- Requests bündeln: Prüfe 10 Domains gleichzeitig, nicht eine nach der anderen.
- Fehler sauber abfangen: Netzwerkprobleme passieren. Retry mit Exponential Backoff.
- API überwachen: Tracke deinen API-Verbrauch. Wenn du dich dem Rate Limit näherst, cache länger.
- API-Key absichern: Niemals ins Git committen. Nutze Environment-Variablen.
- Rate Limits testen: Simuliere hohes Volumen, bevor du in Production gehst.
Zusammenfassung: API-Integrations-Checkliste#
- ✅ API-Key generieren und absichern
- ✅ Basic E-Mail-Health-Check implementieren
- ✅ Caching-Layer hinzufügen (Redis oder In-Memory)
- ✅ Rate-Limit-Handling implementieren
- ✅ Error-Handling für häufige Fehler einbauen
- ✅ Mit deiner echten Domain testen
- ✅ Frontend-Component bauen, das die Ergebnisse anzeigt
- ✅ Alerts für Score-Veränderungen einrichten
- ✅ API-Key-Management im Team-Wiki dokumentieren
- ✅ API-Verbrauch und Kontingent monitoren
Heute loslegen#
Die Public API von Nova Uptime ist auch im kostenlosen Tier verfügbar. Generiere deinen ersten API-Key in den Settings und starte mit der Integration von E-Mail-Health-Checks in deine Plattform.
Für die ausführliche API-Referenz besuche die Nova Uptime API-Dokumentation.
Monitor Your Website Before It Goes Down
Get uptime monitoring, SSL tracking, domain expiry alerts, and email health checks. Free plan — no credit card required.
Start Monitoring FreeVerwandte Artikel
So integrierst du Uptime Monitoring per API in deine App
Ein Developer-Guide zur Integration von Website-Uptime-Monitoring über die REST API von Nova Uptime. Inklusive Authentifizierung, Endpoints.
Die besten kostenlosen E-Mail-Health-Tools 2026: Ein Vergleich
8 Free E-Mail-Health-Checker verglichen: Nova Uptime, MXToolbox, DMARCian, EasyDMARC, Postmark, Mailtrap, Sender Score, ZeroBounce. SPF/DKIM/DMARC + Blacklists.
Domain-Health-Check: Ein vollständiges kostenloses Audit (DNS + SSL + E-Mail + Uptime)
Mach in 5 Minuten ein komplettes kostenloses Domain-Health-Audit: DNS, SSL, E-Mail-Auth (SPF/DKIM/DMARC), Blacklists und Uptime.