GitHub Actions Integration
Automate security testing in your GitHub workflows with AIPTx’s official GitHub Action.Quick Start
Add security scanning to any workflow:Installation
1. Get Your API Key
- Log in to the AIPTx Dashboard
- Navigate to Settings → API Keys
- Generate a new key with appropriate permissions
2. Add Secret to GitHub
- Go to your repository Settings → Secrets and variables → Actions
- Click New repository secret
- Name:
AIPTX_API_KEY - Value: Your AIPTx API key
3. Create Workflow File
Create.github/workflows/security.yml:
Configuration Options
Action Inputs
| Input | Description | Required | Default |
|---|---|---|---|
api-key | AIPTx API key | Yes | - |
target | Target URL to scan | Yes | - |
mode | Scan mode: quick, standard, deep | No | standard |
type | Scan type: web, api, network, full | No | web |
openapi | Path to OpenAPI spec file | No | - |
fail-on | Fail build on severity: critical, high, medium, low | No | critical |
timeout | Scan timeout in minutes | No | 60 |
wait | Wait for scan completion | No | true |
config | Path to aiptx.yaml config file | No | - |
Action Outputs
| Output | Description |
|---|---|
scan-id | The ID of the created scan |
scan-url | URL to view scan results |
findings-critical | Number of critical findings |
findings-high | Number of high findings |
findings-medium | Number of medium findings |
findings-low | Number of low findings |
status | Scan status |
Common Workflows
Pull Request Scanning
Scan preview deployments on pull requests:Scheduled Deep Scan
Run comprehensive scans weekly:Multi-Environment Scanning
Scan multiple environments in parallel:With OpenAPI Specification
Security Gates
Block deployments based on findings:Troubleshooting
Scan times out
Scan times out
Increase the timeout value or use
quick mode for CI/CD:Cannot reach target
Cannot reach target
Ensure your target is accessible from GitHub’s runners. For internal applications, consider using self-hosted runners or deploying a preview environment.
API key not working
API key not working
Verify the secret is correctly named and the API key has appropriate permissions in the AIPTx dashboard.