DRAFT: Add event-based automations documentation#469
Conversation
- Create event-automations.mdx covering webhook-triggered automations - Document built-in GitHub events vs custom webhook integrations - Include GitHub event-based automation example - Add Linear custom integration walkthrough with: - Webhook registration process - Agent-assisted setup workflow - Parameters reference (signature header, event key) - Automation creation after webhook registration - Add filter expressions reference for JMESPath - Update docs.json navigation Co-authored-by: openhands <openhands@all-hands.dev>
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Workflows to automatically generate PRs for you. |
- Linear provides the signing secret (not configurable) - Agent provides curl commands but user executes them (security) - After webhook registration, agent handles automation creation end-to-end - Add tip about auto-generated secrets for other services Co-authored-by: openhands <openhands@all-hands.dev>
|
This LGTM! |
all-hands-bot
left a comment
There was a problem hiding this comment.
Documentation is well-structured and follows existing patterns, but has workflow clarity issues that could confuse users.
| ```bash | ||
| curl -X POST "https://app.all-hands.dev/api/automation/v1/webhooks" \ | ||
| -H "Authorization: Bearer ${OPENHANDS_API_KEY}" \ | ||
| -H "Content-Type: application/json" \ | ||
| -d '{ | ||
| "name": "Linear Issues", | ||
| "source": "linear", | ||
| "event_key_expr": "type", | ||
| "signature_header": "Linear-Signature", | ||
| "webhook_secret": "YOUR_LINEAR_SIGNING_SECRET" | ||
| }' |
There was a problem hiding this comment.
🟡 Suggestion: The event_key_expr parameter needs better explanation. Users need to understand:
- This JMESPath expression extracts the event type from the webhook payload
- The extracted value is matched against the
onfield when creating automations - For Linear, the payload has
{"type": "Issue", "action": "create", ...}soevent_key_expr: "type"extracts"Issue"
Consider adding a concrete example showing the webhook payload → event_key_expr → extracted value → automation on field mapping.
There was a problem hiding this comment.
Fixed in 958ec67. Added an Accordion component with a concrete explanation:
The event_key_expr is a JMESPath expression that extracts the event type from incoming webhook payloads. This extracted value is what you match against in the automation's on field.
Included a concrete example showing how Linear's payload {"type": "Issue", ...} with event_key_expr: "type" extracts "Issue", which is then matched in the automation's on field.
Code Review SummaryTaste Rating: 🟡 Acceptable - Documentation follows existing patterns and provides good coverage, but has clarity issues that need addressing. [CRITICAL ISSUES]
[IMPROVEMENT OPPORTUNITIES]
[POSITIVE ASPECTS]
[RISK ASSESSMENT]
This is documentation-only with no functional changes. The primary risk is user confusion from the workflow contradiction identified above. Once that's clarified, this will be a solid addition to the automation documentation. No breaking changes, no code modifications, no security concerns. VERDICT: Core content is sound and well-organized. The critical issue (webhook registration workflow confusion) needs resolution before merge to prevent user confusion. Style improvements are nice-to-have but not blockers. KEY INSIGHT:
|
|
@OpenHands please read the unresolved review comments, address the review and leave a reply under each comment for what fix was made |
|
I'm on it! malhotra5 can track my progress at all-hands.dev |
- Fix header capitalization to match style guide (Built-In vs. Custom) - Add prose explanation for JMESPath filter expressions - Clarify two-phase workflow for custom webhooks (registration vs automation) - Add Accordion explaining event_key_expr with concrete Linear example - Add disclaimer about verifying signature headers with service docs - Improve Next Steps section with intro linking to Automations Overview
Summary of Work CompletedI've addressed all 7 unresolved review comments on PR #469 and pushed the fixes in commit Checklist: All Review Comments Addressed ✅
Changes Are Concise ✅
Actions Completed
PR Link: #469 |
all-hands-bot
left a comment
There was a problem hiding this comment.
[RISK ASSESSMENT]
- [Overall PR]
⚠️ Risk Assessment: 🟢 LOW
This is documentation for a beta feature with no code changes. The documentation is technically accurate, well-structured, and follows Mintlify conventions. Previous review issues regarding workflow clarity, title case consistency, and disclaimers have been resolved.
VERDICT:
✅ Worth merging (for draft): Documentation is comprehensive and accurate. Minor enhancements suggested to improve first-time user experience.
KEY INSIGHT:
The document successfully bridges the gap between built-in GitHub integration and custom webhook setup, with the Linear walkthrough providing a concrete end-to-end example.
- Add instruction to create OpenHands API key from settings page - Add export statements for OPENHANDS_API_KEY and LINEAR_WEBHOOK_SECRET - Update curl command to use environment variables directly - User can now run the curl command as-is after exporting values
DevinVinson
left a comment
There was a problem hiding this comment.
Looks great! Thank you for the detailed docs while still in Beta.
Summary
This PR adds documentation for event-based automations, a new feature that allows automations to be triggered by webhook events (GitHub, custom services) instead of cron schedules.
Based on the capabilities outlined in OpenHands/extensions#156.
Changes
openhands/usage/automations/event-automations.mdxDocumentation Coverage
Built-in Events vs Custom Integrations
GitHub Event-Based Automation Example
Linear Custom Integration Walkthrough
Complete step-by-step guide covering:
Reference Tables
This PR was created by an AI assistant (OpenHands) to document upcoming event-based automation features.
@malhotra5 can click here to continue refining the PR