Quick setup for testing GitHub webhooks locally using Microsoft DevTunnel.
The fastest way to get started is using the automated setup script:
-
Setup Environment
cp .env.sample .env
Edit
.envand set yourGITHUB_WEBHOOK_SECRET(generate one withopenssl rand -hex 32) -
Run the Setup Script
./scripts/dev-setup.sh https://github.com/owner/repo
This single command will:
- Start DevTunnel automatically
- Launch the webhook server
- Create a GitHub webhook configured for issues events
- Display the webhook URL and status
Press Ctrl+C to stop both services when done.
Prerequisites:
- GitHub CLI (
gh) installed and authenticated (gh auth login) .envfile withGITHUB_WEBHOOK_SECRETconfigured
Supported repository URL formats:
https://github.com/owner/repogit@github.com:owner/repo.gitowner/repo
If you prefer to run each component separately:
-
Setup Environment
cp .env.sample .env
Edit
.envand set yourGITHUB_WEBHOOK_SECRET(generate one withopenssl rand -hex 32)Optional: Enable Repository Cloning
CLONE_REPOS=true # Enable auto-cloning (default: false) CLONE_BASE_DIR=./repos # Base directory (default: ./repos) CLONE_UPDATE_EXISTING=false # Pull updates if exists (default: false)
Note: Repository cloning requires the
ghCLI to be installed and authenticated (gh auth login) -
Start DevTunnel
./scripts/start-devtunnel.sh
Copy the DevTunnel URL from the output (e.g.,
https://xxxxx.devtunnels.ms) -
Start Webhook Server
uv run src/webhook.py
-
Configure GitHub Webhook
- Go to your repository settings → Webhooks → Add webhook
- Payload URL:
https://your-devtunnel-url.devtunnels.ms/webhook - Content type:
application/json - Secret: Use the same secret from your
.envfile - Events: Select "Issues"
- Save webhook
The webhook will print issue details to the console when issues are created or updated. If CLONE_REPOS=true, it will also automatically clone the repository locally.
SDLC is a complete software development lifecycle automation tool that orchestrates the entire feature development workflow from planning to pull request creation:
# Automate complete feature development
./src/sdlc.py "add support for pull request events"
# Or use via uv
uv run src/sdlc.py "add timestamp logging to webhook events"SDLC executes multiple Copilot prompts in sequence, managing context between stages and logging all activities. The workflow orchestrates: feature planning → branch creation → implementation → documentation → pull request.
How It Works:
- Feature planning: Creates a feature spec based on your description
- Branch creation: Creates a git branch for the feature
- Implementation: Implements the feature code
- Documentation: Updates README and GitHub instructions
- Pull request: Creates a GitHub pull request
Each stage logs its command and output to a timestamped markdown file for audit trail and debugging.
Prerequisites:
- GitHub Copilot CLI installed and authenticated
- Python 3.12 or higher
- Git repository initialized locally
ADIL is a command-line utility that integrates GitHub Copilot CLI into your development workflow. It automatically loads project context and helps with development tasks:
# Get help with implementing a feature
./src/adil.py "add support for pull request events"
# Or use via uv
uv run src/adil.py "fix the webhook signature verification"ADIL combines your prompt with project context from docs/prime.md and invokes Copilot with automation enabled. This accelerates the development loop by eliminating manual context setup.
Prerequisites:
- GitHub Copilot CLI installed and authenticated
- Python 3.12 or higher
Display "koozie" in fun ASCII art format:
./src/koozie.pyOr via uv:
uv run src/koozie.pyThis lightweight utility showcases the project's playful side and can be integrated into welcome messages or project documentation.
Run the integration test suite to verify the webhook server works correctly:
# Run all tests
uv run pytest
# Run tests with verbose output
uv run pytest -v
# Run tests with even more verbose output
uv run pytest -vv
# Run specific test file
uv run pytest tests/test_webhook_integration.py -v
# Run specific test
uv run pytest tests/test_webhook_integration.py::test_valid_webhook_with_correct_signature -vThe tests are integration tests that start the actual webhook server as a subprocess and send real HTTP requests to validate behavior. No external services or real GitHub credentials are needed - tests run completely offline and use mock payloads with test secrets.