Skip to Content
DocsDocumentation

DjangoCFG Documentation

Welcome to the DjangoCFG documentation. DjangoCFG is a comprehensive configuration framework that simplifies Django project setup and management.

What is DjangoCFG?

DjangoCFG provides a unified configuration system for Django projects, offering:

  • Type-safe configuration - Pydantic-based models with full IDE support
  • Environment management - Seamless .env file handling
  • Modular architecture - Pick and choose the components you need
  • AI-powered tools - Built-in AI agents for development assistance

Streamlit Admin

Python-only admin panel that runs as a Django child process — no separate Docker service needed.

Modern, real-time admin interface built with Streamlit. Auto-starts with Django, dies when Django dies.

# Just start Django — Streamlit starts automatically python manage.py runserver # Console output: # Streamlit started on port 8501 (PID: 12345) # Streamlit admin available at: http://localhost:8501

Key benefits:

  • No separate Docker service or process management
  • Auto-finds free port if default is busy
  • Works in single Docker container
  • Full JWT authentication from Django
  • Custom extensions with Python decorators

Code Generation

Unified code generation for multi-platform API clients (TypeScript, Python, Go, Swift).

from django_cfg.modules.django_codegen import Config, OpenAPI, Target, Language, TargetType config = Config( openapi=OpenAPI( targets=[ Target( lang=Language.TYPESCRIPT, type=TargetType.ADMIN, path=FRONTEND / "apps/admin/api/generated", groups=["cfg_*", "profiles"], ), ], ), )
python manage.py gen # All platforms python manage.py gen --ts # TypeScript only python manage.py gen --target admin # Specific target