name: nexus description: "Kailash Nexus — MANDATORY for HTTP/API/CLI/MCP unified deployment. Direct FastAPI/Flask BLOCKED."
Kailash Nexus - Multi-Channel Platform Framework
Nexus is a zero-config multi-channel platform built on Kailash Core SDK that deploys workflows as API + CLI + MCP simultaneously.
Features
Nexus transforms workflows into a complete platform with:
- Zero Configuration: Deploy workflows instantly without boilerplate code
- Multi-Channel Access: API, CLI, and MCP from single deployment
- Unified Sessions: Consistent session management across all channels
- Enterprise Features: Health monitoring, plugins, event system, comprehensive logging
- DataFlow Integration: Automatic CRUD API generation from database models
- Production Ready: Deployment patterns, monitoring, troubleshooting guides
- Zero-Config Platform: Workflow-based platform without manual route definition
- Async-First: Uses AsyncLocalRuntime by default for optimal performance
Quick Start
from nexus import Nexus
# Define workflow
workflow = create_my_workflow()
# Deploy to all channels at once
app = Nexus()
app.register("my_workflow", workflow.build())
app.start()
# Now available via:
# - HTTP API: POST http://localhost:8000/api/workflow/{workflow_id}
# - CLI: nexus run {workflow_id} --input '{"key": "value"}'
# - MCP: Connect via MCP client (Claude Desktop, etc.)
Reference Documentation
Getting Started
- nexus-quickstart - Quick start guide
- nexus-installation - Installation and setup
- nexus-architecture - Architecture overview
- README - Framework overview
- nexus-comparison - Nexus vs traditional frameworks
Core Concepts
- nexus-workflow-registration - Registering workflows
- nexus-multi-channel - Multi-channel architecture
- nexus-sessions - Session management
- nexus-config-options - Configuration options
Channel-Specific Patterns
- nexus-api-patterns - HTTP API patterns
- nexus-api-input-mapping - API input handling
- nexus-cli-patterns - CLI usage patterns
- nexus-mcp-channel - MCP channel configuration
Integration
- nexus-dataflow-integration - DataFlow + Nexus patterns
- nexus-plugins - Plugin system
- nexus-event-system - Event-driven architecture
Production & Operations
- nexus-production-deployment - Production deployment
- nexus-health-monitoring - Health checks and monitoring
- nexus-enterprise-features - Enterprise capabilities
- nexus-troubleshooting - Common issues and solutions
v1.3.0 Additions
- nexus-handler-support -
@app.handler()decorator for direct function registration - nexus-auth-plugin - NexusAuthPlugin unified auth (JWT, RBAC, SSO, rate limiting, tenant, audit)
- golden-patterns-catalog - Top 7 production-validated codegen patterns
- codegen-decision-tree - Decision tree, anti-patterns, scaffolding templates
Key Concepts
Zero-Config Platform
Nexus eliminates boilerplate:
- No manual routes - Automatic API generation from workflows
- No CLI arg parsing - Automatic CLI creation
- No MCP server setup - Automatic MCP integration
- Unified deployment - One command for all channels
Multi-Channel Architecture
Single deployment, three access methods:
- HTTP API: RESTful JSON endpoints
- CLI: Command-line interface
- MCP: Model Context Protocol server
Unified Sessions
Consistent session management:
- Cross-channel session tracking
- Session state persistence
- Session-scoped workflows
- Concurrent session support
Enterprise Features
Production-ready capabilities:
- Health monitoring endpoints
- Plugin system for extensibility
- Event system for integrations
- Comprehensive logging and metrics
- Correct channel initialization flow
- Proper workflow registration
When to Use This Skill
Use Nexus when you need to:
- Deploy workflows as production platforms
- Provide multiple access methods (API/CLI/MCP)
- Build enterprise platforms quickly
- Auto-generate CRUD APIs (with DataFlow)
- Replace traditional frameworks with workflow-based platform
- Create multi-channel applications
- Deploy AI agent platforms (with Kaizen)
Integration Patterns
With DataFlow (Auto CRUD API)
from nexus import Nexus
from dataflow import DataFlow
# Define models
db = DataFlow(...)
@db.model
class User:
id: str
name: str
# Auto-generates CRUD endpoints for all models
app = Nexus()
for name, wf in db.get_workflows().items():
app.register(name, wf)
app.start()
# GET /api/User/list
# POST /api/User/create
# GET /api/User/read/{id}
# PUT /api/User/update/{id}
# DELETE /api/User/delete/{id}
With Kaizen (Agent Platform)
from nexus import Nexus
from kaizen.core.base_agent import BaseAgent
# Deploy agents via all channels
agent_workflow = create_agent_workflow()
app = Nexus()
app.register("agent", agent_workflow.build())
app.start()
# Agents accessible via API, CLI, and MCP
With Core SDK (Custom Workflows)
from nexus import Nexus
from kailash.workflow.builder import WorkflowBuilder
# Deploy custom workflows
app = Nexus()
app.register("workflow_1", create_workflow_1().build())
app.register("workflow_2", create_workflow_2().build())
app.register("workflow_3", create_workflow_3().build())
app.start()
Standalone Platform
from nexus import Nexus
# Complete platform from workflows
app = Nexus()
app.register("workflow_a", workflow_a.build())
app.register("workflow_b", workflow_b.build())
app.start()
Critical Rules
- ✅ Use Nexus for workflow platforms
- ✅ Register workflows, not individual routes
- ✅ Leverage unified sessions across channels
- ✅ Enable health monitoring in production
- ✅ Use plugins for custom behavior
- ✅ Nexus uses AsyncLocalRuntime by default (correct for Docker)
- ❌ NEVER mix raw HTTP routes with Nexus
- ❌ NEVER implement manual API/CLI/MCP servers when Nexus can do it
- ❌ NEVER skip health checks in production
Deployment Patterns
Development
app = Nexus()
app.register("my_workflow", workflow.build())
app.start() # Single process, hot reload
Production (Docker)
from nexus import Nexus
app = Nexus()
app.register("my_workflow", workflow.build())
app.start() # Uses AsyncLocalRuntime by default (correct for Docker)
With Load Balancer
# Deploy multiple Nexus instances behind nginx/traefik
docker-compose up --scale nexus=3
Channel Comparison
| Feature | API | CLI | MCP |
|---|---|---|---|
| Access | HTTP | Terminal | MCP Clients |
| Input | JSON | Args/JSON | Structured |
| Output | JSON | Text/JSON | Structured |
| Sessions | ✓ | ✓ | ✓ |
| Auth | ✓ | ✓ | ✓ |
| Streaming | ✓ | ✓ | ✓ |
Related Skills
- 01-core-sdk - Core workflow patterns
- 02-dataflow - Auto CRUD API generation
- 04-kaizen - AI agent deployment
- 05-kailash-mcp - MCP channel details
- 17-gold-standards - Best practices
Support
For Nexus-specific questions, invoke:
nexus-specialist- Nexus implementation and deploymentrelease-specialist- Production deployment patterns- ``decide-framework
skill- When to use Nexus vs other approaches