Build, test, and deploy intelligent AI agents with an intuitive visual builder — no boilerplate required.
🚀 Get Started • ✨ Features • 📖 Documentation • 🏗️ Architecture
- Overview
- Features
- Node Types
- Technology Stack
- Getting Started
- Environment Variables
- API Endpoints
- Kestra Integration
- Architecture
- Project Structure
- How It Works
Triggr is a visual AI agent workflow builder that allows users to design, test, and deploy automation workflows using a drag-and-drop interface. It bridges the gap between designing AI workflows and running them in production by integrating with Kestra, an open-source orchestration platform.
- Workflows often exist only as visual diagrams with no way to execute them
- No scheduling, monitoring, or error handling for automations
- Complex setup required to integrate AI models with external APIs
Triggr transforms your visual workflow designs into production-ready automations:
- Visual Builder → Design workflows with drag-and-drop
- Preview & Test → Chat with your AI agents in real-time
- Deploy to Kestra → One-click deployment to production orchestration
- Monitor & Scale → Track executions, handle errors, and scale automatically
- Drag-and-drop interface powered by React Flow
- Real-time node connections with animated edges
- Customizable node settings with detailed configuration panels
- Auto-save workflow progress to Convex database
- Support for multiple AI providers via OpenRouter:
- Google Gemini (1.5 Flash, 2.5 Flash)
- OpenAI GPT (GPT-4o, GPT-4o Mini, GPT-4.1 Nano)
- xAI Grok 3 Mini
- Configurable system prompts and instructions
- Conversation history inclusion option
- JSON or Text output modes
- HTTP methods: GET, POST, PUT, PATCH, DELETE
- Authentication types: Bearer Token, Query Parameter, Custom Header
- Dynamic URL parameters with placeholder replacement
- Custom headers and request body configuration
- Live chat interface to test your AI agents
- Real-time tool execution and API calls
- Conversation history management
- Debug logs for troubleshooting
- Automatic YAML generation from visual workflows
- One-click deployment to Kestra
- Workflow execution with input parameters
- Execution status monitoring
- KV Store integration for secure API key management
- Clerk authentication for user management
- Protected routes with middleware
- Rate limiting via Arcjet (5000 tokens/30 days)
- Secure API key storage in Kestra KV Store
- Agent management - Create, view, and edit agents
- Workflow overview with execution stats
- Quick actions for common tasks
- Responsive sidebar navigation
Triggr provides 7 different node types for building complex AI workflows:
| Node | Description | Settings |
|---|---|---|
| 🟢 Start Node | Entry point of every workflow | None |
| 🤖 Agent Node | AI-powered processing node | Name, Instruction, Model, Include History, Output Type (Text/JSON), Schema |
| 🔗 API Node | External HTTP API calls | Name, Endpoint, Method, Headers, Body, Auth Type, API Key |
| 🔀 If/Else Node | Conditional branching | Condition expression |
| 🔄 While Node | Loop execution | While condition |
| ✅ User Approval Node | Human-in-the-loop checkpoint | Name, Message |
| 🔴 End Node | Terminates workflow execution | Output Schema |
{
name: string; // Agent display name
instruction: string; // System prompt/instructions
includeHistory: boolean; // Include conversation history
model: string; // AI model (e.g., 'google/gemini-1.5-flash')
output: 'Text' | 'Json'; // Output format
schema: string; // JSON schema for structured output
}{
name: string; // Step name
endpoint: string; // API URL (supports {param} placeholders)
method: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE';
headers: string; // JSON headers
body: string; // Request body (for POST/PUT/PATCH)
authType: 'none' | 'bearer' | 'query' | 'header';
apiKey: string; // API key value
apiKeyName: string; // Key name for query/header auth
}| Technology | Purpose |
|---|---|
| Next.js 15.5 | React framework with App Router |
| React 19.1 | UI library |
| TypeScript 5 | Type safety |
| Tailwind CSS 4 | Styling |
| Framer Motion | Animations |
| React Flow | Visual workflow editor |
| Radix UI | Accessible UI components |
| Lucide Icons | Icon library |
| Technology | Purpose |
|---|---|
| Convex | Real-time database & backend |
| Kestra | Workflow orchestration engine |
| OpenRouter | AI model gateway |
| OpenAI SDK | AI integrations |
| Technology | Purpose |
|---|---|
| Clerk | Authentication & user management |
| Arcjet | Rate limiting & bot protection |
- axios - HTTP client
- zod - Schema validation
- react-hook-form - Form handling
- sonner & react-hot-toast - Notifications
- uuid - Unique ID generation
- date-fns & moment - Date utilities
- Node.js 18+
- npm, yarn, pnpm, or bun
- Convex account
- Clerk account
- OpenRouter or OpenAI API key
- (Optional) Kestra instance for deployment
-
Clone the repository
git clone https://github.com/Arjunhg/triggr.git cd triggr -
Install dependencies
npm install # or yarn install # or pnpm install
-
Set up environment variables
cp .env.example .env.local
Fill in the required environment variables (see Environment Variables)
-
Initialize Convex
npx convex dev
-
Run the development server
npm run dev
-
Open the app Navigate to http://localhost:4000
Create a .env.local file with the following variables:
# Clerk Authentication
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=pk_test_xxx
CLERK_SECRET_KEY=sk_test_xxx
NEXT_PUBLIC_CLERK_SIGN_IN_URL=/sign-in
NEXT_PUBLIC_CLERK_SIGN_UP_URL=/sign-up
# Convex Database
CONVEX_DEPLOYMENT=dev:xxx
NEXT_PUBLIC_CONVEX_URL=https://xxx.convex.cloud
# AI Providers (at least one required)
OPENROUTER_API_KEY=sk-or-xxx
OPENAI_API_KEY=sk-xxx
# Kestra Orchestration (optional)
KESTRA_URL=http://localhost:8080
KESTRA_USERNAME=[email protected]
KESTRA_PASSWORD=kestra
# Arcjet Rate Limiting
ARCJET_KEY=ajkey_xxxPOST /api/agent-chat
Execute AI agent workflow with chat interface.
// Request
{
input: string; // User message
agentToolConfig: object; // Generated agent configuration
conversationId?: string; // Optional conversation ID
}
// Response
{
response: string; // AI response
conversationId: string; // Conversation ID
}POST /api/agent-tool-config
Convert workflow configuration to executable agent config.
// Request
{
jsonConfig: {
startNode: string;
flow: FlowNode[];
}
}
// Response - AgentToolConfig
{
systemPrompt: string;
primaryAgentName: string;
agents: Agent[];
tools: Tool[];
}POST /api/generate-code
Generate executable JavaScript from workflow.
// Request
{
flowConfig: object; // Workflow configuration
}
// Response
{
code: string; // Generated JavaScript code
}POST /api/kestra/generate
Convert workflow to Kestra YAML format.
// Request
{
nodes: NodeType[];
edges: EdgeType[];
flowId: string;
namespace?: string;
}
// Response
{
yaml: string; // Kestra YAML workflow
}POST /api/kestra/deploy
Deploy YAML workflow to Kestra instance.
// Request
{
yaml: string; // Kestra YAML workflow
}
// Response
{
success: boolean;
flowId: string;
namespace: string;
revision: number;
}POST /api/kestra/execute
Execute a deployed Kestra workflow.
// Request
{
namespace: string;
flowId: string;
inputs?: Record<string, any>;
}
// Response
{
success: boolean;
executionId: string;
state: string;
}GET /api/kestra/status?executionId=xxx
Get execution status and results.
// Response
{
executionId: string;
state: string;
tasks: TaskStatus[];
outputs: any;
}GET /api/arcjet
Protected endpoint demonstrating Arcjet rate limiting.
Triggr integrates with Kestra to transform visual workflows into production-ready orchestrated automations.
| Without Kestra | With Kestra |
|---|---|
| Workflows only exist as diagrams | Workflows execute in production |
| No scheduling capability | Cron, event, or API triggers |
| No execution history | Full monitoring & logs |
| No error handling | Automatic retries & error management |
| Cannot scale | Thousands of concurrent executions |
-
Start Kestra (using Docker):
docker run --pull=always --rm -it -p 8080:8080 \ --user=root \ -v /var/run/docker.sock:/var/run/docker.sock \ -v /tmp:/tmp \ kestra/kestra:latest-full server local -
Access Kestra UI: http://localhost:8080
-
Configure KV Store for API keys:
# Set OpenRouter API Key curl -X PUT -H "Content-Type: application/json" \ http://localhost:8080/api/v1/main/namespaces/triggr.workflows/kv/OPENROUTER_API_KEY \ -d '"your-api-key-here"'
Triggr automatically converts visual nodes to Kestra tasks:
| Triggr Node | Kestra Task |
|---|---|
| Start Node | io.kestra.plugin.core.log.Log |
| Agent Node | io.kestra.plugin.ai.completion.ChatCompletion |
| API Node | io.kestra.plugin.core.http.Request |
| If/Else Node | io.kestra.plugin.core.flow.Switch |
| While Node | io.kestra.plugin.core.flow.ForEach |
| End Node | io.kestra.plugin.core.log.Log |
┌─────────────────────────────────────────────────────────────────┐
│ TRIGGR APP │
│ │
│ ┌──────────────┐ ┌──────────────┐ ┌──────────────┐ │
│ │ Landing │ │ Dashboard │ │Agent Builder │ │
│ │ Page │ │ (List) │ │ (Editor) │ │
│ └──────────────┘ └──────────────┘ └──────────────┘
│ │ │ │ │
│ └─────────────────┼─────────────────┘ │
│ │ │
│ ┌────────────────────────┴────────────────────────┐ │
│ │ React Flow Canvas │ │
│ │ ┌────┐ ┌────┐ ┌────┐ ┌────┐ ┌────┐ ┌────┐ │ │
│ │ │Start│→│Agent│→│API │→│If/ │→│Loop│→│End │ │ │
│ │ │Node │ │Node │ │Node│ │Else│ │Node│ │Node│ │ │
│ │ │
└───────────────────────────┼────────────────────────────────────┘
│
┌───────────────────┼───────────────────┐
│ │ │
▼ ▼ ▼
┌──────────────┐ ┌──────────────┐ ┌──────────────┐
│ Convex │ │ OpenRouter │ │ Kestra │
│ Database │ │ AI APIs │ │ Orchestrator │
│ │ │ │ │ │
│ • Users │ │ • Gemini │ │ • Deploy │
│ • Agents │ │ • GPT-4 │ │ • Execute │
│ • Workflows │ │ • Grok │ │ • Monitor │
└──────────────┘ └──────────────┘ └──────────────┘
1. CREATE AGENT
User clicks "New Workflow" → Names the agent → Agent created in Convex
2. BUILD WORKFLOW
Drag nodes from panel → Connect with edges → Configure node settings
3. SAVE WORKFLOW
Click "Save" → Nodes & edges stored in Convex → Auto-synced
4. GENERATE CONFIG
Click "Preview" → System generates AgentToolConfig from workflow
5. TEST IN PREVIEW
Chat with AI agent → Real-time API calls → Tool execution
6. EXPORT TO KESTRA (Optional)
Click "Code" → Switch to "Kestra YAML" → Deploy to Kestra
7. PRODUCTION EXECUTION
Kestra runs workflow → Scheduling, retries, monitoring available
User Action → React Component → Context Update → Convex Mutation → Database
↓
Database → Convex Query → React Component → UI Update
User Input → Agent Chat API → Build Messages → OpenRouter/OpenAI
↓
Tool Calls Required? → Execute Tools → Aggregate Results
↓
Final AI Response → User
- Kestra Integration Guide - Detailed Kestra setup and usage
- OpenRouter Models - Available AI models
- React Flow Docs - Visual editor documentation
- Convex Docs - Database documentation
- Clerk Docs - Authentication documentation
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
Built with ❤️ for automation