Skip to content

AI Features

FlexGate is the first API gateway with native AI integration — turning live traffic into structured signals that Claude can reason about, without dashboards or noisy logs.


How It Works

Live Traffic


FlexGate Event Bus ──► Structured AI Events (10 types)
    │                        │
    │                        ▼
    │                 AI Incident Created
    │                        │
    │                        ▼
    │                 Claude Analysis
    │                 (root cause + actions)
    │                        │
    ▼                        ▼
Metrics / Logs       Auto-Recovery Actions
                     (circuit break, scale, alert)

Core Concepts

ConceptDescription
AI Events10 structured event types — CIRCUIT_BREAKER_OPENED, HIGH_LATENCY, ERROR_RATE_SPIKE, etc.
AI IncidentsPersisted incident records with Claude analysis, confidence scores, and recommended actions
PlaybooksPre-built response strategies for common failure patterns
Cost TrackingPer-analysis token usage and daily budget controls

Sections

Sections

🎯 Use CasesReal scenarios where FlexGate AI saves the day
🚨 Incident ResponseStep-by-step AI-assisted incident resolution
🔄 Auto-RecoveryAutomated healing playbooks for common failures
💰 Cost OptimizationKeep AI analysis costs under $5/day
🧪 Testing GuideTest AI features without live incidents

Quick Setup

bash
# Set your Claude API key
echo "ANTHROPIC_API_KEY=sk-ant-..." >> .env

# Restart FlexGate
npm start

# Verify AI endpoint
curl http://localhost:3001/api/ai/health

💡 Free Providers: Don't have a Claude API key? FlexGate also supports Gemini and free open-source models. See AI Provider Configuration.

Released under the MIT License.