fix: 补充 anthropic-version header 并支持手动触发

添加 API 必需的 anthropic-version: 2023-06-01 header,
同时增加 workflow_dispatch 触发器以便手动调试。
This commit is contained in:
郑诚 (Cheng Zheng)
2026-06-18 15:41:30 +08:00
parent b3c1312847
commit 18615f4a0a

View File

@@ -7,11 +7,13 @@ on:
types: [opened]
issue_comment:
types: [created]
workflow_dispatch:
jobs:
trigger:
runs-on: ubuntu-latest
if: |
github.event_name == 'workflow_dispatch' ||
github.event_name == 'issues' ||
(github.event_name == 'pull_request' && !startsWith(github.event.pull_request.head.ref, 'auto-add-')) ||
(github.event_name == 'issue_comment' && github.event.issue.number == 160)
@@ -20,4 +22,5 @@ jobs:
run: |
curl -s -X POST "https://api.anthropic.com/v1/claude_code/routines/trig_01QqQ9rpKCEVLB5R78v83umP/fire" \
-H "Authorization: Bearer ${{ secrets.CLAUDE_ROUTINE_TOKEN }}" \
-H "anthropic-version: 2023-06-01" \
-H "Content-Type: application/json"