Professional API project generator for Python - Flask, FastAPI, Django-Rest
Project description
๐ vyte - Rapid Development Tool
Professional API project generator for Python. Create production-ready REST APIs in seconds.
โจ Features
- ๐ฏ Multiple Frameworks: Flask-Restx, FastAPI, Django-Rest
- ๐๏ธ Multiple ORMs: SQLAlchemy, TortoiseORM, Peewee, Django ORM
- ๐พ Database Support: PostgreSQL, MySQL, SQLite
- ๐ JWT Authentication: Secure authentication out of the box
- ๐ณ Docker Ready: Complete Docker and docker-compose setup
- ๐งช Testing Suite: Pytest with coverage reports
- ๐ Auto Documentation: Swagger/OpenAPI automatic docs
- โก Modern Stack: Python 3.11+, Pydantic v2, async support
- ๐จ Beautiful CLI: Rich terminal UI with interactive setup
๐ Quick Start
Installation
# Using pip
pip install vyte
# Using pipx (recommended)
pipx install vyte
# From source
git clone https://github.com/PabloDomi/Vyte.git
cd vyte
pip install -e .
Create Your First Project
# Interactive mode (recommended)
vyte create
# Or specify options directly
vyte create \
--name my-api \
--framework FastAPI \
--orm SQLAlchemy \
--database PostgreSQL
What You Get
my-api/
โโโ src/
โ โโโ __init__.py # App factory
โ โโโ main.py # Entry point
โ โโโ config/
โ โ โโโ config.py # Pydantic settings
โ โโโ models/
โ โ โโโ models.py # Database models
โ โโโ routes/
โ โ โโโ routes_example.py
โ โโโ services/
โ โโโ security.py # JWT & security
โโโ tests/
โ โโโ test_api.py
โ โโโ test_models.py
โ โโโ conftest.py
โโโ requirements.txt
โโโ requirements-dev.txt
โโโ Dockerfile
โโโ docker-compose.yml
โโโ .env.example
โโโ .gitignore
โโโ pytest.ini
โโโ README.md
๐ Usage
Interactive Mode
The easiest way to create a project:
vyte create
Follow the prompts to configure your project.
Command Line Options
vyte create \
--name my-api \
--framework FastAPI \
--orm SQLAlchemy \
--database PostgreSQL \
--auth \
--docker \
--tests \
--git
Available Commands
# Create new project
vyte create
# Show framework information
vyte info FastAPI
# List all frameworks and ORMs
vyte list
# Show dependencies for configuration
vyte deps FastAPI --orm SQLAlchemy
# Validate existing project
vyte validate ./my-api
# Open documentation
vyte docs
# Show version
vyte --version
๐ฏ Supported Combinations
| Framework | Compatible ORMs | Async Support |
|---|---|---|
| Flask-Restx | SQLAlchemy, Peewee | โ Sync |
| FastAPI | SQLAlchemy (async), TortoiseORM | โ Async |
| Django-Rest | Django ORM | โ Sync |
๐ง Configuration
Projects use Pydantic Settings for configuration:
# .env file
DATABASE_URL=postgresql://user:pass@localhost:5432/mydb
JWT_SECRET_KEY=your-secret-key-here
ENVIRONMENT=development
DEBUG=True
๐งช Testing
Generated projects include complete testing setup:
# Run tests
pytest
# With coverage
pytest --cov=src --cov-report=html
# Open coverage report
open htmlcov/index.html
๐ณ Docker Support
Run your project with Docker:
# Build and run
docker-compose up -d
# View logs
docker-compose logs -f
# Stop
docker-compose down
๐ Documentation
๐ค Contributing
Contributions are welcome! Please read our Contributing Guide.
# Clone repo
git clone https://github.com/PabloDomi/Vyte.git
cd vyte
# Setup development environment
pip install -e ".[dev]"
pip install pre-commit black ruff isort
# Install pre-commit hooks
pre-commit install
# Run tests
pytest
# Format code
make format
# Run linters
make lint
# Run full CI suite
make ci
๐บ๏ธ Roadmap
Check out our Roadmap to see what's planned for future releases!
Coming in v2.1.0:
vyte upgrade- Upgrade existing projectsvyte add-model- Add models to projects- Customizable templates
- MongoDB support
๐ License
MIT License - see LICENSE file for details.
๐ Acknowledgments
๐ Project Stats
- Test Coverage: 73%
- Code Quality: A+ (Ruff, Black)
- Security: Scanned with Bandit
- Python Versions: 3.11, 3.12
- Platforms: Linux, macOS, Windows
๐ง Contact
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Email: Domi@usal.es
Made with โค๏ธ by Pablo Domรญnguez Blanco
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file vyte-2.0.6.tar.gz.
File metadata
- Download URL: vyte-2.0.6.tar.gz
- Upload date:
- Size: 97.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d740b70197fe2d1713f88e193cf7e65355d672734926a4ed817dbf7e77180634
|
|
| MD5 |
d0791d9d534801dcec80489f66479530
|
|
| BLAKE2b-256 |
6336e474e34f6af3bb3a657a87a6ec14e3679040af9fd0c3218f7ce917861f60
|
File details
Details for the file vyte-2.0.6-py3-none-any.whl.
File metadata
- Download URL: vyte-2.0.6-py3-none-any.whl
- Upload date:
- Size: 119.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
638e2918524eec618cb1cdf2e293dc85f43141cbc03059cf457bd7ec38c35958
|
|
| MD5 |
dc0aaef0a40043b67bcb0083ec040b0d
|
|
| BLAKE2b-256 |
a6507c488bf73613497bcdb5dec254132725abfc8529d91367282fa5edcda8bb
|