mirror of
https://github.com/fastapi/fastapi.git
synced 2026-09-14 13:36:21 +08:00
🎨 Update main imports (and exports)
This commit is contained in:
+6
-2
@@ -1,3 +1,7 @@
|
||||
"""Fast API framework, high performance, fast to learn, fast to code, fast to production"""
|
||||
"""FastAPI framework, high performance, easy to learn, fast to code, ready for production"""
|
||||
|
||||
__version__ = "0.1.0"
|
||||
__version__ = "0.1.2"
|
||||
|
||||
from .applications import FastAPI
|
||||
from .routing import APIRouter
|
||||
from .params import Body, Path, Query, Header, Cookie, Form, File, Security, Depends
|
||||
|
||||
@@ -124,7 +124,7 @@ def generate_operation_id(*, route: routing.APIRoute, method: str) -> str:
|
||||
def generate_operation_summary(*, route: routing.APIRoute, method: str) -> str:
|
||||
if route.summary:
|
||||
return route.summary
|
||||
return method.title() + " " + route.name.replace("_", " ").title()
|
||||
return route.name.replace("_", " ").title() + " " + method.title()
|
||||
|
||||
|
||||
def get_openapi_operation_metadata(*, route: routing.APIRoute, method: str) -> Dict:
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
from .api_key import APIKeyQuery, APIKeyHeader, APIKeyCookie
|
||||
from .http import HTTPBasic, HTTPBearer, HTTPDigest
|
||||
from .oauth2 import OAuth2PasswordRequestForm, OAuth2
|
||||
from .open_id_connect_url import OpenIdConnect
|
||||
|
||||
Reference in New Issue
Block a user