Configuration
Complete environment variable reference
Configuration
Claudear is configured via environment variables in a .env file. It auto-detects which providers to enable based on the variables you configure.
Important: The
.envfile must be in the current working directory when you runclaudear. Always run the command from the cloned repository folder where your.envfile is located.
Setup
Copy the example configuration and edit it:
cp .env.example .env
Single Provider Setup
Linear (Single Team)
# Linear Integration
LINEAR_API_KEY=lin_api_xxxxx
LINEAR_WEBHOOK_SECRET=whsec_xxxxx
LINEAR_TEAM_ID=ENG # Your team key from URL
# Repository
REPO_PATH=/path/to/your/repo
# ngrok (required for webhooks)
NGROK_AUTHTOKEN=your-ngrok-token
Notion (Single Database)
# Notion Integration
NOTION_API_KEY=secret_xxxxx
NOTION_DATABASE_ID=abc123def456
NOTION_POLL_INTERVAL=5
# Repository
REPO_PATH=/path/to/your/repo
# GitHub
GITHUB_TOKEN=ghp_xxxxx
Multi-Instance Setup
Claudear supports multiple Linear teams and Notion databases, each with its own repository.
Multiple Linear Teams
LINEAR_API_KEY=lin_api_xxxxx
LINEAR_WEBHOOK_SECRET=whsec_xxxxx
LINEAR_TEAM_IDS=ENG,INFRA,DESIGN # Comma-separated team keys
# Per-team repository paths (REQUIRED)
LINEAR_ENG_REPO=/path/to/engineering-repo
LINEAR_INFRA_REPO=/path/to/infrastructure-repo
LINEAR_DESIGN_REPO=/path/to/design-system-repo
Multiple Notion Databases
NOTION_API_KEY=secret_xxxxx
NOTION_DATABASE_IDS=abc123,def456,ghi789 # Comma-separated database IDs
NOTION_POLL_INTERVAL=5
# Per-database repository paths (REQUIRED)
NOTION_ABC123_REPO=/path/to/project-alpha-repo
NOTION_DEF456_REPO=/path/to/project-beta-repo
NOTION_GHI789_REPO=/path/to/project-gamma-repo
Note: Database IDs in environment variable names are uppercased and hyphens are removed.
Both Providers + Multiple Instances
Configure both sets of variables - Claudear runs everything simultaneously:
# Linear - Multiple Teams
LINEAR_API_KEY=lin_api_xxxxx
LINEAR_WEBHOOK_SECRET=whsec_xxxxx
LINEAR_TEAM_IDS=ENG,INFRA
LINEAR_ENG_REPO=/path/to/engineering-repo
LINEAR_INFRA_REPO=/path/to/infrastructure-repo
# Notion - Multiple Databases
NOTION_API_KEY=secret_xxxxx
NOTION_DATABASE_IDS=abc123,def456
NOTION_POLL_INTERVAL=5
NOTION_ABC123_REPO=/path/to/project-alpha-repo
NOTION_DEF456_REPO=/path/to/project-beta-repo
# Shared
GITHUB_TOKEN=ghp_xxxxx
NGROK_AUTHTOKEN=your-ngrok-token
Linear Workflow States
| Variable | Default | Description |
|---|---|---|
LINEAR_STATE_TODO | Todo | State that triggers task pickup |
LINEAR_STATE_IN_PROGRESS | In Progress | State while Claude is working |
LINEAR_STATE_IN_REVIEW | In Review | State after PR is created |
LINEAR_STATE_DONE | Done | Terminal state (triggers cleanup) |
Notion Status Values
Claudear auto-detects common status names. Custom mappings can be configured per-database:
| Variable | Default | Description |
|---|---|---|
NOTION_{DB}_STATUS_TODO | Todo | Status that triggers task pickup |
NOTION_{DB}_STATUS_IN_PROGRESS | In Progress | Status while working |
NOTION_{DB}_STATUS_IN_REVIEW | In Review | Status after PR creation |
NOTION_{DB}_STATUS_DONE | Done | Terminal status |
Replace {DB} with your database ID (uppercase, hyphens removed). For single-database setups, Claudear uses smart defaults.
Task Settings
| Variable | Default | Description |
|---|---|---|
MAX_CONCURRENT_TASKS | 5 | Max parallel tasks across all providers |
COMMENT_POLL_INTERVAL | 30 | Seconds between polling for comments |
BLOCKED_TIMEOUT | 3600 | Seconds before a blocked task times out |
Server Settings
| Variable | Default | Description |
|---|---|---|
WEBHOOK_PORT | 8000 | Port for the webhook server |
WEBHOOK_HOST | 0.0.0.0 | Host to bind the server |
Logging
| Variable | Default | Description |
|---|---|---|
LOG_LEVEL | INFO | Logging level (DEBUG, INFO, WARNING, ERROR) |
Getting Your API Keys
Linear API Key
- Go to Linear Settings → API
- Click "Create new API key"
- Name it "Claudear"
- Copy the key (starts with
lin_api_)
Notion API Key
- Go to Notion Integrations
- Create a new integration
- Copy the Internal Integration Token (starts with
secret_) - Share your database with the integration
Finding Your Linear Team Key
Your team key is in Linear URLs: linear.app/ENG/issue/ENG-123 → team key is ENG
Finding Your Notion Database ID
Your database ID is in the URL when viewing the database:
notion.so/workspace/abc123def456?v=... → database ID is abc123def456