Version: 2.0.0
Generated: August 25, 2025
Status: 🚀 LIVE IN PRODUCTION - 17 failures processed, 1 repository analyzed
🤖 **Intelligent CI/CD Failure Analysis & Fixing Platform**
**PRODUCTION VALIDATED SYSTEM** processing real GitHub Actions failures with AI-powered analysis.
## 🚀 **Key Features**
* **Portia AI Framework**: Structured plan-based analysis workflows (7 custom CI/CD tools)
* **Google Gemini 2.5 Pro**: Advanced AI error analysis and fix generation (100% operational)
* **GitHub Integration**: Real-time webhook processing and API integration (tested with real data)
* **PostgreSQL Database**: Complete audit trails and analytics storage (Supabase cloud)
* **ML Analytics**: Pattern recognition, success prediction, and learning (active)
* **Human Approval**: Safe fix application with approval workflows (41.18% approval rate)
## 🔧 **Core Capabilities**
* Analyze failed GitHub Actions workflows (17 failures processed)
* Generate intelligent fix suggestions (100% generation rate)
* Track fix effectiveness over time (comprehensive metrics)
* Learn from repository-specific patterns (chaitanyak175/ci-cd-test-repo)
* Provide comprehensive analytics and insights (live dashboard)
## 📊 **Analytics & Learning**
* Pattern recognition across repositories (multi-language support: Python, JavaScript, Docker)
* ML-based success prediction for fixes (confidence scoring up to 82.38%)
* Repository-specific intelligence (individual profiles)
* Historical analysis and trend detection (real production data)
* Enhanced fix generation with ML insights (context-aware)
---
**Base URL**: `https://ci-cd-fixer-agent-backend.onrender.com` (🚀 **LIVE PRODUCTION**) | `http://localhost:8000` (Development)
- 🚀 Production:
https://ci-cd-fixer-agent-backend.onrender.com✅ LIVE & OPERATIONAL - Development:
http://localhost:8000
📊 Production Status: 17 failures processed | 1 repository analyzed | All services healthy
Currently, this API does not require authentication for development. For production deployment, implement:
Authorization: Bearer <your_jwt_token>Endpoint:
GET /Root endpoint with API information.
Responses:
200 - Successful Response
Endpoint:
POST /webhookHandle GitHub webhook for workflow_run events.
Responses:
200 - Successful Response
Endpoint:
POST /analyze/portiaAnalyze CI/CD failure using Portia's plan-based approach.
Request Body:
{
// Request body based on schema
}Responses:
200 - Successful Response
422 - Validation Error
Endpoint:
GET /fixesGet all pending fixes that require human approval.
Responses:
200 - Successful Response
Endpoint:
POST /fixes/{fix_id}/approveApprove a suggested fix.
Path Parameters:
fix_id(required) —
Responses:
200 - Successful Response
422 - Validation Error
Endpoint:
POST /fixes/{fix_id}/rejectReject a suggested fix.
Path Parameters:
fix_id(required) —
Responses:
200 - Successful Response
422 - Validation Error
Endpoint:
POST /plans/{plan_run_id}/clarifications/{clarification_id}Respond to a Portia plan clarification.
Request Body:
{
// Request body based on schema
}Path Parameters:
plan_run_id(required) —clarification_id(required) —
Responses:
200 - Successful Response
422 - Validation Error
Endpoint:
GET /analytics/patternsGet pattern analysis of workflow failures over the specified period.
Query Parameters:
days_back(integer, default=30) —
Responses:
200 - Successful Response
422 - Validation Error
Endpoint:
GET /analytics/effectivenessGet statistics on fix effectiveness and approval rates.
Responses:
200 - Successful Response
Endpoint:
GET /analytics/repository/{owner}/{repo}Get detailed analytics profile for a specific repository.
Path Parameters:
owner(required) —repo(required) —
Responses:
200 - Successful Response
422 - Validation Error
Endpoint:
GET /analytics/dashboardGet comprehensive analytics dashboard data.
Responses:
200 - Successful Response
Endpoint:
POST /analytics/ml/similar-fixesFind similar fixes using ML-based pattern recognition.
Request Body:
{
// Request body based on schema
}Responses:
200 - Successful Response
422 - Validation Error
Endpoint:
POST /analytics/ml/predict-successPredict the success probability of a proposed fix.
Request Body:
{
// Request body based on schema
}Responses:
200 - Successful Response
422 - Validation Error
Endpoint:
POST /analytics/ml/generate-enhanced-fixGenerate an enhanced fix recommendation using ML insights.
Request Body:
{
// Request body based on schema
}Responses:
200 - Successful Response
422 - Validation Error
Endpoint:
POST /analytics/ml/learn-from-feedbackLearn from user feedback to improve future recommendations.
Request Body:
{
// Request body based on schema
}Responses:
200 - Successful Response
422 - Validation Error
Endpoint:
GET /analytics/ml/pattern-insightsGet insights from learned patterns and ML models.
Responses:
200 - Successful Response
Endpoint:
GET /analytics/ml/model-performanceGet performance metrics of the ML models.
Responses:
200 - Successful Response
Endpoint:
GET /healthCheck the overall health and status of all system components.
Returns the status of:
- Database: PostgreSQL connection status
- GitHub API: GitHub service availability
- Gemini AI: Google Gemini API availability
This endpoint is useful for monitoring and ensuring all services are operational.
Responses:
200 - System is healthy
{
"status": "healthy",
"timestamp": "2025-08-23T10:00:00.000000",
"services": {
"database": "connected",
"github_api": "available",
"gemini_api": "available"
}
}500 - System health check failed
Endpoint:
POST /analyzeManually trigger CI/CD failure analysis for a specific GitHub Actions workflow run.
This endpoint allows you to analyze any workflow run by providing:
- owner: GitHub repository owner/organization
- repo: Repository name
- run_id: GitHub Actions workflow run ID
The analysis will be processed asynchronously and stored in the database for later retrieval. Use this when you want to analyze a specific failed workflow run manually.
Request Body:
{
// Request body based on schema
}Responses:
200 - Analysis triggered successfully
{
"message": "Analysis triggered successfully",
"failure_id": "7",
"owner": "microsoft",
"repo": "vscode",
"run_id": 17152193292
}400 - Invalid request parameters
500 - Internal server error
422 - Validation Error
All endpoints tested on August 25, 2025 against the live production system.
GET /healthLive Response:
{
"status": "healthy",
"timestamp": "2025-08-25T08:15:16.896858",
"services": {
"database": "connected",
"github_api": "available",
"gemini_api": "available"
}
}GET /failuresLive Response:
{
"failures": [
{
"id": 95,
"repo_name": "ci-cd-test-repo",
"owner": "chaitanyak175",
"workflow_name": "🔴 Broken Python Advanced CI",
"run_id": 17199274412,
"status": "failed",
"conclusion": "failure",
"suggested_fix": "**Description:** Fix Docker build configuration...",
"fix_status": "pending",
"created_at": "2025-08-25T04:44:00.605028"
}
],
"count": 17
}GET /analytics/dashboardLive Response:
{
"message": "Analytics dashboard generated",
"dashboard": {
"failure_patterns": {
"total_runs": 17,
"patterns": {
"most_failing_repos": {
"chaitanyak175/ci-cd-test-repo": 17
},
"language_distribution": {
"python": 4,
"javascript": 4,
"docker": 2
}
}
},
"fix_effectiveness": {
"overall_stats": {
"total_fixes": 17,
"approved_fixes": 7,
"approval_rate": 41.18,
"pending_rate": 58.82
}
}
}
}POST /analytics/ml/predict-success
Content-Type: application/json
{
"error_log": "npm install failed",
"suggested_fix": "use --legacy-peer-deps"
}Live Response:
{
"message": "Fix success prediction completed",
"prediction": {
"predicted_success_rate": 0.8238,
"confidence": 0.76,
"factors": {
"similarity_match": 1.0,
"repo_history": 0.5,
"fix_complexity": 0.994,
"error_type_reliability": 0.8
},
"recommendations": [
"✅ High success probability - safe to apply automatically"
],
"similar_fixes_found": 4
}
}GET /analytics/ml/model-performanceLive Response:
{
"message": "ML model performance analysis completed",
"performance": {
"data_summary": {
"total_fixes_last_30_days": 17,
"approved_fixes": 4,
"approval_rate": 0.23529411764705882
},
"model_capabilities": {
"similarity_matching": "✅ Operational",
"success_prediction": "✅ Operational",
"pattern_learning": "✅ Operational",
"adaptive_improvement": "✅ Operational"
}
}
}GET /fixesLive Response:
{
"pending_fixes": [
{
"id": 95,
"repo_name": "ci-cd-test-repo",
"owner": "chaitanyak175",
"workflow_name": "🔴 Broken Python Advanced CI",
"suggested_fix": "**Description:** Fix Docker build configuration...",
"fix_status": "pending",
"created_at": "2025-08-25T04:44:00.605028"
}
]
}The production system includes 24 fully functional endpoints:
GET / # API welcome
GET /health # Health check
GET /ping # Simple ping
POST /webhook # GitHub webhooks
POST /webhook/test # Test webhooks
POST /analyze # Manual analysis
POST /analyze/portia # Portia analysis
GET /failures # All failures
GET /failures/{failure_id} # Specific failure
GET /fixes # Pending fixes
POST /fixes/{fix_id}/approve # Approve fix
POST /fixes/{fix_id}/reject # Reject fix
POST /fixes/{fix_id}/apply # Apply fix
GET /fixes/{fix_id}/status # Fix status
GET /analytics/dashboard # Dashboard
GET /analytics/patterns # Pattern analysis
GET /analytics/effectiveness # Fix effectiveness
GET /analytics/repository/{owner}/{repo} # Repo analytics
POST /analytics/ml/predict-success # ML prediction
GET /analytics/ml/model-performance # ML performance
POST /analytics/ml/similar-fixes # Similar fixes
POST /analytics/ml/pattern-insights # Pattern insights
POST /analytics/ml/generate-enhanced-fix # Enhanced fixes
POST /analytics/ml/learn-from-feedback # Learn feedback
GET /plans/{plan_run_id}/clarifications/{clarification_id} # ClarificationsDevelopers can access the machine-readable schema:
GET /openapi.json
This schema can be imported into Postman, Insomnia, Swagger Editor, or GitHub Copilot for autocompletion and testing.
- Swagger UI:
GET /docs- Interactive API testing interface - ReDoc:
GET /redoc- Clean documentation interface
All error responses follow this format:
{
"detail": "Error message describing what went wrong"
}Common HTTP status codes:
200- Success400- Bad Request (invalid parameters)401- Unauthorized (authentication required)404- Not Found (resource doesn't exist)422- Validation Error (invalid request body)500- Internal Server Error
Generated automatically from OpenAPI schema ✨