Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for HTTPBearer (0.03 sec)

  1. fastapi/security/http.py

        ## Example
    
        ```python
        from typing import Annotated
    
        from fastapi import Depends, FastAPI
        from fastapi.security import HTTPAuthorizationCredentials, HTTPBearer
    
        app = FastAPI()
    
        security = HTTPBearer()
    
    
        @app.get("/users/me")
        def read_current_user(
            credentials: Annotated[HTTPAuthorizationCredentials, Depends(security)]
        ):
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Wed Dec 17 21:25:59 UTC 2025
    - 13.2K bytes
    - Viewed (0)
  2. fastapi/openapi/models.py

        in_: APIKeyIn = Field(alias="in")
        name: str
    
    
    class HTTPBase(SecurityBase):
        type_: SecuritySchemeType = Field(default=SecuritySchemeType.http, alias="type")
        scheme: str
    
    
    class HTTPBearer(HTTPBase):
        scheme: Literal["bearer"] = "bearer"
        bearerFormat: Optional[str] = None
    
    
    class OAuthFlow(BaseModelWithConfig):
        refreshUrl: Optional[str] = None
        scopes: dict[str, str] = {}
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 12:54:56 UTC 2025
    - 15.1K bytes
    - Viewed (0)
Back to top