A self-hosted feature toggle management platform inspired by LaunchDarkly and ConfigCat.
Toggly is organized as a Cargo workspace with three crates:
- toggly-core — Shared types, data models, and SQLite database layer
- toggly-server — Axum HTTP server hosting the Management API and Client Evaluation API
- toggly-tui — Terminal UI (ratatui) for managing feature toggles
- Project — Top-level organizational unit (e.g. "my-app")
- Environment — Deployment context within a project (e.g. "production", "staging"), each with a unique SDK key
- Flag — Feature flag definition scoped to a project, with support for boolean, string, number, and JSON types
- Flag Environment State — Per-environment configuration for each flag (enabled/disabled, default value, off value)
- Rust 1.70+
export TOGGLY_ADMIN_API_KEY="your-secret-admin-key"
cargo run --bin toggly-serverThe server starts on 0.0.0.0:8080 by default. Configuration via environment variables:
TOGGLY_DB_PATH— Path to SQLite database file (default:toggly.db)TOGGLY_ADMIN_API_KEY— (required) Admin API key for management endpointsTOGGLY_HOST— Bind address (default:0.0.0.0)TOGGLY_PORT— Bind port (default:8080)
export TOGGLY_ADMIN_API_KEY="your-secret-admin-key"
cargo run --bin toggly-tuiTOGGLY_SERVER_URL— Server base URL (default:http://localhost:8080)TOGGLY_ADMIN_API_KEY— (required) Admin API key
j/kor arrow keys — NavigateEnter— Select / drill inEsc/q— Go back / quitc— Create (project, environment, or flag)d— Deletet— Toggle flag enabled/disabled (on flag detail screen)Tab— Switch between environments and flags panesr— Refresh
Authenticated via Authorization: Bearer <ADMIN_API_KEY>.
Projects
POST /api/v1/projects— Create projectGET /api/v1/projects— List projectsGET /api/v1/projects/:id— Get projectPUT /api/v1/projects/:id— Update projectDELETE /api/v1/projects/:id— Delete project
Environments
POST /api/v1/projects/:project_id/environments— Create environmentGET /api/v1/projects/:project_id/environments— List environmentsDELETE /api/v1/projects/:project_id/environments/:id— Delete environment
Flags
POST /api/v1/projects/:project_id/flags— Create flagGET /api/v1/projects/:project_id/flags— List flagsGET /api/v1/projects/:project_id/flags/:key— Get flag with all environment statesPUT /api/v1/projects/:project_id/flags/:key— Update flag metadataDELETE /api/v1/projects/:project_id/flags/:key— Delete flag
Flag State
PUT /api/v1/projects/:project_id/flags/:key/environments/:env_id— Update flag state
Authenticated via Authorization: Bearer <SDK_KEY> (the SDK key of the target environment).
GET /eval/v1/flags— Get all flag values for the environmentGET /eval/v1/flags/:key— Get a single flag's resolved value
Example:
curl -H "Authorization: Bearer sdk-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" \
http://localhost:8080/eval/v1/flags
# { "flags": { "dark-mode": { "enabled": true, "value": true }, ... } }