Documentation Index Fetch the complete documentation index at: https://docs.kaireonai.com/llms.txt
Use this file to discover all available pages before exploring further.
Prerequisites
A KaireonAI instance (or the playground )
An API key (from Settings > API Explorer)
Your tenant ID
Node.js 22+ installed
Step 1: Clone and Install
git clone https://github.com/kaireonai/platform.git
cd platform
npm install
Claude Code
Cursor
VS Code
npm Script
claude mcp add kaireonai -- npx tsx /path/to/kaireonai/platform/src/mcp/server.ts
Set environment variables in your Claude settings (.claude/settings.json): {
"mcpServers" : {
"kaireonai" : {
"command" : "npx" ,
"args" : [ "tsx" , "/path/to/kaireonai/platform/src/mcp/server.ts" ],
"env" : {
"KAIREON_API_URL" : "https://playground.kaireonai.com" ,
"KAIREON_API_KEY" : "your-api-key" ,
"KAIREON_TENANT_ID" : "your-tenant-id"
}
}
}
}
Add to .cursor/mcp.json: {
"mcpServers" : {
"kaireonai" : {
"command" : "npx" ,
"args" : [ "tsx" , "/path/to/kaireonai/platform/src/mcp/server.ts" ],
"env" : {
"KAIREON_API_URL" : "https://playground.kaireonai.com" ,
"KAIREON_API_KEY" : "your-api-key" ,
"KAIREON_TENANT_ID" : "your-tenant-id"
}
}
}
}
Create .vscode/mcp.json: {
"servers" : {
"kaireonai" : {
"type" : "stdio" ,
"command" : "npx" ,
"args" : [ "tsx" , "/path/to/kaireonai/platform/src/mcp/server.ts" ],
"env" : {
"KAIREON_API_URL" : "https://playground.kaireonai.com" ,
"KAIREON_API_KEY" : "your-api-key" ,
"KAIREON_TENANT_ID" : "your-tenant-id"
}
}
}
}
You can also start the server directly: cd platform
KAIREON_API_URL = https://playground.kaireonai.com \
KAIREON_API_KEY=your-api-key \
KAIREON_TENANT_ID=your-tenant-id \
npm run mcp
Replace /path/to/kaireonai/platform/src/mcp/server.ts with the actual absolute path to your cloned repository.
Step 3: Your First Queries
Try these natural language commands in your AI IDE:
Explore your setup
Show me the active Decision Flows
What offers do I have configured?
Create entities
Create a new offer called "Summer Savings" in the cross-sell category with priority 75
Create a V2 decision flow called "cross-sell-v2" with diversity ranking and 5 max candidates
Add an enrich node to the cross-sell-v2 flow that loads customer data from the customers schema
Analyze and simulate
Run a health check on my tenant
Explain why customer C-1234 didn't receive the premium card offer
Simulate what happens if I lower the email frequency cap to 2 per week
V2 Pipeline operations
What scoring methods are available?
List the ranking algorithms I can use
Add a filter node to my flow that only keeps offers where priority > 50
Update the score node in my flow to use formula scoring with 40% propensity, 30% value, 20% context, 10% lever
Step 4: Build a Complete Setup
Here’s a full workflow you can give to your AI IDE:
Help me set up a complete telecom cross-sell decisioning flow:
1. Create a "telecom_customers" schema with fields: customer_id, tenure, monthly_spend, plan_type
2. Create two offers: "5G Upgrade" (priority 80) and "Family Plan" (priority 60)
3. Create an email channel
4. Create a V2 decision flow with:
- Enrich from telecom_customers
- Qualify: only customers with tenure > 12 months
- Score with formula method (50% propensity, 30% value, 20% context)
- Rank using diversity to mix offer categories
- Return top 3 offers
5. Run a health check when done
Troubleshooting
”KAIREON_API_KEY environment variable is required”
Make sure the environment variables are set in your IDE’s MCP configuration, not just your shell. Each IDE reads env vars from its own config file.
”API error: 401”
Your API key is invalid or expired. Generate a new one from Settings > API Explorer in the KaireonAI UI.
”API error: 403”
Your API key doesn’t have permission for that operation. Check the role assigned to the key in Settings.
”Flow is not V2”
The Decision Flow you’re trying to modify uses the legacy (V1) config format. Use createV2DecisionFlow to create a new V2 flow, or manually set draftConfig.version = 2 in the UI canvas editor.
Server won’t start
Ensure you have Node.js 22+ and have run npm install in the platform directory. The MCP server requires the @modelcontextprotocol/sdk and zod packages.
The MCP server exposes 105 tools organized by category:
Category Count Examples Data Read/Write 11 listSchemas, createSchema, addSchemaFieldStudio Read/Write 17 listOffers, createOffer, createDecisionFlowV2 Pipeline 9 listV2NodeTypes, createV2DecisionFlow, addV2PipelineNodeAlgorithm & Model 8 trainModel, addPredictor, createExperimentBehavioral Metrics 5 createBehavioralMetric, computeMetricNow, createMetricRuleContent & CMS 10 generateCreativeCopy, createContentItem, syncContentSourceDecisioning 2 recommend, recordOutcomeIntelligence 15 explainDecision, analyzeModelHealth, simulateRuleChangeCustomer & Journey 7 getCustomerProfile, listJourneys, listInteractionsAdministration 9 getTenantSettings, listAuditLogs, listApprovalRequestsDocs 1 searchDocs
See the full MCP Server Reference for complete parameter documentation.
Next Steps
MCP Server Reference See all 105 tools with parameter documentation.
AI Workflows Learn common AI-assisted workflows.
AI Assistant Use the built-in AI assistant in the KaireonAI UI.
Composable Pipeline Learn about the V2 pipeline architecture.