MinoGAN API Documentation
The MinoGAN API lets you manage your autonomous agent swarm programmatically. Create leads, fetch analytics, configure webhooks, and monitor agent health.
This API is available to all MinoGAN customers. Enterprise plans get higher rate limits and priority support.
Authentication
Authenticate requests using an API key in the X-API-Key header. You'll receive your key after onboarding.
# Example authenticated request
curl -H "X-API-Key: your_api_key_here" \
https://your-instance.minogan.ai/api/metrics
Base URL
Each MinoGAN instance gets a dedicated subdomain:
https://your-instance.minogan.ai/api/
Rate Limits
| Plan | Requests/min | Requests/day |
|---|---|---|
| Starter | 60 | 10,000 |
| Growth | 300 | 50,000 |
| Enterprise | 1,000 | Unlimited |
Create Lead
POST
/api/leads
Create or merge a lead. Deduplicates by email automatically.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| string | Yes* | Lead email address | |
| phone | string | Yes* | Phone number (*email or phone required) |
| name | string | No | Full name |
| source | string | No | Lead source (e.g., "website", "chatbot") |
| metadata | object | No | Custom key-value data |
curl -X POST https://api.minogan.ai/api/leads \
-H "Content-Type: application/json" \
-d '{
"email": "jane@example.com",
"name": "Jane Doe",
"source": "landing_page",
"metadata": {"channel": "google_ads", "campaign": "q1-2026"}
}'
# Response
{"ok": true, "lead_id": "LEAD-00042", "score": 65}
List Leads
GET
/api/leads/data
Returns all leads with scores, sources, and metadata.
Lead Timeline
GET
/leads/{lead_id}/timeline
Returns the full lifecycle timeline for a specific lead.
curl https://api.minogan.ai/leads/LEAD-00042/timeline
# Response
{
"lead_id": "LEAD-00042",
"events": [
{"type": "created", "timestamp": "2026-04-12T14:43:17Z", "details": {"source": "web", "channel": "form"}},
{"type": "re_engaged", "timestamp": "2026-04-13T10:22:05Z", "details": {"source": "chatbot"}},
{"type": "converted", "timestamp": "2026-04-15T09:15:33Z", "details": {"by": "manual"}}
],
"count": 3
}
Export Leads CSV
GET
/api/leads/export
Download all leads as CSV. Requires API key.
Lead Stats
GET
/stats
Summary statistics: total leads, by source, by score tier, by day.
System Metrics
GET
/api/metrics
Real-time system metrics: service count, lead count, page views, uptime.
Attribution Report
GET
/api/metrics/attribution
Lead source attribution with conversion funnels per channel.
Agent Performance
GET
/api/metrics/performance
Per-agent resource usage: CPU, memory, uptime, restart count.
Agent Status
GET
/api/metrics/agents
Live status of all agents: active, sub-state, and health indicators.
Webhook Events
MinoGAN can send real-time notifications to your endpoints when key events occur:
| Event | Description | Payload |
|---|---|---|
| lead.created | New lead captured | Lead object with score |
| lead.hot | Lead scored 80+ | Lead object + score details |
| health.degraded | Agent failure detected | Service name + error |
| health.healed | Agent auto-recovered | Service name + restart count |
| revenue.conversion | Payment received | Amount + lead ID |
| reports.daily | Daily briefing generated | Summary text |
Webhook Configuration
Configure webhooks in your notification hub config (/srv/swarm/data/notification_config.json) or via your admin dashboard:
{
"webhooks": [
{
"url": "https://hooks.slack.com/services/...",
"events": ["lead.hot", "health.degraded"],
"format": "slack"
},
{
"url": "https://discord.com/api/webhooks/...",
"events": ["reports.daily"],
"format": "discord"
}
]
}
Agent Lifecycle
Each agent in your swarm follows this lifecycle:
pending → starting → active → [degraded ↔ healing] → stopped
The Auto-Healer agent monitors all services and automatically restarts failed agents (up to 3x per hour). Persistent failures trigger webhook alerts.
Agent Departments
| Department | Purpose | Agents |
|---|---|---|
| COMMAND | Orchestration & scheduling | Queen, Coordinator, Cron |
| GROWTH | Content, SEO, traffic | Content Factory, Keywords, SEO, Links |
| REVENUE | Leads, nurture, payments | Lead API, Email, SMS, WhatsApp, Stripe |
| FABRIC | UI, copy, testing | Frontend, Copywriter, QA, A/B |
| INTEL | Analytics & reporting | Dashboard, Daily Report, Pixels, Profiler |
| SUPPORT | Customer-facing | Chatbot, Notifications, Exit Intent |
| OPS | Infrastructure | Healer, Backup, Health, NATS, Caddy |
Need help? Book a demo or email api@minogan.ai