lindy-core-workflow-b

jeremylongshore's avatarfrom jeremylongshore

Core Lindy workflow for automating tasks and scheduling agents.Use when setting up automated workflows, scheduling agent runs,or creating trigger-based automations.Trigger with phrases like "lindy automation", "schedule lindy agent","lindy workflow automation", "automate with lindy".

⭐939stars🔀114forks📁View on GitHub🕐Updated Jan 11, 2026

When & Why to Use This Skill

This Claude skill facilitates the seamless automation and scheduling of AI agents, enabling the creation of sophisticated, trigger-based workflows. It solves the challenge of manual agent management by providing robust support for cron-based scheduling, webhook integrations, and email-driven triggers, ensuring that agentic tasks are executed autonomously and reliably across various platforms.

Use Cases

  • Scheduled Business Intelligence: Automate daily data collection and reporting by scheduling agents to run at specific times using cron expressions.
  • Event-Driven Webhook Workflows: Trigger agent actions in real-time based on external events from third-party applications like CRMs, GitHub, or payment processors.
  • Automated Email Processing: Set up dedicated email triggers to automatically ingest, analyze, and respond to incoming customer inquiries or support tickets.
  • Multi-Trigger Task Orchestration: Combine multiple automation methods to manage complex, end-to-end business processes that require both periodic checks and immediate event responses.
namelindy-core-workflow-b
description|
allowed-toolsRead, Write, Edit
version1.0.0
licenseMIT
authorJeremy Longshore <jeremy@intentsolutions.io>

Lindy Core Workflow B: Task Automation

Overview

Complete workflow for automating tasks and scheduling Lindy AI agents.

Prerequisites

  • Completed lindy-core-workflow-a (agent creation)
  • Agent ID ready for automation
  • Clear automation requirements defined

Instructions

Step 1: Define Automation Spec

interface AutomationSpec {
  agentId: string;
  trigger: 'schedule' | 'webhook' | 'email' | 'event';
  schedule?: string; // cron expression
  webhookPath?: string;
  emailTrigger?: string;
  eventType?: string;
}

const automationSpec: AutomationSpec = {
  agentId: 'agt_abc123',
  trigger: 'schedule',
  schedule: '0 9 * * *', // Daily at 9 AM
};

Step 2: Create Scheduled Automation

import { Lindy } from '@lindy-ai/sdk';

const lindy = new Lindy({ apiKey: process.env.LINDY_API_KEY });

async function createScheduledAutomation(spec: AutomationSpec) {
  const automation = await lindy.automations.create({
    agentId: spec.agentId,
    type: 'schedule',
    config: {
      cron: spec.schedule,
      timezone: 'America/New_York',
      input: 'Run daily morning tasks',
    },
  });

  console.log(`Created automation: ${automation.id}`);
  return automation;
}

Step 3: Create Webhook Trigger

async function createWebhookAutomation(agentId: string, path: string) {
  const automation = await lindy.automations.create({
    agentId,
    type: 'webhook',
    config: {
      path: path,
      method: 'POST',
      inputMapping: {
        input: '{{body.message}}',
        context: '{{body.context}}',
      },
    },
  });

  console.log(`Webhook URL: ${automation.webhookUrl}`);
  return automation;
}

Step 4: Create Email Trigger

async function createEmailAutomation(agentId: string, triggerEmail: string) {
  const automation = await lindy.automations.create({
    agentId,
    type: 'email',
    config: {
      triggerAddress: triggerEmail,
      inputMapping: {
        input: '{{email.body}}',
        sender: '{{email.from}}',
        subject: '{{email.subject}}',
      },
    },
  });

  console.log(`Forward emails to: ${automation.triggerEmail}`);
  return automation;
}

Output

  • Configured automation triggers
  • Scheduled or event-based agent runs
  • Webhook endpoints for external triggers
  • Email triggers for inbox automation

Error Handling

Error Cause Solution
Invalid cron Bad schedule format Use standard cron syntax
Webhook conflict Path already used Choose unique webhook path
Agent not found Invalid agent ID Verify agent exists

Examples

Multi-Trigger Setup

async function setupAutomations(agentId: string) {
  // Daily summary at 9 AM
  await lindy.automations.create({
    agentId,
    type: 'schedule',
    config: { cron: '0 9 * * *', input: 'Generate daily summary' },
  });

  // Webhook for external events
  await lindy.automations.create({
    agentId,
    type: 'webhook',
    config: { path: '/events', method: 'POST' },
  });

  // Email trigger for support
  await lindy.automations.create({
    agentId,
    type: 'email',
    config: { triggerAddress: 'support@mycompany.com' },
  });
}

Resources

Next Steps

Proceed to lindy-common-errors for troubleshooting guidance.