IntegrationsGitHub Actions
GitHub Actions
Use the silentauth/require-approval Action to gate any workflow step — deployments, migrations, secret rotations — with human approval. The step blocks until an approver responds or the timeout is reached.
Basic Usage
# .github/workflows/deploy.yml
name: Deploy to Production
on:
push:
branches: [main]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Require Human Approval
uses: silentauth/require-approval@v1
with:
project-id: ${{ secrets.SA_PROJECT_ID }}
secret-key: ${{ secrets.SA_SECRET_KEY }}
action: deploy_production
approvers: ops-team
timeout: 30m
params: |
{
"branch": "${{ github.ref_name }}",
"commit": "${{ github.sha }}",
"actor": "${{ github.actor }}"
}
# Only runs after human approves the step above
- name: Deploy
run: ./scripts/deploy.sh productionAction Inputs
| Input | Required | Description |
|---|---|---|
| project-id | Yes | Your SilentAuth project ID from the dashboard |
| secret-key | Yes | Secret key — store in GitHub Secrets |
| action | Yes | Action name (e.g. deploy_production) |
| approvers | Yes | Team name or email of approver(s) |
| timeout | No | Max wait time. Default: 1h. Format: 30m, 2h |
| params | No | JSON string of additional context for the approver |
Setting Secrets
Add SA_PROJECT_ID and SA_SECRET_KEY to your repository secrets:
- Go to your repository → Settings → Secrets and variables → Actions
- Click New repository secret
- Add
SA_PROJECT_IDandSA_SECRET_KEYfrom the SilentAuth dashboard