Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 361 for app (0.08 sec)

  1. docs/em/docs/tutorial/bigger-applications.md

    ```
    
    ///
    
    *  `app` ๐Ÿ“ ๐Ÿ”Œ ๐ŸŒ. & โšซ๏ธ โœ”๏ธ ๐Ÿ› ๐Ÿ“ `app/__init__.py`, โšซ๏ธ "๐Ÿ ๐Ÿ“ฆ" (๐Ÿ—ƒ "๐Ÿ ๐Ÿ•น"): `app`.
    * โšซ๏ธ ๐Ÿ”Œ `app/main.py` ๐Ÿ“. โšซ๏ธ ๐Ÿ”˜ ๐Ÿ ๐Ÿ“ฆ (๐Ÿ“ โฎ๏ธ ๐Ÿ“ `__init__.py`), โšซ๏ธ "๐Ÿ•น" ๐Ÿ‘ˆ ๐Ÿ“ฆ: `app.main`.
    * ๐Ÿ“ค `app/dependencies.py` ๐Ÿ“, ๐Ÿ’– `app/main.py`, โšซ๏ธ "๐Ÿ•น": `app.dependencies`.
    * ๐Ÿ“ค ๐Ÿ“ `app/routers/` โฎ๏ธ โž•1๏ธโƒฃ ๐Ÿ“ `__init__.py`, โšซ๏ธ "๐Ÿ ๐Ÿ“ฆ": `app.routers`.
    * ๐Ÿ“ `app/routers/items.py` ๐Ÿ”˜ ๐Ÿ“ฆ, `app/routers/`,, โšซ๏ธ ๐Ÿ”: `app.routers.items`.
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 15.5K bytes
    - Viewed (0)
  2. docs/en/docs/tutorial/bigger-applications.md

    * There's also an `app/dependencies.py` file, just like `app/main.py`, it is a "module": `app.dependencies`.
    * There's a subdirectory `app/routers/` with another file `__init__.py`, so it's a "Python subpackage": `app.routers`.
    * The file `app/routers/items.py` is inside a package, `app/routers/`, so, it's a submodule: `app.routers.items`.
    * The same with `app/routers/users.py`, it's another submodule: `app.routers.users`.
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 18.4K bytes
    - Viewed (0)
  3. tests/test_dependency_contextmanager.py

            yield state
        finally:
            state["context_b"] = f"finished b with a: {state['context_a']}"
    
    
    @app.get("/async")
    async def get_async(state: str = Depends(asyncgen_state)):
        return state
    
    
    @app.get("/sync")
    async def get_sync(state: str = Depends(generator_state)):
        return state
    
    
    @app.get("/async_raise")
    async def get_async_raise(state: str = Depends(asyncgen_state_try)):
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat Aug 17 04:13:50 UTC 2024
    - 11.6K bytes
    - Viewed (0)
  4. docs/em/docs/advanced/behind-a-proxy.md

    & โšซ๏ธ โš™๏ธ ๐Ÿ”˜ ๐Ÿ•โ” ๐Ÿ—œ ๐ŸŽง-๐Ÿˆธ.
    
    ## ๐Ÿ—ณ โฎ๏ธ ๐ŸŽž โžก ๐Ÿ”ก
    
    โœ”๏ธ ๐Ÿ—ณ โฎ๏ธ ๐ŸŽž โžก ๐Ÿ”ก, ๐Ÿ‘‰ ๐Ÿ’ผ, โ›“ ๐Ÿ‘ˆ ๐Ÿ‘† ๐Ÿ’ช ๐Ÿ“ฃ โžก `/app` ๐Ÿ‘† ๐Ÿ“Ÿ, โœ‹๏ธ โคด๏ธ, ๐Ÿ‘† ๐Ÿšฎ ๐Ÿงฝ ๐Ÿ”› ๐Ÿ” (๐Ÿ—ณ) ๐Ÿ‘ˆ ๐Ÿ”œ ๐Ÿšฎ ๐Ÿ‘† **FastAPI** ๐Ÿˆธ ๐Ÿ”ฝ โžก ๐Ÿ’– `/api/v1`.
    
    ๐Ÿ‘‰ ๐Ÿ’ผ, โฎ๏ธ โžก `/app` ๐Ÿ”œ ๐Ÿค™ ๐Ÿฆ `/api/v1/app`.
    
    โœ‹๏ธ ๐ŸŒ ๐Ÿ‘† ๐Ÿ“Ÿ โœ ๐Ÿค” ๐Ÿ“ค `/app`.
    
    & ๐Ÿ—ณ ๐Ÿ”œ **"โŽ"** **โžก ๐Ÿ”ก** ๐Ÿ”› โœˆ โญ ๐Ÿ“ถ ๐Ÿ“จ Uvicorn, ๐Ÿšง ๐Ÿ‘† ๐Ÿˆธ ๐Ÿค” ๐Ÿ‘ˆ โšซ๏ธ ๐Ÿฆ `/app`, ๐Ÿ‘ˆ ๐Ÿ‘† ๐Ÿšซ โœ”๏ธ โ„น ๐ŸŒ ๐Ÿ‘† ๐Ÿ“Ÿ ๐Ÿ”Œ ๐Ÿ”ก `/api/v1`.
    
    ๐Ÿ†™ ๐Ÿ“ฅ, ๐ŸŒ ๐Ÿ”œ ๐Ÿ‘ท ๐Ÿ›Ž.
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 10.1K bytes
    - Viewed (0)
  5. docs/pt/docs/advanced/behind-a-proxy.md

          prefixes = ["/api/v1"]
    
      [http.routers]
    
        [http.routers.app-http]
          entryPoints = ["http"]
          service = "app"
          rule = "PathPrefix(`/api/v1`)"
          middlewares = ["api-stripprefix"]
    
      [http.services]
    
        [http.services.app]
          [http.services.app.loadBalancer]
            [[http.services.app.loadBalancer.servers]]
              url = "http://127.0.0.1:8000"
    ```
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 27 15:28:18 UTC 2024
    - 12.2K bytes
    - Viewed (0)
  6. docs/em/docs/deployment/docker.md

    # (2)
    CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "80"]
    ```
    
    1๏ธโƒฃ. ๐Ÿ“ `main.py` ๐Ÿ“ `/code` ๐Ÿ“ ๐Ÿ”— (๐Ÿต ๐Ÿ™† `./app` ๐Ÿ“).
    
    2๏ธโƒฃ. ๐Ÿƒ Uvicorn & ๐Ÿ’ฌ โšซ๏ธ ๐Ÿ—„ `app` ๐ŸŽš โšช๏ธโžก๏ธ `main` (โ†ฉ๏ธ ๐Ÿญ โšช๏ธโžก๏ธ `app.main`).
    
    โคด๏ธ ๐Ÿ”† Uvicorn ๐Ÿ“‹ โš™๏ธ ๐Ÿ†• ๐Ÿ•น `main` โ†ฉ๏ธ `app.main` ๐Ÿ—„ FastAPI ๐ŸŽš `app`.
    
    ## ๐Ÿ› ๏ธ ๐Ÿ”ง
    
    โžก๏ธ ๐Ÿ’ฌ ๐Ÿ”„ ๐Ÿ”ƒ ๐ŸŽ [๐Ÿ› ๏ธ ๐Ÿ”ง](concepts.md){.internal-link target=_blank} โš– ๐Ÿ“ฆ.
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Mon Aug 12 21:47:53 UTC 2024
    - 27.9K bytes
    - Viewed (0)
  7. tests/test_response_by_alias.py

    
    @app.get("/by-alias/dict", response_model=Model)
    def by_alias_dict():
        return {"alias": "Foo"}
    
    
    @app.get("/by-alias/model", response_model=Model)
    def by_alias_model():
        return Model(alias="Foo")
    
    
    @app.get("/by-alias/list", response_model=List[Model])
    def by_alias_list():
        return [{"alias": "Foo"}, {"alias": "Bar"}]
    
    
    @app.get("/no-alias/dict", response_model=ModelNoAlias)
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jul 07 17:12:13 UTC 2023
    - 11.1K bytes
    - Viewed (0)
  8. docs/ko/docs/tutorial/first-steps.md

    ์ด๊ฒƒ์ด "**๊ฒฝ๋กœ ์ž‘๋™ ๋ฐ์ฝ”๋ ˆ์ดํ„ฐ**"์ž…๋‹ˆ๋‹ค.
    
    ///
    
    ๋‹ค๋ฅธ ์ž‘๋™๋„ ์‚ฌ์šฉํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค:
    
    * `@app.post()`
    * `@app.put()`
    * `@app.delete()`
    
    ํ”ํžˆ ์‚ฌ์šฉ๋˜์ง€ ์•Š๋Š” ๊ฒƒ๋“ค๋„ ์žˆ์Šต๋‹ˆ๋‹ค:
    
    * `@app.options()`
    * `@app.head()`
    * `@app.patch()`
    * `@app.trace()`
    
    /// tip | "ํŒ"
    
    ๊ฐ ์ž‘๋™(HTTP ๋ฉ”์†Œ๋“œ)์„ ์›ํ•˜๋Š” ๋Œ€๋กœ ์‚ฌ์šฉํ•ด๋„ ๋ฉ๋‹ˆ๋‹ค.
    
    **FastAPI**๋Š” ํŠน์ • ์˜๋ฏธ๋ฅผ ๊ฐ•์ œํ•˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค.
    
    ์—ฌ๊ธฐ์„œ ์ •๋ณด๋Š” ์ง€์นจ์„œ์ผ๋ฟ ๊ฐ•์ œ์‚ฌํ•ญ์ด ์•„๋‹™๋‹ˆ๋‹ค.
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 10.4K bytes
    - Viewed (0)
  9. docs/zh/docs/tutorial/bigger-applications.md

    ///
    
    * `app` ็›ฎๅฝ•ๅŒ…ๅซไบ†ๆ‰€ๆœ‰ๅ†…ๅฎนใ€‚ๅนถไธ”ๅฎƒๆœ‰ไธ€ไธช็ฉบๆ–‡ไปถ `app/__init__.py`๏ผŒๅ› ๆญคๅฎƒๆ˜ฏไธ€ไธชใ€ŒPython ๅŒ…ใ€๏ผˆใ€ŒPython ๆจกๅ—ใ€็š„้›†ๅˆ๏ผ‰๏ผš`app`ใ€‚
    * ๅฎƒๅŒ…ๅซไธ€ไธช `app/main.py` ๆ–‡ไปถใ€‚็”ฑไบŽๅฎƒไฝไบŽไธ€ไธช Python ๅŒ…๏ผˆไธ€ไธชๅŒ…ๅซ `__init__.py` ๆ–‡ไปถ็š„็›ฎๅฝ•๏ผ‰ไธญ๏ผŒๅ› ๆญคๅฎƒๆ˜ฏ่ฏฅๅŒ…็š„ไธ€ไธชใ€Œๆจกๅ—ใ€๏ผš`app.main`ใ€‚
    * ่ฟ˜ๆœ‰ไธ€ไธช `app/dependencies.py` ๆ–‡ไปถ๏ผŒๅฐฑๅƒ `app/main.py` ไธ€ๆ ท๏ผŒๅฎƒๆ˜ฏไธ€ไธชใ€Œๆจกๅ—ใ€๏ผš`app.dependencies`ใ€‚
    * ๆœ‰ไธ€ไธชๅญ็›ฎๅฝ• `app/routers/` ๅŒ…ๅซๅฆไธ€ไธช `__init__.py` ๆ–‡ไปถ๏ผŒๅ› ๆญคๅฎƒๆ˜ฏไธ€ไธชใ€ŒPython ๅญๅŒ…ใ€๏ผš`app.routers`ใ€‚
    * ๆ–‡ไปถ `app/routers/items.py` ไฝไบŽ `app/routers/` ๅŒ…ไธญ๏ผŒๅ› ๆญคๅฎƒๆ˜ฏไธ€ไธชๅญๆจกๅ—๏ผš`app.routers.items`ใ€‚
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 18.4K bytes
    - Viewed (0)
  10. tests/test_dependency_overrides.py

    from fastapi.testclient import TestClient
    
    app = FastAPI()
    
    router = APIRouter()
    
    
    async def common_parameters(q: str, skip: int = 0, limit: int = 100):
        return {"q": q, "skip": skip, "limit": limit}
    
    
    @app.get("/main-depends/")
    async def main_depends(commons: dict = Depends(common_parameters)):
        return {"in": "main-depends", "params": commons}
    
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Thu Apr 18 19:40:57 UTC 2024
    - 15.4K bytes
    - Viewed (0)
Back to top