Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 871 for code (0.15 sec)

  1. docs/em/docs/tutorial/response-status-code.md

    ๐ŸŽ ๐ŸŒŒ ๐Ÿ‘† ๐Ÿ’ช โœ” ๐Ÿ“จ ๐Ÿท, ๐Ÿ‘† ๐Ÿ’ช ๐Ÿ“ฃ ๐Ÿ‡บ๐Ÿ‡ธ๐Ÿ” ๐Ÿ‘” ๐Ÿ“Ÿ โš™๏ธ ๐Ÿ“จ โฎ๏ธ ๐Ÿ”ข `status_code` ๐Ÿ™† *โžก ๐Ÿ› ๏ธ*:
    
    * `@app.get()`
    * `@app.post()`
    * `@app.put()`
    * `@app.delete()`
    * โ™’๏ธ.
    
    ```Python hl_lines="6"
    {!../../../docs_src/response_status_code/tutorial001.py!}
    ```
    
    !!! note
        ๐Ÿ‘€ ๐Ÿ‘ˆ `status_code` ๐Ÿ”ข "๐Ÿ‘จโ€๐ŸŽจ" ๐Ÿ‘ฉโ€๐Ÿ”ฌ (`get`, `post`, โ™’๏ธ). ๐Ÿšซ ๐Ÿ‘† *โžก ๐Ÿ› ๏ธ ๐Ÿ”ข*, ๐Ÿ’– ๐ŸŒ ๐Ÿ”ข & ๐Ÿ’ช.
    
    `status_code` ๐Ÿ”ข ๐Ÿ“จ ๐Ÿ”ข โฎ๏ธ ๐Ÿ‡บ๐Ÿ‡ธ๐Ÿ” ๐Ÿ‘” ๐Ÿ“Ÿ.
    
    !!! info
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Apr 01 09:26:04 GMT 2023
    - 3.4K bytes
    - Viewed (0)
  2. docs/ko/docs/tutorial/response-status-code.md

    # ์‘๋‹ต ์ƒํƒœ ์ฝ”๋“œ
    
    ์‘๋‹ต ๋ชจ๋ธ๊ณผ ๊ฐ™์€ ๋ฐฉ๋ฒ•์œผ๋กœ, ์–ด๋–ค *๊ฒฝ๋กœ ์ž‘๋™*์ด๋“  `status_code` ๋งค๊ฐœ๋ณ€์ˆ˜๋ฅผ ์‚ฌ์šฉํ•˜์—ฌ ์‘๋‹ต์— ๋Œ€ํ•œ HTTP ์ƒํƒœ ์ฝ”๋“œ๋ฅผ ์„ ์–ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.
    
    * `@app.get()`
    * `@app.post()`
    * `@app.put()`
    * `@app.delete()`
    * ๊ธฐํƒ€
    
    ```Python hl_lines="6"
    {!../../../docs_src/response_status_code/tutorial001.py!}
    ```
    
    !!! note "์ฐธ๊ณ "
        `status_code` ๋Š” "๋ฐ์ฝ”๋ ˆ์ดํ„ฐ" ๋ฉ”์†Œ๋“œ(`get`, `post` ๋“ฑ)์˜ ๋งค๊ฐœ๋ณ€์ˆ˜์ž…๋‹ˆ๋‹ค. ๋ชจ๋“  ๋งค๊ฐœ๋ณ€์ˆ˜๋“ค๊ณผ ๋ณธ๋ฌธ์ฒ˜๋Ÿผ *๊ฒฝ๋กœ ์ž‘๋™ ํ•จ์ˆ˜*๊ฐ€ ์•„๋‹™๋‹ˆ๋‹ค.
    
    `status_code` ๋งค๊ฐœ๋ณ€์ˆ˜๋Š” HTTP ์ƒํƒœ ์ฝ”๋“œ๋ฅผ ์ˆซ์ž๋กœ ์ž…๋ ฅ๋ฐ›์Šต๋‹ˆ๋‹ค.
    
    !!! info "์ •๋ณด"
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu May 12 00:06:16 GMT 2022
    - 4.8K bytes
    - Viewed (0)
  3. docs/em/docs/advanced/response-change-status-code.md

    & โคด๏ธ ๐Ÿ‘† ๐Ÿ’ช โš’ `status_code` ๐Ÿ‘ˆ *๐Ÿ”€* ๐Ÿ“จ ๐ŸŽš.
    
    ```Python hl_lines="1  9  12"
    {!../../../docs_src/response_change_status_code/tutorial001.py!}
    ```
    
    & โคด๏ธ ๐Ÿ‘† ๐Ÿ’ช ๐Ÿ“จ ๐Ÿ™† ๐ŸŽš ๐Ÿ‘† ๐Ÿ’ช, ๐Ÿ‘† ๐Ÿ›Ž ๐Ÿ”œ ( `dict`, ๐Ÿ’ฝ ๐Ÿท, โ™’๏ธ).
    
    & ๐Ÿšฅ ๐Ÿ‘† ๐Ÿ“ฃ `response_model`, โšซ๏ธ ๐Ÿ”œ โš™๏ธ โ›ฝ & ๐Ÿ—œ ๐ŸŽš ๐Ÿ‘† ๐Ÿ“จ.
    
    **FastAPI** ๐Ÿ”œ โš™๏ธ ๐Ÿ‘ˆ *๐Ÿ”€* ๐Ÿ“จ โš— ๐Ÿ‘” ๐Ÿ“Ÿ (๐Ÿช & ๐ŸŽš), & ๐Ÿ”œ ๐Ÿšฎ ๐Ÿ‘ซ ๐Ÿ ๐Ÿ“จ ๐Ÿ‘ˆ ๐Ÿ”Œ ๐Ÿ’ฒ ๐Ÿ‘† ๐Ÿ“จ, โ›ฝ ๐Ÿ™† `response_model`.
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Apr 01 09:26:04 GMT 2023
    - 1.2K bytes
    - Viewed (0)
  4. docs/ru/docs/tutorial/response-status-code.md

    ะ’ั‹ ะผะพะถะตั‚ะต ะทะฐะดะฐั‚ัŒ HTTP ะบะพะด ัั‚ะฐั‚ัƒัะฐ ะพั‚ะฒะตั‚ะฐ ั ะฟะพะผะพั‰ัŒัŽ ะฟะฐั€ะฐะผะตั‚ั€ะฐ `status_code` ะฟะพะดะพะฑะฝะพ ั‚ะพะผัƒ, ะบะฐะบ ะฒั‹ ะพะฟั€ะตะดะตะปัะตั‚ะต ัั…ะตะผัƒ ะพั‚ะฒะตั‚ะฐ ะฒ ะปัŽะฑะพะน ะธะท *ะพะฟะตั€ะฐั†ะธะน ะฟัƒั‚ะธ*:
    
    * `@app.get()`
    * `@app.post()`
    * `@app.put()`
    * `@app.delete()`
    * ะธ ะดั€ัƒะณะธั….
    
    ```Python hl_lines="6"
    {!../../../docs_src/response_status_code/tutorial001.py!}
    ```
    
    !!! note "ะŸั€ะธะผะตั‡ะฐะฝะธะต"
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Apr 25 18:44:34 GMT 2023
    - 7K bytes
    - Viewed (0)
  5. docs/en/docs/advanced/response-change-status-code.md

    You probably read before that you can set a default [Response Status Code](../tutorial/response-status-code.md){.internal-link target=_blank}.
    
    But in some cases you need to return a different status code than the default.
    
    ## Use case
    
    For example, imagine that you want to return an HTTP status code of "OK" `200` by default.
    
    But if the data didn't exist, you want to create it, and return an HTTP status code of "CREATED" `201`.
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Jan 11 16:31:18 GMT 2024
    - 1.5K bytes
    - Viewed (0)
  6. docs/es/docs/advanced/response-change-status-code.md

    # Response - Cambiar el Status Code
    
    Probablemente ya has leรญdo con anterioridad que puedes establecer un [Response Status Code](../tutorial/response-status-code.md){.internal-link target=_blank} por defecto.
    
    Pero en algunos casos necesitas retornar un status code diferente al predeterminado.
    
    ## Casos de uso
    
    Por ejemplo, imagina que quieres retornar un HTTP status code de "OK" `200` por defecto.
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Feb 06 19:56:23 GMT 2024
    - 1.6K bytes
    - Viewed (0)
  7. docs/de/docs/advanced/response-change-status-code.md

    AnschlieรŸend kรถnnen Sie den `status_code` in diesem *vorรผbergehenden* Response-Objekt festlegen.
    
    ```Python hl_lines="1  9  12"
    {!../../../docs_src/response_change_status_code/tutorial001.py!}
    ```
    
    Und dann kรถnnen Sie wie gewohnt jedes benรถtigte Objekt zurรผckgeben (ein `dict`, ein Datenbankmodell usw.).
    
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Mar 30 20:18:58 GMT 2024
    - 1.8K bytes
    - Viewed (0)
  8. tests/test_response_code_no_body.py

    client = TestClient(app)
    
    
    def test_get_response():
        response = client.get("/a")
        assert response.status_code == 204, response.text
        assert "content-length" not in response.headers
        assert response.content == b""
    
    
    def test_openapi_schema():
        response = client.get("/openapi.json")
        assert response.status_code == 200, response.text
        assert response.json() == {
            "openapi": "3.1.0",
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Fri Jun 30 18:25:16 GMT 2023
    - 3.2K bytes
    - Viewed (0)
  9. docs/en/docs/tutorial/response-status-code.md

    # Response Status Code
    
    The same way you can specify a response model, you can also declare the HTTP status code used for the response with the parameter `status_code` in any of the *path operations*:
    
    * `@app.get()`
    * `@app.post()`
    * `@app.put()`
    * `@app.delete()`
    * etc.
    
    ```Python hl_lines="6"
    {!../../../docs_src/response_status_code/tutorial001.py!}
    ```
    
    !!! note
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Aug 29 14:02:58 GMT 2020
    - 4K bytes
    - Viewed (0)
  10. docs/de/docs/tutorial/response-status-code.md

    * `@app.get()`
    * `@app.post()`
    * `@app.put()`
    * `@app.delete()`
    * usw.
    
    ```Python hl_lines="6"
    {!../../../docs_src/response_status_code/tutorial001.py!}
    ```
    
    !!! note "Hinweis"
    Plain Text
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Apr 02 02:32:57 GMT 2024
    - 4.7K bytes
    - Viewed (0)
Back to top