Releases: Wytamma/fasteve
Releases · Wytamma/fasteve
v0.2.3
Version 0.2.2
Fix versioning error.
Full Changelog: v0.2.1...v0.2.2
Version 0.2.1
🎇 Pagination!
Version 0.2.0
Added SQL support via SQLModel.
Below is a example SQL API in fasteve. This API (41 lines) is equivalent to the sqlmodel example (107 lines).
from typing import Optional
from fasteve import Fasteve, Resource, SQLModel, SQLField as Field
from fasteve.io.sql import SQLDataLayer
class HeroBase(SQLModel):
name: str = Field(index=True)
secret_name: str
age: Optional[int] = Field(default=None, index=True)
class Hero(HeroBase, table=True):
id: Optional[int] = Field(default=None, primary_key=True)
class HeroCreate(HeroBase):
pass
class HeroRead(HeroBase):
id: int
class HeroUpdate(SQLModel):
name: Optional[str] = None
secret_name: Optional[str] = None
age: Optional[int] = None
hero = Resource(
model=Hero,
response_model=HeroRead,
create_model=HeroCreate,
update_model=HeroUpdate,
resource_methods=["GET", "POST"],
item_methods=["GET", "DELETE", "PATCH"],
)
resources = [hero]
app = Fasteve(resources=resources, data=SQLDataLayer)
Version 0.1.3
Version 0.1.3
I've updated all the dependancies and fixed the tests.
first release
0.1.2 :sparkles: PyPI badge and hosted logo