GitHub Integration
GitHub Integration
Integrate GovernanceAI with GitHub to automatically scan repositories for AI model usage, dependencies, and compliance violations.
Setup Process
Step 1: Install GitHub App
- Go to Integrations → GitHub
- Click Install GitHub App
- You’ll be redirected to GitHub
- Select repositories to authorize (all or specific)
- Click Install & Authorize
- You’ll be redirected back to GovernanceAI
Step 2: Configure Scanning
Repository Selection:
- ✅ Automatic - Scan all existing and new repositories
- ✅ Manual - Select specific repositories
- ✅ Pattern-based - Scan repos matching patterns
Scan Settings:
- Trigger: Push, Pull Request, Scheduled
- Frequency: Hourly, Daily, Weekly
- Depth: Full repo scan or recent changes only
Step 3: Webhook Configuration
Webhooks enable real-time scanning:
- Automatically installed by GitHub App
- Triggers on:
push,pull_request - Sends scan results to GovernanceAI
- Creates GitHub checks on PRs
Automated Scanning
Push Scanning
On every push to main branch:
Pull Request Scanning
Automatic checks on every PR:
Example PR Comment:
Permissions
Required GitHub App Permissions:
Not Requested:
- ❌ Write access to code
- ❌ Access to secrets or keys
- ❌ Deployment permissions
GitHub Actions Integration
Workflow Example
Auto-Discovery
GovernanceAI automatically detects:
- ✅ LLM calls (OpenAI, Claude, Hugging Face, etc.)
- ✅ Model training code
- ✅ AI dependencies (langchain, llamaindex, etc.)
- ✅ Prompt engineering patterns
- ✅ Vector database integrations
- ✅ RAG implementations
Example Detection:
Troubleshooting
App not appearing in PR checks:
- Ensure webhook is active
- Check repository permissions
- Verify app installation
Scans not triggering:
- Verify webhook payload (Settings → Developer settings → Webhooks)
- Check API key is valid
- Review rate limits
Missing repositories:
- Reinstall app with more permissions
- Check organization restrictions
- Verify branch protection rules
Next Steps
- GitLab Integration - Connect GitLab
- Running Scans - Learn about scanning
- API Reference - Integration APIs