Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 161 for from (0.31 sec)

  1. docs/ru/docs/tutorial/request-files.md

        **FastAPI** наследует `UploadFile` непосредственно из **Starlette**, но добавляет некоторые детали для совместимости с **Pydantic** и другими частями FastAPI.
    
    ## Про данные формы ("Form Data")
    
    Способ, которым HTML-формы (`<form></form>`) отправляют данные на сервер, обычно использует "специальную" кодировку для этих данных, отличную от JSON.
    
    **FastAPI** позаботится о том, чтобы считать эти данные из нужного места, а не из JSON.
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Wed Mar 13 19:02:19 GMT 2024
    - 15.4K bytes
    - Viewed (0)
  2. docs/ru/docs/tutorial/body-nested-models.md

    В Python версии 3.9 это будет выглядеть так:
    
    ```Python
    my_list: list[str]
    ```
    
    В версиях Python до 3.9 это будет выглядеть так:
    
    ```Python
    from typing import List
    
    my_list: List[str]
    ```
    
    Это всё стандартный синтаксис Python для объявления типов.
    
    Используйте этот же стандартный синтаксис для атрибутов модели с внутренними типами.
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri Mar 22 01:42:11 GMT 2024
    - 14.9K bytes
    - Viewed (0)
  3. docs/de/docs/advanced/behind-a-proxy.md

    Starten Sie nun Traefik:
    
    <div class="termy">
    
    ```console
    $ ./traefik --configFile=traefik.toml
    
    INFO[0000] Configuration loaded from file: /home/user/awesomeapi/traefik.toml
    ```
    
    </div>
    
    Und jetzt starten Sie Ihre Anwendung mit Uvicorn, indem Sie die Option `--root-path` verwenden:
    
    <div class="termy">
    
    ```console
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Sat Mar 30 20:30:07 GMT 2024
    - 13.1K bytes
    - Viewed (0)
  4. docs/en/docs/tutorial/request-files.md

        **FastAPI**'s `UploadFile` inherits directly from **Starlette**'s `UploadFile`, but adds some necessary parts to make it compatible with **Pydantic** and the other parts of FastAPI.
    
    ## What is "Form Data"
    
    The way HTML forms (`<form></form>`) sends the data to the server normally uses a "special" encoding for that data, it's different from JSON.
    
    **FastAPI** will make sure to read that data from the right place instead of JSON.
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Wed Mar 13 19:02:19 GMT 2024
    - 10.2K bytes
    - Viewed (0)
  5. tests/test_security_oauth2.py

    from dirty_equals import IsDict
    from fastapi import Depends, FastAPI, Security
    from fastapi.security import OAuth2, OAuth2PasswordRequestFormStrict
    from fastapi.testclient import TestClient
    from pydantic import BaseModel
    
    app = FastAPI()
    
    reusable_oauth2 = OAuth2(
        flows={
            "password": {
                "tokenUrl": "token",
                "scopes": {"read:users": "Read the users", "write:users": "Create users"},
            }
        }
    )
    
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 10.7K bytes
    - Viewed (0)
  6. tests/test_tutorial/test_request_forms_and_files/test_tutorial001.py

    import pytest
    from dirty_equals import IsDict
    from fastapi import FastAPI
    from fastapi.testclient import TestClient
    
    
    @pytest.fixture(name="app")
    def get_app():
        from docs_src.request_forms_and_files.tutorial001 import app
    
        return app
    
    
    @pytest.fixture(name="client")
    def get_client(app: FastAPI):
        client = TestClient(app)
        return client
    
    
    def test_post_form_no_body(client: TestClient):
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 9.8K bytes
    - Viewed (0)
  7. docs/ru/docs/tutorial/schema-extra-example.md

    ## Использование `example` и `examples` в OpenAPI
    
    При использовании любой из этих функций:
    
    * `Path()`
    * `Query()`
    * `Header()`
    * `Cookie()`
    * `Body()`
    * `Form()`
    * `File()`
    
    вы также можете добавить аргумент, содержащий `example` или группу `examples` с дополнительной информацией, которая будет добавлена в **OpenAPI**.
    
    ### Параметр `Body` с аргументом `example`
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri Mar 22 01:42:11 GMT 2024
    - 11.6K bytes
    - Viewed (0)
  8. docs/de/docs/tutorial/dependencies/index.md

        ```Python hl_lines="8-11"
        {!> ../../../docs_src/dependencies/tutorial001.py!}
        ```
    
    Das war's schon.
    
    **Zwei Zeilen**.
    
    Und sie hat die gleiche Form und Struktur wie alle Ihre *Pfadoperation-Funktionen*.
    
    Sie können sie sich als *Pfadoperation-Funktion* ohne den „Dekorator“ (ohne `@app.get("/some-path")`) vorstellen.
    
    Und sie kann alles zurückgeben, was Sie möchten.
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Sat Mar 30 18:01:10 GMT 2024
    - 13.1K bytes
    - Viewed (0)
  9. docs/vi/docs/index.md

    Bây giờ sửa tệp tin `main.py` để nhận body từ một request `PUT`.
    
    Định nghĩa của body sử dụng kiểu dữ liệu chuẩn của Python, cảm ơn Pydantic.
    
    ```Python hl_lines="4  9-12  25-27"
    from typing import Union
    
    from fastapi import FastAPI
    from pydantic import BaseModel
    
    app = FastAPI()
    
    
    class Item(BaseModel):
        name: str
        price: float
        is_offer: Union[bool, None] = None
    
    
    @app.get("/")
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Mon Apr 29 05:18:04 GMT 2024
    - 21.9K bytes
    - Viewed (0)
  10. docs/de/docs/tutorial/response-model.md

    * In der OpenAPI *Pfadoperation* ein **JSON-Schema** für die Response hinzuzufügen.
        * Dieses wird von der **automatischen Dokumentation** verwendet.
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Sat Mar 30 20:26:58 GMT 2024
    - 19.9K bytes
    - Viewed (0)
Back to top