.env.example to .env and configure the required variables to get started.
Required Variables
These variables must be set for Nectr to start and review PRs.AI Configuration
The Claude model to use for PR reviews.
Database
PostgreSQL connection string with asyncpg driver.Recommended: Use Supabase free tier.Navigate to: Dashboard → Connect → Connection Pooling → Session Mode (port 5432)
GitHub OAuth
GitHub OAuth App client secret.
GitHub Personal Access Token (Classic) with
repo scope.Used to post PR review comments on behalf of your account.Create at: github.com/settings/tokens → Generate new token (classic)Required scope: repo (Full control of private repositories)Authentication
Secret key for JWT signing and token encryption.Generate a secure random key:
JWT signing algorithm.
JWT token expiration time in minutes (default: 24 hours).
URLs
Public URL where your backend API is hosted.This URL is used for:
- GitHub webhook callback endpoints
- OAuth redirect URIs
Public URL where your frontend is hosted.Used for redirects after authentication.
Neo4j Knowledge Graph
Neo4j connection URI.Enables file-expert maps and related-PR context in every review.Get a free instance at: neo4j.com/cloud/platform/aura-graph-database
Neo4j username.
Neo4j password.
Mem0 Memory Layer
Mem0 API key for semantic memory storage.Enables per-project patterns and per-developer learned habits.Get your API key at: mem0.ai
Optional Variables
These variables enable optional features. Leave blank to disable.MCP Integrations
Pull live context (issues, errors, messages) into every review. Each integration is independent — set only the ones you use.Linear Integration
Linear Integration
Sentry Integration
Sentry Integration
Slack Integration
Slack Integration
Slack MCP server base URL for fetching relevant channel messages.
Slack Bot (Direct Notifications)
Slack Bot User OAuth Token for direct notifications.This is separate from the MCP Slack integration above.
Slack app signing secret for verifying webhook requests.
Webhook Security
Global fallback webhook secret.Per-repo secrets are stored in the database automatically when you connect a repo. This global secret is only used as a fallback if no per-repo secret is found.
Feature Flags
Enable parallel review mode with 3 specialized agents.
false(default): Single agentic review loop (faster, less token usage)true: 3 specialized agents run in parallel (security / performance / style)
How Parallel Agents Work
How Parallel Agents Work
When enabled, Nectr runs three specialized agents concurrently:
- Security Agent - Focuses on vulnerabilities, authentication, data validation
- Performance Agent - Analyzes efficiency, database queries, caching
- Style Agent - Reviews code style, patterns, and maintainability
- ✅ More thorough, specialized analysis
- ✅ Parallel execution can be faster for large PRs
- ❌ Higher token usage (4x Claude API calls)
- ❌ Slightly higher cost per review
App Settings
Safe to leave as-is for local development.Application name.
Application environment.
development- Development mode (CORS relaxed, debug enabled)production- Production mode (CORS strict, webhook signature verification enforced)
Enable debug mode.
Logging level.Options:
DEBUG, INFO, WARNING, ERROR, CRITICALServer host binding.
Server port.
Example Configuration
Minimal Configuration (Required Only)
Minimal Configuration (Required Only)
Full Configuration (All Features)
Full Configuration (All Features)
Next Steps
OAuth Setup
Configure GitHub OAuth App for user authentication
Webhooks
Learn how webhooks are configured and verified