Search Options

Results per page
Sort
Preferred Languages
Advance

Results 111 - 120 of 332 for Cookie2 (0.11 sec)

  1. docs_src/cookie_params/tutorial001.py

    from typing import Union
    
    from fastapi import Cookie, FastAPI
    
    app = FastAPI()
    
    
    @app.get("/items/")
    async def read_items(ads_id: Union[str, None] = Cookie(default=None)):
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Fri May 13 23:38:22 UTC 2022
    - 202 bytes
    - Viewed (0)
  2. docs/es/docs/advanced/response-change-status-code.md

    Para esos casos, puedes usar un parámetro `Response`.
    
    ## Usar un parámetro `Response`
    
    Puedes declarar un parámetro de tipo `Response` en tu *función de la operación de path* (como puedes hacer para cookies y headers).
    
    Y luego puedes establecer el `status_code` en ese objeto de respuesta *temporal*.
    
    ```Python hl_lines="1  9  12"
    {!../../../docs_src/response_change_status_code/tutorial001.py!}
    ```
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Tue Feb 06 19:56:23 UTC 2024
    - 1.6K bytes
    - Viewed (0)
  3. docs/ru/docs/tutorial/header-params.md

    # Header-параметры
    
    Вы можете определить параметры заголовка таким же образом, как вы определяете параметры `Query`, `Path` и `Cookie`.
    
    ## Импорт `Header`
    
    Сперва импортируйте `Header`:
    
    === "Python 3.10+"
    
        ```Python hl_lines="3"
        {!> ../../../docs_src/header_params/tutorial001_an_py310.py!}
        ```
    
    === "Python 3.9+"
    
        ```Python hl_lines="3"
        {!> ../../../docs_src/header_params/tutorial001_an_py39.py!}
        ```
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Tue Oct 17 05:59:11 UTC 2023
    - 8.7K bytes
    - Viewed (0)
  4. fastapi/__init__.py

    from .exceptions import HTTPException as HTTPException
    from .exceptions import WebSocketException as WebSocketException
    from .param_functions import Body as Body
    from .param_functions import Cookie as Cookie
    from .param_functions import Depends as Depends
    from .param_functions import File as File
    from .param_functions import Form as Form
    from .param_functions import Header as Header
    from .param_functions import Path as Path
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Thu May 02 22:50:18 UTC 2024
    - 1.1K bytes
    - Viewed (0)
  5. doc/next/6-stdlib/99-minor/net/http/61472.md

    The new [Request.CookiesNamed] method retrieves all cookies that match the given name....
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Mar 20 18:08:20 UTC 2024
    - 87 bytes
    - Viewed (0)
  6. docs_src/websockets/tutorial002_an_py310.py

    from typing import Annotated
    
    from fastapi import (
        Cookie,
        Depends,
        FastAPI,
        Query,
        WebSocket,
        WebSocketException,
        status,
    )
    from fastapi.responses import HTMLResponse
    
    app = FastAPI()
    
    html = """
    <!DOCTYPE html>
    <html>
        <head>
            <title>Chat</title>
        </head>
        <body>
            <h1>WebSocket Chat</h1>
            <form action="" onsubmit="sendMessage(event)">
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Sat Mar 18 12:29:59 UTC 2023
    - 2.8K bytes
    - Viewed (0)
  7. docs_src/websockets/tutorial002_py310.py

    from fastapi import (
        Cookie,
        Depends,
        FastAPI,
        Query,
        WebSocket,
        WebSocketException,
        status,
    )
    from fastapi.responses import HTMLResponse
    
    app = FastAPI()
    
    html = """
    <!DOCTYPE html>
    <html>
        <head>
            <title>Chat</title>
        </head>
        <body>
            <h1>WebSocket Chat</h1>
            <form action="" onsubmit="sendMessage(event)">
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Sat Mar 18 12:29:59 UTC 2023
    - 2.7K bytes
    - Viewed (0)
  8. docs/de/docs/tutorial/header-params.md

    # Header-Parameter
    
    So wie `Query`-, `Path`-, und `Cookie`-Parameter können Sie auch <abbr title='Header – Kopfzeilen, Header, Header-Felder: Schlüssel-Wert-Metadaten, die vom Client beim Request, und vom Server bei der Response gesendet werden'>Header</abbr>-Parameter definieren.
    
    ## `Header` importieren
    
    Importieren Sie zuerst `Header`:
    
    === "Python 3.10+"
    
        ```Python hl_lines="3"
        {!> ../../../docs_src/header_params/tutorial001_an_py310.py!}
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Sat Mar 30 18:00:50 UTC 2024
    - 6.4K bytes
    - Viewed (0)
  9. docs/zh/docs/tutorial/header-params.md

        ```
    
    !!! note "技术细节"
    
        `Header` 是 `Path`、`Query`、`Cookie` 的**兄弟类**,都继承自共用的 `Param` 类。
    
        注意,从 `fastapi` 导入的 `Query`、`Path`、`Header` 等对象,实际上是返回特殊类的函数。
    
    !!! info "说明"
    
        必须使用 `Header` 声明 header 参数,否则该参数会被解释为查询参数。
    
    ## 自动转换
    
    `Header` 比 `Path`、`Query` 和 `Cookie` 提供了更多功能。
    
    大部分标准请求头用**连字符**分隔,即**减号**(`-`)。
    
    但是 `user-agent` 这样的变量在 Python 中是无效的。
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Sat Mar 30 22:42:51 UTC 2024
    - 5.4K bytes
    - Viewed (0)
  10. pilot/pkg/security/authz/builder/testdata/http/custom-http-provider-out2.yaml

        authorizationResponse:
          allowedClientHeaders:
            patterns:
            - exact: Set-cookie
              ignoreCase: true
            - ignoreCase: true
              prefix: x-prefix-
            - ignoreCase: true
              suffix: -suffix
          allowedClientHeadersOnSuccess:
            patterns:
            - exact: Set-cookie
              ignoreCase: true
            - ignoreCase: true
              prefix: x-prefix-
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Mar 20 12:45:43 UTC 2023
    - 1.6K bytes
    - Viewed (0)
Back to top