Search Options

Results per page
Sort
Preferred Languages
Advance

Results 111 - 120 of 1,929 for FastAPI (0.07 sec)

  1. tests/test_additional_responses_bad.py

    import pytest
    from fastapi import FastAPI
    from fastapi.testclient import TestClient
    
    app = FastAPI()
    
    
    @app.get("/a", responses={"hello": {"description": "Not a valid additional response"}})
    async def a():
        pass  # pragma: no cover
    
    
    openapi_schema = {
        "openapi": "3.1.0",
        "info": {"title": "FastAPI", "version": "0.1.0"},
        "paths": {
            "/a": {
                "get": {
                    "responses": {
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jun 30 18:25:16 UTC 2023
    - 1.1K bytes
    - Viewed (0)
  2. docs/ko/docs/deployment/cloud.md

    사실상 거의 **모든 클라우드 제공업체**를 사용하여 여러분의 FastAPI 애플리케이션을 배포할 수 있습니다.
    
    대부분의 경우, 주요 클라우드 제공업체에서는 FastAPI를 배포할 수 있도록 가이드를 제공합니다.
    
    ## 클라우드 제공업체 - 후원자들
    
    몇몇 클라우드 제공업체들은 [**FastAPI를 후원하며**](../help-fastapi.md#sponsor-the-author){.internal-link target=_blank} ✨, 이를 통해 FastAPI와 FastAPI **생태계**가 지속적이고 건전한 **발전**을 할 수 있습니다.
    
    이는 FastAPI와 **커뮤니티** (여러분)에 대한 진정한 헌신을 보여줍니다. 그들은 여러분에게 **좋은 서비스**를 제공할 뿐 만이 아니라 여러분이 **훌륭하고 건강한 프레임워크인** FastAPI 를 사용하길 원하기 때문입니다. 🙇
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Jan 28 10:38:34 UTC 2024
    - 1.3K bytes
    - Viewed (0)
  3. tests/test_security_api_key_query_description.py

    from fastapi import Depends, FastAPI, Security
    from fastapi.security import APIKeyQuery
    from fastapi.testclient import TestClient
    from pydantic import BaseModel
    
    app = FastAPI()
    
    api_key = APIKeyQuery(name="key", description="API Key Query")
    
    
    class User(BaseModel):
        username: str
    
    
    def get_current_user(oauth_header: str = Security(api_key)):
        user = User(username=oauth_header)
        return user
    
    
    @app.get("/users/me")
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jun 30 18:25:16 UTC 2023
    - 2K bytes
    - Viewed (0)
  4. tests/test_security_http_base_optional.py

    from typing import Optional
    
    from fastapi import FastAPI, Security
    from fastapi.security.http import HTTPAuthorizationCredentials, HTTPBase
    from fastapi.testclient import TestClient
    
    app = FastAPI()
    
    security = HTTPBase(scheme="Other", auto_error=False)
    
    
    @app.get("/users/me")
    def read_current_user(
        credentials: Optional[HTTPAuthorizationCredentials] = Security(security),
    ):
        if credentials is None:
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jun 30 18:25:16 UTC 2023
    - 1.9K bytes
    - Viewed (0)
  5. tests/test_security_http_digest.py

    from fastapi import FastAPI, Security
    from fastapi.security import HTTPAuthorizationCredentials, HTTPDigest
    from fastapi.testclient import TestClient
    
    app = FastAPI()
    
    security = HTTPDigest()
    
    
    @app.get("/users/me")
    def read_current_user(credentials: HTTPAuthorizationCredentials = Security(security)):
        return {"scheme": credentials.scheme, "credentials": credentials.credentials}
    
    
    client = TestClient(app)
    
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jun 30 18:25:16 UTC 2023
    - 2K bytes
    - Viewed (0)
  6. tests/test_security_oauth2_authorization_code_bearer.py

    from typing import Optional
    
    from fastapi import FastAPI, Security
    from fastapi.security import OAuth2AuthorizationCodeBearer
    from fastapi.testclient import TestClient
    
    app = FastAPI()
    
    oauth2_scheme = OAuth2AuthorizationCodeBearer(
        authorizationUrl="authorize", tokenUrl="token", auto_error=True
    )
    
    
    @app.get("/items/")
    async def read_items(token: Optional[str] = Security(oauth2_scheme)):
        return {"token": token}
    
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jun 30 18:25:16 UTC 2023
    - 2.3K bytes
    - Viewed (0)
  7. docs/fr/docs/tutorial/first-steps.md

    `FastAPI` est une classe Python qui fournit toutes les fonctionnalités nécessaires au lancement de votre API.
    
    /// note | "Détails techniques"
    
    `FastAPI` est une classe héritant directement de `Starlette`.
    
    Vous pouvez donc aussi utiliser toutes les fonctionnalités de <a href="https://www.starlette.io/" class="external-link" target="_blank">Starlette</a> depuis `FastAPI`.
    
    ///
    
    ### Étape 2 : créer une "instance" `FastAPI`
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 10.3K bytes
    - Viewed (0)
  8. docs/pt/docs/tutorial/first-steps.md

    Você também pode usá-lo para gerar código automaticamente para clientes que se comunicam com sua API. Por exemplo, aplicativos front-end, móveis ou IoT.
    
    ## Recapitulando, passo a passo
    
    ### Passo 1: importe `FastAPI`
    
    ```Python hl_lines="1"
    {!../../docs_src/first_steps/tutorial001.py!}
    ```
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 9.6K bytes
    - Viewed (0)
  9. tests/test_invalid_sequence_param.py

    from typing import Dict, List, Optional, Tuple
    
    import pytest
    from fastapi import FastAPI, Query
    from pydantic import BaseModel
    
    
    def test_invalid_sequence():
        with pytest.raises(AssertionError):
            app = FastAPI()
    
            class Item(BaseModel):
                title: str
    
            @app.get("/items/")
            def read_items(q: List[Item] = Query(default=None)):
                pass  # pragma: no cover
    
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri May 13 23:38:22 UTC 2022
    - 1.2K bytes
    - Viewed (0)
  10. docs_src/static_files/tutorial001.py

    from fastapi import FastAPI
    from fastapi.staticfiles import StaticFiles
    
    app = FastAPI()
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Thu Mar 26 19:09:53 UTC 2020
    - 159 bytes
    - Viewed (0)
Back to top