Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 21 - 30 of 92 for johndoe (0.18 seconds)

  1. docs_src/path_operation_configuration/tutorial002_py310.py

    
    @app.get("/items/", tags=["items"])
    async def read_items():
        return [{"name": "Foo", "price": 42}]
    
    
    @app.get("/users/", tags=["users"])
    async def read_users():
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Wed Feb 04 12:07:26 GMT 2026
    - 524 bytes
    - Click Count (0)
  2. docs/zh-hant/docs/tutorial/path-params.md

      "message": "Deep Learning FTW!"
    }
    ```
    
    ## 包含路徑的路徑參數 { #path-parameters-containing-paths }
    
    假設你有一個路徑為 `/files/{file_path}` 的「路徑操作」。
    
    但你需要 `file_path` 本身就包含一個「路徑」,像是 `home/johndoe/myfile.txt`。
    
    所以,該檔案的 URL 會是:`/files/home/johndoe/myfile.txt`。
    
    ### OpenAPI 支援 { #openapi-support }
    
    OpenAPI 並不支援直接宣告一個「路徑參數」內再包含一個「路徑」,因為那會導致難以測試與定義的情況。
    
    然而,你仍可在 **FastAPI** 中這樣做,方法是使用 Starlette 的其中一個內部工具。
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:05:38 GMT 2026
    - 8.4K bytes
    - Click Count (0)
  3. docs/en/docs/tutorial/security/simple-oauth2.md

    Now use the operation `GET` with the path `/users/me`.
    
    You will get your user's data, like:
    
    ```JSON
    {
      "username": "johndoe",
      "email": "johndoe@example.com",
      "full_name": "John Doe",
      "disabled": false,
      "hashed_password": "fakehashedsecret"
    }
    ```
    
    <img src="/img/tutorial/security/image06.png">
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Mar 05 18:13:19 GMT 2026
    - 9.4K bytes
    - Click Count (0)
  4. docs/en/docs/tutorial/security/oauth2-jwt.md

    Using the credentials:
    
    Username: `johndoe`
    Password: `secret`
    
    /// check
    
    Notice that nowhere in the code is the plaintext password "`secret`", we only have the hashed version.
    
    ///
    
    <img src="/img/tutorial/security/image08.png">
    
    Call the endpoint `/users/me/`, you will get the response as:
    
    ```JSON
    {
      "username": "johndoe",
      "email": "johndoe@example.com",
      "full_name": "John Doe",
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Thu Mar 05 18:13:19 GMT 2026
    - 10.7K bytes
    - Click Count (0)
  5. docs/ja/docs/tutorial/path-params.md

    }
    ```
    
    ## パスを含んだパスパラメータ { #path-parameters-containing-paths }
    
    パス `/files/{file_path}` となる *path operation* を持っているとしましょう。
    
    ただし、 `home/johndoe/myfile.txt` のような*パス*を含んだ `file_path` が必要です。
    
    したがって、そのファイルのURLは `/files/home/johndoe/myfile.txt` の様になります。
    
    ### OpenAPIサポート { #openapi-support }
    
    OpenAPIはテストや定義が困難なシナリオにつながる可能性があるため、内部に*パス*を含む*パスパラメータ*の宣言をサポートしていません。
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 14:07:17 GMT 2026
    - 10.8K bytes
    - Click Count (0)
  6. docs/zh-hant/docs/tutorial/security/simple-oauth2.md

    點選「Authorize」按鈕。
    
    使用下列帳密:
    
    User: `johndoe`
    
    Password: `secret`
    
    <img src="/img/tutorial/security/image04.png">
    
    在系統中完成驗證後,你會看到如下畫面:
    
    <img src="/img/tutorial/security/image05.png">
    
    ### 取得自己的使用者資料 { #get-your-own-user-data }
    
    現在使用 `GET` 方法呼叫路徑 `/users/me`。
    
    你會取得自己的使用者資料,如:
    
    ```JSON
    {
      "username": "johndoe",
      "email": "johndoe@example.com",
      "full_name": "John Doe",
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:05:38 GMT 2026
    - 9.1K bytes
    - Click Count (0)
  7. docs/zh/docs/tutorial/security/simple-oauth2.md

    点击“Authorize”按钮。
    
    使用以下凭证:
    
    用户名:`johndoe`
    
    密码:`secret`
    
    <img src="/img/tutorial/security/image04.png">
    
    通过身份验证后,显示下图所示的内容:
    
    <img src="/img/tutorial/security/image05.png">
    
    ### 获取当前用户数据 { #get-your-own-user-data }
    
    使用 `/users/me` 路径的 `GET` 操作。
    
    可以提取如下当前用户数据:
    
    ```JSON
    {
      "username": "johndoe",
      "email": "johndoe@example.com",
      "full_name": "John Doe",
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:06:37 GMT 2026
    - 9K bytes
    - Click Count (0)
  8. docs/zh-hant/docs/tutorial/security/oauth2-jwt.md

    用和先前相同的方式授權應用。
    
    使用下列認證資訊:
    
    Username: `johndoe`
    Password: `secret`
    
    /// check | 檢查
    
    注意在程式碼中完全沒有明文密碼「`secret`」,我們只有雜湊後的版本。
    
    ///
    
    <img src="/img/tutorial/security/image08.png">
    
    呼叫端點 `/users/me/`,你會得到類似這樣的回應:
    
    ```JSON
    {
      "username": "johndoe",
      "email": "johndoe@example.com",
      "full_name": "John Doe",
      "disabled": false
    }
    ```
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:05:38 GMT 2026
    - 10.1K bytes
    - Click Count (0)
  9. docs/zh/docs/tutorial/security/oauth2-jwt.md

    像之前一样进行授权。
    
    使用以下凭证:
    
    用户名: `johndoe`
    密码: `secret`
    
    /// check | 检查
    
    注意,代码中的任何地方都没有明文密码 “`secret`”,我们只有它的哈希版本。
    
    ///
    
    <img src="/img/tutorial/security/image08.png">
    
    调用 `/users/me/` 端点,你将得到如下响应:
    
    ```JSON
    {
      "username": "johndoe",
      "email": "johndoe@example.com",
      "full_name": "John Doe",
      "disabled": false
    }
    ```
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:06:37 GMT 2026
    - 10.1K bytes
    - Click Count (0)
  10. docs/ja/docs/tutorial/security/simple-oauth2.md

    「Authorize」ボタンをクリックします。
    
    次の認証情報を使います:
    
    User: `johndoe`
    
    Password: `secret`
    
    <img src="/img/tutorial/security/image04.png">
    
    システムで認証されると、次のように表示されます:
    
    <img src="/img/tutorial/security/image05.png">
    
    ### 自分のユーザーデータを取得 { #get-your-own-user-data }
    
    `GET` の path `/users/me` を使います。
    
    次のようなユーザーデータが取得できます:
    
    ```JSON
    {
      "username": "johndoe",
      "email": "******@****.***",
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 14:07:17 GMT 2026
    - 12.1K bytes
    - Click Count (0)
Back to Top