Hex CI Integration
Instructions
GitHub Actions — Trigger Hex on Deploy
name: Deploy & Refresh Data
on:
push:
branches: [main]
jobs:
refresh-hex:
runs-on: ubuntu-latest
steps:
- name: Trigger Hex project refresh
env:
HEX_API_TOKEN: ${{ secrets.HEX_API_TOKEN }}
run: |
curl -X POST \
-H "Authorization: Bearer $HEX_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{"inputParams": {"triggered_by": "ci"}, "updateCacheResult": true}' \
https://app.hex.tech/api/v1/project/${{ vars.HEX_PROJECT_ID }}/run
gh secret set HEX_API_TOKEN --body "hex_token_..."
gh variable set HEX_PROJECT_ID --body "project-id"
Resources