skills/beam/beam-tools/create-beam-task-auto-trigger/SKILL.md
Create an auto-trigger webhook script for a Beam.ai agent task. Supports simple query-based, query with attachments/data (base64-encoded), and email-triggered (Gmail/Workable) agents. Load when user says "create auto trigger", "create task auto trigger", "convert task to webhook", "create beam webhook", "automate beam task", or provides a Beam task URL to create a webhook trigger script.
npx skillsauth add beam-ai-team/beam-next-skills create-beam-task-auto-triggerInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Convert a Beam.ai task into an auto-trigger webhook script for scheduled execution.
This skill automates the process of:
Time saved: ~15 minutes of manual work per webhook script
The skill intelligently detects and handles three types of agent triggers:
Agents triggered by simple text queries with no additional data. The webhook sends:
{
"query": "summarize the document",
"timestamp": "2026-01-02T13:00:13Z"
}
Agents triggered by queries that require attachments or additional context. The webhook sends:
{
"query": "analyze the attached resume",
"additionalInfo": "",
"beamAgentOSTaskID": "7c516cc3-f8fa-4ffc-af65-5eee0aa2792a",
"beamTaskId": "CAN-3",
"beamTaskTimestamp": "2025-12-05T07:55:48Z",
"attachments": [
{
"name": "Marcus_Chen_Resume.pdf",
"type": "file",
"key": "53919651-bb7a-44de-9d94-6cf540ff640f_7bba5443-4ef2-432b-b256-7a00ba6da373_Marcus_Chen_Resume.pdf"
}
],
"timestamp": "2026-01-02T13:00:13Z"
}
Agents triggered by email messages. The webhook sends the full email payload:
{
"id": "196a54bba916edc4",
"messageId": "196a54bba916edc4",
"threadId": "196a54bba916edc4",
"labelIds": ["UNREAD", "CATEGORY_PERSONAL", "INBOX"],
"snippet": "email preview text",
"headers": {
"from": "[email protected]",
"to": "[email protected]",
"subject": "Email Subject"
},
"attachments": [...],
"textPlain": "email body text",
"textHtml": "<div>email body html</div>",
"timestamp": "2026-01-02T13:00:13Z"
}
The skill automatically detects which type based on the task payload structure.
.env file at project root with:
BEAM_API_KEY=your_beam_api_key
BEAM_WORKSPACE_ID=your_workspace_id
Dependencies: requests, python-dotenv (already installed)
# Interactive mode (recommended)
python 03-skills/create-beam-task-auto-trigger/scripts/create_auto_trigger.py
# With task URL
python 03-skills/create-beam-task-auto-trigger/scripts/create_auto_trigger.py \
--task-url "https://app.beam.ai/{workspace}/{agent}/tasks/{task-id}"
# With all parameters
python 03-skills/create-beam-task-auto-trigger/scripts/create_auto_trigger.py \
--task-url "https://app.beam.ai/..." \
--webhook-url "https://api.beamstudio.ai/agent-tasks/{agent}/webhook/{webhook-id}" \
--script-name "my-agent-task.sh"
# With file attachment (base64 encoded)
python 03-skills/create-beam-task-auto-trigger/scripts/create_auto_trigger.py \
--task-url "https://app.beam.ai/..." \
--webhook-url "https://api.beamstudio.ai/..." \
--script-name "resume-screening.sh" \
--attachment-file "/path/to/resume.pdf"
The task URL from Beam.ai (from the browser address bar):
https://app.beam.ai/505d2090-2b5d-4e45-b0f4-cc3a0b299aa8/8cb86b50-aa8f-4876-a3cb-7eb62e910528/tasks/1c08f856-d1a2-47c4-a62a-01ff7d24b3df
The agent webhook URL (get from Beam agent settings):
https://api.beamstudio.ai/agent-tasks/{agent-id}/webhook/{webhook-id}
Choose a descriptive name for the webhook script:
interview-scheduling-agent.sh
data-processing-task.sh
The skill will:
04-workspace/scripts/webhook-scheduler/webhooks/Created Script:
04-workspace/scripts/webhook-scheduler/webhooks/{script-name}.sh
Script Content:
#!/bin/bash
TIMESTAMP=$(date -u +%Y-%m-%dT%H:%M:%SZ)
TASK_PAYLOAD='{"id":"...","messageId":"...","timestamp":"__TIMESTAMP_PLACEHOLDER__",...}'
TASK_WITH_TIMESTAMP=$(echo "$TASK_PAYLOAD" | sed "s/__TIMESTAMP_PLACEHOLDER__/$TIMESTAMP/g")
curl --location 'https://api.beamstudio.ai/agent-tasks/{agent}/webhook/{webhook-id}' \
--form 'task="'"$TASK_WITH_TIMESTAMP"'"' \
--form 'encodedContextFiles="[{\"mimeType\":\"application/pdf\",\"fileType\":\"document\",\"fileExtension\":\"pdf\",\"data\":\"<base64-encoded-content>\"}]"'
python 03-skills/create-beam-task-auto-trigger/scripts/create_auto_trigger.py
# Prompts:
# Task URL: https://app.beam.ai/.../tasks/abc123
# Webhook URL: https://api.beamstudio.ai/agent-tasks/.../webhook/xyz789
# Script name: my-task.sh
# Output:
# ✅ Created: 04-workspace/scripts/webhook-scheduler/webhooks/my-task.sh
python 03-skills/create-beam-task-auto-trigger/scripts/create_auto_trigger.py \
--task-url "https://app.beam.ai/505d.../tasks/1c08f856..." \
--webhook-url "https://api.beamstudio.ai/agent-tasks/8cb86.../webhook/17f4e..." \
--script-name "interview-scheduling.sh"
python 03-skills/create-beam-task-auto-trigger/scripts/create_auto_trigger.py \
--task-url "https://app.beam.ai/505d.../tasks/7c516cc3..." \
--webhook-url "https://api.beamstudio.ai/agent-tasks/53919651.../webhook/36bf660f..." \
--script-name "resume-screening.sh" \
--attachment-file "/Users/yourname/Documents/Marcus_Chen_Resume.pdf"
# Output:
# ✅ Created: 04-workspace/scripts/webhook-scheduler/webhooks/resume-screening.sh
# 📎 Attachment: Marcus_Chen_Resume.pdf (base64 encoded)
# Test the webhook immediately
bash 04-workspace/scripts/webhook-scheduler/webhooks/interview-scheduling.sh
| Parameter | Required | Description |
|-----------|----------|-------------|
| --task-url | Yes* | Beam.ai task URL from browser |
| --webhook-url | Yes* | Agent webhook URL from Beam settings |
| --script-name | Yes* | Name for the webhook script (must end in .sh) |
| --attachment-file | No | Path to file to attach (e.g., resume.pdf). Will be base64 encoded and included in payload |
| --output-dir | No | Output directory (default: webhook-scheduler/webhooks) |
| --workspace | No | Beam workspace: bid or prod (default: bid) |
* Required in CLI mode, prompted in interactive mode
taskQuery or originalTaskQuery from tasktask field: Task payload with dynamic timestampencodedContextFiles field: Array of base64-encoded files\" instead of ")Format Details:
--form multipart format instead of --data JSON{\"key\":\"value\"} becomes {\\\"key\\\":\\\"value\\\"}separators=(',', ':') - no spacestask and encodedContextFilesThe created script is automatically added to the webhook rotation:
Common Issues:
| Error | Cause | Solution |
|-------|-------|----------|
| Invalid task URL | URL format incorrect | Use full URL from Beam browser |
| Task not found | Task ID doesn't exist | Verify task ID in Beam dashboard |
| Authentication failed | API key invalid | Check .env file credentials |
| Webhook URL invalid | Missing agent/webhook ID | Get URL from Beam agent settings |
Finding Webhook URL:
Script Naming:
customer-onboarding.shinvoice-processing.sh.sh: my-task.shTesting:
Version: 1.4 Created: 2026-01-02 Updated: 2026-01-05 Status: Production Ready
--form multipart format (matches Beam API requirements)task and encodedContextFiles into two form fields\" instead of ")separators=(',', ':') (no spaces)encodedContextFiles field when attachments exist--attachment-file parameter to attach files (PDFs, etc.)testing
Audit registry.yaml against disk, validate SKILL.md frontmatter, find duplicates and orphans. Load when user says 'audit skills registry', 'validate beam-next-skills', 'registry drift', 'skills catalog audit', 'check registry yaml'.
tools
All Workable ATS operations — fetch JDs, search candidates, post assessments/reviews. Load when user says "fetch JD", "search workable", "push to workable", "post review", "rate candidate", "workable", "push assessment", "list jobs", or after interview-coach completes an evaluation. Replaces workable-fetch-jd and workable-push-assessment.
data-ai
Load when user mentions "tavily research", "market intelligence", "competitive research", "GTM research", or needs real-time market data for sales, marketing, or vertical strategy.
development
Shared resource library for Slack integration skills. DO NOT load directly - provides common references (setup, API docs, error handling, authentication) and scripts used by slack-connect and individual Slack skills.