Skip to main content

FABI+ Framework - Production-ready, modular, extensible API-only Python framework

Project description

FABI+ Framework

FABI+ Logo

FABI+ (FastAPI + Django-like Admin Interface) is a modern Python web framework that combines the speed and flexibility of FastAPI with the convenience of Django-style admin interfaces and ORM patterns.

PyPI version Python Support License: MIT Tests Coverage

Documentation โ€ข Quick Start โ€ข Examples โ€ข Contributing

๐Ÿš€ Features

๐Ÿ”ฅ Core Features

  • FastAPI Backend: High-performance async API with automatic OpenAPI documentation
  • Django-style Admin: Familiar admin interface with CRUD operations
  • Multiple ORM Support: SQLModel and SQLAlchemy (Tortoise ORM planned for future release)
  • Auto-generated APIs: Automatic CRUD endpoints for your models
  • CLI Tools: Django-like management commands (startproject, startapp, migrate)

๐Ÿ” Authentication & Security

  • OAuth2 + JWT: Built-in authentication with JWT tokens
  • Role-based Permissions: Granular permissions with custom roles
  • User Registration: Built-in user registration and management
  • Security Headers: CORS, CSP, and other security features
  • Rate Limiting: Built-in API rate limiting

๐Ÿ—„๏ธ Database & ORM

  • Database Migrations: Alembic integration for schema management
  • Multiple Databases: PostgreSQL, MySQL, SQLite support
  • Connection Pooling: Optimized database connections
  • Query Optimization: Built-in query optimization and caching

๐Ÿš€ Production Ready

  • Docker Support: Ready-to-use Docker configurations
  • Caching Support: Redis and in-memory caching
  • Logging & Monitoring: Comprehensive logging and health checks
  • Performance: Optimized for high-performance applications
  • Scalability: Horizontal and vertical scaling support

๐Ÿ“ฆ Installation

Using pip (Recommended)

pip install fabiplus

From source

git clone https://github.com/helevon/fabiplus.git
cd fabiplus
pip install -e .

Development installation

git clone https://github.com/helevon/fabiplus.git
cd fabiplus
pip install -e ".[dev]"

๐Ÿƒโ€โ™‚๏ธ Quick Start

1. Create a new project

fabiplus project startproject myblog
cd myblog

2. Create an app

fabiplus app startapp blog

3. Define your models

# apps/blog/models.py
from fabiplus.core.models import BaseModel, register_model
from sqlmodel import Field
from typing import Optional
import uuid

@register_model
class Post(BaseModel, table=True):
    """Blog post model"""
    
    title: str = Field(max_length=200, description="Post title")
    content: str = Field(description="Post content")
    excerpt: Optional[str] = Field(default="", description="Post excerpt")
    is_published: bool = Field(default=False, description="Is published")
    author_id: uuid.UUID = Field(foreign_key="user.id", description="Post author")
    
    class Config:
        _verbose_name = "Blog Post"
        _verbose_name_plural = "Blog Posts"
    
    def __str__(self):
        return self.title

4. Configure your app

# myblog/settings.py
INSTALLED_APPS = [
    "apps.core",
    "apps.blog",  # Add your app here
]

5. Run migrations

fabiplus db makemigrations
fabiplus db migrate

6. Create a superuser

fabiplus user create --username admin --email admin@example.com --password admin123 --superuser

7. Start the server

fabiplus server run

8. Access your application

๐ŸŽฏ Use Cases

FABI+ is perfect for:

  • Blog Systems: Content management with authentication
  • API Backends: RESTful APIs with automatic documentation
  • Admin Dashboards: Data management interfaces
  • E-commerce: Product catalogs and order management
  • CMS Applications: Content management systems
  • SaaS Applications: Multi-tenant applications with role-based access

๐Ÿ“š Documentation

๐Ÿค Contributing

We welcome contributions from the community! FABI+ is open source and we encourage you to help make it better.

๐ŸŒŸ Ways to Contribute

  • ๐Ÿ› Report Bugs: Create an issue
  • ๐Ÿ’ก Request Features: Feature requests
  • ๐Ÿ“ Improve Documentation: Help us improve our docs
  • ๐Ÿ”ง Submit Code: Fix bugs or add new features
  • ๐Ÿงช Write Tests: Help us improve test coverage
  • ๐Ÿ’ฌ Join Discussions: GitHub Discussions

๐Ÿ› ๏ธ Development Setup

  1. Fork and clone the repository

    git clone https://github.com/yourusername/fabiplus.git
    cd fabiplus
    
  2. Set up development environment

    python -m venv venv
    source venv/bin/activate  # On Windows: venv\Scripts\activate
    pip install -e ".[dev]"
    
  3. Run tests

    pytest
    
  4. Format code

    black fabiplus/
    isort fabiplus/
    

๐Ÿ“‹ Development Process

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Make your changes
  4. Add tests for your changes
  5. Run the test suite (pytest)
  6. Format your code (black . && isort .)
  7. Commit your changes (git commit -m 'Add amazing feature')
  8. Push to the branch (git push origin feature/amazing-feature)
  9. Open a Pull Request

๐Ÿงช Testing

We maintain high test coverage. Please add tests for any new features:

# Run all tests
pytest

# Run with coverage
pytest --cov=fabiplus

# Run specific test file
pytest tests/test_models.py

# Run with verbose output
pytest -v

๐Ÿ“ Code Style

We use Black and isort for code formatting:

# Format code
black fabiplus/ tests/
isort fabiplus/ tests/

# Check formatting
black --check fabiplus/ tests/
isort --check-only fabiplus/ tests/

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

MIT License Summary

  • โœ… Commercial use - Use in commercial projects
  • โœ… Modification - Modify the source code
  • โœ… Distribution - Distribute the software
  • โœ… Private use - Use privately
  • โŒ Liability - No warranty or liability
  • โŒ Warranty - No warranty provided

๐Ÿ™ Acknowledgments

  • FastAPI - For the excellent async framework
  • Django - For admin interface inspiration
  • SQLModel - For the modern ORM approach
  • Pydantic - For data validation
  • Alembic - For database migrations
  • The Python Community - For amazing tools and libraries

๐ŸŒŸ Star History

Star History Chart

๐Ÿ“ž Support & Community


Made with โค๏ธ by the Helevon team

โญ Star us on GitHub โ€ข ๐Ÿš€ Try the Demo โ€ข ๐Ÿ“– Read the Docs

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

fabiplus-1.0.0.tar.gz (269.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fabiplus-1.0.0-py3-none-any.whl (314.3 kB view details)

Uploaded Python 3

File details

Details for the file fabiplus-1.0.0.tar.gz.

File metadata

  • Download URL: fabiplus-1.0.0.tar.gz
  • Upload date:
  • Size: 269.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for fabiplus-1.0.0.tar.gz
Algorithm Hash digest
SHA256 dd5400f3a62132c1dbbc7707b546961e8cfef2244b6dd1a0940e10f03358f5da
MD5 7235739fe55954759c63f28713fe9632
BLAKE2b-256 da247be5783d2a4f02c6dd4819f18fe15dba45b63a21e4c9454983f2deb85916

See more details on using hashes here.

Provenance

The following attestation bundles were made for fabiplus-1.0.0.tar.gz:

Publisher: ci.yml on Helevon-Technologies-LTD/fabiplus

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fabiplus-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: fabiplus-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 314.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for fabiplus-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ade4c24c685f55b94eee6b35c6aa8cdcc71faa3a980419145f42cd3273f7b587
MD5 e2c085cd25ad9bedc998578844ec5211
BLAKE2b-256 4b476c3733399a222e2843866b10e80714fdcfa57f6837b713b4bd4880606b14

See more details on using hashes here.

Provenance

The following attestation bundles were made for fabiplus-1.0.0-py3-none-any.whl:

Publisher: ci.yml on Helevon-Technologies-LTD/fabiplus

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page