cbfa 0.0.7
pip install cbfa
Latest version
Released:
Class-based views for the FastAPI
Navigation
Verified details
These details have been verified by PyPIProject links
GitHub Statistics
Maintainers
Unverified details
These details have not been verified by PyPIMeta
- License: MIT License
- Author: Evgeniy Blinov
- Requires: Python >=3.8
Classifiers
- Framework
- Intended Audience
- License
- Operating System
- Programming Language
- Topic
Project description
A bit of dummy patching for FastAPI, class-based handlers. So far without self
support.
Install it:
$ pip install cbfa
And use:
from typing import Optional
from fastapi import FastAPI
from pydantic import BaseModel
from cbfa import ClassBased
app = FastAPI()
wrapper = ClassBased(app)
class Item(BaseModel):
name: str
price: float
is_offer: Optional[bool] = None
@wrapper('/item')
class Item:
def get(item_id: int, q: Optional[str] = None):
return {"item_id": item_id, "q": q}
def post(item_id: int, item: Item):
return {"item_name": item.name, "item_id": item_id}
Project details
Verified details
These details have been verified by PyPIProject links
GitHub Statistics
Maintainers
Unverified details
These details have not been verified by PyPIMeta
- License: MIT License
- Author: Evgeniy Blinov
- Requires: Python >=3.8
Classifiers
- Framework
- Intended Audience
- License
- Operating System
- Programming Language
- Topic
Release history Release notifications | RSS feed
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
File details
Details for the file cbfa-0.0.7.tar.gz
.
File metadata
- Download URL: cbfa-0.0.7.tar.gz
- Upload date:
- Size: 3.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 37eebc4009e09f9413a79ec9619572aca63ee169c5701ac7346c7544c0d42d45 |
|
MD5 | 47701c0d16f3ecc74bdc1d8841c6ceb7 |
|
BLAKE2b-256 | 6b1f3000b0f886ffd177ac804e1c4e3b32ebb1fa3142ca425e8728cd501f3af1 |
Provenance
The following attestation bundles were made for cbfa-0.0.7.tar.gz
:
Publisher:
release.yml
on pomponchik/cbfa
-
Statement:
- Statement type:
https://in-toto.io/Statement/v1
- Predicate type:
https://docs.pypi.org/attestations/publish/v1
- Subject name:
cbfa-0.0.7.tar.gz
- Subject digest:
37eebc4009e09f9413a79ec9619572aca63ee169c5701ac7346c7544c0d42d45
- Sigstore transparency entry: 178601251
- Sigstore integration time:
- Permalink:
pomponchik/cbfa@68ab2f083eb54f51abf7b5f16ea0d8bcf86c375d
- Branch / Tag:
refs/heads/main
- Owner: https://github.com/pomponchik
- Access:
public
- Token Issuer:
https://token.actions.githubusercontent.com
- Runner Environment:
github-hosted
- Publication workflow:
release.yml@68ab2f083eb54f51abf7b5f16ea0d8bcf86c375d
- Trigger Event:
push
- Statement type:
File details
Details for the file cbfa-0.0.7-py3-none-any.whl
.
File metadata
- Download URL: cbfa-0.0.7-py3-none-any.whl
- Upload date:
- Size: 3.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 153ff42059bd104fbd5e12048d51b1e3a1912f6ade1b89ef6a0594a75213f805 |
|
MD5 | 328902404bbd1a6d7e9837910b2ea0a0 |
|
BLAKE2b-256 | e6665d216319c4f26b76a3e71d536b2f6735f2291cebd0319abfd93a6b7a9c06 |
Provenance
The following attestation bundles were made for cbfa-0.0.7-py3-none-any.whl
:
Publisher:
release.yml
on pomponchik/cbfa
-
Statement:
- Statement type:
https://in-toto.io/Statement/v1
- Predicate type:
https://docs.pypi.org/attestations/publish/v1
- Subject name:
cbfa-0.0.7-py3-none-any.whl
- Subject digest:
153ff42059bd104fbd5e12048d51b1e3a1912f6ade1b89ef6a0594a75213f805
- Sigstore transparency entry: 178601256
- Sigstore integration time:
- Permalink:
pomponchik/cbfa@68ab2f083eb54f51abf7b5f16ea0d8bcf86c375d
- Branch / Tag:
refs/heads/main
- Owner: https://github.com/pomponchik
- Access:
public
- Token Issuer:
https://token.actions.githubusercontent.com
- Runner Environment:
github-hosted
- Publication workflow:
release.yml@68ab2f083eb54f51abf7b5f16ea0d8bcf86c375d
- Trigger Event:
push
- Statement type: