A dynamic FastAPI router that automatically creates CRUD routes for your models

Overview

Create CRUD routes with lighting speed
A dynamic FastAPI router that automatically creates CRUD routes for your models

Tests Docs Package version


Documentation: https://fastapi-crudrouter.awtkns.com

Source Code: https://github.com/awtkns/fastapi-crudrouter


Tired of rewriting the same generic CRUD routes? Need to rapidly prototype a feature for a presentation or a hackathon? Thankfully, fastapi-crudrouter has your back. As an extension to the APIRouter included with FastAPI, the FastAPI CRUDRouter will automatically generate and document your CRUD routes for you, all you have to do is pass your model and maybe your database connection.

FastAPI-CRUDRouter is also lighting fast, well tested, and production ready.

Installation

pip install fastapi-crudrouter

Basic Usage

Below is a simple example of what the CRUDRouter can do. In just ten lines of code, you can generate all the crud routes you need for any model. A full list of the routes generated can be found here.

from pydantic import BaseModel
from fastapi import FastAPI
from fastapi_crudrouter import MemoryCRUDRouter as CRUDRouter

class Potato(BaseModel):
    id: int
    color: str
    mass: float

app = FastAPI()
app.include_router(CRUDRouter(schema=Potato))

OpenAPI Support

By default, all routes generated by the CRUDRouter will be documented according to OpenAPI spec.

Below are the default routes created by the CRUDRouter shown in the generated OpenAPI documentation.

OpenAPI Route Overview

The CRUDRouter is able to dynamically generate detailed documentation based on the models given to it.

OpenAPI Route Detail

Future Features 😎

Features planned for future releases include:

  • Pagination support
  • MongoDB / motor support
  • Support for other backends
  • And much more

Please open an issue if there is a specific feature you would like supported.

Comments
  • [FEAT] Different dependencies per function

    [FEAT] Different dependencies per function

    Hello,

    I am looking at modifying your crudrouter to work with Marmelab's react-admin.

    To work with their Listview, I added pagination, sort column and order, column filter and result count to the get_all function.

    To work with their Edit and Create views, I have permissions rules on the front end but I would like to have some on the backend too.

    I added a dependency to the router and check there the authenticated status. I suppose I could extend it to check the method and path and allow / restrict access based on this and permissions. However I thought it would also be convenient to have different dependencies per route/function as these rules might be different from collection to collection.

    Something like this:

    users_router = SQLAlchemyCRUDRouter(
        schema=User,
        create_schema=UserCreate,
        db_model=UserModel,
        db=get_db,
        prefix='users',
        dependencies=[Depends(token_auth)],
        delete_one_route_dependencies=[Depends(must_be_admin)],
        delete_all_route_dependencies=[Depends(must_be_admin)],
    )
    

    I am not sure this is a good idea but if it seems interesting, where would you suggest I look at implementing this? I looked in your code but was not sure if this should be in CRUDGenerator or in add_api_route.

    In any case, great project, thank you !

    enhancement 
    opened by DorskFR 15
  • Add ormar support

    Add ormar support

    Hi,

    Since I am lazy and want the tools to do boring work for me I installed and used:

    • flake8 - to check styles, pep8, complexity etc. with set of plugins to check different style related issues
    • black - installed with flake8 (one of plugins) to format code in a consistent way -> always the same regardless who is making the change, I especially like how it breaks long lines
    • mypy - to check the types annotations

    I also modified the code to pass all those test/ tools which mean a lot of minor changes basically everywhere, added missing types, fixed types enough to pass mypy checks (although it's not done fully), remove unused imports, reorder import etc. You still have few minor issues like some too complex methods according to those checks but that I didn't want to change.

    I also extracted creation of the items in pagination tests into fixtures and changed it's scope (scope is now class so they run once per implementation), as before they were running per every parametrization and in effect the tests for all backends were running several minutes and now they run like 40s, and tests should run quickly or you end up not running them often enough. Since you test creation in the separate tests I think it's beneficial as you do not create the same items 20-30 times in those few tests.

    I know that you might not like such a massive changes (although they are all style related - there is no logic change - apart from ormar implementation of course :) ), so if you refuse it we can just extract ormar files (tests and backend) with docs.

    It was still easier for me to check my ormar implementation this way even if you would want to discard those changes.

    But I think the project would benefit from tiding up that was done in this PR, so please review the PR and let me know what you think.

    enhancement 
    opened by collerek 13
  • DELETE endpoint returns 404

    DELETE endpoint returns 404

    I'm mixing this project and FastAPI-Users together so I have a very basic DatabasesCRUDRouter that has delete_all_route disabled and the delete_one_route has FastAPI-Users dependency for superuser on it. Otherwise, nothing else interacts with the delete endpoints yet when I delete an item I'm returned with 404 error and the detail says the item is not found.

    The item is deleted though.

    from fastapi import Depends
    from fastapi_crudrouter import DatabasesCRUDRouter
    
    from app.core.users import fastapi_users
    from app.db.session import database
    from app.models.thing import Thing as ThingTable 
    from app.schemas.thing import ThingCreate, Thing
    
    current_active_verified_user = fastapi_users.current_user(active=True, verified=True)
    current_superuser = fastapi_users.current_user(active=True, superuser=True)
    
    thing_db = ThingTable.__table__
    
    router = DatabasesCRUDRouter(
        prefix="things",
        tags=["things"],
        schema=Thing,
        create_schema=ThingCreate,
        table=thing_db,
        database=database,
        # Disable delete_all endpoint
        delete_all_route=False,
        # Dependencies for endpoints
        create_route=[Depends(current_active_verified_user)],
        update_route=[Depends(current_active_verified_user)],
        delete_one_route=[Depends(current_superuser)],
    )
    
    bug 
    opened by michaeltoohig 10
  • document 404 response

    document 404 response

    Closes #103, #102

    PR Includes 404 responses for the retrieve, update, and delete endpoints.

    Context

    I started working on this thinking that crudrouter manually documented the 200 and 422 response, but I've come to suspect that this is built-into FastAPI - is that right?

    Passing responses to fastapi.routing.add_api_route seems to satisfy the wip test I created. I also tested with

    Left to do

    Before finalizing, I was hoping to run the test suite here @awtkns - I had some trouble setting up some of the test requirements locally 👏 And please let me know if you have any suggestions for improvement.

    And if you have any ideas about where to include tests, that would be great! So far I just put a wip test in test_openapi_schema.py which seemed fitting.

    enhancement 
    opened by sondrelg 9
  • Feature/poetry

    Feature/poetry

    Resolves #156

    • Adds pyproject.toml with poetry config.
    • Adds poetry.lock — all dependencies are here.
    • Updates requirements.txt and dev.requirements.txt — exported from poetry, so no conflicting package versions are installed.
    • Updates contributing.md with info about poetry.
    • Changes psycopg2 to psycopg2-binary to avoid building psycopg2.
    opened by dclimber 8
  • ModuleNotFoundError: No module named 'fastapi_crudrouter'

    ModuleNotFoundError: No module named 'fastapi_crudrouter'

    Hello.

    I'm trying fastapi-crudrouter. Unfortunetly, I'm experiencing an unrecognized issue:

    ModuleNotFoundError: No module named 'fastapi_crudrouter'

    I have virtualenv with fastapi-crudrouter installed

    rom pydantic import  BaseModel
    from fastapi import FastAPI
    from fastapi_crudrouter import MemoryCRUDRouter as CRUDRouter
    
    
    class Potato(BaseModel):
        id: int
        color: str
        mass: float
    
    app = FastAPI()
    
    app.include_router(CRUDRouter(schema=Potato))
    

    requiremnts.txt

    fastapi==0.68.1
    fastapi-crudrouter==0.8.1
    pydantic==1.8.2
    starlette==0.14.2
    typing-extensions==3.10.0.2
    
    opened by arkryonia 8
  • CrudRouter Lazy loading support

    CrudRouter Lazy loading support

    Hello, I would like to know if there is a way to have "lazy loading" using crudrouter on fastapi? Is there a solution or a manner to do it? Thank you in advance.

    question 
    opened by davidgfr 6
  • Tortoise orm support

    Tortoise orm support

    So I run into an import error for the testclient when I try and run the tests but in theory everything works for the test implementation and I tested it by hand and it should behave the same way as the others!

    opened by timwford 5
  • Validation error with Json pydantic field

    Validation error with Json pydantic field

    I use a JSONB column in Postgres, but I do get an error on the GET all route with my specified pydantic model with json_field: Optional[pydantic.Json] = None with proper json data in my database table. The exception is:

    ..../python3.9/site-packages/fastapi/routing.py", line 137, in serialize_response
        raise ValidationError(errors, field.type_)
    pydantic.error_wrappers.ValidationError: 2 validation errors for MyModel
    response -> 0
      value is not a valid dict (type=type_error.dict)
    

    Any idea how to fix that? Thanks.

    opened by unidesigner 4
  • Dependencies can be added to each separate route (list of dependencies)

    Dependencies can be added to each separate route (list of dependencies)

    Hello,

    So as discussed in #37

    I think this might be how to make a pull request so I give it a try.

    If this is not needed or too late, it's fine, I am glad to learn!

    closes #59 #37

    opened by DorskFR 4
  • SQLAlchemyCRUDRouter - With joined tables

    SQLAlchemyCRUDRouter - With joined tables

    fastapi 0.63.0 fastapi-crudrouter 0.6.1

    Trying to use SQLAlchemyCRUDRouter for joined tables , All endpoints created automatically (amazing:)).

    Tried using the "create one " for input:

    {
      "customer_no": 1,
      "subscriber": [
        {
          "subscriber_no": 1,
          "is_active": false,
          "owner": 1
        }
      ]
    }
    
    

    End up with error:

    File "/usr/local/lib/python3.8/site-packages/sqlalchemy/orm/state.py", line 434, in _initialize_instance
        return manager.original_init(*mixed[1:], **kwargs)
      File "/usr/local/lib/python3.8/site-packages/sqlalchemy/orm/decl_base.py", line 1086, in _declarative_constructor
        setattr(self, k, kwargs[k])
      File "/usr/local/lib/python3.8/site-packages/sqlalchemy/orm/attributes.py", line 427, in __set__
        self.impl.set(
      File "/usr/local/lib/python3.8/site-packages/sqlalchemy/orm/attributes.py", line 1512, in set
        collections.bulk_replace(
      File "/usr/local/lib/python3.8/site-packages/sqlalchemy/orm/collections.py", line 817, in bulk_replace
        appender(member, _sa_initiator=initiator)
      File "/usr/local/lib/python3.8/site-packages/sqlalchemy/orm/collections.py", line 1131, in append
        item = __set(self, item, _sa_initiator)
      File "/usr/local/lib/python3.8/site-packages/sqlalchemy/orm/collections.py", line 1096, in __set
        item = executor.fire_append_event(item, _sa_initiator)
      File "/usr/local/lib/python3.8/site-packages/sqlalchemy/orm/collections.py", line 727, in fire_append_event
        return self.attr.fire_append_event(
      File "/usr/local/lib/python3.8/site-packages/sqlalchemy/orm/attributes.py", line 1345, in fire_append_event
        value = fn(state, value, initiator or self._append_token)
      File "/usr/local/lib/python3.8/site-packages/sqlalchemy/orm/attributes.py", line 1675, in emit_backref_from_collection_append_event
        child_state, child_dict = instance_state(child), instance_dict(child)
    AttributeError: 'dict' object has no attribute '_sa_instance_state'
    
    

    Code:

    Routes:

    from config.config import postgress_engine,SessionLocal
    from fastapi_crudrouter impor SQLAlchemyCRUDRouter as SQLDBCrudRouter
    
    customer_router = APIRouter()
    
    def get_db():
        session = SessionLocal()
        try:
            yield session
            session.commit()
        finally:
            session.close()
    
    
    customer_router = SQLDBCrudRouter(schema=Customer,create_schema=CustomerCreate,
                 db_model=CustomerModel,db=get_db,prefix='customer')
    

    schemas.py

    
    
    from pydantic import BaseModel
    from typing import List, Optional
    
    
    class SubscriberBase(BaseModel):
        subscriber_no: int
        is_active: bool = False
    
    class SubscriberCreate(BaseModel):
        pass
    
    
    class Subscriber(SubscriberBase):
        owner: int
    
        class Config:
            orm_mode = True
    
    class CustomerCreate(BaseModel):
        customer_no: Optional[int] = None
        subscriber: Optional[List[Subscriber]] =None
    
    class Customer(CustomerCreate):
        id: int
        class Config:
            orm_mode = True
    
    

    models.py

    
    from sqlalchemy import Boolean, Column, ForeignKey, Integer, String,DateTime
    from sqlalchemy.orm import relationship
    from config.config import Base
    
    
    class CustomerModel(Base):
        __tablename__ = 'customer'
        id = Column(Integer, primary_key=True, index=True)
        customer_no= Column(Integer,index=True)
        subscriber= relationship("SubscriberModel", back_populates="owner")
    
    
    class SubscriberModel(Base):
        __tablename__ = 'subscriber'
        id = Column(Integer, ForeignKey("customer.id"))
        subscriber_no= Column(Integer, primary_key=True, index=True)
        owner = relationship("CustomerModel", back_populates="subscriber")
    
    
    
    
    question 
    opened by avico78 4
  • Add feature to customize the item_id parameter name

    Add feature to customize the item_id parameter name

    As mentioned in #163 a feature request to customize the item_id parameter name in the OpenAPI specification was requested. I implemented it and added some extra tests and documentation for it.

    I would be very thankful if you would add the HACKTOBERFEST-ACCEPTED to this pull request.

    Hope this helps. Thanks in advance.

    opened by nikstuckenbrock 1
  • Allow objects in attributes for create/update routes (sqlalchemy)

    Allow objects in attributes for create/update routes (sqlalchemy)

    This is something I've implemented for sqlalchemy at my day job. Wondering if it's useful to others...

    For one-2-many and many-2-many relationships, it would be nice to allow the create and update routes to accept a partial object in the foreign key attribute. For example:

    client.post("/heros", json={
        "name": Bob,
        "team": {"name": "Avengers"}
    }
    

    As is today, you need to do the following:

    client.post("/heros", json={
        "name": Bob,
        "team_id": 42
    }
    

    I've created PR https://github.com/awtkns/fastapi-crudrouter/pull/171 with an initial implementation. Would appreciate feedback. I'm not 100% happy with the way that I've connected the read and table objects and would welcome ideas on that.

    One other feature that would be nice would be to allow for sub-object creation. That could be enabled at the route level with some arg. I don't have a need for that right now, but would be good for a full solution.

    I've only implemented this for SQLAlchemy as that's all I'm using right now. Would probably be applicable to other back-ends as well.

    opened by cycledriver 0
  • [sqlalchemy] allow create/update with object for one/many 2 many

    [sqlalchemy] allow create/update with object for one/many 2 many

    For one-2-many and many-2-many relationships, allow the create and update routes to accept a partial object in the foreign key attribute. For example:

    client.post("/heros", json={
        "name": Bob,
        "team": {"name": "Avengers"}
    }
    

    Assuming there is already a team called Avengers, Bob will be created, the Team with name "Avengers" will be looked up and used to populate Bob's team_id foreign key attribute.

    The only setup required is for the input model for the foreign object to specify the Table class that can be used to lookup the object.

    For example:

    class Team(Base):
        """Team DTO."""
    
        __tablename__ = "teams"
    
        id = Column(Integer, primary_key=True, index=True)
        name = Column(String, unique=True)
    
    class TeamUpdate(Model):
        name: str
    
        class Meta:
            orm_model = Team
    
    opened by cycledriver 1
  • All ORMs/backends should allow partial updates

    All ORMs/backends should allow partial updates

    Currently, only tortoise and ormar backends are allowing partial updates. See relevant line for tortoise below.

    https://github.com/awtkns/fastapi-crudrouter/blob/66fd32fafaf191c58c388eb8a849dddef6e569a4/fastapi_crudrouter/core/tortoise.py#L95

    Behaviour should be consistent across all backends when possible.

    Requirement of fields should be determined by pydantic model as its primary function is validation. Currently, marking a field of pydantic model as Optional or setting a default value doesn't allow skipping that field when sending a request (for backends other than tortoise and ormar).

    Making this change would allow to both keeping the current behaviour and enabling partial updates depending on your pydantic model.

    I can create a pull request for this if it gets approved. I have already tested it in my local environment and doesn't seem to break anything else.

    opened by ulasozguler 0
  • Update sqlalchemy.py

    Update sqlalchemy.py

    Generally, define the sql model as SQLALCHEMY. The models extends Base. Parent of base is Model, but type of child Model is not Model. Therefore I fix type of db_model in SQLAlchemyCRUDRouter.

    Finally warnning is shutdown.

    opened by owjs3901 2
Releases(v0.8.5)
  • v0.8.5(Jan 27, 2022)

    🎉 Highlights

    With the release of v0.8.5 fastapi-crudrouter now officially supports both Python 3.10 and typed python. This release also includes significant improvements to the documentation, test suite, and developer experience.

    Keep an eye of for the next release which will contain support for async SQLAlchemy (#122).

    Big thanks to all contributors that made this possible!

    ✨ Features

    • Typed python support #132 #111
    • Python 3.10 support #114
    • Test suite now runs against multiple databases #86
    • Documentation improvements #79 #91 #117 #123 #124 #125 @andrewthetechie
    • More informative exceptions #94 #137
    • General test suite improvements #96 #97

    🐛 Bug Fixes

    • OrderBy not working correctly with Microsoft SQL Server #88
    • 404 response not documented in OpenAPI spec #104 @sondrelg
    • DatabasesCRUDRouter not functioning for inserts and deletes with AsyncPG #98

    Full Changelog: https://github.com/awtkns/fastapi-crudrouter/compare/v0.8.0...v0.8.5

    Source code(tar.gz)
    Source code(zip)
  • v0.8.0(Jul 7, 2021)

    🎉 Highlights

    With the release of v0.6.0 fastapi-crudrouter now supports Gino as an async backend! When generating routes, GinoCRUDRouter will automatically tie into your database using your Gino models. To use it, simply pass your Gino database model, a database reference, and your pydantic.

    GinoCRUDRouter(
        schema=MyPydanticModel,
        db_model=MyModel, 
        db=db
    )
    

    Check out the docs for more details on how to use the GinoCRUDRouter.

    ✨ Features

    • Full Gino Support @Turall #78
    • Documentation improvements #69 #75

    🐛 Bug Fixes

    • All Path Prefixes are now correctly lowercase #64 #65
    Source code(tar.gz)
    Source code(zip)
  • v0.7.0(Apr 18, 2021)

    🎉 Highlights

    With the release of v0.7.0 fastapi-crudrouter now provides the ability to set custom dependencies on a per route basis; a much requested feature. Prior to this release, it was only possible to set dependencies for all the routes at once.

    MemoryCRUDRouter(
        schema=MySchema,
        create_route=[Depends(user)],
        delete_all_route=[Depends(admin)]
    )
    

    Shown above is a brief example on how limiting each route to specific access rights would work using this new feature. Check out the docs for more details.

    ✨ Features

    • Custom Dependencies Per Route #37 #59 #60 @DorskFR @jm-moreau
    • Ability to Provide a List of Custom Tags for OpenAPI #57 @jm-moreau
    • Improved Documentation #52
    • Dark Mode for Documentation
    Source code(tar.gz)
    Source code(zip)
  • v0.6.0(Mar 26, 2021)

    🎉 Highlights

    With the release of v0.6.0 fastapi-crudrouter now supports ormar as an async backend! When generating routes, the OrmarCRUDRouter will automatically tie into your database using your ormar models. To use it, simply pass your ormar database model as the schema.

    OrmarCRUDRouter(
        schema=MyPydanticModel, 
        paginate=25
    )
    

    Check out the docs for more details on how to use the OrmarCRUDRouter.

    ✨ Features

    • Full Ormar Support @collerek #46
    • Better handling of database errors in the update route @sorXCode #48
    • Improved typing #46 #43
    • Black, Flake8 and Mypy linting #46
    • Additional Tests for nested models #40

    🐛 Bug Fixes

    • Pagination issues when max limit was set to null @ethanhaid #42
    Source code(tar.gz)
    Source code(zip)
  • v0.5.0(Mar 7, 2021)

    🎉 Highlights

    With the release of v0.5.0 all CRUDRouters now supports pagination. All "get all" routes now accept skip and limit query parameters allowing you to easily paginate your routes. By default, no limit is set on the number of items returned by your routes. Should you wish to limit the number of items that a client can request, it can be done as shown below.

    CRUDRouter(
        schema=MyPydanticModel, 
        paginate=25
    )
    

    Check out the docs on pagination for more information!

    ✨ Features

    • Pagination Support #34
    • Ability to set custom update schemas @andreipopovici #31 #27
    • Better documentation of past releases #36

    🐛 Bug Fixes

    • Prefixing not available for versions of fastapi below v0.62.0 #29 #30
    • Fixed an Import Issue SQLAlchemy and Integrity Errors @andreipopovici #33
    Source code(tar.gz)
    Source code(zip)
  • v0.4.0(Feb 2, 2021)

    ✨Features

    • Full support for tortoise-orm #24
    • Dynamic pk/id types for get_one, delete_one, and update_one routes #26

    🐛 Bug Fixes

    • Fixed the summary for the delete one route #16
    • Fixed import errors when certain packages are not installed #21
    • Improved SQLA type hinting
    Source code(tar.gz)
    Source code(zip)
  • v0.3.0(Jan 4, 2021)

    🎉 Initial Release 🎉

    Tired of rewriting the same generic CRUD routes? Need to rapidly prototype a feature for a presentation or a hackathon? Thankfully, fastapi-crudrouter has your back. As an extension to the APIRouter included with FastAPI, the FastAPI CRUDRouter will automatically generate and document your CRUD routes for you.

    Documentation: https://fastapi-crudrouter.awtkns.com

    Source Code: https://github.com/awtkns/fastapi-crudrouter

    Installation

    pip install fastapi_crudrouter
    

    Usage

    Below is a simple example of what the CRUDRouter can do. In just ten lines of code, you can generate all the crud routes you need for any model. A full list of the routes generated can be found here.

    from pydantic import BaseModel
    from fastapi import FastAPI
    from fastapi_crudrouter import MemoryCRUDRouter as CRUDRouter
    
    class Potato(BaseModel):
        id: int
        color: str
        mass: float
    
    app = FastAPI()
    app.include_router(CRUDRouter(model=Potato))
    

    Features

    • Automatic pydantic model based route generation and documentation (Docs)
    • Ability to customize any of the generated routes (Docs)
    • Authorization and FastAPI dependency support (Docs)
    • Support for both async and non-async relational databases using SQLAlchemy (Docs)
    • Extensive documentation.
    • And much more 😎
    Source code(tar.gz)
    Source code(zip)
    fastapi-crudrouter-0.3.0.tar.gz(5.23 KB)
    fastapi-crudrouter-0.3.0.win-amd64.zip(18.63 KB)
Owner
Adam Watkins
Software Engineer / Outdoor Enthusiast
Adam Watkins
Prometheus exporter for several chia node statistics

prometheus-chia-exporter Prometheus exporter for several chia node statistics It's assumed that the full node, the harvester and the wallet run on the

30 Sep 19, 2022
A rate limiter for Starlette and FastAPI

SlowApi A rate limiting library for Starlette and FastAPI adapted from flask-limiter. Note: this is alpha quality code still, the API may change, and

Laurent Savaete 562 Jan 01, 2023
Keycloack plugin for FastApi.

FastAPI Keycloack Keycloack plugin for FastApi. Your aplication receives the claims decoded from the access token. Usage Run keycloak on port 8080 and

Elber 4 Jun 24, 2022
:rocket: CLI tool for FastAPI. Generating new FastAPI projects & boilerplates made easy.

Project generator and manager for FastAPI. Source Code: View it on Github Features 🚀 Creates customizable project boilerplate. Creates customizable a

Yagiz Degirmenci 1k Jan 02, 2023
Formatting of dates and times in Flask templates using moment.js.

Flask-Moment This extension enhances Jinja2 templates with formatting of dates and times using moment.js. Quick Start Step 1: Initialize the extension

Miguel Grinberg 358 Nov 28, 2022
Get MODBUS data from Sofar (K-TLX) inverter through LSW-3 or LSE module

SOFAR Inverter + LSW-3/LSE Small utility to read data from SOFAR K-TLX inverters through the Solarman (LSW-3/LSE) datalogger. Two scripts to get inver

58 Dec 29, 2022
A minimum reproducible repository for embedding panel in FastAPI

FastAPI-Panel A minimum reproducible repository for embedding panel in FastAPI Follow either This Tutorial or These steps below ↓↓↓ Clone the reposito

Tyler Houssian 15 Sep 22, 2022
fastapi-admin2 is an upgraded fastapi-admin, that supports ORM dialects, true Dependency Injection and extendability

FastAPI2 Admin Introduction fastapi-admin2 is an upgraded fastapi-admin, that supports ORM dialects, true Dependency Injection and extendability. Now

Glib 14 Dec 05, 2022
FastAPI client generator

FastAPI-based API Client Generator Generate a mypy- and IDE-friendly API client from an OpenAPI spec. Sync and async interfaces are both available Com

David Montague 283 Jan 04, 2023
A RESTful API for creating and monitoring resource components of a hypothetical build system. Built with FastAPI and pydantic. Complete with testing and CI.

diskspace-monitor-CRUD Background The build system is part of a large environment with a multitude of different components. Many of the components hav

Nick Hopewell 67 Dec 14, 2022
Mixer -- Is a fixtures replacement. Supported Django, Flask, SqlAlchemy and custom python objects.

The Mixer is a helper to generate instances of Django or SQLAlchemy models. It's useful for testing and fixture replacement. Fast and convenient test-

Kirill Klenov 871 Dec 25, 2022
Пример использования GraphQL Ariadne с FastAPI и сравнение его с GraphQL Graphene FastAPI

FastAPI Ariadne Example Пример использования GraphQL Ariadne с FastAPI и сравнение его с GraphQL Graphene FastAPI - GitHub ###Запуск на локальном окру

ZeBrains Team 9 Nov 10, 2022
Easily integrate socket.io with your FastAPI app 🚀

fastapi-socketio Easly integrate socket.io with your FastAPI app. Installation Install this plugin using pip: $ pip install fastapi-socketio Usage To

Srdjan Stankovic 210 Dec 23, 2022
Repository for the Demo of using DVC with PyCaret & MLOps (DVC Office Hours - 20th Jan, 2022)

Using DVC with PyCaret & FastAPI (Demo) This repo contains all the resources for my demo explaining how to use DVC along with other interesting tools

Tezan Sahu 6 Jul 22, 2022
Docker image with Uvicorn managed by Gunicorn for high-performance FastAPI web applications in Python 3.6 and above with performance auto-tuning. Optionally with Alpine Linux.

Supported tags and respective Dockerfile links python3.8, latest (Dockerfile) python3.7, (Dockerfile) python3.6 (Dockerfile) python3.8-slim (Dockerfil

Sebastián Ramírez 2.1k Dec 31, 2022
A comprehensive CRUD API generator for SQLALchemy.

FastAPI Quick CRUD Introduction Advantage Constraint Getting started Installation Usage Design Path Parameter Query Parameter Request Body Upsert Intr

192 Jan 06, 2023
Toolkit for developing and maintaining ML models

modelkit Python framework for production ML systems. modelkit is a minimalist yet powerful MLOps library for Python, built for people who want to depl

140 Dec 27, 2022
Redis-based rate-limiting for FastAPI

Redis-based rate-limiting for FastAPI

Glib 6 Nov 14, 2022
Learn to deploy a FastAPI application into production DigitalOcean App Platform

Learn to deploy a FastAPI application into production DigitalOcean App Platform. This is a microservice for our Try Django 3.2 project. The goal is to extract any and all text from images using a tec

Coding For Entrepreneurs 59 Nov 29, 2022
A Sample App to Demonstrate React Native and FastAPI Integration

React Native - Service Integration with FastAPI Backend. A Sample App to Demonstrate React Native and FastAPI Integration UI Based on NativeBase toolk

YongKi Kim 4 Nov 17, 2022