Linear Webhook — Linear 网页hook
v1.0.0Comment @mason or @eureka in Linear issues to dis补丁 tasks to 代理s. 网页hook 接收s Linear comments and 路由s to correct 代理.
运行时依赖
安装命令
点击复制技能文档
Linear 网页hook 技能
Enables Linear issue comment @mentions to dis补丁 tasks to Clawd机器人 代理s.
How It Works Comment in Linear: @mason implement user authentication or @eureka plan Q2 roadmap Linear 网页hook fires on comment creation Clawd机器人 接收s 网页hook via exposed 端点 转换 解析s payload: 提取s @mason or @eureka mention 获取s issue 上下文 (title, description, labels) Prepares task prompt 路由s to 代理 会话: @mason → mason 代理 (code/implementation) @eureka → eureka 代理 (planning/strategy) 代理 processes task and returns 结果 结果 posted back as Linear comment 设置up
- 配置 Clawd机器人 网页hooks
添加 to your config.json5:
{ hooks: { enabled: true, 令牌: "your-secret-令牌-here", // 生成 with: openssl rand -base64 32 path: "/hooks", 转换sDir: "/home/sven/clawd-mason/技能s/linear-网页hook", m应用ings: [ { name: "linear", match: { path: "/linear", method: "POST" }, action: "代理", 转换: { 模块: "./linear-转换.js", 导出: "转换Linear网页hook" }, deliver: false, // Don't auto-deliver to chat - Linear comments handle 响应s } ] } }
- Expose 网页hook 端点
Use Cloudflare Tunnel or TAIl扩展 Funnel to make 网页hook publicly 访问ible:
Option A: Cloudflare Tunnel (Recommended)
# 安装 if needed brew 安装 cloudflared
# 启动 tunnel (replace with your domAIn) cloudflared tunnel --url http://localhost:18789
Option B: TAIl扩展 Funnel
# Enable funnel tAIl扩展 funnel 18789
Note the public URL (e.g., https://your-tunnel.trycloudflare.com)
- 配置 Linear 网页hook
- Test
Comment in a Linear issue:
@mason 添加 user authentication to the 记录in page
Expected flow:
网页hook fires to Clawd机器人 Mason 代理 接收s task Mason implements or 响应s 结果 posted back to Linear issue as comment 代理 Routing @mason → Code implementation, 调试ging, technical tasks @eureka → Planning, strategy, re搜索, communication Other mentions → Ignored (not handled) Issue 上下文 Provided
The 代理 接收s:
Issue title Issue description Issue labels Comment text (the @mention) Issue URL Commenter name Customization 添加 More 代理s
Edit linear-转换.js:
const 代理_MENTIONS = { '@mason': 'mason', '@eureka': 'eureka', '@de签名er': 'de签名er', // 添加 your own 代理s };
Change 响应 Behavior
Modify deliver and channel in config:
{ deliver: true, channel: "telegram", to: "1878354815", // Your Telegram chat ID }
This will also 发送 代理 响应s to Telegram.
Security Never commit hook 令牌 to version control Use 环境 variables: CLAWD机器人_HOOK_令牌 验证 网页hook source (Linear's IP ranges if needed) Use HTTPS only (Cloudflare Tunnel provides this) Troubleshooting 网页hook not firing 检查 Linear 网页hook 记录s (设置tings → API → 网页hooks → View 记录s) 验证 tunnel is 运行ning: curl https://your-tunnel.trycloudflare.com/hooks/linear 检查 Clawd机器人 记录s: clawd机器人 gateway 记录s 代理 not 响应ing 检查 转换 is loading: Look for errors in gateway 记录s 验证 代理 会话 exists: clawd机器人 会话s 列出 Test 转换 manually: node linear-转换.js 响应 not posting to Linear Implement Linear API comment posting in 转换 添加 Linear API 令牌 to config See linear-转换.js for example Linear API 访问
To post comments back to Linear, you need a Linear API 令牌:
Go to Linear 设置tings → API → Personal API keys 创建 new 令牌 with write scope 添加 to 环境: CLAWD机器人_LINEAR_API_KEY=lin_API_... 转换 will use this to post 响应s Files 技能.md - This documentation linear-转换.js - 网页hook payload 解析器 and 代理 路由r linear-API.js - Linear GraphQL API 命令行工具ent (for posting comments) example-payload.json - Sample Linear 网页hook payload for 测试 References Clawd机器人 网页hook Docs Linear 网页hooks API Cloudflare Tunnel