Capture social media leads automatically, classify them with AI, store in Google Sheets, and notify your team via Slack and Jira—all in one intelligent workflow.
This Lead Management & Automation Workflow transforms incoming social media direct messages into organized, actionable leads while automatically generating weekly performance reports. The agent intelligently filters, classifies, and routes leads across your entire business infrastructure—from spreadsheet storage to project management systems to team notifications—all without manual intervention.
Key benefits and time savings:
Target use cases:
This workflow is ideal for growing teams and organizations that:
Whether you're a startup scaling your sales process or an established company streamlining lead management, this agent adapts to your needs and grows with your business.
Why it's needed: Powers intelligent lead classification using GPT-4o to analyze incoming messages and determine lead quality, relevance, and key characteristics.
Setup steps:
How to obtain API keys: OpenAI requires a paid account with billing set up. Visit platform.openai.com/account/billing/overview to add a payment method.
Configuration in TaskAGI: Once connected, the workflow automatically uses GPT-4o for lead classification. No additional configuration needed—the model is specified in the workflow node.
Why it's needed: Serves as your centralized lead database, storing all captured leads and enabling historical analysis for weekly reporting.
Setup steps:
TaskAGI Lead Database
Date, Name, Email, Message, Classification, Quality Score
How to obtain credentials: Google Sheets uses OAuth authentication—no API key needed. Simply authorize TaskAGI to access your Google account.
Configuration in TaskAGI: After authentication, you can reference your sheet URL in any Google Sheets node. The workflow will automatically append rows with lead data.
Why it's needed: Automatically creates tasks for qualified leads, ensuring your development or operations team can track and manage follow-up actions.
Setup steps:
yourcompany.atlassian.net)How to obtain API keys: Visit your Jira instance's settings. For Jira Cloud, go to id.atlassian.com/manage-profile/security/api-tokens.
Configuration in TaskAGI: Specify your Project Key (e.g., SALES) and Issue Type (e.g., Task) in the workflow node. The agent will create issues automatically.
Why it's needed: Delivers real-time notifications to your team when new leads arrive and sends weekly performance reports to keep everyone informed.
Setup steps:
TaskAGI Lead Agent
chat:write and channels:read
xoxb-)How to obtain credentials: Create a Slack app in your workspace's app management portal. You'll need admin access to your Slack workspace.
Configuration in TaskAGI: Specify the Channel Name (e.g., #sales-leads or #weekly-reports) in each Slack node. The bot will post messages to these channels automatically.
1. Receive Social DM (Webhook Trigger) This node receives incoming messages from your social media channels. Configure the webhook URL in your social platform's settings to point to the TaskAGI endpoint provided. This is your workflow's entry point—every incoming message triggers the entire process.
2. Filter Lead Keywords
Set up keyword filters to identify genuine leads. Example keywords: interested, pricing, demo, inquiry, contact. Configure the function to return true if keywords are found, allowing the workflow to continue. This prevents spam from clogging your system.
3. GPT Lead Classifier The AI analyzes filtered messages and returns a JSON object with:
summary: Brief description of the leadquality_score: Rating from 1-10 indicating lead qualityExample prompt output:
{
"summary": "Small business owner interested in automation tools",
"quality_score": 8
}
4. Prepare Lead Data Transform the classified data into a structured format matching your Google Sheets columns. Map fields like sender name, email, message content, classification, and quality score.
5. Store Lead in Sheets Append the prepared data to your Google Sheets. Ensure your sheet_url is configured correctly. This creates a permanent record of all leads.
6. Create Jira Task For high-quality leads (quality_score > 6), automatically create a Jira task. Configure:
Task or Story
7. Notify Slack Send immediate notifications to your team. Format the message to include:
8. Weekly Report Schedule
Trigger every Monday at 9:00 AM. Configure the schedule interval to weekly with your preferred timezone.
9. Get All Leads Retrieve the complete lead history from Google Sheets for analysis.
10. Filter Recent Leads Extract leads from the past 7 days using date comparison functions.
11. Generate Report Stats Calculate metrics:
12. Post Weekly Report
Send a formatted summary to your #weekly-reports Slack channel with key metrics and trends.
{
"sender": "John Smith",
"email": "john@example.com",
"message": "Hi! I'm interested in learning more about your automation tools. Can we schedule a demo?"
}
✅ Successful execution shows:
✅ Weekly report verification:
Your lead management automation is now live and working for you!