使用 curl 触发Github Action。

curl -X POST https://api.github.com/repos/:owner/:repo/dispatches \
    -H "Accept: application/vnd.github.everest-preview+json" \
    -H "Authorization: token TRIGGER_TOKEN" \
    --data '{"event_type": "TRIGGER_EVENT"}'
 
curl -X POST https://api.github.com/repos/shaowenchen/wait-webhook-to-run/dispatches \
    -H "Accept: application/vnd.github.everest-preview+json" \
    -H "Authorization: token ghp_xxxxxxxxxxxxxxxxxxxxxxxxxx" \
    --data '{"event_type": "webhook-1"}'
 
curl -X POST https://api.github.com/repos/shaowenchen/wait-webhook-to-run/dispatches \
    -H "Accept: application/vnd.github.everest-preview+json" \
    -H "Authorization: token ghp_xxxxxxxxxxxxxxxxxxxxxxxxxx" \
    --data '{"event_type": "webhook-2"}'