Sales Leads REST API
B2C Lead-Generierung aus neuen MaStR-Installationen mit ML-Scoring (0-100 Punkte).
📡 Endpunkt
POST /api/business-intelligence/sales-leads
🎯 Lead Scoring
0-100 Punkte
⚡ Response
300-800ms
📊 Conversion
30-40% (Score ≥70)
REST API Übersicht
HTTP Endpunkt
POST https://api.cernion.de/api/business-intelligence/sales-leads
Authentication
Authorization: Bearer YOUR_API_TOKEN
Request Parameters
| Parameter | Typ | Required | Beschreibung |
|---|---|---|---|
region |
string | ✅ Ja | Region/Stadt/PLZ (z.B. "Bayern", "München", "80331") |
installationType |
enum | ✅ Ja | solar, storage, wallbox, heatpump |
daysBack |
number | ❌ Nein | Zeitfenster 1-365 Tage (default: 30) |
limit |
number | ❌ Nein | Max. Leads (1-100, default: 10) |
minScore |
number | ❌ Nein | Min. Lead-Score 0-100 (default: 60) |
Beispiel Request
{
"region": "Bayern",
"installationType": "solar",
"daysBack": 30,
"limit": 20,
"minScore": 70
}
Response Schema
{
"success": true,
"data": {
"region": "Bayern",
"installationType": "solar",
"timeWindow": "Last 30 days",
"totalLeads": 127,
"qualifiedLeads": 23,
"leads": [
{
"leadId": "LEAD_987654",
"score": 87,
"scoreBreakdown": {
"commissioningDate": 38,
"installationSize": 28,
"location": 16,
"type": 5
},
"installation": {
"mastrNummer": "SEE999888777666",
"capacityKWp": 12.5,
"commissioningDate": "2026-01-15",
"daysOld": 24,
"address": "Musterstraße 42, 80331 München",
"postalCode": "80331",
"type": "solar"
},
"customerProfile": {
"segment": "prosumer",
"estimatedARPU": 1450,
"estimatedLTV": 10000,
"ownerType": "residential"
},
"recommendations": {
"primaryOffer": "Prosumer-Tarif mit Eigenverbrauchsoptimierung",
"crossSell": ["Batteriespeicher nachrüsten", "Wallbox", "Dynamischer Tarif"],
"contactWindow": "30-90 days after commissioning (optimal engagement)",
"conversionProbability": "35-45%"
}
}
],
"statistics": {
"avgScore": 74.2,
"highQualityLeads": 23,
"mediumQualityLeads": 58,
"lowQualityLeads": 46,
"totalEstimatedARPU": "33,350€",
"totalEstimatedLTV": "230,000€"
}
}
}
Code-Beispiele
curl -X POST https://api.cernion.de/api/business-intelligence/sales-leads \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"region": "Bayern",
"installationType": "solar",
"daysBack": 30,
"limit": 20,
"minScore": 70
}'
const API_TOKEN = 'YOUR_API_TOKEN';
async function getSalesLeads() {
const response = await fetch(
'https://api.cernion.de/api/business-intelligence/sales-leads',
{
method: 'POST',
headers: {
'Authorization': `Bearer ${API_TOKEN}`,
'Content-Type': 'application/json'
},
body: JSON.stringify({
region: 'Bayern',
installationType: 'solar',
daysBack: 30,
limit: 20,
minScore: 70
})
}
);
const data = await response.json();
console.log(`Total Leads: ${data.data.totalLeads}`);
console.log(`Qualified: ${data.data.qualifiedLeads}`);
console.log(`Total LTV: ${data.data.statistics.totalEstimatedLTV}\n`);
// Top 5 Leads
data.data.leads.slice(0, 5).forEach(lead => {
console.log(`Lead ${lead.leadId}: Score ${lead.score}`);
console.log(` Address: ${lead.installation.address}`);
console.log(` Capacity: ${lead.installation.capacityKWp} kWp`);
console.log(` ARPU: ${lead.customerProfile.estimatedARPU}€`);
console.log(` Offer: ${lead.recommendations.primaryOffer}\n`);
});
return data;
}
getSalesLeads();
import requests
import pandas as pd
API_TOKEN = 'YOUR_API_TOKEN'
def get_sales_leads(region='Bayern', installation_type='solar', min_score=70):
"""Get qualified sales leads"""
response = requests.post(
'https://api.cernion.de/api/business-intelligence/sales-leads',
headers={
'Authorization': f'Bearer {API_TOKEN}',
'Content-Type': 'application/json'
},
json={
'region': region,
'installationType': installation_type,
'daysBack': 30,
'limit': 50,
'minScore': min_score
}
)
data = response.json()['data']
print(f'\n=== Sales Leads Report ===')
print(f'Region: {data["region"]}')
print(f'Total Leads: {data["totalLeads"]}')
print(f'Qualified (Score ≥{min_score}): {data["qualifiedLeads"]}')
print(f'Total LTV: {data["statistics"]["totalEstimatedLTV"]}\n')
# Convert to DataFrame
leads_df = pd.DataFrame(data['leads'])
# Analysis
print('Score Distribution:')
print(f'High Quality (≥80): {len(leads_df[leads_df["score"] >= 80])}')
print(f'Medium Quality (70-79): {len(leads_df[(leads_df["score"] >= 70) & (leads_df["score"] < 80)])}')
print(f'Lower Quality (60-69): {len(leads_df[(leads_df["score"] >= 60) & (leads_df["score"] < 70)])}')
# Top 10 Leads
print(f'\n=== Top 10 Leads ===')
top_leads = leads_df.nlargest(10, 'score')
for idx, lead in top_leads.iterrows():
print(f'{lead["leadId"]}: Score {lead["score"]} - {lead["installation"]["capacityKWp"]} kWp')
print(f' LTV: {lead["customerProfile"]["estimatedLTV"]}€')
print(f' Offer: {lead["recommendations"]["primaryOffer"]}\n')
return data
if __name__ == '__main__':
leads = get_sales_leads(region='Bayern', installation_type='solar', min_score=70)
Lead-Scoring System (0-100 Punkte)
| Faktor | Max. Punkte | Berechnung |
|---|---|---|
| Commissioning Date | 40 | Neuer = höher. Optimal: 1-90 Tage alt (volle 40 Punkte) |
| Installation Size | 30 | Prosumer Sweet Spot: 5-15 kWp Solar (volle 30 Punkte) |
| Location | 20 | Einkommensstarke Gebiete, günstige Demografie, wenig Wettbewerb |
| Type | 10 | Solar + Storage Combo = Premium Lead (10 Punkte) |
Score-Thresholds
≥80 Punkte: Premium
- Conversion: 50%+
- ARPU: 1.450€ (Prosumer)
- LTV: 10.000€
- Action: Sofortiger Anruf
70-79 Punkte: Gut
- Conversion: 30-40%
- ARPU: 1.200€
- LTV: 7.000€
- Action: E-Mail + Follow-up
60-69 Punkte: Standard
- Conversion: 15-25%
- ARPU: 800€
- LTV: 4.000€
- Action: Automatisierte Kampagne
Anwendungsfälle
🎯 Prosumer-Akquise
10-30 kWp Solar: ARPU 1.450€, LTV 10k€. Filter: minScore=75, installationType=solar
🔋 Speicher-Retrofits
Bestehende Solar ohne Storage → Cross-Sell Battery (ROI 6-12 Jahre, KfW 442 bis 10.200€)
🚗 E-Mobility Leads
Wallbox-Eigentümer → Dynamischer Tarif + Solar-Retrofit. ARPU 950€, Conversion 25%
📍 Territory Planning
Batch-Kampagnen by PLZ für effiziente Außendienst-Routen
ROI durch Lead-Scoring
| Szenario | Leads/Monat | Conversion | ARPU | Revenue/Jahr |
|---|---|---|---|---|
| Premium Leads (Score ≥80) | 20 | 50% | 1.450€ | 174.000€ (120 Kunden) |
| Gute Leads (Score 70-79) | 40 | 35% | 1.200€ | 201.600€ (168 Kunden) |
| Standard Leads (Score 60-69) | 60 | 20% | 800€ | 115.200€ (144 Kunden) |
| Gesamt | 120/Monat | — | 490.800€/Jahr | |
💡 Akquise-Kosten: 150€/Lead × 432 Leads = 64.800€ → ROI 7.6x
FAQ
Wie aktuell sind die MaStR-Daten?
Täglich synchronisiert (max. 24h alt). Neue Installationen erscheinen 2-5 Tage nach Inbetriebnahme im MaStR.
Kann ich eigene Scoring-Kriterien definieren?
Ja, im Business Tier. Gewichten Sie Faktoren nach Ihrer Strategie (z.B. Location +10 Punkte in Gebieten mit geringer Konkurrenz).
Welche Kontaktdaten erhalte ich?
MaStR enthält keine persönlichen Daten (DSGVO). Sie erhalten: Adresse, Anlagendetails, Inbetriebnahmedatum. Für Kontaktaufnahme: Briefpost an Adresse.
Was ist der optimale minScore?
70 Punkte für Balance zwischen Quantität und Qualität (30-40% Conversion). 80+ für Premium-Only (50%+ Conversion, aber weniger Volumen).
Lead-Pipeline automatisieren
120 qualifizierte Leads/Monat = 490k€ zusätzliches Jahresrevenue
Durchschnittliche Setup-Zeit: 5 Minuten. Erste Leads nach wenigen Minuten.