Skip to main content

Quick Start

Installation

pip install nexroo-cli
nexroo install

(optionnal, for SaaS features like managing or getting workflow revisions)

nexroo login

Your First Workflow

Basic Workflow with Built-in Actions

Create a my-workflow.json file:

{
"addons": [],
"entrypoints": [
{
"id": "default",
"name": "My First Workflow",
"startAt": "hello-step"
}
],
"workflow": {
"id": "hello-workflow",
"name": "Hello World Workflow",
"version": "1.0.0",
"steps": [
{
"id": "hello-step",
"name": "Say Hello",
"action": "builtin::log",
"parameters": {
"message": "Hello, World!",
"level": "info"
}
}
]
}
}

Run your workflow:

nexroo run my-workflow.json

Basic AI-Powered Workflow

Create an ai-workflow.json file that uses an AI agent addon:

{
"addons": [
{
"id": "claude-1",
"type": "anthropic",
"name": "Claude AI",
"description": "Claude AI agent for database automation",
"enabled": true,
"config": {
"model": "claude-3-5-sonnet-20241022",
"version": "claude-3-5",
"temperature": 0.7
},
"secrets": {
"anthropic_api_key": "CLAUDE_API_KEY"
}
},
],
"entrypoints": [
{
"id": "default",
"name": "AI Assistant Workflow",
"startAt": "generate-response"
}
],
"workflow": {
"id": "ai-assistant",
"name": "AI Assistant Workflow",
"version": "1.0.0",
"steps": [
{
"name": "Described by Agent",
"id": "step-agent-describe",
"action": "claude-1::chat_completion",
"runLimit": 1,
"onError": {
"action": "stop-workflow"
},
"parameters": {
"message": "Describe here what this agent step must do..",
"system": "You are an AI assistant in a workflow engine. You will receive inputs from steps and make actions."
},
}
]
}
}

Set up your Anthropic and MongoDB secrets as environment variables

Run your AI workflow:

nexroo run ai-workflow.json

AI-Powered Advanced Workflow

This example use tools, those are available for agent node using Anthropic or OpenAI models. (Claude & GPT)

{
"addons": [
{
"id": "claude-1",
"type": "anthropic",
"name": "Claude AI",
"description": "Claude AI agent for database automation",
"enabled": true,
"config": {
"model": "claude-3-5-sonnet-20241022",
"version": "claude-3-5",
"temperature": 0.7
},
"secrets": {
"anthropic_api_key": "CLAUDE_API_KEY"
}
},
{
"id": "storage-mongo-1",
"type": "mongodb",
"name": "MongoDB to review",
"description": "MongoDB user storage to be reviewed by AI",
"enabled": true,
"config": {
"host": "localhost",
"database": "ai_automation_db",
"port": 27017,
"authSource": "admin",
"tls": false
},
"secrets": {
"db_user": "MONGO_USER",
"db_password": "MONGO_PASSWORD"
}
},
],
"entrypoints": [
{
"id": "default",
"name": "AI Assistant Workflow",
"startAt": "generate-response"
}
],
"workflow": {
"id": "ai-assistant",
"name": "AI Assistant Workflow",
"version": "1.0.0",
"steps": [
{
"name": "Described by Agent",
"id": "step-agent-describe",
"action": "claude-1::chat_completion",
"runLimit": 1,
"onError": {
"action": "stop-workflow"
},
"useStorage": [
{
"addonId": "storage-mongo-1",
"action": [
{"name": "describe", "description": "Get details about the production database."},
{"name": "describe_collection", "description": "Get detail about a specific collection in production database."},
]
},
],
"parameters": {
"message": "Use all available tools to describe the database and review it.",
"system": "You are a database administrator AI. Use all available MongoDB tools to perform operation user ask for."
},
}
]
}
}

Set you environnement variables, then :

Run your AI workflow:

nexroo run ai-workflow.json